| Package | org.papervision3d.objects |
| Class | public class DisplayObject3D |
| Inheritance | DisplayObject3D DisplayObjectContainer3D flash.events.EventDispatcher |
| Subclasses | CameraObject3D, Collada, Vertices3D |
| Property | Defined by | ||
|---|---|---|---|
![]() | children : Object
Returns the children object.
| DisplayObjectContainer3D | |
| container : Sprite
The Sprite that you draw into when rendering in a MovieScene3D.
| DisplayObject3D | ||
| extra : Object
An object that contains user defined properties.
| DisplayObject3D | ||
| faces : Array
[internal-use]
| DisplayObject3D | ||
| geometry : GeometryObject3D
The GeometryObject3D object that contains the 3D definition of this instance.
| DisplayObject3D | ||
| id : int
[read-only] Unique id of this instance.
| DisplayObject3D | ||
| material : MaterialObject3D
The default material for the object instance.
| DisplayObject3D | ||
| materials : MaterialsList
The list of materials for this instance.
| DisplayObject3D | ||
| name : String
An optional object name.
| DisplayObject3D | ||
![]() | numChildren : int
Returns the number of children of this object.
| DisplayObjectContainer3D | |
| parent : DisplayObjectContainer3D
[read-only] Indicates the DisplayObjectContainer3D object that contains this display object.
| DisplayObject3D | ||
| projected : Dictionary
[internal-use]
| DisplayObject3D | ||
![]() | root : DisplayObjectContainer3D
[read-only] [read-only] The scene, which is the top-most displayObjectContainer3D in the tree structure.
| DisplayObjectContainer3D | |
| rotationX : Number
Specifies the rotation around the X axis from its original orientation.
| DisplayObject3D | ||
| rotationY : Number
Specifies the rotation around the Y axis from its original orientation.
| DisplayObject3D | ||
| rotationZ : Number
Specifies the rotation around the Z axis from its original orientation.
| DisplayObject3D | ||
| scale : Number [write-only]
Sets the 3D scale as applied from the registration point of the object.
| DisplayObject3D | ||
| scaleX : Number [write-only]
Sets the scale along the local X axis as applied from the registration point of the object.
| DisplayObject3D | ||
| scaleY : Number [write-only]
Sets the scale along the local Y axis as applied from the registration point of the object.
| DisplayObject3D | ||
| scaleZ : Number [write-only]
Sets the scale along the local Z axis as applied from the registration point of the object.
| DisplayObject3D | ||
| scene : SceneObject3D
The scene where the object belongs.
| DisplayObject3D | ||
| screenZ : Number
[internal-use] The depth (z coordinate) of the transformed object's center.
| DisplayObject3D | ||
| transform : Matrix3D
A Matrix3D object containing values that affect the scaling, rotation, and translation of the display object.
| DisplayObject3D | ||
| view : Matrix3D
[internal-use] A camera transformed Matrix3D object.
| DisplayObject3D | ||
| visible : Boolean
Whether or not the display object is visible.
| DisplayObject3D | ||
| x : Number
An Number that sets the X coordinate of a object relative to the scene coordinate system.
| DisplayObject3D | ||
| y : Number
An Number that sets the Y coordinate of a object relative to the scene coordinates.
| DisplayObject3D | ||
| z : Number
An Number that sets the Z coordinate of a object relative to the scene coordinates.
| DisplayObject3D | ||
| ZERO : DisplayObject3D
[static][read-only]
Returns an empty DiplayObject3D object positioned in the center of the 3D coordinate system (0, 0 ,0).
| DisplayObject3D | ||
| Property | Defined by | ||
|---|---|---|---|
![]() | _children : Dictionary
[internal-use] Names indexed by children.
| DisplayObjectContainer3D | |
![]() | _childrenByName : Object
[internal-use] Children indexed by name.
| DisplayObjectContainer3D | |
| _sorted : Array | DisplayObject3D | ||
| _transformDirty : Boolean = false
[internal-use]
| DisplayObject3D | ||
| Method | Defined by | ||
|---|---|---|---|
|
DisplayObject3D(name:String = null, geometry:GeometryObject3D = null, initObject:Object = null)
Creates a new DisplayObject3D instance.
| DisplayObject3D | ||
![]() |
Adds a child DisplayObject3D instance to this DisplayObjectContainer instance.
| DisplayObjectContainer3D | |
![]() |
Adds all the children of a DisplayObject3D instance to this DisplayObjectContainer instance.
| DisplayObjectContainer3D | |
![]() |
addCollada(filename:String, materials:MaterialsList = null, scale:Number = 1):void
This method has been deprecated.
| DisplayObjectContainer3D | |
|
addGeometry(geometry:GeometryObject3D = null):void
Adds a geometry definition to the instance.
| DisplayObject3D | ||
![]() |
childrenList():String
Returns a string value with the list of objects.
| DisplayObjectContainer3D | |
|
copyPosition(reference:*):void
Copies the position information (x, y and z coordinates) from another object or Matrix3D.
| DisplayObject3D | ||
|
copyTransform(reference:*):void
Copies the transformation information (position, rotation and scale) from another object or Matrix3D.
| DisplayObject3D | ||
|
distanceTo(obj:DisplayObject3D):Number
Gets the distance to the position of the given object.
| DisplayObject3D | ||
![]() |
getChildByName(name:String):DisplayObject3D
Returns the child display object that exists with the specified name.
| DisplayObjectContainer3D | |
|
getMaterialByName(name:String):MaterialObject3D
Returns the material that exists with the specified name in the materials list.
| DisplayObject3D | ||
|
hitTestObject(obj:DisplayObject3D, multiplier:Number = 1):Boolean
Evaluates the display object to see if it overlaps or intersects with the obj display object.
| DisplayObject3D | ||
|
hitTestPoint(x:Number, y:Number, z:Number):Boolean
Evaluates the display object to see if it overlaps or intersects with the point specified by the x, y and z parameters.
| DisplayObject3D | ||
|
Make the object look at a specific position.
| DisplayObject3D | ||
|
materialsList():String
Returns a string value with the list of material names of the materials list.
| DisplayObject3D | ||
|
moveBackward(distance:Number):void
Translate the display object in the opposite direction it is facing, i.e.
| DisplayObject3D | ||
|
moveDown(distance:Number):void
Translate the display object downwards, with respect to the direction it is facing, i.e.
| DisplayObject3D | ||
|
moveForward(distance:Number):void
Translate the display object in the direction it is facing, i.e.
| DisplayObject3D | ||
|
moveLeft(distance:Number):void
Translate the display object lateraly, to the left of the direction it is facing, i.e.
| DisplayObject3D | ||
|
moveRight(distance:Number):void
Translate the display object lateraly, to the right of the direction it is facing, i.e.
| DisplayObject3D | ||
|
moveUp(distance:Number):void
Translate the display object upwards, with respect to the direction it is facing, i.e.
| DisplayObject3D | ||
|
pitch(angle:Number):void
Rotate the display object around its lateral or transverse axis an axis running from the pilot's left to right in piloted aircraft, and parallel to the wings of a winged aircraft; thus the nose pitches up and the tail down, or vice-versa.
| DisplayObject3D | ||
|
[internal-use] Projects three dimensional coordinates onto a two dimensional plane to simulate the relationship of the camera to subject.
| DisplayObject3D | ||
![]() |
Removes the specified child DisplayObject3D instance from the child list of the DisplayObjectContainer3D instance.
| DisplayObjectContainer3D | |
![]() |
removeChildByName(name:String):DisplayObject3D
Removes the child DisplayObject3D instance that exists with the specified name, from the child list of the DisplayObjectContainer3D instance.
| DisplayObjectContainer3D | |
|
render(scene:SceneObject3D):void
[internal-use] Render the projected object.
| DisplayObject3D | ||
|
roll(angle:Number):void
Rotate the display object around the longitudinal axis an axis drawn through the body of the vehicle from tail to nose in the normal direction of flight, or the direction the object is facing.
| DisplayObject3D | ||
|
toString():String
Returns a string value representing the three-dimensional position values of the display object instance.
| DisplayObject3D | ||
|
Move the object along a given direction.
| DisplayObject3D | ||
|
yaw(angle:Number):void
Rotate the display object around about the vertical axis an axis drawn from top to bottom.
| DisplayObject3D | ||
| Method | Defined by | ||
|---|---|---|---|
|
updateTransform():void
[internal-use] Updates the transform Matrix3D with the current rotation and scale values.
| DisplayObject3D | ||
| container | property |
public var container:SpriteThe Sprite that you draw into when rendering in a MovieScene3D. While Scene3D uses a single Sprite container for all the objects, MovieScene3D renders each object in its own unique Sprite. You can use the container like any other Sprite. For example, you can add events to it, apply filters or change the blend mode.
| extra | property |
public var extra:ObjectAn object that contains user defined properties.
All properties of the extra field are copied into the new instance. The properties specified with extra are publicly available.| faces | property |
public var faces:Array[internal-use]
| geometry | property |
public var geometry:GeometryObject3DThe GeometryObject3D object that contains the 3D definition of this instance.
When different objects share the same geometry, they become instances. They are the same object, displayed multiple times. Changing the shape of this object changes the shape of all of its instances. Instancing an object saves system memory, and is useful to display an object multiple times while maintaining its shape. For example, you could create armies and forests full of duplicate objects without needing the memory to handle that much actual geometry. Each instance has its own transform node so it can have its own position, rotation, and scaling.| id | property |
public var id:int[read-only] Unique id of this instance.
| material | property |
public var material:MaterialObject3DThe default material for the object instance. Materials collect data about how objects appear when rendered.
| materials | property |
public var materials:MaterialsListThe list of materials for this instance.
| name | property |
public var name:StringAn optional object name.
| parent | property |
public var parent:DisplayObjectContainer3D[read-only] Indicates the DisplayObjectContainer3D object that contains this display object.
| projected | property |
public var projected:Dictionary[internal-use]
| rotationX | property |
rotationX:Number [read-write]Specifies the rotation around the X axis from its original orientation.
Implementation public function get rotationX():Number
public function set rotationX(value:Number):void
| rotationY | property |
rotationY:Number [read-write]Specifies the rotation around the Y axis from its original orientation.
Implementation public function get rotationY():Number
public function set rotationY(value:Number):void
| rotationZ | property |
rotationZ:Number [read-write]Specifies the rotation around the Z axis from its original orientation.
Implementation public function get rotationZ():Number
public function set rotationZ(value:Number):void
| scale | property |
scale:Number [write-only]Sets the 3D scale as applied from the registration point of the object.
Implementation public function set scale(value:Number):void
| scaleX | property |
scaleX:Number [write-only]Sets the scale along the local X axis as applied from the registration point of the object.
Implementation public function set scaleX(value:Number):void
| scaleY | property |
scaleY:Number [write-only]Sets the scale along the local Y axis as applied from the registration point of the object.
Implementation public function set scaleY(value:Number):void
| scaleZ | property |
scaleZ:Number [write-only]Sets the scale along the local Z axis as applied from the registration point of the object.
Implementation public function set scaleZ(value:Number):void
| scene | property |
public var scene:SceneObject3DThe scene where the object belongs.
| screenZ | property |
public var screenZ:Number[internal-use] The depth (z coordinate) of the transformed object's center. Also known as the distance from the camera. Used internally for z-sorting.
| _sorted | property |
protected var _sorted:Array
| transform | property |
public var transform:Matrix3DA Matrix3D object containing values that affect the scaling, rotation, and translation of the display object.
| _transformDirty | property |
protected var _transformDirty:Boolean = false[internal-use]
| view | property |
public var view:Matrix3D[internal-use] A camera transformed Matrix3D object.
| visible | property |
public var visible:BooleanWhether or not the display object is visible.
A Boolean value that indicates whether the object is projected, transformed and rendered. A value of false will effectively ignore the object. The default value is true.| x | property |
x:Number [read-write]An Number that sets the X coordinate of a object relative to the scene coordinate system.
Implementation public function get x():Number
public function set x(value:Number):void
| y | property |
y:Number [read-write]An Number that sets the Y coordinate of a object relative to the scene coordinates.
Implementation public function get y():Number
public function set y(value:Number):void
| z | property |
z:Number [read-write]An Number that sets the Z coordinate of a object relative to the scene coordinates.
Implementation public function get z():Number
public function set z(value:Number):void
| ZERO | property |
ZERO:DisplayObject3D [read-only]Returns an empty DiplayObject3D object positioned in the center of the 3D coordinate system (0, 0 ,0).
Implementation public static function get ZERO():DisplayObject3D
| DisplayObject3D | () | constructor |
public function DisplayObject3D(name:String = null, geometry:GeometryObject3D = null, initObject:Object = null)Creates a new DisplayObject3D instance. After creating the instance, call the addChild() method of a DisplayObjectContainer3D.
Parametersname:String (default = null) — [optional] - The name of the newly created object.
|
|
geometry:GeometryObject3D (default = null) — [optional] - The geometry of the newly created object.
|
|
initObject:Object (default = null) — [optional] - An object that contains user defined properties with which to populate the newly created DisplayObject3D.
|
| addGeometry | () | method |
public function addGeometry(geometry:GeometryObject3D = null):voidAdds a geometry definition to the instance. A geometry describes the visual shape and appearance of an object in a scene.
Parametersgeometry:GeometryObject3D (default = null) — A geometry definition.
|
| copyPosition | () | method |
public function copyPosition(reference:*):voidCopies the position information (x, y and z coordinates) from another object or Matrix3D.
Parametersreference:* — A DisplayObject3D or Matrix3D object to copy the position from.
|
| copyTransform | () | method |
public function copyTransform(reference:*):voidCopies the transformation information (position, rotation and scale) from another object or Matrix3D.
Parametersreference:* — A DisplayObject3D or Matrix3D object to copy the position from.
|
| distanceTo | () | method |
public function distanceTo(obj:DisplayObject3D):NumberGets the distance to the position of the given object.
Parametersobj:DisplayObject3D — The display object to measure the distance to.
|
Number — The distance to the registration point of the given object.
|
| getMaterialByName | () | method |
public function getMaterialByName(name:String):MaterialObject3DReturns the material that exists with the specified name in the materials list.
If more that one material object has the specified name, the method returns the first material object in the materials list. Parametersname:String — The name of the material to return.
|
MaterialObject3D —
The material object with the specified name.
|
| hitTestObject | () | method |
public function hitTestObject(obj:DisplayObject3D, multiplier:Number = 1):BooleanEvaluates the display object to see if it overlaps or intersects with the obj display object.
Parametersobj:DisplayObject3D — The display object to test against.
|
|
multiplier:Number (default = 1) |
Boolean — true if the display objects intersect; false if not.
|
| hitTestPoint | () | method |
public function hitTestPoint(x:Number, y:Number, z:Number):BooleanEvaluates the display object to see if it overlaps or intersects with the point specified by the x, y and z parameters.
The x, y and z parameters specify a point in the coordinate space of the instance parent object, not the scene (unless that parent object is the scene). Parametersx:Number — The x coordinate to test against this object.
|
|
y:Number — The y coordinate to test against this object.
|
|
z:Number — The z coordinate to test against this object.
|
Boolean — true if the display object overlaps or intersects with the specified point; false otherwise.
|
| lookAt | () | method |
public function lookAt(targetObject:DisplayObject3D, upAxis:Number3D = null):voidMake the object look at a specific position.
ParameterstargetObject:DisplayObject3D — Object to look at.
|
|
upAxis:Number3D (default = null) — The vertical axis of the universe. Normally the positive Y axis.
|
| materialsList | () | method |
public function materialsList():StringReturns a string value with the list of material names of the materials list.
ReturnsString — A string.
|
| moveBackward | () | method |
public function moveBackward(distance:Number):voidTranslate the display object in the opposite direction it is facing, i.e. it's negative Z axis.
Parametersdistance:Number — The distance that the object should move backward.
|
| moveDown | () | method |
public function moveDown(distance:Number):voidTranslate the display object downwards, with respect to the direction it is facing, i.e. it's negative Y axis.
Parametersdistance:Number — The distance that the object should move down.
|
| moveForward | () | method |
public function moveForward(distance:Number):voidTranslate the display object in the direction it is facing, i.e. it's positive Z axis.
Parametersdistance:Number — The distance that the object should move forward.
|
| moveLeft | () | method |
public function moveLeft(distance:Number):voidTranslate the display object lateraly, to the left of the direction it is facing, i.e. it's negative X axis.
Parametersdistance:Number — The distance that the object should move left.
|
| moveRight | () | method |
public function moveRight(distance:Number):voidTranslate the display object lateraly, to the right of the direction it is facing, i.e. it's positive X axis.
Parametersdistance:Number — The distance that the object should move right.
|
| moveUp | () | method |
public function moveUp(distance:Number):voidTranslate the display object upwards, with respect to the direction it is facing, i.e. it's positive Y axis.
Parametersdistance:Number — The distance that the object should move up.
|
| pitch | () | method |
public function pitch(angle:Number):voidRotate the display object around its lateral or transverse axis an axis running from the pilot's left to right in piloted aircraft, and parallel to the wings of a winged aircraft; thus the nose pitches up and the tail down, or vice-versa.
Parametersangle:Number — The angle to rotate.
|
| project | () | method |
public function project(parent:DisplayObject3D, camera:CameraObject3D, sorted:Array = null):Number[internal-use] Projects three dimensional coordinates onto a two dimensional plane to simulate the relationship of the camera to subject.
This is the first step in the process of representing three dimensional shapes two dimensionally. Parametersparent:DisplayObject3D — The DisplayObject3D object that contains this display object.
|
|
camera:CameraObject3D — Camera3D object to render from.
|
|
sorted:Array (default = null) — The list of faces of the current sort branch.
|
Number |
| render | () | method |
public function render(scene:SceneObject3D):void[internal-use] Render the projected object.
Parametersscene:SceneObject3D — The scene where the object belongs.
|
| roll | () | method |
public function roll(angle:Number):voidRotate the display object around the longitudinal axis an axis drawn through the body of the vehicle from tail to nose in the normal direction of flight, or the direction the object is facing.
Parametersangle:Number |
| toString | () | method |
public override function toString():StringReturns a string value representing the three-dimensional position values of the display object instance.
ReturnsString — A string.
|
| translate | () | method |
public function translate(distance:Number, axis:Number3D):voidMove the object along a given direction.
Parametersdistance:Number — The distance that the object should travel.
|
|
axis:Number3D — The direction that the object should move towards.
|
| updateTransform | () | method |
protected function updateTransform():void[internal-use] Updates the transform Matrix3D with the current rotation and scale values.
| yaw | () | method |
public function yaw(angle:Number):voidRotate the display object around about the vertical axis an axis drawn from top to bottom.
Parametersangle:Number — The angle to rotate.
|