Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
TSceneState
Inherited By:
None.
Purpose:
TRootSceneState is a concrete class, derived from TSceneState, that is ideal for the root 2-D scene state of a graphic hierarchy. The class supplies the default light, camera, and so forth. (The default camera is a perspective camera, the default ambient light is white, and the default atmosphere shader is a TDepthCueingShader whose depth cue color is white and whose near and far Z values are 1e10.) The TRootGrafState class uses a TRootSceneState to represent the default scene state.
To create a hierarchy, link TLinkableSceneState objects to a TRootSceneState object by passing it as an argument to their LinkTo member functions.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
None.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
- TRootSceneState ()
- TRootSceneState (const TRootSceneState &)
Interface Category:
API.
Purpose:
- Default constructor. The default camera is a perspective camera, the default ambient light is white, and the default atmosphere shader is a TDepthCueingShader whose depth cue color is white and whose near and far Z values are 1e10.
- Copy constructor.
Calling Context:
- Called by the stream-in operators. You can also call this function directly.
- Called to copy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TRootSceneState ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TRootSceneState::GetAmbientLight
virtual void GetAmbientLight (TColor &) const
Interface Category:
API.
Purpose:
Returns, in its argument, a TColor indicating the intensity and hue of the ambient light shining on the scene.
Calling Context:
You can call this function directly.
Parameters:
- TColor & -The color (hue and intensity) of the ambient light is returned here.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TRootSceneState::GetAtmosphereShader
virtual const TAtmosphereShader * GetAtmosphereShader () const
Interface Category:
API.
Purpose:
Returns a constant pointer to the TAtmosphereShader, which simulates atmospheric attenuation due to haze, clouds, or fog between the objects in the scene and the viewer.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Returns a constant pointer to the TAtmosphereShader held by this object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual const TCamera * GetCamera () const
Interface Category:
API.
Purpose:
Returns a constant pointer to the TCamera, which simulates a camera or eye that views the scene.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Returns a constant pointer to the TCamera held by this object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TRootSceneState::GetSceneAttribute
virtual const TGrafAttribute * GetSceneAttribute (const TToken & attributeName) const
Interface Category:
API.
Purpose:
This function always returns NIL because there are no extended attributes in a TRootSceneState. The function is implemented simply to satisfy polymorphism, because this class is a concrete descendant of TSceneState.
Calling Context:
You can call this function directly.
Parameters:
- const TToken & attributeName -The name of the requested attribute.
Return Value:
Returns a constant pointer to a TGrafAttribute that is always set to NIL.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TRootSceneState::CreateSceneAttributeIterator
virtual TSceneAttributeIterator * CreateSceneAttributeIterator () const
Interface Category:
API.
Purpose:
This function always returns NIL because there are no extended attributes in a TRootSceneState. The function is implemented simply to satisfy polymorphism, because this class is a concrete descendant of TSceneState.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Returns a constant pointer to a TSceneAttributeIterator that is always set to NIL.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TRootSceneState::CreateLightIterator
virtual TIteratorOver < TKeyValuePair < TLightSurrogate , TLight >>* CreateLightIterator () const
Interface Category:
API.
Purpose:
This function always returns NIL because there is no default set of lights in a TRootSceneState. The function is implemented simply to satisfy polymorphism, because this class is a concrete descendant of TSceneState.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Always returns NIL.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.