Hierarchy

  • PBLightSource

Properties

active?: boolean

default = true, whether the lightSource is active or not.

color?: PBColor3

default = Color.white, the tint of the light, in RGB format where each component is a floating point value with a range from 0 to 1.

intensity?: number

default = 250, ranges from 1 (dim) to 100,000 (very bright), expressed in Lumens for Point and Spot.

range?: number

default = 0, how far the light travels, expressed in meters. If left at 0 will be computed automatically

shadow?: boolean

default = false, whether the light casts shadows or not.

shadowMaskTexture?: TextureUnion

Texture mask through which shadows are cast to simulate caustics, soft shadows, and light shapes such as light entering from a window.

type?: {
    $case: "point";
    point: PBLightSource_Point;
} | {
    $case: "spot";
    spot: PBLightSource_Spot;
}