2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
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
9 // http://floralicense.org/license/
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.
18 * @file FUiEffects_PePointSurfaceNURBS.h
19 * @brief This is the header file for the PointSurfaceNurbs class
22 #ifndef _FUI_EFFECTS_INTERNAL_PE_POINTSURFACENURBS_H_
23 #define _FUI_EFFECTS_INTERNAL_PE_POINTSURFACENURBS_H_
26 #include "FUiEffects_PePointSurface.h"
28 namespace Tizen { namespace Ui { namespace Effects { namespace _PhysicsEngine
32 * @class PointSurfaceNURBS
33 * @brief Class for graphical element: nurbs point
38 class PointSurfaceNurbs
45 * PointSurfaceNURBS class constructor
49 * @param[in] objId physical element's id
50 * @param[in] positionInit point initial position
51 * @param[in] massInit point initial mass
52 * @param[in] weightInit NURBS initial weight
53 * @param[in] fixed point fixation setting
54 * @param[in] row row number in grid
55 * @param[in] col column number in grid
60 Tizen::Ui::Effects::_Utils::Vec3f positionInit,
75 virtual ~PointSurfaceNurbs();
82 * @return enum value that corresponds to object's type
85 virtual Tizen::Ui::Effects::_Runtime::ESurface GetType(void) const;
88 * Sets object into the initial state
93 virtual void Initialize(void);
96 * Binds point with model parameters
100 * @return binding result, successful - true, failed - false
101 * @param[in] pEnvResist pointer to environmental resistance value
102 * @param[in] pGravAcc pointer to gravity acceleration vector
103 * @param[in] pGroundLevel pointer to model ground level value
106 virtual bool Construct(
107 const float* pEnvResist,
108 const Tizen::Ui::Effects::_Utils::Vec3f* pGravAcc,
109 const float* pGroundLevel
113 * Performs simulation step with given delta time
117 * @param[in] timeStep simulation time step
120 virtual void Calculate(float timeStep);
123 * Gets element property value
127 * @return struct that contains property type and value
128 * @param[in] property enum value for necessary property
131 virtual Tizen::Ui::Effects::_Runtime::PropertyCast GetProperty(
132 Tizen::Ui::Effects::_Runtime::ElementProperty property
136 * Sets element bool property values
140 * @return true if set successful, false if failed
141 * @param[in] property property name
142 * @param[in] boolValue new bool value for property
145 virtual bool SetProperty(
146 Tizen::Ui::Effects::_Runtime::ElementProperty property,
151 * Sets element numeric property values
155 * @return true if set successful, false if failed
156 * @param[in] property property name
157 * @param[in] numericValue new numeric value for property
160 virtual bool SetProperty(
161 Tizen::Ui::Effects::_Runtime::ElementProperty property,
162 LUA_NUMBER numericValue
166 * Sets element vector property values
170 * @return true if set successful, false if failed
171 * @param[in] property property name
172 * @param[in] vectorValue new vector value for property
175 virtual bool SetProperty(
176 Tizen::Ui::Effects::_Runtime::ElementProperty property,
177 const Tizen::Ui::Effects::_Utils::Vec3f & vectorValue
185 * @return NURBS weight value
188 float GetWeight(void) const;
191 * Gets grid row which contains this point
195 * @return grid row number
198 unsigned int GetRow(void) const;
201 * Gets grid column which contains this point
205 * @return grid column number
208 unsigned int GetCol(void) const;
213 // internal initialize function
214 void InitPointNurbs(void);
222 const float __nurbsWeightInit;
224 // current simulation values
230 }; // PointSurfaceNURBS
232 } } } } // Tizen::Ui::Effects::_PhysicsEngine
234 #endif //_FUI_EFFECTS_INTERNAL_PE_POINTSURFACENURBS_H_