Class InstancedElement
Represents an instanced element within a scene, providing position, rotation, and size transformations.
Inherited Members
Namespace: Genesis.Graphics
Assembly: Genesis.dll
Syntax
public class InstancedElement : GameElement
Constructors
InstancedElement()
Declaration
public InstancedElement()
Properties
Initialized
Gets or sets a value indicating whether the instance has been initialized.
Declaration
public bool Initialized { get; set; }
Property Value
Type | Description |
---|---|
bool |
InstanceID
Gets or sets the unique identifier for the instance within its container.
Declaration
public int InstanceID { get; set; }
Property Value
Type | Description |
---|---|
int |
Location
Gets or sets the location of the instance in the world space. Updates the instance matrix in the parent container when changed.
Declaration
public override Vec3 Location { get; set; }
Property Value
Type | Description |
---|---|
Vec3 |
Overrides
Rotation
Gets or sets the rotation of the instance in degrees (X, Y, Z). Updates the instance matrix in the parent container when changed.
Declaration
public override Vec3 Rotation { get; set; }
Property Value
Type | Description |
---|---|
Vec3 |
Overrides
Size
Gets or sets the size (scale) of the instance in the world space. Updates the instance matrix in the parent container when changed.
Declaration
public override Vec3 Size { get; set; }
Property Value
Type | Description |
---|---|
Vec3 |
Overrides
Methods
GetModelViewMatrix()
Computes the model-view transformation matrix for the instance.
Declaration
public mat4 GetModelViewMatrix()
Returns
Type | Description |
---|---|
mat4 | A GlmSharp.mat4 representing the combined transformations: translation, rotation, and scaling. |