123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102 |
- #ifndef S_LIGHT_H_INCLUDED
- #define S_LIGHT_H_INCLUDED
- #include "SColor.h"
- #include "vector3d.h"
- namespace irr
- {
- namespace video
- {
- enum E_LIGHT_TYPE
- {
-
- ELT_POINT,
-
- ELT_SPOT,
-
- ELT_DIRECTIONAL,
-
- ELT_COUNT
- };
- const c8* const LightTypeNames[] =
- {
- "Point",
- "Spot",
- "Directional",
- 0
- };
- struct SLight
- {
- SLight() : AmbientColor(0.f,0.f,0.f), DiffuseColor(1.f,1.f,1.f),
- SpecularColor(1.f,1.f,1.f), Attenuation(1.f,0.f,0.f),
- OuterCone(45.f), InnerCone(0.f), Falloff(2.f),
- Position(0.f,0.f,0.f), Direction(0.f,0.f,1.f),
- Radius(100.f), Type(ELT_POINT), CastShadows(true)
- {}
-
- SColorf AmbientColor;
-
-
- SColorf DiffuseColor;
-
-
- SColorf SpecularColor;
-
-
- core::vector3df Attenuation;
-
- f32 OuterCone;
-
- f32 InnerCone;
-
- f32 Falloff;
-
-
- core::vector3df Position;
-
-
- core::vector3df Direction;
-
-
- f32 Radius;
-
- E_LIGHT_TYPE Type;
-
- bool CastShadows:1;
- };
- }
- }
- #endif
|