00001 //*************************************************************************************** 00002 // File supervisor: Crosswalk team 00012 //*************************************************************************************** 00013 00014 #ifndef _FOG_H 00015 #define _FOG_H 00016 00017 #include "Template.h" 00018 00024 class XSIEXPORT CSLFog 00025 : public CSLTemplate 00026 { 00027 public: 00030 enum EFogType 00031 { 00032 SI_VERTEX, 00033 SI_PIXEL, 00034 }; 00035 00038 enum EFogInterpolationType 00039 { 00040 SI_LINEAR, 00041 SI_EXPONENTIAL, 00042 }; 00043 00050 CSLFog(CSLScene* in_pScene, CSLModel *in_pModel, CdotXSITemplate* in_pTemplate); 00051 00054 virtual ~CSLFog(); 00055 00059 EFogType GetFogType() { return m_Type; } 00060 00064 SI_Void SetFogType(EFogType in_Type) { m_Type = in_Type; } 00065 00069 EFogInterpolationType GetFogInterpolationType() { return m_InterpolationType; } 00070 00074 SI_Void SetFogInterpolationType(EFogInterpolationType in_Type) { m_InterpolationType = in_Type; } 00075 00079 CSIBCColorf GetColor() { return m_Color; } 00080 00084 SI_Void SetColor(CSIBCColorf& in_rColor) { m_Color = in_rColor; } 00085 00089 SI_Float GetNear() { return m_Near; } 00090 00094 SI_Void SetNear(SI_Float in_fValue) { m_Near = in_fValue; } 00095 00099 SI_Float GetFar() { return m_Far; } 00100 00104 SI_Void SetFar(SI_Float in_fValue) { m_Far = in_fValue; } 00105 00110 virtual CSLAnimatableType* ParameterFromName(SI_Char *in_szName); 00111 00117 virtual CSLAnimatableType* ParameterFromType(EFCurveType in_Type, SI_Char *in_szParameterName); 00118 00122 virtual ETemplateType Type() { return SI_FOG; } 00123 00124 CSLColorRGBProxy* GetColorProxy(){ return &m_Color; }; 00125 CSLFloatProxy* GetNearProxy(){ return &m_Near; }; 00126 CSLFloatProxy* GetFarProxy(){ return &m_Far; }; 00127 00128 private: 00129 CSLEnumProxy<EFogType, SI_FOG> m_Type; 00130 CSLEnumProxy<EFogInterpolationType, SI_EXPONENTIAL> m_InterpolationType; 00131 00132 CSLColorRGBProxy m_Color; 00133 CSLFloatProxy m_Near; 00134 CSLFloatProxy m_Far; 00135 }; 00136 00137 #endif