License conversion from Flora to Apache 2.0
[platform/core/uifw/dali-core.git] / capi / dali / public-api / math / angle-axis.h
1 #ifndef __DALI_ANGLE_AXIS_H__
2 #define __DALI_ANGLE_AXIS_H__
3
4 /*
5  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  */
20
21 /**
22  * @addtogroup CAPI_DALI_MATH_MODULE
23  * @{
24  */
25
26 // INTERNAL INCLUDES
27 #include <dali/public-api/math/degree.h>
28 #include <dali/public-api/math/vector3.h>
29
30 namespace Dali DALI_IMPORT_API
31 {
32
33 struct Radian;
34
35 /**
36  * @brief An angle & axis pair.
37  *
38  * This is slightly easier to understand than quaternions for handling rotations
39  * of objects. Both elements should be non-zero to correctly describe a rotation.
40  */
41 struct DALI_IMPORT_API AngleAxis
42 {
43   /**
44    * @brief Create an angle-axis pair.
45    *
46    */
47   AngleAxis();
48
49   /**
50    * @brief Create an angle-axis pair.
51    *
52    * @param[in] initialAngle The initial angle in degrees.
53    * @param[in] initialAxis The initial axis.
54    */
55   AngleAxis( Degree initialAngle, Vector3 initialAxis );
56
57   /**
58    * @brief Create an angle-axis pair.
59    *
60    * @param[in] initialAngle The initial angle in radians.
61    * @param[in] initialAxis The initial axis.
62    */
63   AngleAxis( Radian initialAngle, Vector3 initialAxis );
64
65   Degree angle; ///< The angle in degrees
66   Vector3 axis; ///< The axis
67 };
68
69 } // namespace Dali
70
71 /**
72  * @}
73  */
74 #endif // __DALI_ANGLE_AXIS_H__