1 #ifndef DALI_TOOLKIT_PRIMITIVE_VISUAL_PROPERTIES_H
2 #define DALI_TOOLKIT_PRIMITIVE_VISUAL_PROPERTIES_H
5 * Copyright (c) 2016 Samsung Electronics Co., Ltd.
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
11 * http://www.apache.org/licenses/LICENSE-2.0
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.
22 #include <dali-toolkit/public-api/toolkit-property-index-ranges.h>
31 * @addtogroup dali_toolkit_visuals
35 namespace PrimitiveVisual
44 * @brief The specific shape to render.
45 * @details Name "shape", type Shape::Type (Property::INTEGER) or Property::STRING.
47 * @note Optional. If not specified, the default is Shape::SPHERE.
50 SHAPE = VISUAL_PROPERTY_START_INDEX,
53 * @brief The color of the shape.
54 * @details Name "mixColor", type Property::VECTOR4.
56 * @note Optional. If not specified, the default is Vector4(0.5, 0.5, 0.5, 1.0).
57 * @note Applies to ALL shapes.
62 * @brief The number of slices as you go around the shape.
63 * @details Name "slices", type Property::INTEGER.
64 * For spheres and conical frustrums, this determines how many divisions there are as you go around the object.
66 * @note Optional. If not specified, the default is 128.
69 * - Shape::CONICAL_FRUSTRUM
72 * @note The range is from 1 to 255.
77 * @brief The number of stacks as you go down the shape.
78 * @details Name "stacks", type Property::INTEGER.
79 * For spheres, 'stacks' determines how many layers there are as you go down the object.
81 * @note Optional. If not specified, the default is 128.
84 * @note The range is from 1 to 255.
89 * @brief The scale of the radius of the top circle of a conical frustrum.
90 * @details Name "scaleTopRadius", type Property::FLOAT.
92 * @note Optional. If not specified, the default is 1.0f.
94 * - Shape::CONICAL_FRUSTRUM
95 * @note Only values greater than or equal to 0.0f are accepted.
100 * @brief The scale of the radius of the bottom circle of a conical frustrum.
101 * @details Name "scaleBottomRadius", type Property::FLOAT.
103 * @note Optional. If not specified, the default is 1.5f.
105 * - Shape::CONICAL_FRUSTRUM
107 * @note Only values greater than or equal to 0.0f are accepted.
112 * @brief The scale of the height of a conic.
113 * @details Name "scaleHeight", type Property::FLOAT.
115 * @note Optional. If not specified, the default is 3.0f.
117 * - Shape::CONICAL_FRUSTRUM
120 * @note Only values greater than or equal to 0.0f are accepted.
125 * @brief The scale of the radius of a cylinder.
126 * @details Name "scaleRadius", type Property::FLOAT.
128 * @note Optional. If not specified, the default is 1.0f.
131 * @note Only values greater than or equal to 0.0f are accepted.
136 * @brief The dimensions of a cuboid. Scales in the same fashion as a 9-patch image.
137 * @details Name "scaleDimensions", type Property::VECTOR3.
139 * @note Optional. If not specified, the default is Vector3::ONE.
142 * - Shape::OCTAHEDRON
143 * - Shape::BEVELLED_CUBE
144 * @note Each vector3 parameter should be greater than or equal to 0.0f.
149 * @brief Determines how bevelled the cuboid should be, based off the smallest dimension.
150 * @details Name "bevelPercentage", type Property::FLOAT.
151 * Bevel percentage ranges from 0.0 to 1.0. It affects the ratio of the outer face widths to the width of the overall cube.
153 * @note Optional. If not specified, the default is 0.0f (no bevel).
155 * - Shape::BEVELLED_CUBE
156 * @note The range is from 0.0f to 1.0f.
161 * @brief Defines how smooth the bevelled edges should be.
162 * @details Name "bevelSmoothness", type Property::FLOAT.
164 * @note Optional. If not specified, the default is 0.0f (sharp edges).
166 * - Shape::BEVELLED_CUBE
167 * @note The range is from 0.0f to 1.0f.
172 * @brief The position, in stage space, of the point light that applies lighting to the model.
173 * @details Name "lightPosition", type Property::VECTOR3.
174 * This is based off the stage's dimensions, so using the width and height of the stage halved will correspond to the center,
175 * and using all zeroes will place the light at the top left corner.
177 * @note Optional. If not specified, the default is an offset outwards from the center of the screen.
178 * @note Applies to ALL shapes.
183 } // namespace Property
189 * @brief The primitive shape to render.
193 SPHERE, ///< A perfectly round geometrical object in three-dimensional space. @SINCE_1_1.45
194 CONICAL_FRUSTRUM, ///< The area bound between two circles, i.e. a cone with the tip removed. @SINCE_1_1.45
195 CONE, ///< Equivalent to a conical frustrum with top radius of zero. @SINCE_1_1.45
196 CYLINDER, ///< Equivalent to a conical frustrum with equal radii for the top and bottom circles. @SINCE_1_1.45
197 CUBE, ///< Equivalent to a bevelled cube with a bevel percentage of zero. @SINCE_1_1.45
198 OCTAHEDRON, ///< Equivalent to a bevelled cube with a bevel percentage of one. @SINCE_1_1.45
199 BEVELLED_CUBE, ///< A cube/cuboid with all edges flattened to some degree. @SINCE_1_1.45
203 } // namespace PrimitiveVisual
209 } // namespace Toolkit
213 #endif // DALI_TOOLKIT_PRIMITIVE_VISUAL_PROPERTIES_H