Am5os
 All Classes Functions Pages
Public Member Functions | Static Public Member Functions | List of all members
Scenario Class Referenceabstract
Inheritance diagram for Scenario:
[legend]

Public Member Functions

virtual bool Detect (FrameDetectionData detected_objects)=0
 
virtual std::string GetScenarioInformation ()=0
 

Static Public Member Functions

static float ComputeDistance (Element first, Element second)
 
static float ComputeCenterDistance (Element first, Element second)
 
static bool DoOverlap (Element first, Element second)
 
static bool DoContain (Element big, Element small)
 

Member Function Documentation

float Scenario::ComputeCenterDistance ( Element  first,
Element  second 
)
static

Computes the distance between two objects. Uses the distance between the center of the objects. Can be overriden in subclasses.

Parameters
firstThe first object
secondThe second object
Returns
The distance between the center of the objects.

Here is the call graph for this function:

float Scenario::ComputeDistance ( Element  first,
Element  second 
)
static

Computes the distance between two objects. Uses the distance between the position of the objects as default. Can be overriden in subclasses.

Parameters
firstThe first object
secondThe second object
Returns
The distance between the objects

Here is the call graph for this function:

virtual bool Scenario::Detect ( FrameDetectionData  detected_objects)
pure virtual

Detects a certain scenario. Must be overriden in subclasses.

Parameters
detected_objectsThe frame data with detected objects
Returns
true whether the circumstances for a certain scenario are met, false if not

Implemented in HumansInFrontOfBusScenario.

Here is the caller graph for this function:

bool Scenario::DoContain ( Element  big,
Element  small 
)
static

Computes whether the big element contains the small one

Parameters
bigThe surrounding object
smallThe contained object
Returns
true whether it is contained, false if not (equal size and position will be true)

Here is the call graph for this function:

bool Scenario::DoOverlap ( Element  first,
Element  second 
)
static

Computes whether the two objects overlap. As default, overlapping of one pixel in the bounding boxes of the elements is enough to return true. Can be overriden in subclasses.

Parameters
firstThe first object
secondThe second object
Returns
true whether there is an overlapping, false if not

Here is the call graph for this function:

Here is the caller graph for this function:

virtual std::string Scenario::GetScenarioInformation ( )
pure virtual

Describes the detectable scenario with a human-readable string. Must be overriden in subclasses.

Returns
A String that describes the detected scenario

Implemented in HumansInFrontOfBusScenario.

Here is the caller graph for this function:


The documentation for this class was generated from the following files: