MaterialReflections Class Reference

#include <private_reflectionmain.h>

Public Member Functions

 MaterialReflections ()
 
virtual ~MaterialReflections ()
 
void Init (Material *pMaterial)
 
Int32 ConvertToID (Int32 nDescID)
 
Int32 ConvertToLayerID (Int32 nDescID)
 
Int32 ConvertToDataID (Int32 nDescID)
 
XReflectionLayerGetLayerFromLayerDataID (Int32 nLayerID)
 
void ScaleAnimationTrack (CTrack *pTrack, Float fScale)
 
void CopyAnimationData (Int32 nSourceID, Int32 nTargetID, Bool bQuick=false, Bool bScale=false, Float fScale=1.0)
 
void RemapOldData (BaseContainer *pData, Bool bOnLoad, Int32 nFileVersion)
 
void FindPrimaryLayers (BaseContainer *pData, Int32 &nLayerReflection, Int32 &nLayerSpecular)
 
void RebuildOldData (BaseContainer *pData, Bool bQuick)
 
void RebuildOldDataRestore (BaseContainer *pData)
 
Bool RemapOldReflectionLayersData (BaseContainer *pData)
 
ReflectionLayerSDKAddReflectionLayer ()
 
ReflectionLayerSDKGetReflectionLayerID (Int32 nID)
 
ReflectionLayerSDKGetReflectionLayerIndex (Int32 nIndex)
 
ReflectionLayerSDKGetReflectionLayerTrans ()
 
Int32 SDKGetReflectionLayerCount ()
 
void SDKRemoveReflectionLayerID (Int32 nID)
 
void SDKRemoveReflectionLayerIndex (Int32 nIndex)
 
void SDKRemoveReflectionAllLayers ()
 
void SDKGetAllReflectionShaders (BaseArray< BaseShader * > &ShaderList)
 
void SDKGetReflectionPrimaryLayers (Int32 &nLayerReflection, Int32 &nLayerSpecular)
 
Int32 SDKReflectionLayerGetLayerID (const ReflectionLayer *layer)
 
String SDKReflectionLayerGetName (const ReflectionLayer *layer)
 
void SDKReflectionLayerSetName (ReflectionLayer *layer, const String &name)
 
Int32 SDKReflectionLayerGetFlags (const ReflectionLayer *layer)
 
void SDKReflectionLayerSetFlags (ReflectionLayer *layer, Int32 flags)
 
Bool GetParameter (const DescID &id, GeData &t_data)
 
Bool SetDParameter (const DescID &id, const GeData &t_data)
 
Int GetLayerCount ()
 

Static Public Member Functions

static String GetDefaultLayerName (Int32 layerId)
 

Public Attributes

Materialm_pMaterial
 
BaseContainerm_pData
 
iXRLayersDataTypem_pLayerData
 
Bool m_bSaveStateReflection
 
Bool m_bSaveStateSpecular
 
Float m_fGlobalReflection
 
Float m_fGlobalSpecular
 
Bool m_bValidDDUV
 
String m_szLayerName
 
Int32 m_tristatePreviewFlags
 
Int32 _tristateLayerNameFlags
 

Detailed Description

Handles material reflection channel.

Constructor & Destructor Documentation

◆ MaterialReflections()

◆ ~MaterialReflections()

virtual ~MaterialReflections ( )
virtual

Member Function Documentation

◆ Init()

void Init ( Material pMaterial)

Initializes reflection channel with default values. A 'Default Specular' layer is added.

Parameters
[in]pMaterialThe material to initialize its reflection channel.

◆ ConvertToID()

Int32 ConvertToID ( Int32  nDescID)

Converts a description id into a reflection layer parameter id.

Parameters
[in]nDescIDThe description id.
Returns
The reflection layer parameter id.

◆ ConvertToLayerID()

Int32 ConvertToLayerID ( Int32  nDescID)

Converts a description id into a reflection layer id.

Parameters
[in]nDescIDThe description id.
Returns
The layer id.

◆ ConvertToDataID()

Int32 ConvertToDataID ( Int32  nDescID)

◆ GetLayerFromLayerDataID()

XReflectionLayer* GetLayerFromLayerDataID ( Int32  nLayerID)

◆ ScaleAnimationTrack()

void ScaleAnimationTrack ( CTrack pTrack,
Float  fScale 
)

◆ CopyAnimationData()

void CopyAnimationData ( Int32  nSourceID,
Int32  nTargetID,
Bool  bQuick = false,
Bool  bScale = false,
Float  fScale = 1.0 
)

◆ RemapOldData()

void RemapOldData ( BaseContainer pData,
Bool  bOnLoad,
Int32  nFileVersion 
)

◆ FindPrimaryLayers()

void FindPrimaryLayers ( BaseContainer pData,
Int32 nLayerReflection,
Int32 nLayerSpecular 
)

◆ RebuildOldData()

void RebuildOldData ( BaseContainer pData,
Bool  bQuick 
)

◆ RebuildOldDataRestore()

void RebuildOldDataRestore ( BaseContainer pData)

◆ RemapOldReflectionLayersData()

Bool RemapOldReflectionLayersData ( BaseContainer pData)

◆ SDKAddReflectionLayer()

ReflectionLayer* SDKAddReflectionLayer ( )

◆ SDKGetReflectionLayerID()

ReflectionLayer* SDKGetReflectionLayerID ( Int32  nID)

◆ SDKGetReflectionLayerIndex()

ReflectionLayer* SDKGetReflectionLayerIndex ( Int32  nIndex)

◆ SDKGetReflectionLayerTrans()

ReflectionLayer* SDKGetReflectionLayerTrans ( )

◆ SDKGetReflectionLayerCount()

Int32 SDKGetReflectionLayerCount ( )

◆ SDKRemoveReflectionLayerID()

void SDKRemoveReflectionLayerID ( Int32  nID)

◆ SDKRemoveReflectionLayerIndex()

void SDKRemoveReflectionLayerIndex ( Int32  nIndex)

◆ SDKRemoveReflectionAllLayers()

void SDKRemoveReflectionAllLayers ( )

◆ SDKGetAllReflectionShaders()

void SDKGetAllReflectionShaders ( BaseArray< BaseShader * > &  ShaderList)

◆ SDKGetReflectionPrimaryLayers()

void SDKGetReflectionPrimaryLayers ( Int32 nLayerReflection,
Int32 nLayerSpecular 
)

◆ SDKReflectionLayerGetLayerID()

Int32 SDKReflectionLayerGetLayerID ( const ReflectionLayer layer)

◆ SDKReflectionLayerGetName()

String SDKReflectionLayerGetName ( const ReflectionLayer layer)

◆ SDKReflectionLayerSetName()

void SDKReflectionLayerSetName ( ReflectionLayer layer,
const String name 
)

◆ SDKReflectionLayerGetFlags()

Int32 SDKReflectionLayerGetFlags ( const ReflectionLayer layer)

◆ SDKReflectionLayerSetFlags()

void SDKReflectionLayerSetFlags ( ReflectionLayer layer,
Int32  flags 
)

◆ GetParameter()

Bool GetParameter ( const DescID id,
GeData t_data 
)

◆ SetDParameter()

Bool SetDParameter ( const DescID id,
const GeData t_data 
)

◆ GetDefaultLayerName()

static String GetDefaultLayerName ( Int32  layerId)
static

Gets the default layer name. Example: if layerId is 3, then layer name will be "Layer 3".

Parameters
[in]layerIdLayer id.
Returns
The layer name.

◆ GetLayerCount()

Int GetLayerCount ( )

Gets the layer count (incl. transparency layer)

Returns
Layer count.

Member Data Documentation

◆ m_pMaterial

Material* m_pMaterial

◆ m_pData

BaseContainer* m_pData

◆ m_pLayerData

iXRLayersDataType* m_pLayerData

◆ m_bSaveStateReflection

Bool m_bSaveStateReflection

◆ m_bSaveStateSpecular

Bool m_bSaveStateSpecular

◆ m_fGlobalReflection

Float m_fGlobalReflection

◆ m_fGlobalSpecular

Float m_fGlobalSpecular

◆ m_bValidDDUV

Bool m_bValidDDUV

◆ m_szLayerName

String m_szLayerName

◆ m_tristatePreviewFlags

Int32 m_tristatePreviewFlags

◆ _tristateLayerNameFlags

Int32 _tristateLayerNameFlags