package { import away3d.core.math.Quaternion; import flash.geom.Matrix3D; import flash.geom.Vector3D; /** * 剛体クラス */ public class RigidBody { public var fMass:Number; // total mass (constant) public var mInertia:Matrix3D; // mass moment of inertia in body coordinates (constant) public var mInertiaInverse:Matrix3D;// inverse of mass moment of inertia matrix (constant)
public var vPosition:Vector3D; // position in earth coordinates public var vVelocity:Vector3D; // velocity in earth coordinates public var vVelocityBody:Vector3D; // velocity in body coordinates public var vAcceleration:Vector3D; // acceleration of cg in earth space public var vAngularAcceleration:Vector3D; //angular acceleration in body coordinates public var vAngularVelocity:Vector3D;// angular velocity in body coordinates public var vEulerAngles:Vector3D; // Euler angles in body coordinates public var fSpeed:Number; // speed (magnitude of the velocity)
public var qOrientation:Quaternion; // orientation in earth coordinates
public var vForces:Vector3D // total force on body public var vMoments:Vector3D; // total moment (torque) on body
public var mIeInverse:Matrix3D; // inverse of moment of inertia in earth coordinates
public var vAngularVelocityGlobal:Vector3D; // angular velocity in terms of earth fixed coords. public var vAngularAccelerationGlobal:Vector3D; // angular acceleration in terms of earth fixed coords.
public var fRadius:Number; public var vVertexList:Array = new Array(8);