56 std::vector<MeshVertex> scratch;
void setCorners(const GuiCorners &c)
Sets the corner radii of a rectangle.
void setShape(SHAPE s)
Sets the shape kind (rectangle or ellipse)
void setStyle(const GuiShapeStyle &s)
Sets the look for every state; applies immediately.
void setPaint(const GuiPaint &p)
Sets one look for every state.
void setTransition(float seconds)
Sets how long a change of state takes to blend, in seconds (0 = instant)
GuiShape(int w=0, int h=0)
Constructor.
void draw() override
Constantly called to draw the shape.
void setCapsule()
Rounds a rectangle's ends fully (radius half the shorter side)
SHAPE
Basic shape kinds a paint can be applied to.
Per-corner radii, in the order top-left, top-right, bottom-right, bottom-left.
A set of paints, one per state. States left unset fall back to the normal paint. GuiShapeStyle(rest)....