diff --git a/shaders/phong/glsl.frag b/shaders/phong/glsl.frag index 381adc2..f499d72 100644 --- a/shaders/phong/glsl.frag +++ b/shaders/phong/glsl.frag @@ -9,7 +9,7 @@ precision highp float; // ===== Constants ============================================================ -const int MAX_LIGHTS = 16; +const int MAX_LIGHTS = 24; const int MAX_SHADOWS = 8; const float MAX_SHAD_A = 0.125; diff --git a/src/core/context.ts b/src/core/context.ts index 83b5c27..59d0da5 100644 --- a/src/core/context.ts +++ b/src/core/context.ts @@ -33,7 +33,7 @@ import fragShaderBill from '../../shaders/billboard/glsl.frag' import vertShaderBill from '../../shaders/billboard/glsl.vert' /** @ignore Total max dynamic lights */ -const MAX_LIGHTS = 16 +const MAX_LIGHTS = 24 /** * The main rendering context. This is the effectively main entry point for the library. diff --git a/src/engine/lights.ts b/src/engine/lights.ts index d8def7c..b672e88 100644 --- a/src/engine/lights.ts +++ b/src/engine/lights.ts @@ -266,6 +266,9 @@ export class LightPoint { /** Is this light enabled? Default: true */ public enabled: boolean + /** Metadata is a key/value store for any extra data you want to store on a node */ + public metadata: Record + /** * Create a default point light, positioned at the world origin * @param position - Position of the light in world space @@ -284,6 +287,8 @@ export class LightPoint { // No ambient contribution by default, this can get messy otherwise this.ambient = Colours.BLACK this.enabled = true + + this.metadata = {} } /**