Class PrimitiveVisual
Definition
- Assembly:
- Tizen.NUI.dll
A class encapsulating the property map of the primitive visual.
public class PrimitiveVisual : VisualMap, IDisposable
- Inheritance
- Implements
-
System.IDisposable
Constructors
View SourcePrimitiveVisual()
Constructor.
Declaration
public PrimitiveVisual()
Properties
View SourceBevelPercentage
Gets or sets determines how bevelled the cuboid should be, based off the smallest dimension.
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.
If not specified, the default is 0.0f (no bevel).
Applies to:
- PrimitiveVisualShapeType.BevelledCube
The range is from 0.0f to 1.0f.
Optional.
Declaration
public float BevelPercentage { get; set; }
Property Value
Type | Description |
---|---|
float |
BevelSmoothness
Gets or sets descriptions of how smooth the bevelled edges should be.
If not specified, the default is 0.0f (sharp edges).
Applies to:
- PrimitiveVisualShapeType.BevelledCube
The range is from 0.0f to 1.0f.
Optional.
Declaration
public float BevelSmoothness { get; set; }
Property Value
Type | Description |
---|---|
float |
LightPosition
Gets or sets the position, in the 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 the height of the stage halved will correspond to the center,
and using all zeroes will place the light at the top-left corner.
If not specified, the default is an offset outwards from the center of the screen.
Applies to all shapes.
Optional.
Declaration
public Vector3 LightPosition { get; set; }
Property Value
Type | Description |
---|---|
Vector3 |
MixColor
Gets or sets the color of the shape.
If not specified, the default is Color (0.5, 0.5, 0.5, 1.0).
Applies to all shapes.
Optional.
Declaration
public Color MixColor { get; set; }
Property Value
Type | Description |
---|---|
Color |
ScaleBottomRadius
Gets or sets the scale of the radius of the bottom circle of a conical frustum.
If not specified, the default is 1.5f.
Applies to: - PrimitiveVisualShapeType.ConicalFrustrum
- PrimitiveVisualShapeType.Cone
Only values greater than or equal to 0.0f are accepted.
Optional.
Declaration
public float ScaleBottomRadius { get; set; }
Property Value
Type | Description |
---|---|
float |
ScaleDimensions
Gets or sets the dimensions of a cuboid. Scales in the same fashion as a 9-patch image.
If not specified, the default is Vector3.One.
Applies to:
- PrimitiveVisualShapeType.Cube
- PrimitiveVisualShapeType.Octahedron
- PrimitiveVisualShapeType.BevelledCube
Each Vector3 parameter should be greater than or equal to 0.0f.
Optional.
Declaration
public Vector3 ScaleDimensions { get; set; }
Property Value
Type | Description |
---|---|
Vector3 |
ScaleHeight
Gets or sets the scale of the height of a conic.
If not specified, the default is 3.0f.
Applies to:
- PrimitiveVisualShapeType.ConicalFrustrum
- PrimitiveVisualShapeType.Cone
- PrimitiveVisualShapeType.Cylinder
Only values greater than or equal to 0.0f are accepted.
Optional.
Declaration
public float ScaleHeight { get; set; }
Property Value
Type | Description |
---|---|
float |
ScaleRadius
Gets or sets the scale of the radius of a cylinder.
If not specified, the default is 1.0f.
Applies to:
- PrimitiveVisualShapeType.Cylinder
Only values greater than or equal to 0.0f are accepted.
Optional.
Declaration
public float ScaleRadius { get; set; }
Property Value
Type | Description |
---|---|
float |
ScaleTopRadius
Gets or sets the scale of the radius of the top circle of a conical frustum.
If not specified, the default is 1.0f.
Applies to: - PrimitiveVisualShapeType.ConicalFrustrum
Only values greater than or equal to 0.0f are accepted.
Optional.
Declaration
public float ScaleTopRadius { get; set; }
Property Value
Type | Description |
---|---|
float |
Shape
Gets or sets the specific shape to render.
If not specified, the default is PrimitiveVisualShapeType.Sphere.
Optional.
Declaration
public PrimitiveVisualShapeType Shape { get; set; }
Property Value
Type | Description |
---|---|
PrimitiveVisualShapeType |
Slices
Gets or sets the number of slices as you go around the shape.
For spheres and conical frustums, this determines how many divisions there are as you go around the object.
If not specified, the default is 128.
The range is from 1 to 255.
Optional.
Declaration
public int Slices { get; set; }
Property Value
Type | Description |
---|---|
int |
Stacks
Gets or sets the number of stacks as you go down the shape.
For spheres, 'stacks' determines how many layers there are as you go down the object.
If not specified, the default is 128.
The range is from 1 to 255.
Optional.
Declaration
public int Stacks { get; set; }
Property Value
Type | Description |
---|---|
int |
Methods
View SourceComposingPropertyMap()
Compose the out visual map.
Declaration
protected override void ComposingPropertyMap()