#include <ObstaclesModel.h>
Public Types | |
| enum | Directions { back, backRight, right, frontRight, front, frontLeft, left, backLeft, numberOfDirections } |
| enum | SearchDirections { searchLeft, searchLeftAndRight, searchRight } |
| enum | { numOfSectors = 90, maxDistance = 1500 } |
| enum | { ownGoal = 0, opponentGoal = 1 } |
Public Member Functions | |
| ObstaclesModel () | |
| ~ObstaclesModel () | |
| void | operator= (const ObstaclesModel &other) |
| copies another ObstaclesModel to this one | |
| void | setFrameNumber (unsigned long frameNumber) |
| double | getDistanceInCorridor (double angle, double width) const |
| returns the distance to the closest obstacle in the corridor specified by angle and width | |
| double | getAngleOfNextFreeSector (double sizeOfSector, double angle, int minDistance) const |
| returns the angle of the closest free sector with angle sizeOfSector relative to angle. | |
| double | getAngleOfNextFreeSectorLeft (double sizeOfSector, double angle, int minDistance) const |
| returns the angle of the closest free with angle sizeOfSector relative to angle. | |
| double | getAngleOfNextFreeSectorRight (double sizeOfSector, double angle, int minDistance) const |
| int | getDistanceInMajorDirection (Directions direction) const |
| returns the distance to the closest obstacle in one of the major directions defined above | |
| int | getDistanceInDirection (double direction, double openingAngle) const |
| return the distance to the closest obstacle in a given direction and a given opening angle | |
| int | getSectorDistanceInDirection (double direction) const |
| return the distance of an sector to the closest obstacle in a given direction | |
| double | getTotalFreeSpaceInSector (double direction, double openingAngle, double maxDist) const |
| sums up all distances in a sector specified by direction and opening angle; the maxDist(ance) specifies what the maximum distance should be when adding up (you don't want really big single values to distort the sum) | |
| int | getMinimalDistanceInRange (double centerAngle, double openingAngle, double &angleWithMinimalDistance) const |
| Calculates the angle with the closest distance to an obstacle. | |
| int | getMinimalDistanceInRange (double centerAngle, double openingAngle, double &angleWithMinimalDistance, ObstaclesPercept::ObstacleType obstacleType) const |
| Calculates the angle with the closest distance to an obstacle of a certain obstacle type. | |
| double | getPercentageOfLowDistanceObstaclesInRange (double centerAngle, double openingAngle, int maxDistance) const |
| Calculates the percentage of sectors with obstacles that are closer than the specified distance in the specified range. | |
| double | getAngleOfLargeGapInRange (double centerAngle, double openingAngle, SearchDirections searchDirection) const |
| Calculates the angle with the farsest distance to an obstacle. | |
| double | getAngleOfLargeGapInRange2 (double centerAngle, double openingAngle, SearchDirections searchDirection) const |
| Calculates the angle with the farsest distance to an obstacle. | |
Static Public Member Functions | |
| double | getAngleOfSector (int sector) |
| return the center angle of a given sector | |
| int | getSectorFromAngle (double angle) |
| return the corresponding sector to a given angle | |
Public Attributes | |
| unsigned long | frameNumber |
| the frame number when perceived | |
| int | distance [numOfSectors] |
| the distance to the closest obstacle in an angular sector | |
| ObstaclesPercept::ObstacleType | obstacleType [numOfSectors] |
| int | corridorInFront |
| the distance to the closest obstacle in a rectangular corridor in front of the robot | |
| int | currentlySeenStartSector |
| currently seen begining sector and end sector | |
| int | currentlySeenEndSector |
| double | angleToFreePartOfGoal [2] |
| double | widthOfFreePartOfGoal [2] |
| double | distanceToFreePartOfGoal [2] |
| unsigned long | lastTimeFreePartOfGoalWasDetermined [2] |
| bool | angleToFreePartOfGoalWasDetermined [2] |
| bool | angleToNextFreeTeammateWasDetermined |
| double | angleToNextFreeTeammate |
| double | distanceToNextFreeTeammate |
| double | angleToSeenGoal [2] |
| angle to seen goal, updated by vision and odometry | |
| double | distanceToSeenGoal [2] |
| distance to seen goal, updated by vision and odometry | |
| bool | trustSeenGoal [2] |
| something is definitely wrong with the seen goal (occurs only when not seeing the goal) | |
| unsigned long | timeOfSeenGoal [2] |
| time since last seen goal | |
| double | bodyPSD |
| last value of the body psd sensor (if present) | |
Definition at line 21 of file ObstaclesModel.h.
|
|
Definition at line 30 of file ObstaclesModel.h. |
|
|
Definition at line 31 of file ObstaclesModel.h. |
|
|
Definition at line 32 of file ObstaclesModel.h. |
|
|
Definition at line 139 of file ObstaclesModel.h. |
|
|
Definition at line 16 of file ObstaclesModel.cpp. References angleToFreePartOfGoalWasDetermined, angleToNextFreeTeammateWasDetermined, bodyPSD, corridorInFront, currentlySeenEndSector, currentlySeenStartSector, distance, lastTimeFreePartOfGoalWasDetermined, maxDistance, numOfSectors, and trustSeenGoal. |
|
|
Definition at line 36 of file ObstaclesModel.cpp. |
|
|
copies another ObstaclesModel to this one
Definition at line 514 of file ObstaclesModel.cpp. References corridorInFront, distance, numOfSectors, and obstacleType. |
|
|
return the center angle of a given sector
Definition at line 37 of file ObstaclesModel.h. References numOfSectors, pi, and pi2. Referenced by getAngleOfLargeGapInRange(), getAngleOfLargeGapInRange2(), getAngleOfNextFreeSector(), getAngleOfNextFreeSectorLeft(), getAngleOfNextFreeSectorRight(), getDistanceInCorridor(), GTCamObstaclesLocator::modelLine(), and GTCamObstaclesLocator::modelRobot(). |
|
|
Definition at line 53 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::execute(). |
|
||||||||||||
|
returns the distance to the closest obstacle in the corridor specified by angle and width
Definition at line 107 of file ObstaclesModel.cpp. References Geometry::Line::base, Geometry::Line::direction, distance, getAngleOfSector(), getSectorFromAngle(), LINE, maxDistance, numOfSectors, pi_2, point, Vector2< int >::x, Vector2< double >::x, Vector2< int >::y, and Vector2< double >::y. Referenced by GT2005BasicBehaviorGoToPointAndAvoidObstacles::execute(), and GT2005ConfigurationSymbols::update(). |
Here is the call graph for this function:

|
||||||||||||||||
|
returns the angle of the closest free sector with angle sizeOfSector relative to angle. Free means free up to minDistance Definition at line 257 of file ObstaclesModel.cpp. References distance, getAngleOfSector(), getSectorFromAngle(), numOfSectors, and pi2. Referenced by GT2005BasicBehaviorGoToPointAndAvoidObstacles::execute(). |
Here is the call graph for this function:

|
||||||||||||||||
|
returns the angle of the closest free with angle sizeOfSector relative to angle. Free means free up to minDistance Definition at line 163 of file ObstaclesModel.cpp. References distance, getAngleOfSector(), getSectorFromAngle(), numOfSectors, and pi2. Referenced by AngleSymbols::calculateCombinedAngles(). |
Here is the call graph for this function:

|
||||||||||||||||
|
Definition at line 211 of file ObstaclesModel.cpp. References distance, getAngleOfSector(), getSectorFromAngle(), numOfSectors, and pi2. Referenced by AngleSymbols::calculateCombinedAngles(). |
Here is the call graph for this function:

|
|
returns the distance to the closest obstacle in one of the major directions defined above
Definition at line 40 of file ObstaclesModel.cpp. References distance, maxDistance, numberOfDirections, and numOfSectors. |
|
||||||||||||
|
return the distance to the closest obstacle in a given direction and a given opening angle
Definition at line 61 of file ObstaclesModel.cpp. References distance, getSectorFromAngle(), and numOfSectors. Referenced by GT2005BasicBehaviorDirectedScanForObstacles::execute(), ObstaclesSymbols::getNearestObstacleFrontLeft(), ObstaclesSymbols::getNearestObstacleFrontRight(), ObstaclesSymbols::getObstacleInFront(), GTStandardConverter::setData(), and GT2005ConfigurationSymbols::update(). |
Here is the call graph for this function:

|
|
return the distance of an sector to the closest obstacle in a given direction
Definition at line 81 of file ObstaclesModel.cpp. References distance, and getSectorFromAngle(). |
Here is the call graph for this function:

|
||||||||||||||||
|
sums up all distances in a sector specified by direction and opening angle; the maxDist(ance) specifies what the maximum distance should be when adding up (you don't want really big single values to distort the sum)
Definition at line 88 of file ObstaclesModel.cpp. References distance, getSectorFromAngle(), and numOfSectors. Referenced by GT2005BasicBehaviorGoToPointAndAvoidObstacles::execute(). |
Here is the call graph for this function:

|
||||||||||||||||
|
Calculates the angle with the closest distance to an obstacle. Returns the distance. Definition at line 316 of file ObstaclesModel.cpp. Referenced by ObstaclesSymbols::getMinDistanceLeft(), ObstaclesSymbols::getMinDistanceRight(), and ObstaclesSymbols::update(). |
|
||||||||||||||||||||
|
Calculates the angle with the closest distance to an obstacle of a certain obstacle type. Returns the distance. Definition at line 346 of file ObstaclesModel.cpp. |
|
||||||||||||||||
|
Calculates the percentage of sectors with obstacles that are closer than the specified distance in the specified range.
Definition at line 377 of file ObstaclesModel.cpp. Referenced by ObstaclesSymbols::getObstacleInFront(), and ObstaclesSymbols::update(). |
|
||||||||||||||||
|
Calculates the angle with the farsest distance to an obstacle. Returns the angle. Definition at line 399 of file ObstaclesModel.cpp. References RingBufferWithSum< n >::add(), distance, getAngleOfSector(), getSectorFromAngle(), RingBufferWithSum< n >::getSum(), min, searchLeft, and searchRight. |
Here is the call graph for this function:

|
||||||||||||||||
|
Calculates the angle with the farsest distance to an obstacle. Returns the angle. Definition at line 456 of file ObstaclesModel.cpp. References RingBufferWithSum< n >::add(), distance, getAngleOfSector(), RingBufferWithSum< n >::getMinimum(), getSectorFromAngle(), RingBufferWithSum< n >::getSum(), min, searchLeft, and searchRight. |
Here is the call graph for this function:

|
Here is the call graph for this function:

|
|
the frame number when perceived
Definition at line 51 of file ObstaclesModel.h. Referenced by GTCamObstaclesLocator::execute(), operator<<(), and operator>>(). |
|
|
the distance to the closest obstacle in an angular sector
Definition at line 56 of file ObstaclesModel.h. Referenced by GTCamObstaclesLocator::execute(), getAngleOfLargeGapInRange(), getAngleOfLargeGapInRange2(), getAngleOfNextFreeSector(), getAngleOfNextFreeSectorLeft(), getAngleOfNextFreeSectorRight(), getDistanceInCorridor(), getDistanceInDirection(), getDistanceInMajorDirection(), getSectorDistanceInDirection(), getTotalFreeSpaceInSector(), GTCamObstaclesLocator::modelLine(), GTCamObstaclesLocator::modelRobot(), ObstaclesModel(), operator=(), and GT2005ObstaclesLocator::setObstaclesModel(). |
|
|
Definition at line 59 of file ObstaclesModel.h. Referenced by GTCamObstaclesLocator::execute(), GTCamObstaclesLocator::modelLine(), GTCamObstaclesLocator::modelRobot(), operator=(), and GT2005ObstaclesLocator::setObstaclesModel(). |
|
|
the distance to the closest obstacle in a rectangular corridor in front of the robot
Definition at line 62 of file ObstaclesModel.h. Referenced by GTCamObstaclesLocator::execute(), ObstaclesSymbols::getMinDistanceMiddle(), ObstaclesModel(), operator=(), and GT2005ObstaclesLocator::setObstaclesModel(). |
|
|
currently seen begining sector and end sector
Definition at line 65 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::addObstaclesPercept(), and ObstaclesModel(). |
|
|
Definition at line 66 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::addObstaclesPercept(), and ObstaclesModel(). |
|
|
Definition at line 140 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateCombinedAngles(), AngleSymbols::calculateVisionBasedAngles(), GT2005ObstaclesLocator::determineFreePartsOfGoals(), and GTCamObstaclesLocator::execute(). |
|
|
Definition at line 141 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateVisionBasedAngles(), GT2005ObstaclesLocator::determineFreePartsOfGoals(), GTCamObstaclesLocator::execute(), operator<<(), and operator>>(). |
|
|
Definition at line 142 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineFreePartsOfGoals(), and GTCamObstaclesLocator::execute(). |
|
|
Definition at line 143 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineFreePartsOfGoals(), GTCamObstaclesLocator::execute(), AngleSymbols::getTimeSinceOpponentGoalDetection(), and ObstaclesModel(). |
|
|
Definition at line 144 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateCombinedAngles(), GT2005ObstaclesLocator::determineFreePartsOfGoals(), GTCamObstaclesLocator::execute(), ObstaclesModel(), operator<<(), and operator>>(). |
|
|
Definition at line 146 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineNextFreeTeammate(), GTCamObstaclesLocator::execute(), and ObstaclesModel(). |
|
|
Definition at line 147 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineNextFreeTeammate(), and GTCamObstaclesLocator::execute(). |
|
|
Definition at line 148 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineNextFreeTeammate(), and GTCamObstaclesLocator::execute(). |
|
|
angle to seen goal, updated by vision and odometry
Definition at line 151 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateVisionBasedAngles(), and GT2005ObstaclesLocator::determineSeenGoals(). |
|
|
distance to seen goal, updated by vision and odometry
Definition at line 154 of file ObstaclesModel.h. Referenced by GT2005ObstaclesLocator::determineSeenGoals(). |
|
|
something is definitely wrong with the seen goal (occurs only when not seeing the goal)
Definition at line 157 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateCombinedAngles(), GT2005ObstaclesLocator::determineSeenGoals(), AngleSymbols::getTrustOfSeenAngleToOpponentGoal(), and ObstaclesModel(). |
|
|
time since last seen goal
Definition at line 161 of file ObstaclesModel.h. Referenced by AngleSymbols::calculateCombinedAngles(), GT2005ObstaclesLocator::determineSeenGoals(), and AngleSymbols::getTimeSinceLastSeenOpponentGoal(). |
|
|
last value of the body psd sensor (if present)
Definition at line 167 of file ObstaclesModel.h. Referenced by ObstaclesModel(), and GT2005ObstaclesLocator::setObstaclesModel(). |
1.3.6