* The svg rasterizing tasks to be processed in the worker thread.
*
* Life cycle of a rasterizing task is as follows:
* The svg rasterizing tasks to be processed in the worker thread.
*
* Life cycle of a rasterizing task is as follows:
- * 1. Created by SvgRenderer in the main thread
+ * 1. Created by SvgVisual in the main thread
* 2. Queued in the worked thread waiting to be processed.
* 3. If this task gets its turn to do the rasterization, it triggers main thread to apply the rasterized image to material then been deleted in main thread call back
* Or if this task is been removed ( new image/size set to the renderer or actor off stage) before its turn to be processed, it then been deleted in the worker thread.
* 2. Queued in the worked thread waiting to be processed.
* 3. If this task gets its turn to do the rasterization, it triggers main thread to apply the rasterized image to material then been deleted in main thread call back
* Or if this task is been removed ( new image/size set to the renderer or actor off stage) before its turn to be processed, it then been deleted in the worker thread.
To render content, the required actors can be created and added to the control itself as its children.
However, this solution is not fully optimised and means extra actors will be added, and thus, need to be processed by DALi.
To render content, the required actors can be created and added to the control itself as its children.
However, this solution is not fully optimised and means extra actors will be added, and thus, need to be processed by DALi.
-Controls should be as generic as possible so the recommendation is to re-use control renderers to create the content required as described in the [Control Renderers](@ref control-renderers) section.
+Controls should be as generic as possible so the recommendation is to re-use control renderers to create the content required as described in the [Visuals](@ref visuals) section.
Currently, this is devel-api though, so is subject to change.
-Setting DALI_DEBUG_RENDERING environment variable will enable the renderer debuging.
-
-Then, every concrete control renderer( ColorRenderer, BorderRenderer, ImageRenderer, GradientRenderer, etc. ) is replaced with a DebugRenderer object.
-Debug renderer renders a simple quad wireframe, so that the control layout and scene structure is clearly displayed.
@@ -85,12+85,12 @@ Both Linear and Radial gradients are supported.
| radius | FLOAT | For Radial | The size of the radius. |
| stopOffset | ARRAY of FLOAT | No | All the stop offsets. If not supplied default is 0.0 and 1.0. |
| stopColor | ARRAY of VECTOR4 | Yes | The color at those stop offsets. At least 2 required to show a gradient. |
| radius | FLOAT | For Radial | The size of the radius. |
| stopOffset | ARRAY of FLOAT | No | All the stop offsets. If not supplied default is 0.0 and 1.0. |
| stopColor | ARRAY of VECTOR4 | Yes | The color at those stop offsets. At least 2 required to show a gradient. |
-| [units](@ref gradient-renderer-units) | STRING | No | *OBJECT_BOUNDING_BOX* or *USER_SPACE*. Default: *OBJECT_BOUNDING_BOX*. |
-| [spreadMethod](@ref gradient-renderer-spread-method) | STRING | No | *PAD*, *REFLECT* or *REPEAT*. Default: *PAD*. |
+| [units](@ref gradient-visual-units) | STRING | No | *OBJECT_BOUNDING_BOX* or *USER_SPACE*. Default: *OBJECT_BOUNDING_BOX*. |
+| [spreadMethod](@ref gradient-visual-spread-method) | STRING | No | *PAD*, *REFLECT* or *REPEAT*. Default: *PAD*. |
If the *stopOffset* and *stopColor* arrays do not have the same number of elements, then the minimum of the two is used as the stop points.
If the *stopOffset* and *stopColor* arrays do not have the same number of elements, then the minimum of the two is used as the stop points.
-### Units {#gradient-renderer-units}
+### Units {#gradient-visual-units}
Defines the coordinate system for the attributes:
+ Start (x1, y1) and End (x2 and y2) points of a line if using a linear gradient.
Defines the coordinate system for the attributes:
+ Start (x1, y1) and End (x2 and y2) points of a line if using a linear gradient.
@@ -101,7+101,7 @@ Defines the coordinate system for the attributes:
| OBJECT_BOUNDING_BOX | *Default*. Uses the normals for the start, end & center points, i.e. top-left is (-0.5, -0.5) and bottom-right is (0.5, 0.5). |
| USER_SPACE | Uses the user coordinates for the start, end & center points, i.e. in a 200 by 200 control, top-left is (0, 0) and bottom-right is (200, 200). |
| OBJECT_BOUNDING_BOX | *Default*. Uses the normals for the start, end & center points, i.e. top-left is (-0.5, -0.5) and bottom-right is (0.5, 0.5). |
| USER_SPACE | Uses the user coordinates for the start, end & center points, i.e. in a 200 by 200 control, top-left is (0, 0) and bottom-right is (200, 200). |
Renders a mesh using a .obj file, optionally with textures provided by a mtl file. Scaled to fit the control.
Renders a mesh using a .obj file, optionally with textures provided by a mtl file. Scaled to fit the control.
-![ ](../assets/img/renderers/mesh-renderer.png)
-![ ](renderers/mesh-renderer.png)
+![ ](../assets/img/renderers/mesh-visual.png)
+![ ](renderers/mesh-visual.png)
### Properties Supported
### Properties Supported
@@ -443,12+443,13 @@ Renders a mesh using a .obj file, optionally with textures provided by a mtl fil
| objectUrl | STRING | Yes | The location of the ".obj" file. |
| materialUrl | STRING | No | The location of the ".mtl" file. Leave blank for a textureless object. |
| texturesPath | STRING | If using material | Path to the directory the textures (including gloss and normal) are stored in. |
| objectUrl | STRING | Yes | The location of the ".obj" file. |
| materialUrl | STRING | No | The location of the ".mtl" file. Leave blank for a textureless object. |
| texturesPath | STRING | If using material | Path to the directory the textures (including gloss and normal) are stored in. |
-| [shaderType](@ref mesh-renderer-shader-type) | STRING | No | Sets the type of shader to be used with the mesh. |
+| [shaderType](@ref mesh-visual-shader-type) | STRING | No | Sets the type of shader to be used with the mesh. |
| useMipmapping | BOOLEAN | No | Flag for whether to use mipmaps for textures or not. Default true. |
| useSoftNormals | BOOLEAN | No | Flag for whether to average normals at each point to smooth textures or not. Default true. |
| lightPosition | VECTOR3 | No | The position, in stage space, of the point light that applies lighting to the model. This is based off the stage's dimensions, so using the width and height of the stage halved will correspond to the center, and using all zeroes will place the light at the upper left corner. Note that this corresponds to a shader property, so it can be registered and set in the actor as well. |
| useMipmapping | BOOLEAN | No | Flag for whether to use mipmaps for textures or not. Default true. |
| useSoftNormals | BOOLEAN | No | Flag for whether to average normals at each point to smooth textures or not. Default true. |
| lightPosition | VECTOR3 | No | The position, in stage space, of the point light that applies lighting to the model. This is based off the stage's dimensions, so using the width and height of the stage halved will correspond to the center, and using all zeroes will place the light at the upper left corner. Note that this corresponds to a shader property, so it can be registered and set in the actor as well. |
-### Shader Type {#mesh-renderer-shader-type}
+
+### Shader Type {#mesh-visual-shader-type}
When specifying the shader type, if anything the shader requires is missing, a simpler type that can be handled with what has been supplied will be used instead.
When specifying the shader type, if anything the shader requires is missing, a simpler type that can be handled with what has been supplied will be used instead.