#include <Objects.h>
Inheritance diagram for FixedObject:
Public Member Functions | |
VecPosition | getGlobalPosition (SideT s, double dGoalWidth=14.02) const |
AngDeg | getGlobalAngle (SideT s) |
void | show (ostream &os=cout) |
Definition at line 126 of file Objects.h.
VecPosition FixedObject::getGlobalPosition | ( | SideT | s, | |
double | dGoalWidth = 14.02 | |||
) | const |
This method returns the global position of this fixed object. Only works when the object type equals a flag or a goal. Furthermore the side of the agent has to be passed since the global positions differ for the left and the right side. For some flags the size of the goal is important. So this value can be passed also. Otherwise the default value is 14.02.
s | side of agent (global position differs for left and right side) | |
dGoalWidth | width of a goal, needed for pole objects next to goal |
Definition at line 296 of file Objects.cpp.
References SoccerTypes::getGlobalPositionFlag(), and Object::getType().
This methods returns the global angle of this fixed object in the world. Only works when the fixed object is a line. The angle for the left team rises clockwise, i.e. left=0, bottom=90, etc. For the right team this is counterclockwise: right=0, top=90, etc)
s | side of agent (angles differ for left and right side) |
Definition at line 307 of file Objects.cpp.
References SoccerTypes::getGlobalAngleLine(), and Object::getType().
void FixedObject::show | ( | ostream & | os = cout |
) | [virtual] |
This method prints all the information about this FixedObject to the specified output stream
os | output stream to print all relevant information to. |
Implements Object.
Definition at line 275 of file Objects.cpp.
References DEFAULT_TEAM_NAME, VecPosition::getDirection(), VecPosition::getMagnitude(), SoccerTypes::getObjectStr(), MAX_TEAM_NAME_LENGTH, Object::objectType, Object::posRelative, Object::timeLastSeen, and Object::timeRelativePosition.