Skip to content

Documentation / @ripl/3d / LIGHT_DIRECTION

Variable: LIGHT_DIRECTION ​

const LIGHT_DIRECTION: object

Defined in: 3d/src/constants.ts:6

Pre-normalised light direction vectors for common light positions.

Type Declaration ​

back ​

readonly back: [0, 0, 1]

bottom ​

readonly bottom: [0, 1, 0]

bottomLeft ​

readonly bottomLeft: [-0.707, 0.707, 0]

bottomRight ​

readonly bottomRight: [0.707, 0.707, 0]

front ​

readonly front: [0, 0, -1]

left ​

readonly left: [-1, 0, 0]

readonly right: [1, 0, 0]

top ​

readonly top: [0, -1, 0]

topBack ​

readonly topBack: [0, -0.707, 0.707]

topFront ​

readonly topFront: [0, -0.707, -0.707]

topLeft ​

readonly topLeft: [-0.707, -0.707, 0]

topLeftBehind ​

readonly topLeftBehind: [-0.577, -0.577, 0.577]

topLeftFront ​

readonly topLeftFront: [-0.577, -0.577, -0.577]

topRight ​

readonly topRight: [0.707, -0.707, 0]

topRightBehind ​

readonly topRightBehind: [0.577, -0.577, 0.577]

topRightFront ​

readonly topRightFront: [0.577, -0.577, -0.577]