SpriteShapeRenderer
Renders SpriteShapes defined through the SpriteShapeUtility.GenerateSpriteShape API.
Read time 8 minutesLast updated 5 days ago
Definition
- Type: Class
- Namespace: UnityEngine.U2D
- Assembly: UnityEngine.SpriteShapeModule
- Inherits from: Renderer
public class SpriteShapeRenderer : Renderer
Properties
Property | Description |
|---|---|
| color | Rendering color for the SpriteShape. |
| maskInteraction | Specifies how the SpriteShape interacts with the masks. |
Methods
Method | Description |
|---|---|
| GetBounds | Get Bounds data as NativeArray. The array count of this NativeArray will always be 1. |
| GetChannels | Get/Set an array of mesh data of SpriteShapeRenderer. |
| GetSegments | Get/Set an array of segments of SpriteShapeRenderer. |
| GetShaderUserValue | Returns the custom value assigned to this renderer. |
| GetSplineMeshCount | Gets the number of submeshes. |
| Prepare | Prepare and generate the SpriteShape geometry that will be fed to SpriteShape generator for rendering. |
| SetLocalAABB | Provides methods for setting the bounding volume of the Sprite Shape geometry. |
| SetShaderUserValue | Assign a custom value to this renderer. |
Inheritance
Operators
Operator | Description |
|---|---|
| operator == | Compares two object references to see if they refer to the same object. |
| bool | Determines whether the object exists. |
| operator != | Compares if two objects refer to a different object. |