Ctrl+K

Geometry

Declaration

public abstract class Strawberry.Graphics.Geometry

Represents a renderable geometric mesh composed of vertices and optional indices.

Inherits: Strawberry.DisposableReferenceObject

Type Parameters

Name Description
T The vertex type defining the layout of the geometry's vertex data (e.g., position, color, texture coordinates). Must be a value type.

Properties

GraphicsContext abstract

Gets the graphics context that created and manages this geometry resource.

IGraphicsContext GraphicsContext { get }

Methods

Render abstract

Renders the geometry using the currently active shader and pipeline state of the graphics context.

void Render()

UpdateVB abstract

Updates the underlying vertex buffer with the provided vertex data.

void UpdateVB(T[] vertices)

Parameters:

Name Type Description
vertices T[] An array of vertices defining the new geometry shape and attributes.

UpdateIB abstract

Updates the underlying index buffer with the provided index data.

void UpdateIB(uint[] indices)

Parameters:

Name Type Description
indices System.UInt32[] An array of unsigned integers defining the order in which vertices should be rendered.