Fork for IVI: mesa fixing
[profile/ivi/uifw.git] / src / ui / effects / inc / FUiEffects_RuntimePropertyCast.h
1 //
2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
4 //
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
8 //
9 //     http://floralicense.org/license/
10 //
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
16 //
17 /**
18  * @file        FUiEffects_RuntimePropertyCast.h
19  * @brief       This is the header file for the PropertyCast structure.
20  */
21
22 #ifndef _FUI_EFFECTS_INTERNAL_RUNTIME_PROPERTY_CAST_H_
23 #define _FUI_EFFECTS_INTERNAL_RUNTIME_PROPERTY_CAST_H_
24
25 #include <lua.hpp>
26 #include <vector>
27 #include <utils/FUiEffects_Utils.h>
28
29
30 namespace Tizen { namespace Ui { namespace Effects { namespace _Runtime
31 {
32
33 class PointLight;
34 class SpotLight;
35 class DirectionalLight;
36 template<class T> class EffectsVector;
37
38 /**
39  * @struct      PropertyCast
40  * @brief       The instances of this structure are needed for
41  *                      returning a property value from model to lua
42  *
43  * @since 2.0
44  *
45  */
46 // tolua_begin                          <--(!do not edit!)the beginning of export part to lua
47 struct PropertyCast
48 {
49         enum
50         {
51                 NO_PROPERTY,            /**< means absence property*/
52                 NUMBER,                         /**< for parameters of float, double, integer and similar types*/
53                 BOOL,                           /**< for parameters of boolean type*/
54                 VEC3,                           /**< for parameters of vector3 type*/
55                 VECTOR_VECTOR,          /**< for vector<vector<long> > type from algorithm of finding nearest points to specified*/
56                 POINT_LIGHT,
57                 SPOT_LIGHT,
58                 DIRECTIONAL_LIGHT
59         } type;
60
61         union TypeValue
62         {
63                 LUA_NUMBER numberValue;                                                                                                 /**< stores a parameter of float or double, or integer, or similar type*/
64                 bool boolValue;
65 // tolua_end                                                                                                                                    <--(!do not edit!)the ending of export part to lua
66                 const _Utils::Vec3f* vec3Value;
67                 const EffectsVector<EffectsVector<long> >* vecVecValue;                                 /**< for vector<vector<long> > type from algorithm of finding nearest points to specified*/
68 // tolua_begin                                                                                                                                  <--(!do not edit!)the beginning of export part to lua
69 #if 0
70                 tolua_readonly Vector3* vec3Value;                                                                              /**< for lua code, should be ignored by c++ compiler*/
71                 tolua_readonly EffectsVector<EffectsVector<long> >* vecVecValue;                /**< for lua code, should be ignored by c++ compiler*/
72 #endif
73 // tolua_end
74                 const PointLight* pPointLight;
75                 const SpotLight* pSpotLight;
76                 const DirectionalLight* pDirectionalLight;
77 // tolua_begin
78 #if 0
79                 PointLight* pPointLight;
80                 SpotLight* pSpotLight;
81                 DirectionalLight* pDirectionalLight;
82 #endif
83         };
84
85         TypeValue value;
86 }; // PropertyCast
87 // tolua_end                            <--(!do not edit!)the ending of export part to lua
88
89 } } } } // Tizen::Ui::Effects::_Runtime
90
91 #endif //_FUI_EFFECTS_INTERNAL_RUNTIME_PROPERTY_CAST_H_