#include <PfieldGeometry.h>
Inheritance diagram for Circle:
Public Member Functions | |
GeometryType | getType () const |
PfieldGeometricObject * | clone () const |
double | distanceTo (const PfPose &base, const PfVec &pos, PfVec &contact) const |
virtual void | initRadiusOfCollisionCircle () |
PfieldGeometricObject * | getAbs (const PfPose &base) const |
void | setAbsoluteFromOther (const PfPose &base, PfieldGeometricObject *other) |
virtual void | getPoints (std::vector< PfVec > &points) |
Public Attributes | |
double | radius |
Definition at line 290 of file PfieldGeometry.h.
PfieldGeometricObject * Circle::clone | ( | ) | const [virtual] |
Clones a circle
Implements PfieldGeometricObject.
Definition at line 373 of file PfieldGeometry.cpp.
References PfieldGeometricObject::intersectable, PfieldGeometricObject::position, radius, and PfieldGeometricObject::radiusOfCollisionCircle.
Referenced by getAbs().
double Circle::distanceTo | ( | const PfPose & | base, | |
const PfVec & | pos, | |||
PfVec & | contact | |||
) | const [virtual] |
Computes the distance from the border of the object to a given point
base | The pose of the object to which the geometric object is assigned | |
pos | The tested point | |
contact | Returns the next position of the geometric object to the point |
Implements PfieldGeometricObject.
Definition at line 336 of file PfieldGeometry.cpp.
References PfVec::distanceTo(), PfVec::normalize(), PfPose::pos, and radius.
PfieldGeometricObject * Circle::getAbs | ( | const PfPose & | base | ) | const [virtual] |
Returns a geometric object with absolute coordinates
base | The pose of the object |
Implements PfieldGeometricObject.
Definition at line 359 of file PfieldGeometry.cpp.
References clone(), PfPose::pos, and PfieldGeometricObject::position.
void Circle::getPoints | ( | std::vector< PfVec > & | points | ) | [virtual] |
Returns all points of the object
points | The list of points to which the object's points will be attached |
Reimplemented from PfieldGeometricObject.
Definition at line 385 of file PfieldGeometry.cpp.
References PfieldGeometricObject::position.
GeometryType Circle::getType | ( | ) | const [inline, virtual] |
Returns the type of a geometric object
Implements PfieldGeometricObject.
Definition at line 299 of file PfieldGeometry.h.
References CIRCLE.
void Circle::initRadiusOfCollisionCircle | ( | ) | [virtual] |
Computes value of the radiusOfCollisionCircle variable
Implements PfieldGeometricObject.
Definition at line 353 of file PfieldGeometry.cpp.
References radius, and PfieldGeometricObject::radiusOfCollisionCircle.
Referenced by FutureWorldModelGenerator::getMaxRotationForObject(), and Parser::parseGeometricObject().
void Circle::setAbsoluteFromOther | ( | const PfPose & | base, | |
PfieldGeometricObject * | other | |||
) | [virtual] |
Computes absolute coordinates from a base pose and another, relative polygon. Use careful! The other object has to be the same type and the size! Only positions are changed, other members will be ignored!
base | The new absolute position | |
other | A relative geometric object |
Implements PfieldGeometricObject.
Definition at line 367 of file PfieldGeometry.cpp.
References PfPose::pos, and PfieldGeometricObject::position.
double Circle::radius |
The radius of the circle
Definition at line 294 of file PfieldGeometry.h.
Referenced by clone(), distanceTo(), FutureWorldModelGenerator::getMaxRotationForObject(), initRadiusOfCollisionCircle(), intersectCircleAndCircle(), and Parser::parseGeometricObject().