#include <PhysicalObject.h>
Inheritance diagram for PhysicalObject:
The object can have tactile sensors distributed on its surface. nSensors is the number of tactile sensors. The tactile sensors have a maximum activation (1) for a force greater than saturationForce.
Definition at line 26 of file PhysicalObject.h.
|
Default constructor; initializes everything with 0. Definition at line 8 of file PhysicalObject.cpp. References activations, alpha, boxMax, boxMin, externalTorque, I, m, omega, parent, real, relativeAlpha, and Vector2::setXY(). |
|
Destructor; purges the lists. Definition at line 33 of file PhysicalObject.cpp. References activations, and deleteContacts(). |
|
Adds given contact to the contact list. Definition at line 116 of file PhysicalObject.h. Referenced by ContactInfo::setupObject(). |
|
Computes the coordinates of the bounding box. It is called after each call to integrate() or rollback(). Reimplemented in CappedRectangle, and Circle. Definition at line 83 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::computeMemberPositions(), integrate(), and rollback(). |
|
Computes the derivatives, given the contact forces. The globalContacts pointer is needed for contact processing for articulated agents. Reimplemented in Spherus, Elastoid, and ArticulatedAgentQuasistatic. Definition at line 80 of file PhysicalObject.cpp. References contacts, ContactInfo::force, ContactInfo::n, omega, ContactInfo::pxn, setSensors(), ContactInfo::sigma, and v. Referenced by Spherus::computeDerivatives(). |
|
Computes the derivatives (velocity, angular velocity) of the object, ignoring any eventual contact forces. Reimplemented in Spherus, Border, Elastoid, and ArticulatedAgentQuasistatic. Definition at line 71 of file PhysicalObject.cpp. References externalForce, externalTorque, omega, Vector2::setToZero(), and v. Referenced by Spherus::computeDerivativesWithoutContacts(). |
|
Computes the moment of inertia around the z axis that passes through the center, based on the mass and the geometrical properties. To be overridden. Reimplemented in CappedRectangle, and Circle. Definition at line 65 of file PhysicalObject.h. References I. |
|
Sets the mass based on the density. To be overridden. Reimplemented in CappedRectangle, and Circle. Definition at line 61 of file PhysicalObject.h. References m. |
|
Transmits perceptual information to the controller and gets motor information from it. To be overridden by agents or other objects with self-generated movement. Reimplemented in Iunctus, Spherus, and Pac. Definition at line 102 of file PhysicalObject.h. Referenced by Simulator::controll(). |
|
Delete the contacts of the object. Reimplemented in Iunctus, Spherus, Elastoid, ArticulatedAgentBase, and ArticulatedLink. Definition at line 43 of file PhysicalObject.cpp. References contacts, purgeContainer(), and resetSensors(). Referenced by Spherus::deleteContacts(), Iunctus::deleteContacts(), ArticulatedLink::deleteContacts(), ArticulatedAgentBase::deleteContacts(), and ~PhysicalObject(). |
|
Reimplemented in CappedRectangle, and VisualSensor. Definition at line 47 of file PhysicalObject.h. References detectContacts(). |
|
Reimplemented in CappedRectangle, Circle, and VisualSensor. Definition at line 44 of file PhysicalObject.h. References detectContacts(). |
|
Reimplemented in Border, CappedRectangle, Circle, and VisualSensor. Definition at line 41 of file PhysicalObject.h. References detectContacts(). |
|
Contact handling. Implemented in Spherus, Border, CappedRectangle, Circle, ComposedPhysicalObject, Elastoid, VisualSensor, and ArticulatedAgentBase. Referenced by VisualSensor::detectContacts(), Simulator::detectContacts(), detectContacts(), Circle::detectContacts(), CappedRectangle::detectContacts(), and Border::detectContacts(). |
|
Detects internal contacts. Does nothing for primitive objects or composed objects. To be overriden by complex objects that have parts that move relative to each other, such as articulated objects. Reimplemented in Spherus, Elastoid, and ArticulatedAgentBase. Definition at line 107 of file PhysicalObject.h. |
|
Detects whether a click of the mouse at rMouse has touched the object. In case of contact, returns true and sets p to the relative vector between the center of the object and the contact point; p is expressed in the object reference frame because it rotates with the object while the object is dragged. The object needs to be set by the function because, for articulated objects, the dragged object is an articulation and not the whole articulated object. To be overriden by the various object primitives. Reimplemented in Spherus, CappedRectangle, Circle, ComposedPhysicalObject, Elastoid, and ArticulatedAgentBase. Definition at line 133 of file PhysicalObject.h. |
|
Draws the contact forces. Definition at line 135 of file PhysicalObject.cpp. References contacts, GUI::drawForce(), ContactInfo::force, ContactInfo::n, ContactInfo::p, r, and ContactInfo::sigma. |
|
Computes the contribution of the current object to the matrix of interactions between all objects that are in contact. Reimplemented in Border, ArticulatedAgentBase, and ArticulatedLink. Definition at line 95 of file PhysicalObject.cpp. References ContactInfo::alpha, ContactSolver::contactMatrix, contacts, ContactSolver::contactVector, Vector2::cross(), ContactInfo::n, omega, ContactInfo::p, ContactInfo::pxn, and ContactInfo::sigma. |
|
Advances the time to the next timestep. Reimplemented in Spherus, Border, ComposedPhysicalObject, Elastoid, ArticulatedAgentQuasistatic, and ArticulatedLink. Definition at line 56 of file PhysicalObject.cpp. References alpha, alphaOld, computeBox(), Integrator::integrate(), normalizeAlpha(), omega, r, rOld, and v. Referenced by Spherus::integrate(), and ComposedPhysicalObject::integrate(). |
|
Verifies if the object has circular symmetry; in this case, computations of rotational properties can be skipped, on various occasions. By default, returns 0 (not symmetrical). To be overridden by symmetrical objects (Circle). Reimplemented in Circle. Definition at line 70 of file PhysicalObject.h. |
|
Normalizes Alpha to a value between 0 and 2 PI. Definition at line 203 of file PhysicalObject.h. References alpha. Referenced by integrate(). |
|
Registers all composing primitives of the object with the simulator. Reimplemented in ComposedPhysicalObject, Elastoid, and ArticulatedAgentBase. Definition at line 39 of file PhysicalObject.cpp. References Simulator::registerPrimitive(). Referenced by Simulator::registerObject(). |
|
Resets tactile sensors to zero. Reimplemented in ComposedPhysicalObject. Definition at line 48 of file PhysicalObject.cpp. References activations. Referenced by deleteContacts(), and ComposedPhysicalObject::resetSensors(). |
|
Rolls back the time to the previous timestep. Reimplemented in Border, ComposedPhysicalObject, ArticulatedAgentQuasistatic, and ArticulatedLink. Definition at line 65 of file PhysicalObject.cpp. References alpha, computeBox(), and r. Referenced by ComposedPhysicalObject::rollback(). |
|
Sets the mass m of the object. Definition at line 58 of file PhysicalObject.h. |
|
Sets the position r of the object. Definition at line 52 of file PhysicalObject.h. References r, Vector2::x, and Vector2::y. |
|
Sets the activation of a tactile sensor, corresponding to the given contact. To be overridden. Reimplemented in CappedRectangle, and Circle. Definition at line 98 of file PhysicalObject.h. Referenced by setSensors(), and ComposedPhysicalObject::setSensors(). |
|
Sets the activations of the tactile sensors, on the basis of the contact forces related to the contacts of the object with other objects. Reimplemented in ComposedPhysicalObject. Definition at line 126 of file PhysicalObject.cpp. References contacts, and setSensor(). Referenced by computeDerivatives(). |
|
Sets the velocity v of the object. Definition at line 55 of file PhysicalObject.h. References v, Vector2::x, and Vector2::y. |
|
A vector containing the activations of the sensors. Definition at line 193 of file PhysicalObject.h. Referenced by PhysicalObject(), resetSensors(), and ~PhysicalObject(). |
|
Rotation angle around center of mass relative to the LRS Definition at line 149 of file PhysicalObject.h. Referenced by Simulator::applyMouseForce(), ArticulatedAgentQuasistatic::backwardDynamics(), VisualSensor::computeGamma(), ComposedPhysicalObject::computeMemberPositions(), VisualSensor::draw(), Iunctus::draw(), ArticulatedAgentQuasistatic::forwardAccelerations(), ArticulatedAgentQuasistatic::forwardKinematics(), Simulator::indexContacts(), Spherus::integrate(), integrate(), normalizeAlpha(), PhysicalObject(), and rollback(). |
|
Value of alpha at the previous timestep. Definition at line 152 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::computeMemberPositions(), and integrate(). |
|
Minimum coordinates of the axis-aligned bounding box surrounding the object. Definition at line 184 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::computeMemberPositions(), ArticulatedAgentQuasistatic::integrate(), PhysicalObject(), and ArticulatedAgentQuasistatic::rollback(). |
|
Minimum coordinates of the axis-aligned bounding box surrounding the object. Definition at line 181 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::computeMemberPositions(), ArticulatedAgentQuasistatic::integrate(), PhysicalObject(), ArticulatedAgentQuasistatic::rollback(), and Simulator::sortObjects(). |
|
The list of contacts that act on the object. The list owns the contacts. Definition at line 187 of file PhysicalObject.h. Referenced by ArticulatedAgentQuasistatic::backwardDynamics(), computeDerivatives(), deleteContacts(), drawContactForces(), fillContactMatrix(), ArticulatedAgentQuasistatic::forwardAccelerations(), and setSensors(). |
|
The sum of external forces acting on the object Definition at line 161 of file PhysicalObject.h. Referenced by ElasticLink::applyForces(), Simulator::applyMouseForce(), ArticulatedAgentQuasistatic::backwardDynamics(), Spherus::computeDerivativesWithoutContacts(), and computeDerivativesWithoutContacts(). |
|
The sum of external torques acting on the object Definition at line 164 of file PhysicalObject.h. Referenced by Simulator::applyMouseForce(), ArticulatedAgentQuasistatic::backwardDynamics(), computeDerivativesWithoutContacts(), and PhysicalObject(). |
|
Moment of inertia for rotation around the z axis that passes through the center of mass. Definition at line 158 of file PhysicalObject.h. Referenced by computeInertia(), ComposedPhysicalObject::computeMassProperties(), and PhysicalObject(). |
|
A text label for the object; used primarily for debugging. Definition at line 190 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::addObject(). |
|
Mass Definition at line 146 of file PhysicalObject.h. Referenced by Spherus::computeCircleProprioception(), computeMass(), ComposedPhysicalObject::computeMassProperties(), and PhysicalObject(). |
|
The number of unit sensors (pixels) in the tactile sensor. Reimplemented in Spherus. Definition at line 200 of file PhysicalObject.h. |
|
Angular velocity around center of mass relative to the LRS Definition at line 155 of file PhysicalObject.h. Referenced by computeDerivatives(), computeDerivativesWithoutContacts(), fillContactMatrix(), ArticulatedAgentQuasistatic::forwardAccelerations(), integrate(), and PhysicalObject(). |
|
The parent of the object. It is NULL for simple objects, not NULL for objects that are members of composed objects. Definition at line 168 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::addObject(), PhysicalObject(), and ContactInfo::setupObject(). |
|
Position of the center of mass of the object relative to laboratory reference system (LRS) Definition at line 137 of file PhysicalObject.h. Referenced by ElasticLink::applyForces(), Simulator::applyMouseForce(), Spherus::computeMemberPositions(), ComposedPhysicalObject::computeMemberPositions(), Spherus::computeState(), VisualSensor::detectContacts(), Circle::detectContacts(), CappedRectangle::detectContacts(), VisualSensor::draw(), Spherus::draw(), Iunctus::draw(), ElasticLink::draw(), drawContactForces(), ArticulatedAgentQuasistatic::forwardKinematics(), integrate(), rollback(), setPosition(), and ContactInfo::setupObject(). |
|
The rotation of the member object relative to the reference system of the composed object (ORS), for objects that are members of composed objects. Definition at line 178 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::addObject(), ComposedPhysicalObject::computeMemberPositions(), and PhysicalObject(). |
|
The position of the member object relative to the reference system of the composed object (ORS), for objects that are members of composed objects. Definition at line 173 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::addObject(), ComposedPhysicalObject::computeMassProperties(), and ComposedPhysicalObject::computeMemberPositions(). |
|
Value of r at the previous timestep. Definition at line 140 of file PhysicalObject.h. Referenced by ComposedPhysicalObject::computeMemberPositions(), and integrate(). |
|
The saturation contact force for contact sensors Definition at line 196 of file PhysicalObject.h. |
|
Velocity relative to the LRS Definition at line 143 of file PhysicalObject.h. Referenced by ArticulatedAgentQuasistatic::backwardDynamics(), Spherus::computeCircleProprioception(), computeDerivatives(), computeDerivativesWithoutContacts(), ArticulatedAgentQuasistatic::forwardAccelerations(), integrate(), and setVelocity(). |
Thyrix homepage Users' guide
(C) Arxia 2004-2005