new ODE.Mass(pointer)
Name | Type | Description |
---|---|---|
pointer |
Number |
optional
heap memory pointer to cast into Mass |
Methods
-
destroy()
D:/work/ODE.js/lib/ode.js, line 227 -
clear memory space in LLVM heap
-
getPointer(){Number}
D:/work/ODE.js/lib/ode.js, line 220 -
get offset address in heap memory
Returns:
Type Description Number -
setCapsule(density, direction, radius, length){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 274 -
Set the mass parameters to represent a Capsule of the given parameters and density, with the center of mass at (0,0,0)
Name Type Description density
Number direction
Number The capsule's long axis is oriented along the body's x, y or z axis according to the value of direction (1 = X axis , 2 = Y axis, 3 = Z axis).
radius
Number The radius of the capsule
length
Number The length of the capsule
Returns:
Type Description ODE.Mass -
setCapsuleTotal(total_mass, direction, radius, length){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 284 -
Set the mass parameters to represent a Capsule of the given parameters and mass, with the center of mass at (0,0,0)
Name Type Description total_mass
Number direction
Number The capsule's long axis is oriented along the body's x, y or z axis according to the value of direction (1 = X axis , 2 = Y axis, 3 = Z axis).
radius
Number The radius of the capsule
length
Number The length of the capsule
Returns:
Type Description ODE.Mass -
setParameters(mass, cgx, cgy, cgz, I11, I22, I33, I12, I13, I23){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 240 -
fill all mass parameters
Name Type Description mass
Number total mass of the rigid body.
cgx
Number center of gravity position in body frame.
cgy
Number center of gravity position in body frame.
cgz
Number center of gravity position in body frame.
I11
Number 3x3 inertia tensor matrix in body frame.
I22
Number 3x3 inertia tensor matrix in body frame.
I33
Number 3x3 inertia tensor matrix in body frame.
I12
Number 3x3 inertia tensor matrix in body frame.
I13
Number 3x3 inertia tensor matrix in body frame.
I23
Number 3x3 inertia tensor matrix in body frame.
Returns:
Type Description ODE.Mass -
setSphere(density, radius){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 257 -
Set the mass parameters to represent a sphere of the given radius and density, with the center of mass at (0,0,0) relative to the body.
Name Type Description density
Number radius
number Returns:
Type Description ODE.Mass -
setSphereTotal(total_mass, radius){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 266 -
Set the mass parameters to represent a sphere of the given radius and mass, with the center of mass at (0,0,0) relative to the body.
Name Type Description total_mass
Number radius
Number Returns:
Type Description ODE.Mass -
setZero(){ODE.Mass}
D:/work/ODE.js/lib/ode.js, line 233 -
clear all mass parameters
Returns:
Type Description ODE.Mass