Class PolyBoard
- Namespace
- RichHudFramework.UI.Rendering
- Assembly
- RichHudClient.dll
Renders a regular 2D polygon (e.g., triangle, hexagon, circle approximation) using billboards. The shape is constructed as a triangle fan from the center.
public class PolyBoard
- Inheritance
-
PolyBoard
- Derived
Constructors
PolyBoard()
public PolyBoard()
Properties
Color
The color tint applied to the polygon material.
public virtual Color Color { get; set; }
Property Value
MatAlignment
Determines how the texture is scaled to fit the polygon's bounding box.
public MaterialAlignment MatAlignment { get; set; }
Property Value
Material
The texture applied to the polygon.
public virtual Material Material { get; set; }
Property Value
Sides
The number of sides (vertices) on the polygon perimeter. Higher values approximate a circle.
public virtual int Sides { get; set; }
Property Value
Methods
Draw(Vector2, Vector2, MatrixD[])
Renders the full polygon defined by Sides with the specified dimensions and position.
public virtual void Draw(Vector2 size, Vector2 origin, MatrixD[] matrixRef)
Parameters
Draw(Vector2, Vector2, Vector2I, MatrixD[])
Renders a specific range of faces (pie slice) of the polygon.
public virtual void Draw(Vector2 size, Vector2 origin, Vector2I faceRange, MatrixD[] matrixRef)
Parameters
sizeVector2originVector2faceRangeVector2IThe start and end index of the triangles to draw.
matrixRefMatrixD[]
GetSliceOffset(Vector2, Vector2I)
Calculates the center offset of a specific slice of the polygon relative to the billboard center. Useful for radial menus or separated pie charts.
public virtual Vector2 GetSliceOffset(Vector2 bbSize, Vector2I range)