public interface IBodyPart
Modifier and Type | Method and Description |
---|---|
void |
collectSensors(java.util.Map<java.lang.String,ISensor> result) |
void |
generateJointActions(java.util.Map<java.lang.String,float[]> actions)
Informs the action component to create action commands from this body
model
|
void |
getAllHingeJoints(java.util.List<IHingeJoint> result) |
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
getAnchor()
Retrieve the anchor of the joint in the local body system.
|
java.util.List<IHingeJoint> |
getBackwardHingeChain() |
IBodyPart |
getBodyPart(java.lang.String name) |
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
getCenterOfMass() |
IBodyPart |
getChild(java.lang.String name) |
java.util.Collection<IBodyPart> |
getChildren()
A collection of the child body parts to this body part.
|
org.apache.commons.math3.geometry.euclidean.threed.Vector3D[] |
getCorners()
Get the position of the corners relative to the center of the BodyPart
e.g. for a cube this will return eight vectors to the corners of it
6___________4
/| /|
/ | / |
7___________5 |
| | | |
| 3________|__1 z
| / | / | x
|/ |/ | /
2___________0 |/_____y
TODO: change the method that the sequence makes more sense
|
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
getGeometry()
Get geometry of this BodyPart
|
double |
getGlobalPitch(org.apache.commons.math3.geometry.euclidean.threed.Rotation globalOrientation) |
double |
getGlobalRoll(org.apache.commons.math3.geometry.euclidean.threed.Rotation globalOrientation) |
double[][] |
getJacobian(org.apache.commons.math3.geometry.euclidean.threed.Vector3D endEffectorPos,
org.apache.commons.math3.geometry.euclidean.threed.Vector3D targetAngles)
Retrieve the jacobian matrix, having this IBodyPart as the end of the
chain.
|
IJoint |
getJoint() |
Pose3D |
getJointTransformation()
The complete transformation matrix from torso to the last Joint in this
row.
|
float |
getMass()
Mass of this BodyPart
|
java.lang.String |
getName()
get name of the bodypart
|
int |
getNoOfChildren() |
org.apache.commons.math3.geometry.euclidean.threed.Rotation |
getOrientation()
The complete orientation matrix from torso to the last Joint in this row.
|
IBodyPart |
getParent()
Get parent BodyPart
|
Pose3D |
getPose()
Return the pose (position and orientation) of the body part's center.
|
Pose3D |
getPose(org.apache.commons.math3.geometry.euclidean.threed.Vector3D localPos)
Return the pose (position and orientation) of the specified local position
relative to the body part's center.
|
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
getPosition()
Position of the center of this BodyPart relative to the torso.
|
<T extends ISensor> |
getSensor(java.lang.Class<T> type)
Returns the sensor instance of the requested type, if this body part
contains such a sensor type.
|
ISensor |
getSensorDeep(java.lang.String name)
Searches the body part hierarchy for a sensor with passed name
|
org.apache.commons.math3.geometry.euclidean.threed.Vector3D |
getTranslation()
Retrieve the translation from the center of the parent body part to the
center of this body part with a zero joint angles.
|
float |
getWholeMass() |
void |
updateFromPerception(IPerception perception)
Updates the joint values in the body model from perception
|
void |
updateJointsSpeed(IBodyPart part)
Deep update of joint's desired speed from the passed body part.
|
void |
updateNoPerception()
Updates the joint values in the body model with no perception
|
java.lang.String getName()
IBodyPart getParent()
org.apache.commons.math3.geometry.euclidean.threed.Vector3D getPosition()
org.apache.commons.math3.geometry.euclidean.threed.Rotation getOrientation()
Pose3D getPose()
Pose3D getPose(org.apache.commons.math3.geometry.euclidean.threed.Vector3D localPos)
Pose3D getJointTransformation()
float getMass()
float getWholeMass()
org.apache.commons.math3.geometry.euclidean.threed.Vector3D getGeometry()
void generateJointActions(java.util.Map<java.lang.String,float[]> actions)
action
- the action component that creates the action protocolvoid updateFromPerception(IPerception perception)
perception
- the new perception we madevoid updateNoPerception()
int getNoOfChildren()
java.util.Collection<IBodyPart> getChildren()
IBodyPart getChild(java.lang.String name)
name
- name of the child body partIJoint getJoint()
IBodyPart getBodyPart(java.lang.String name)
name
- the name of the part to retrieveorg.apache.commons.math3.geometry.euclidean.threed.Vector3D getCenterOfMass()
ISensor getSensorDeep(java.lang.String name)
name
- the name of the sensor<T extends ISensor> T getSensor(java.lang.Class<T> type)
T
- - the type if the sensortype
- - the type of the sensorvoid updateJointsSpeed(IBodyPart part)
part
- the body part from which to take the update valuesdouble getGlobalPitch(org.apache.commons.math3.geometry.euclidean.threed.Rotation globalOrientation)
globalOrientation
- matrix representing the global orientation of the
torsodouble getGlobalRoll(org.apache.commons.math3.geometry.euclidean.threed.Rotation globalOrientation)
globalOrientation
- matrix representing the global orientation of the
torsoorg.apache.commons.math3.geometry.euclidean.threed.Vector3D[] getCorners()
6___________4 /| /| / | / | 7___________5 | | | | | | 3________|__1 z | / | / | x |/ |/ | / 2___________0 |/_____yTODO: change the method that the sequence makes more sense
void collectSensors(java.util.Map<java.lang.String,ISensor> result)
result
- map to add all sensors deep for cachingdouble[][] getJacobian(org.apache.commons.math3.geometry.euclidean.threed.Vector3D endEffectorPos, org.apache.commons.math3.geometry.euclidean.threed.Vector3D targetAngles)
endEffectorPos
- - the position of the end effector of the
configuration in the local system of this IBodyPartorg.apache.commons.math3.geometry.euclidean.threed.Vector3D getTranslation()
org.apache.commons.math3.geometry.euclidean.threed.Vector3D getAnchor()
void getAllHingeJoints(java.util.List<IHingeJoint> result)
result
- java.util.List<IHingeJoint> getBackwardHingeChain()