Namespace Stride.CommunityToolkit.Shapes
Classes
- DashPattern
The dash pattern along an outline, in on-screen pixels - constant at any zoom, like the border. Dash holds one; each draw call captures its values as it is made.
- FillGradient
A gradient across a shape's fill. Gradient holds one; each draw call captures its values as it is made.
- ShapeBatch
Immediate-mode drawing of filled convex shapes whose outline stays a constant number of pixels wide at any zoom, distance or window size, because the shader measures it per fragment from a signed distance function instead of building it as geometry. "Pixels" here means pixels on a 100% display: the widths follow the display's scale by default (see AutoScale), so they are the same size to the eye everywhere.
- ShapeBatchExtensions
Wires ShapeBatch rendering into a game's graphics compositor.
- ShapeBatchFeature
Renders every ShapeBatch with
ShapeShader: one instanced draw of a shared quad per batch, the shape records, their points and the points of space runs delivered through three structured buffers and evaluated per fragment as a signed distance function.
- ShapeComponent
Draws a flat shape at this entity's world transform through a ShapeBatch, so shapes take part in Stride's component system - scripts, hierarchy, enable and disable - without needing a model or a material. Nothing else is required: where the game called
AddShapeBatch()the shape draws through that batch, and otherwise through a depth-tested one the processor registers for itself, which is also how the shape shows in Game Studio's scene editor.
- ShapeEffectKeys
The parameters
ShapeEffectpermutes on and the base keys a batch's fill source generates its own texture, sampler and value keys from.
- ShapeFill
How a shape's interior is painted. Fill holds one; each draw call captures its values as it is made.
- ShapeGlow
A soft glow outside a shape's outline. Glow holds one; each draw call captures its values as it is made.
- ShapeProcessor
Submits every enabled ShapeComponent to its ShapeBatch each frame, reading the plane and scale to draw in from the entity's world matrix.
Structs
- ShapeHit
A shape found under a screen position by TryPick(Vector2, out ShapeHit, float) or PickAll(Vector2, float).
Enums
- ScreenCorner
A corner of the screen, or of the rectangle a batch is drawing into - what Corner(ScreenCorner) hands back a pixel position for, so a widget is placed as a corner plus an offset rather than by a hardcoded resolution.