dJointSetPistonAnchorOffset

@brief Set the Piston anchor as if the 2 bodies were already at [dx,dy, dz] appart. @ingroup joints

This function initialize the anchor and the relative position of each body as if the position between body1 and body2 was already the projection of [dx, dy, dz] along the Piston axis. (i.e as if the body1 was at its current position - [dx,dy,dy] when the axis is set). Ex: <PRE> dReal offset = 3; dVector3 axis; dJointGetPistonAxis(jId, axis); dJointSetPistonAnchor(jId, 0, 0, 0); // If you request the position you will have: dJointGetPistonPosition(jId) == 0 dJointSetPistonAnchorOffset(jId, 0, 0, 0, axisX*offset, axisY*offset, axisZ*offset); // If you request the position you will have: dJointGetPistonPosition(jId) == offset </PRE> @param j The Piston joint for which the anchor point will be set @param x The X position of the anchor point in world frame @param y The Y position of the anchor point in world frame @param z The Z position of the anchor point in world frame @param dx A delta to be substracted to the X position as if the anchor was set when body1 was at current_positionX - dx @param dx A delta to be substracted to the Y position as if the anchor was set when body1 was at current_positionY - dy @param dx A delta to be substracted to the Z position as if the anchor was set when body1 was at current_positionZ - dz

extern (C) nothrow
void
dJointSetPistonAnchorOffset

Meta