Go to the documentation of this file.00001 #ifndef __FBLIGHT_H__
00002 #define __FBLIGHT_H__
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00043 #include <kaydaradef.h>
00044 #ifndef FBSDK_DLL
00045
00048 #define FBSDK_DLL K_DLLIMPORT
00049 #endif
00050
00051 #include <fbsdk/fbmodel.h>
00052
00053 #ifdef FBSDKUseNamespace
00054 namespace FBSDKNamespace {
00055 #endif
00056
00057 FB_DEFINE_COMPONENT( FBSDK_DLL, Light );
00058
00060
00062 __FB_FORWARD( FBLight );
00063
00065 enum FBLightType {
00066 kFBLightTypePoint = 0,
00067 kFBLightTypeInfinite,
00068 kFBLightTypeSpot,
00069 kFBLightTypeArea
00070 };
00071
00072 FB_DEFINE_ENUM( FBSDK_DLL, LightType );
00073
00075 enum FBAttenuationType {
00076 kFBAttenuationNone = 0,
00077 kFBAttenuationLinear,
00078 kFBAttenuationQuadratic,
00079 kFBAttenuationCubic
00080 };
00081
00082 FB_DEFINE_ENUM( FBSDK_DLL, AttenuationType );
00083
00085 class FBSDK_DLL FBLight : public FBModel
00086 {
00087 __FBClassDeclare( FBLight,FBModel );
00088 public:
00093 FBLight(const char* pName, HIObject pObject=NULL);
00094
00096 enum EAreaLightShapes {
00097 eRectangle,
00098 eSphere
00099 };
00100
00101 typedef FBPropertyBaseEnum<EAreaLightShapes> PropertyAreaLightShapes;
00102
00103
00104
00111 FBPropertyLightType LightType;
00112 PropertyAreaLightShapes AreaLightShape;
00113 FBPropertyAttenuationType AttenuationType;
00114 FBPropertyAnimatableDouble Intensity;
00115 FBPropertyAnimatableDouble InnerAngle;
00116 FBPropertyAnimatableDouble OuterAngle;
00117 FBPropertyAnimatableDouble ConeAngle;
00118 FBPropertyAnimatableDouble FogIntensity;
00119 FBPropertyAnimatableColor DiffuseColor;
00120 FBPropertyBool CastLightOnObject;
00121 FBPropertyBool CastShadows;
00122
00123
00124 FBPropertyBool DrawGroundProjection;
00125 FBPropertyBool DrawVolumetricLight;
00126 FBPropertyBool DrawFrontFacingVolumetric;
00127 FBPropertyVideo GoboMedia;
00128
00129 FBPropertyBool EnableBarnDoor;
00130 FBPropertyDouble LeftBarnDoor;
00131 FBPropertyDouble RightBarnDoor;
00132 FBPropertyDouble TopBarnDoor;
00133 FBPropertyDouble BottomBarnDoor;
00134 };
00135
00137
00140 class FBSDK_DLL FBPropertyListLight : public FBPropertyListComponent
00141 {
00142 public:
00143 FBPropertyListLight();
00148 FBLight* operator[](int pIndex);
00149 };
00150
00152
00154 __FB_FORWARD( FBGlobalLight );
00155
00157 enum FBFogMode
00158 {
00159 kFBFogModeLinear,
00160 kFBFogModeExponential,
00161 kFBFogModeSquareExponential
00162 };
00163
00164 FB_DEFINE_ENUM( FBSDK_DLL, FogMode );
00165
00167 class FBSDK_DLL FBGlobalLight : public FBBox
00168 {
00169 __FBClassDeclare( FBGlobalLight, FBBox );
00170
00172 FBGlobalLight();
00173
00174 public:
00175
00176 FBPropertyAnimatableColor AmbientColor;
00177
00178
00179 FBPropertyBool FogEnable;
00180 FBPropertyAnimatableColor FogColor;
00181 FBPropertyAnimatableDouble FogBegin;
00182 FBPropertyAnimatableDouble FogEnd;
00183 FBPropertyAnimatableDouble FogDensity;
00184 FBPropertyFogMode FogMode;
00185
00189 static FBGlobalLight& TheOne();
00190 };
00191
00192 #ifdef FBSDKUseNamespace
00193 }
00194 #endif
00195 #endif