-
Notifications
You must be signed in to change notification settings - Fork 103
SceneObject
daemonburrito edited this page May 6, 2011
·
7 revisions
The SceneObject class is a container used to represent an object in a Scene. A SceneObject can contain meshes, child SceneObjects or simply be a "Null" pointer or target for reference or animation.
Parameters:
-
mesh - A Mesh,
null
to represent an 'Empty' or an Object Constructor. Object constructor is equivalent to object structure. - name (optional) - String name for the SceneObject used for referencing/retrieval.
Object Constructor:
- init object
-
position
- Position in Scene or relative to parent, default:[0.0, 0.0, 0.0]
. -
rotation
- Rotation in Scene or relative to parent, default:[0.0, 0.0, 0.0]
. -
scale
- Scale in Scene or relative to parent, default:[1.0,1.0,1.0]
. -
motion
- A Motion belonging to this SceneObject, default:null
. -
name
- Name of SceneObject for referencing/retrieval, default:null
. -
mesh
- A Mesh, default:null
.
-
Purpose:
Bind another SceneObject as a child of this object. The child object's transformation becomes relative to the parent.
Parameters:
childSceneObject - Another SceneObject to bind as a child.
Returns:
none
Purpose:
Retrieve the SceneObject's current axis-aligned bounding box information. The AABB is just a bounding box that contains the SceneObject's mesh's transformed bounding box in world space.
Returns:
Axis-aligned bounding box, format: [ [minX, minY, minZ] , [maxX, maxY, maxZ] ]
.