Loading [MathJax]/extensions/TeX/AMSsymbols.js
Radium Engine  1.5.0
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages
LightData.cpp
1 #include <Core/Asset/LightData.hpp>
2 
3 namespace Ra {
4 namespace Core {
5 namespace Asset {
6 
8 LightData::LightData( const std::string& name, const LightType& type ) :
9  AssetData( name ), m_frame( Eigen::Matrix<Scalar, 4, 4>::Identity() ), m_type( type ) {}
10 
12  AssetData( data ), m_frame( data.m_frame ), m_type( data.m_type ), m_color( data.m_color ) {
13 
14  switch ( m_type ) {
15  case POINT_LIGHT:
16  m_pointlight = data.m_pointlight;
17  break;
18  case SPOT_LIGHT:
19  m_spotlight = data.m_spotlight;
20  break;
21  case DIRECTIONAL_LIGHT:
22  m_dirlight = data.m_dirlight;
23  break;
24  case AREA_LIGHT:
25  m_arealight = data.m_arealight;
26  break;
27  default:
28  break;
29  }
30 }
31 
34 
35 } // namespace Asset
36 } // namespace Core
37 } // namespace Ra
LightData(const std::string &name="", const LightType &type=UNKNOWN)
CONSTRUCTOR.
Definition: LightData.cpp:8
Definition: Cage.cpp:3