| Package | de.nulldesign.nd3d.objects |
| Class | public class KeyframeMesh |
| Inheritance | KeyframeMesh Mesh Object3D |
| Subclasses | MD2 |
There are a couple very specific details that must be adhered to by all subclasses in order for this to work properly:
[1] The subclass MUST allocate properly sized arrays with memory for faces and vertices
[2] The Face3D objects in faces must have an id cooresponding to their original array order
Please feel free to use, but please mention me!
| Property | Defined by | ||
|---|---|---|---|
![]() | angleX : Number | Object3D | |
![]() | angleY : Number | Object3D | |
![]() | angleZ : Number | Object3D | |
![]() | container : Sprite | Object3D | |
![]() | deltaAngleX : Number = 0 | Object3D | |
![]() | deltaAngleY : Number = 0 | Object3D | |
![]() | deltaAngleZ : Number = 0 | Object3D | |
![]() | direction : Vertex | Object3D | |
![]() | faceList : Array | Object3D | |
| fps : int
Number of animation frames to display per second
| KeyframeMesh | ||
| frames : Array
The array of frames that make up the animation sequence.
| KeyframeMesh | ||
![]() | hidden : Boolean = false | Object3D | |
![]() | isInteractive : Boolean = false | Object3D | |
| keyframe : int | KeyframeMesh | ||
![]() | name : String | Object3D | |
![]() | positionAsVertex : Vertex | Object3D | |
![]() | quaternion : Quaternion | Object3D | |
![]() | scaleX : Number = 1 | Object3D | |
![]() | scaleY : Number = 1 | Object3D | |
![]() | scaleZ : Number = 1 | Object3D | |
![]() | userData : * | Object3D | |
![]() | vertexList : Array | Object3D | |
![]() | xPos : Number = 0 | Object3D | |
![]() | yPos : Number = 0 | Object3D | |
![]() | zPos : Number = 0 | Object3D | |
| Method | Defined by | ||
|---|---|---|---|
|
KeyframeMesh(material:Material, fps:int = 24, scale:Number = 1)
KeyframeMesh is a class used [internal] to provide a "keyframe animation"/"vertex animation"/"mesh deformation"
framework for subclass loaders.
| KeyframeMesh | ||
![]() |
Adds a new face to the mesh
| Mesh | |
![]() |
Clones the mesh
| Mesh | |
![]() |
deg2rad(deg:Number):Number
[static]
| Object3D | |
![]() |
flipNormals():void
Flips the normals of every face in the mesh
| Mesh | |
![]() |
getAngles():String
| Object3D | |
|
gotoAndPlay(frame:int):void
| KeyframeMesh | ||
|
gotoAndStop(frame:int):void
| KeyframeMesh | ||
![]() |
lookAtDirection():void
| Object3D | |
![]() |
lookAtTarget(target:Object3D):void
| Object3D | |
|
loop(start:int, end:int):void
| KeyframeMesh | ||
![]() |
moveToDirection(speed:Number):void
| Object3D | |
![]() |
rad2deg(rad:Number):Number
[static]
| Object3D | |
![]() |
rotateAround(origin:Object3D, angleX:Number = 0, angleY:Number = 0):void
| Object3D | |
![]() |
rotateVerticesX(angle:Number):void
Rotate vertices coordinates around X axis
| Object3D | |
![]() |
rotateVerticesY(angle:Number):void
Rotate vertices coordinates around Y axis
| Object3D | |
![]() |
rotateVerticesZ(angle:Number):void
Rotate vertices coordinates around Z axis
| Object3D | |
![]() |
scale(x:Number = 1, y:Number = 1, z:Number = 1):void
| Object3D | |
|
stop():void
| KeyframeMesh | ||
![]() |
toString():String
| Object3D | |
![]() |
translateVertices(tx:Number, ty:Number, tz:Number):void
Translate vertices coordinates
| Object3D | |
|
update():void
| KeyframeMesh | ||
![]() |
vertexInList(v:Vertex):Boolean
Checks if a mesh already contains a vertex
| Mesh | |
![]() |
weldVertices(tolerance:Number = 1):void
Welds vertices that are close together
| Mesh | |
| Constant | Defined by | ||
|---|---|---|---|
| ANIM_LOOP : int = 2 [static]
| KeyframeMesh | ||
| ANIM_NORMAL : int = 1 [static]
Three kinds of animation sequences:
[1] Normal (sequential, just playing)
[2] Loop (a loop)
[3] Stop (stopped, not animating)
| KeyframeMesh | ||
| ANIM_STOP : int = 4 [static]
| KeyframeMesh | ||
| fps | property |
public var fps:intNumber of animation frames to display per second
| frames | property |
public var frames:ArrayThe array of frames that make up the animation sequence.
| keyframe | property |
keyframe:int [read-write]Implementation
public function get keyframe():int
public function set keyframe(value:int):void
| KeyframeMesh | () | constructor |
public function KeyframeMesh(material:Material, fps:int = 24, scale:Number = 1)KeyframeMesh is a class used [internal] to provide a "keyframe animation"/"vertex animation"/"mesh deformation" framework for subclass loaders. There are some subtleties to using this class, so please, I suggest you don't (not yet). Possible file formats are MD2, MD3, 3DS, etc...
Parametersmaterial:Material |
|
fps:int (default = 24) |
|
scale:Number (default = 1) |
| gotoAndPlay | () | method |
public function gotoAndPlay(frame:int):voidParameters
frame:int |
| gotoAndStop | () | method |
public function gotoAndStop(frame:int):voidParameters
frame:int |
| loop | () | method |
public function loop(start:int, end:int):voidParameters
start:int |
|
end:int |
| stop | () | method |
public function stop():void
| update | () | method |
public function update():void
| ANIM_LOOP | constant |
public static const ANIM_LOOP:int = 2
| ANIM_NORMAL | constant |
public static const ANIM_NORMAL:int = 1Three kinds of animation sequences: [1] Normal (sequential, just playing) [2] Loop (a loop) [3] Stop (stopped, not animating)
| ANIM_STOP | constant |
public static const ANIM_STOP:int = 4