Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes

IXRefAtmospheric Class Reference

Search for all occurrences

Detailed Description

Class representing xref atmospherics.

This interface groups functionality specific to xref atmospherics. In order to access functionality common to all xref scene entities, use the IXRefItem interface. An xref atmospheric acts as a wrapper around the xrefed atmospheric (also referred to as the "source atmospheric"). For example, requests for getting the atmospheric's gizmos (NumGizmos, GetGizmo) are passed to the source atmospheric, as are requests for interfaces. Client or plugin code working with atmospherics should not be required to write xref atmospheric specific code, unless the desired functionality is xref specific.

Note:
Note that xref atmospherics can only have gizmos that are xrefs (xref objects) themselves. Xref atmospherics will be automatically removed from the scene when all their gizmos have been removed.
Xref Atmospherics are never nested, even when their gizmos are, and they are always owned by non-nested (top-level) xref records.

#include <iXrefAtmos.h>

Inheritance diagram for IXRefAtmospheric:
Inheritance graph
[legend]

List of all members.

Public Types

enum   { kfpGetSourceAtm }

Public Member Functions

Class_ID  ClassID ()
  Returns the class id of the object type this class represents.
SClass_ID  SuperClassID ()
  Returns the super class id the object type this class represents.
virtual Atmospheric GetSourceAtmospheric (bool resolveNestedXRef=false)=0
  Retrieves the source atmospheric, i.e., the actual atmospheric behind the XRef.
virtual Interface_ID  GetID ()
virtual FPInterfaceDesc GetDesc ()
BEGIN_FUNCTION_MAP  FN_1 (kfpGetSourceAtm, TYPE_REFTARG, GetSourceAtmospheric, TYPE_bool)

Static Public Member Functions

static bool  Is_IXRefAtmospheric (Animatable &animatable)
  Determines whether it is safe to cast an Animatable to an IXRefAtmospheric.
static IXRefAtmospheric GetInterface (InterfaceServer &is)
  Retrieves the IXRefAtmospheric interface from a scene entity.

Static Public Attributes

static FPInterfaceDesc  mFPInterfaceDesc

Member Enumeration Documentation

anonymous enum

Member Function Documentation

Class_ID ClassID ( ) [inline, virtual]

Returns the class id of the object type this class represents.

Reimplemented from Animatable.

{ return XREFATMOS_CLASS_ID; }      
SClass_ID SuperClassID ( ) [inline, virtual]

Returns the super class id the object type this class represents.

Reimplemented from Atmospheric.

{ return ATMOSPHERIC_CLASS_ID; }
virtual Atmospheric* GetSourceAtmospheric ( bool  resolveNestedXRef = false ) [pure virtual]

Retrieves the source atmospheric, i.e., the actual atmospheric behind the XRef.

Parameters:
[in] resolveNestedXRef - When set to true, the method will recursively resolve any nested XRef atmospherics, guaranteeing that the one being returned is NOT an XRef atmospheric. When set to false, the source is returned directly without attempting to resolve nesting.
Returns:
The source atmospheric, or NULL if the XRef is unresolved.
bool Is_IXRefAtmospheric ( Animatable animatable ) [inline, static]

Determines whether it is safe to cast an Animatable to an IXRefAtmospheric.

Parameters:
[in] animatable - The animatable to test.
Returns:
true if the specified animatable can be safely cast to IXRefAtmospheric, false otherwise.
                                                                        {

    return ((animatable.SuperClassID() == ATMOSPHERIC_CLASS_ID) &&
                    (animatable.ClassID() == XREFATMOS_CLASS_ID));
}
static IXRefAtmospheric* GetInterface ( InterfaceServer is ) [inline, static]

Retrieves the IXRefAtmospheric interface from a scene entity.

Parameters:
[in] is - Reference to scene entity
Returns:
- Pointer to the IXRefAtmospheric interface of the scene entity or NULL if it's not an xref atmospheric
                                                               {
        return static_cast<IXRefAtmospheric*>(is.GetInterface(IID_XREF_ATMOS));
    };
virtual Interface_ID GetID ( ) [inline, virtual]
Remarks:
This method overrides GetID() in those interfaces that do not publish metadata but instead have a unique Interface_ID for quick internal identification in implementation code that might be shared by a bunch of mixin interfaces.
Returns:
The Interface_ID.
Default Implementation:
{ return GetDesc()->ID; }

Reimplemented from FPMixinInterface.

{ return IID_XREF_ATMOS; }
virtual FPInterfaceDesc* GetDesc ( ) [inline, virtual]
Remarks:
Returns a pointer to the class which contains the interface metadata.

Implements FPInterface.

{ return &mFPInterfaceDesc; }
BEGIN_FUNCTION_MAP FN_1 ( kfpGetSourceAtm  ,
TYPE_REFTARG  ,
GetSourceAtmospheric  ,
TYPE_bool   
)

Member Data Documentation


IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric
IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric IXRefAtmospheric