PointLight

Represents a point light source in 3D space.

Properties

SizeOf

(uint): Gets the size of the PointLight in bytes.

Public Methods

SetPosition

public void SetPosition(Vector3 pos)

Sets the position of the point light.

Parameters:

  • pos (Vector3): The new position of the point light.

SetColor

public void SetColor(Vector4 col, float intensity)

Sets the color and intensity of the point light.

Parameters:

  • col (Vector4): The color of the point light.
  • intensity (float): The intensity of the point light.

GetAsBytes

public readonly byte[] GetAsBytes()

Converts the PointLight to a byte array.

Returns: byte[]

  • A byte array representing the PointLight.

ToString

public override readonly string ToString()

Returns: string

Equals

public readonly bool Equals(PointLight other)

Indicates whether this PointLight is equal to another one.

Parameters:

  • other (PointLight): The point light to compare with this one.

Returns: bool

  • true if the two lights are equal; otherwise, false.

Equals

public override readonly bool Equals(object? obj)

Parameters:

  • obj (object?)

Returns: bool

GetHashCode

public override int GetHashCode()

Returns: int