|
Drag[en]gine Script Module DragonScript 1.35
|
Immutable rig resources. More...
Public Member Functions | |
Management | |
| String | getFilename () |
| Normalized filename the rig has been loaded from. | |
| void | save (String filename) |
| Save rig to filename. | |
| bool | equals (Object other) |
| Rig is equal to another object. | |
| int | hashCode () |
| Hash code for use as dictionary keys. | |
Bone | |
| int | getBoneCount () |
| Number of bones. | |
| int | indexOfBoneNamed (String name) |
| Index of named bone or -1 if absent. | |
| String | boneGetName (int bone) |
| Name of bone at index. | |
| Vector | boneGetPosition (int bone) |
| Bone position. | |
| Quaternion | boneGetOrientation (int bone) |
| Bone orientation. | |
| Vector | boneGetRotation (int bone) |
| Bone rotation in degrees. | |
| Matrix | getBoneMatrix (int bone) |
| Matrix transforming from local bone space to model space in reference pose. | |
| Matrix | getBoneInverseMatrix (int bone) |
| Matrix transforming from model space to local bone space in reference pose. | |
| Vector | boneGetCentralMassPoint (int bone) |
| Bone central mass point. | |
| float | boneGetMass (int bone) |
| Bone mass in kg. | |
| bool | boneGetDynamic (int bone) |
| Bone is enabled for dynamic simulation if collider rig or collider component is dynamic. | |
| int | boneGetParent (int bone) |
| Index of parent bone or -1 if bone is a root bone. | |
| int | getRootBone () |
| Index of root bone or -1 if no root bone is set. | |
Bone Inverse Kinematics | |
| Vector | boneGetIKLimitsLower (int bone) |
| Bone inverse kinematics lower limits used by animator rules. | |
| Vector | boneGetIKLimitsUpper (int bone) |
| Bone inverse kinematics upper limits used by animator rules. | |
| Vector | boneGetIKResistance (int bone) |
| Bone inverse kinematics resisteance used by animator rules. | |
| bool | boneGetIKLocked (int bone, int axis) |
| Bone inverse kinematics per axis locked state used by animator rules. | |
Bone Constraints | |
| int | boneGetConstraintCount (int bone) |
| Bone constraint count. | |
| ColliderConstraint | boneGetConstraintAt (int bone, int constraint) |
| Create collider constraint from bone constraint at index. | |
| Vector | boneConstraintGetReferencePosition (int bone, int constraint) |
| Position of the reference coordinate frame. | |
| Quaternion | boneConstraintGetReferenceOrientation (int bone, int constraint) |
| Orientation of the reference coordinate frame. | |
| Vector | boneConstraintGetBoneOffset (int bone, int constraint) |
| Offset of the bone constraint position relative to the reference coordinate frame. | |
Bone Shapes | |
| ShapeList | boneGetShapes (int bone) |
| Bone shapes. | |
| String | boneShapeGetProperty (int bone, int shape) |
| Bone shape property string. | |
Shapes | |
| ShapeList | getShapes () |
| Shapes. | |
| String | shapeGetProperty (int shape) |
| Shape property string. | |
| Vector | getCentralMassPoint () |
| Rig central mass point. | |
Constructors | |
| Rig | new (String filename) |
| Load rig from file. | |
| static void | loadAsynchron (String filename, ResourceListener listener) |
| Load rig from file asynchronously. | |
Immutable rig resources.
Rig resources provide deforming models, physicsl simulation and collision detection as well as properties for animation.
This is a native class. It can not be subclassed.
| Vector Dragengine.Scenery.Rig.boneConstraintGetBoneOffset | ( | int | bone, |
| int | constraint ) |
Offset of the bone constraint position relative to the reference coordinate frame.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
| EOutOfBoundary | constraint is less than 0 or greater than or equal to boneGetConstraintCount(). |
References boneGetConstraintCount().
Referenced by getCentralMassPoint().
| Quaternion Dragengine.Scenery.Rig.boneConstraintGetReferenceOrientation | ( | int | bone, |
| int | constraint ) |
Orientation of the reference coordinate frame.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
| EOutOfBoundary | constraint is less than 0 or greater than or equal to boneGetConstraintCount(). |
References boneGetIKLocked().
Referenced by getCentralMassPoint().
| Vector Dragengine.Scenery.Rig.boneConstraintGetReferencePosition | ( | int | bone, |
| int | constraint ) |
Position of the reference coordinate frame.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
| EOutOfBoundary | constraint is less than 0 or greater than or equal to boneGetConstraintCount(). |
References boneGetIKResistance().
Referenced by getShapes().
| Vector Dragengine.Scenery.Rig.boneGetCentralMassPoint | ( | int | bone | ) |
Bone central mass point.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetRotation().
Referenced by getRootBone().
| ColliderConstraint Dragengine.Scenery.Rig.boneGetConstraintAt | ( | int | bone, |
| int | constraint ) |
Create collider constraint from bone constraint at index.
The created collider constraint can be added to a ColliderRig or ColliderComponent. This is useful if a rig only serves as source for collider bone constraints dynamically managed at runtime or replacing bone constraints with modified versions for example in response to collisions.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
| EOutOfBoundary | constraint is less than 0 or greater than or equal to boneGetConstraintCount(). |
References boneGetIKLimitsUpper().
Referenced by boneShapeGetProperty().
| int Dragengine.Scenery.Rig.boneGetConstraintCount | ( | int | bone | ) |
Bone constraint count.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetIKLimitsLower().
Referenced by boneConstraintGetBoneOffset().
| bool Dragengine.Scenery.Rig.boneGetDynamic | ( | int | bone | ) |
Bone is enabled for dynamic simulation if collider rig or collider component is dynamic.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References getBoneInverseMatrix().
Referenced by boneGetIKLimitsLower().
| Vector Dragengine.Scenery.Rig.boneGetIKLimitsLower | ( | int | bone | ) |
Bone inverse kinematics lower limits used by animator rules.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetDynamic().
Referenced by boneGetConstraintCount().
| Vector Dragengine.Scenery.Rig.boneGetIKLimitsUpper | ( | int | bone | ) |
Bone inverse kinematics upper limits used by animator rules.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
Referenced by boneGetConstraintAt().
| bool Dragengine.Scenery.Rig.boneGetIKLocked | ( | int | bone, |
| int | axis ) |
Bone inverse kinematics per axis locked state used by animator rules.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References getRootBone().
Referenced by boneConstraintGetReferenceOrientation().
| Vector Dragengine.Scenery.Rig.boneGetIKResistance | ( | int | bone | ) |
Bone inverse kinematics resisteance used by animator rules.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetParent().
Referenced by boneConstraintGetReferencePosition().
| float Dragengine.Scenery.Rig.boneGetMass | ( | int | bone | ) |
Bone mass in kg.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References getBoneMatrix().
Referenced by getRootBone().
| String Dragengine.Scenery.Rig.boneGetName | ( | int | bone | ) |
Name of bone at index.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References getBoneCount(), and indexOfBoneNamed().
Referenced by boneGetOrientation().
| Quaternion Dragengine.Scenery.Rig.boneGetOrientation | ( | int | bone | ) |
Bone orientation.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetName().
Referenced by getBoneMatrix().
| int Dragengine.Scenery.Rig.boneGetParent | ( | int | bone | ) |
Index of parent bone or -1 if bone is a root bone.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
Referenced by boneGetIKResistance().
| Vector Dragengine.Scenery.Rig.boneGetPosition | ( | int | bone | ) |
Bone position.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
Referenced by boneGetRotation().
| Vector Dragengine.Scenery.Rig.boneGetRotation | ( | int | bone | ) |
Bone rotation in degrees.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetPosition().
Referenced by boneGetCentralMassPoint().
| ShapeList Dragengine.Scenery.Rig.boneGetShapes | ( | int | bone | ) |
Bone shapes.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
Referenced by getCentralMassPoint().
| String Dragengine.Scenery.Rig.boneShapeGetProperty | ( | int | bone, |
| int | shape ) |
Bone shape property string.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
| EOutOfBoundary | shape is less than 0 or greater than or equal to boneGetShapes().getCount(). |
References boneGetConstraintAt().
Referenced by getCentralMassPoint().
| bool Dragengine.Scenery.Rig.equals | ( | Object | other | ) |
| int Dragengine.Scenery.Rig.getBoneCount | ( | ) |
Number of bones.
Referenced by boneGetName().
| Matrix Dragengine.Scenery.Rig.getBoneInverseMatrix | ( | int | bone | ) |
Matrix transforming from model space to local bone space in reference pose.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
Referenced by boneGetDynamic().
| Matrix Dragengine.Scenery.Rig.getBoneMatrix | ( | int | bone | ) |
Matrix transforming from local bone space to model space in reference pose.
| EOutOfBoundary | bone is less than 0 or greater than or equal to getBoneCount(). |
References boneGetOrientation().
Referenced by boneGetMass().
| Vector Dragengine.Scenery.Rig.getCentralMassPoint | ( | ) |
Rig central mass point.
References boneConstraintGetBoneOffset(), boneConstraintGetReferenceOrientation(), boneGetShapes(), boneShapeGetProperty(), getCentralMassPoint(), getShapes(), and shapeGetProperty().
Referenced by getCentralMassPoint().
| String Dragengine.Scenery.Rig.getFilename | ( | ) |
Normalized filename the rig has been loaded from.
References getFilename().
Referenced by getFilename().
| int Dragengine.Scenery.Rig.getRootBone | ( | ) |
Index of root bone or -1 if no root bone is set.
References boneGetCentralMassPoint(), and boneGetMass().
Referenced by boneGetIKLocked().
| ShapeList Dragengine.Scenery.Rig.getShapes | ( | ) |
| int Dragengine.Scenery.Rig.hashCode | ( | ) |
Hash code for use as dictionary keys.
Implements Object.hashCode().
References hashCode().
Referenced by hashCode().
| int Dragengine.Scenery.Rig.indexOfBoneNamed | ( | String | name | ) |
Index of named bone or -1 if absent.
Referenced by boneGetName().
|
static |
Load rig from file asynchronously.
Registers a request in the game engine to load an rig. Once finished or if the file is already loaded the listener is used to deliver the loaded rig or null if the loading failed.
References loadAsynchron().
Referenced by loadAsynchron().
| Rig Dragengine.Scenery.Rig.new | ( | String | filename | ) |
Load rig from file.
If the rig file has been already loaded it is assigned to this object. If the rig is not loaded yet the engine loads the rig. This call blocks until the rig is fully loaded and ready to be used. For asynchronous loading use loadAsynchron(). Multiple objects can point to the same loaded rig resource. Once no object instance uses an rig file anymore it is released from memory.
References new().
Referenced by new().
| void Dragengine.Scenery.Rig.save | ( | String | filename | ) |
| String Dragengine.Scenery.Rig.shapeGetProperty | ( | int | shape | ) |
Shape property string.
| EOutOfBoundary | shape is less than 0 or greater than or equal to getShapes().getCount(). |
Referenced by getCentralMassPoint().