User Guide

ADOBE ATMOSPHERE 303
User Guide
worldSpacePosition
The worldSpacePosition of the object as a Vector.
// set the worldSpacePosition of the object to a known anchor
myObject.worldSpacePosition = myAnchor3.worldSpacePosition;
worldSpaceOrientation
The worldSpaceOrientation of the object (as a Rotation).
// set the worldSpaceOrientation of the object to a known anchor
myObject.worldSpaceOrientation = myAnchor3.worldSpaceOrientation;
worldSpaceTransform
The worldSpaceTransform is the combined worldSpacePosition and worldSpaceOrientation of the object.
// set the worldSpaceTransform of the object to a known anchor
myObject.worldSpaceTransform = myAnchor3.worldSpaceTransform;
SceneGroup
The SceneGroup module is used to represent a single SceneGroup in the scene graph. A SceneGroup contains a
transformation that affects the location of everything contained within the SceneGroup. A SceneGroup includes an
array of solid objects, an array of Viewpoint objects and an array of child SceneGroups. The SceneGroup may be in
coordinates relative to its parent SceneGroup, or in world coordinates. This is determined by the value of the fl ag
attachedToParentModel”. When the value of this fl ag is changed, the position coordinates are updated to maintain
the same location in world space. Any Atmosphere world saved from the Builder may be loaded as a SceneGroup.
Avatars are also examples of SceneGroups.
When positioning a SceneGroup, you are actually specifying the location of the pivot point of the SceneGroup within
the parent SceneGroup. The origin of the coordinate frame of a SceneGroup is coincident with the location and
orientation of the EntryPoint with title “Pivot” or “Eye” if one is present. (“Eye” is prefered for avatars and “Pivot” for
scene SceneGroups.) If neither is present the pivot point is the origin of the coordinate system for the SceneGroup
as specifi ed in the Builder. To allow a SceneGroup to exhibit physically-realistic motion, a function is used to create a
physical model. This then updates the orientation and position of the SceneGroup every time step.
Note: Any SceneGroup methods that access or perform operations on the geometry or elements within a
SceneGroup can only be done once the SceneGroup has fully loaded. Examples of this are createPhysicalModel, crea
teConvexPhysicalModel, getSolidObjectCount, getSolidObject, getViewpointObjectCount, getViewpointObject, and
getDistantLightCount, getDistantLight.
Global Properties
mySceneGroup
Loaded SceneGroups can have attached scripts, use mySceneGroup to access the SceneGroup from within its
script. In the case of avatar scripts, it refers to the avatar’s SceneGroup.
mySceneGroup.getSolidObject(0).useDynamicLighting = false;