forked from pixijs-userland/lights
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpixi-lights.d.ts
58 lines (56 loc) · 2.02 KB
/
pixi-lights.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/// <reference types="pixi.js" />
/// <reference types="pixi-layers" />
declare namespace PIXI.lights {
const diffuseGroup: PIXI.display.Group;
const normalGroup: PIXI.display.Group;
const lightGroup: PIXI.display.Group;
function registerPlugin(name: string, lightShader: LightShader): void;
class Light extends PIXI.Container {
constructor(color?: number, brightness?: number, vertices?: Float32Array, indices?: Float32Array);
vertices: Float32Array;
indices: Float32Array;
blendMode: number;
drawMode: number;
dirty: number;
lightHeight: number;
falloff: number[];
shaderName: string;
useViewportQuad: boolean;
color: number;
brightness: number;
private _color: number;
private _colorRgba: number[];
syncShader(shader: PIXI.Shader): void;
}
class LightShader extends PIXI.Shader {
constructor(gl: WebGLRenderingContext, vertexSrc: string, fragmentSrc: string, customUniforms: any, customAttributes: any);
}
class DirectionalLight extends Light {
constructor(color?: number, brightness?: number, target?: PIXI.PointLike | PIXI.DisplayObject);
target: PIXI.PointLike | PIXI.DisplayObject;
private _directionVector: PIXI.Point;
}
class DirectionalLightShader extends PIXI.Shader {
constructor(gl: WebGLRenderingContext);
}
class AmbientLight extends Light {
constructor(color?: number, brightness?: number);
}
class AmbientLightShader extends PIXI.Shader {
constructor(gl: WebGLRenderingContext);
}
class PointLight extends Light {
constructor(color?: number, brightness?: number);
}
class PointLightShader extends PIXI.Shader {
constructor(gl: WebGLRenderingContext);
}
class WireframeShader extends PIXI.Shader {
constructor(gl: WebGLRenderingContext);
}
class LightRenderer extends PIXI.ObjectRenderer {
}
}
declare module "pixi-lights" {
export = PIXI.lights;
}