react-map4d-map 1.3.8 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/MFBuilding.d.ts +21 -21
- package/dist/components/MFBuildingOverlay.d.ts +10 -10
- package/dist/components/MFCircle.d.ts +18 -18
- package/dist/components/MFDataLayer.d.ts +7 -7
- package/dist/components/MFDirectionsRenderer.d.ts +31 -31
- package/dist/components/MFGroundOverlay.d.ts +6 -6
- package/dist/components/MFImageOverlay.d.ts +6 -6
- package/dist/components/MFMap.d.ts +38 -38
- package/dist/components/MFMarker.d.ts +36 -36
- package/dist/components/MFMarkerCluster.d.ts +8 -8
- package/dist/components/MFPOI.d.ts +19 -19
- package/dist/components/MFPOIOverlay.d.ts +6 -6
- package/dist/components/MFPolygon.d.ts +21 -18
- package/dist/components/MFPolyline.d.ts +22 -22
- package/dist/components/MFTileOverlay.d.ts +10 -10
- package/dist/context/Map4dContext.d.ts +6 -7
- package/dist/context/index.d.ts +2 -2
- package/dist/context/{MarkerClusterContext.d.ts → markerClusterContext.d.ts} +8 -9
- package/dist/engine/Color.d.ts +34 -34
- package/dist/engine/MathUtils.d.ts +8 -8
- package/dist/engine/Matrix.d.ts +115 -115
- package/dist/engine/ResourceReference.d.ts +8 -8
- package/dist/engine/Shader.d.ts +118 -118
- package/dist/engine/ShaderSource.d.ts +42 -42
- package/dist/engine/Texture.d.ts +51 -51
- package/dist/engine/Vector2.d.ts +82 -82
- package/dist/engine/Vector3.d.ts +84 -84
- package/dist/engine/Vertex.d.ts +2 -2
- package/dist/enum/index.d.ts +2 -2
- package/dist/enum/mapEventEnum.d.ts +11 -11
- package/dist/index.d.ts +18 -18
- package/dist/index.js +2324 -2299
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +2305 -2283
- package/dist/index.modern.js.map +1 -1
- package/dist/map/ProjectionMercator.d.ts +26 -26
- package/dist/models/LatLng.d.ts +37 -37
- package/dist/models/Map4dObject.d.ts +32 -32
- package/dist/models/MapConstants.d.ts +165 -165
- package/dist/tool/index.d.ts +1 -1
- package/dist/tool/variableTool.d.ts +3 -3
- package/dist/ultils/CoordinateTransformer.d.ts +11 -11
- package/package.json +23 -16
- package/dist/engine/Framebuffer.d.ts +0 -16
- package/dist/engine/Model.d.ts +0 -77
- package/dist/index.css +0 -9
- package/dist/index.test.d.ts +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Vector2 } from "./Vector2";
|
|
2
|
-
export declare class MathUtils {
|
|
3
|
-
static clamp(value: number, min: number, max: number): number;
|
|
4
|
-
static toRadians(angleDegrees: number): number;
|
|
5
|
-
static distance(p1: Vector2, p2: Vector2): number;
|
|
6
|
-
static findNextPowerOf2(n: number): number;
|
|
7
|
-
static findPreviousPowerOf2(n: number): number;
|
|
8
|
-
}
|
|
1
|
+
import { Vector2 } from "./Vector2";
|
|
2
|
+
export declare class MathUtils {
|
|
3
|
+
static clamp(value: number, min: number, max: number): number;
|
|
4
|
+
static toRadians(angleDegrees: number): number;
|
|
5
|
+
static distance(p1: Vector2, p2: Vector2): number;
|
|
6
|
+
static findNextPowerOf2(n: number): number;
|
|
7
|
+
static findPreviousPowerOf2(n: number): number;
|
|
8
|
+
}
|
package/dist/engine/Matrix.d.ts
CHANGED
|
@@ -1,115 +1,115 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* the matrix class
|
|
3
|
-
*/
|
|
4
|
-
import { Vector3 } from "./Vector3";
|
|
5
|
-
export declare class Matrix4 {
|
|
6
|
-
data: Float32Array;
|
|
7
|
-
/**
|
|
8
|
-
* create an eye 4x4 matrix
|
|
9
|
-
* @param data
|
|
10
|
-
*/
|
|
11
|
-
constructor(data?: Float32Array);
|
|
12
|
-
setIdentity(x?: number, y?: number, z?: number): this;
|
|
13
|
-
copy(other: Matrix4): this;
|
|
14
|
-
/**
|
|
15
|
-
* get a translation matrix
|
|
16
|
-
* @param x
|
|
17
|
-
* @param y
|
|
18
|
-
* @param z
|
|
19
|
-
* @returns {Matrix4}
|
|
20
|
-
*/
|
|
21
|
-
static translate(x: number, y: number, z?: number): Matrix4;
|
|
22
|
-
translate(x: number, y: number, z?: number): this;
|
|
23
|
-
get position(): Vector3;
|
|
24
|
-
/**
|
|
25
|
-
* get a rotation matrix around x-axis
|
|
26
|
-
* @param alpha
|
|
27
|
-
* @returns {Matrix4}
|
|
28
|
-
*/
|
|
29
|
-
static rotateX(alpha: number): Matrix4;
|
|
30
|
-
setRotationX(alpha: number): this;
|
|
31
|
-
rotateX(alpha: number): this;
|
|
32
|
-
/**
|
|
33
|
-
* get a rotation matrix around y-axis
|
|
34
|
-
* @param alpha
|
|
35
|
-
* @returns {Matrix4}
|
|
36
|
-
*/
|
|
37
|
-
static rotateY(alpha: number): Matrix4;
|
|
38
|
-
setRotationY(alpha: number): this;
|
|
39
|
-
rotateY(alpha: number): this;
|
|
40
|
-
/**
|
|
41
|
-
* get a rotation matrix around z-axis
|
|
42
|
-
* @param alpha
|
|
43
|
-
* @returns {Matrix4}
|
|
44
|
-
*/
|
|
45
|
-
static rotateZ(alpha: number): Matrix4;
|
|
46
|
-
setRotationZ(alpha: number): this;
|
|
47
|
-
rotateZ(alpha: number): this;
|
|
48
|
-
/**
|
|
49
|
-
* get a scale matrix
|
|
50
|
-
* @param x
|
|
51
|
-
* @param y
|
|
52
|
-
* @param z
|
|
53
|
-
* @returns {Matrix4}
|
|
54
|
-
*/
|
|
55
|
-
/**
|
|
56
|
-
* concatenate with other transformation matrix
|
|
57
|
-
* @param matrix
|
|
58
|
-
* @returns {Matrix4}
|
|
59
|
-
*/
|
|
60
|
-
multiply(matrix: Matrix4): Matrix4;
|
|
61
|
-
/**
|
|
62
|
-
*
|
|
63
|
-
* @param left
|
|
64
|
-
* @param right
|
|
65
|
-
* @param bottom
|
|
66
|
-
* @param top
|
|
67
|
-
* @param near
|
|
68
|
-
* @param far
|
|
69
|
-
* @returns {Matrix4}
|
|
70
|
-
*/
|
|
71
|
-
static ortho(left: number, right: number, bottom: number, top: number, near?: number, far?: number): Matrix4;
|
|
72
|
-
setOrtho(left: number, right: number, bottom: number, top: number, near?: number, far?: number): this;
|
|
73
|
-
/**
|
|
74
|
-
* create a perspective matrix
|
|
75
|
-
* @param fov
|
|
76
|
-
* @param aspect
|
|
77
|
-
* @param near
|
|
78
|
-
* @param far
|
|
79
|
-
* @returns {Matrix4}
|
|
80
|
-
*/
|
|
81
|
-
static perspective(fov: number, aspect: number, near: number, far: number): Matrix4;
|
|
82
|
-
setPerspective(fov: number, aspect: number, near: number, far: number): void;
|
|
83
|
-
/**
|
|
84
|
-
*
|
|
85
|
-
* @param left
|
|
86
|
-
* @param right
|
|
87
|
-
* @param bottom
|
|
88
|
-
* @param top
|
|
89
|
-
* @param near
|
|
90
|
-
* @param far
|
|
91
|
-
* @returns {Matrix4}
|
|
92
|
-
*/
|
|
93
|
-
static frustum(left: number, right: number, bottom: number, top: number, near?: number, far?: number): Matrix4;
|
|
94
|
-
setFrustum(left: number, right: number, bottom: number, top: number, near?: number, far?: number): void;
|
|
95
|
-
/**
|
|
96
|
-
* transform a vector
|
|
97
|
-
* @param vector
|
|
98
|
-
* @param w include transformation
|
|
99
|
-
*/
|
|
100
|
-
transform(vector: Vector3, w?: number): Vector3;
|
|
101
|
-
/**
|
|
102
|
-
* get the matrix buffer
|
|
103
|
-
* @returns {number[]}
|
|
104
|
-
*/
|
|
105
|
-
buffer(): Float32Array
|
|
106
|
-
/**
|
|
107
|
-
* return look at matrix
|
|
108
|
-
* @param eye
|
|
109
|
-
* @param target
|
|
110
|
-
* @param scale
|
|
111
|
-
* @param up
|
|
112
|
-
* @returns {Matrix4}
|
|
113
|
-
*/
|
|
114
|
-
inverse(): Matrix4;
|
|
115
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* the matrix class
|
|
3
|
+
*/
|
|
4
|
+
import { Vector3 } from "./Vector3";
|
|
5
|
+
export declare class Matrix4 {
|
|
6
|
+
data: Float32Array;
|
|
7
|
+
/**
|
|
8
|
+
* create an eye 4x4 matrix
|
|
9
|
+
* @param data
|
|
10
|
+
*/
|
|
11
|
+
constructor(data?: Float32Array);
|
|
12
|
+
setIdentity(x?: number, y?: number, z?: number): this;
|
|
13
|
+
copy(other: Matrix4): this;
|
|
14
|
+
/**
|
|
15
|
+
* get a translation matrix
|
|
16
|
+
* @param x
|
|
17
|
+
* @param y
|
|
18
|
+
* @param z
|
|
19
|
+
* @returns {Matrix4}
|
|
20
|
+
*/
|
|
21
|
+
static translate(x: number, y: number, z?: number): Matrix4;
|
|
22
|
+
translate(x: number, y: number, z?: number): this;
|
|
23
|
+
get position(): Vector3;
|
|
24
|
+
/**
|
|
25
|
+
* get a rotation matrix around x-axis
|
|
26
|
+
* @param alpha
|
|
27
|
+
* @returns {Matrix4}
|
|
28
|
+
*/
|
|
29
|
+
static rotateX(alpha: number): Matrix4;
|
|
30
|
+
setRotationX(alpha: number): this;
|
|
31
|
+
rotateX(alpha: number): this;
|
|
32
|
+
/**
|
|
33
|
+
* get a rotation matrix around y-axis
|
|
34
|
+
* @param alpha
|
|
35
|
+
* @returns {Matrix4}
|
|
36
|
+
*/
|
|
37
|
+
static rotateY(alpha: number): Matrix4;
|
|
38
|
+
setRotationY(alpha: number): this;
|
|
39
|
+
rotateY(alpha: number): this;
|
|
40
|
+
/**
|
|
41
|
+
* get a rotation matrix around z-axis
|
|
42
|
+
* @param alpha
|
|
43
|
+
* @returns {Matrix4}
|
|
44
|
+
*/
|
|
45
|
+
static rotateZ(alpha: number): Matrix4;
|
|
46
|
+
setRotationZ(alpha: number): this;
|
|
47
|
+
rotateZ(alpha: number): this;
|
|
48
|
+
/**
|
|
49
|
+
* get a scale matrix
|
|
50
|
+
* @param x
|
|
51
|
+
* @param y
|
|
52
|
+
* @param z
|
|
53
|
+
* @returns {Matrix4}
|
|
54
|
+
*/
|
|
55
|
+
/**
|
|
56
|
+
* concatenate with other transformation matrix
|
|
57
|
+
* @param matrix
|
|
58
|
+
* @returns {Matrix4}
|
|
59
|
+
*/
|
|
60
|
+
multiply(matrix: Matrix4): Matrix4;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @param left
|
|
64
|
+
* @param right
|
|
65
|
+
* @param bottom
|
|
66
|
+
* @param top
|
|
67
|
+
* @param near
|
|
68
|
+
* @param far
|
|
69
|
+
* @returns {Matrix4}
|
|
70
|
+
*/
|
|
71
|
+
static ortho(left: number, right: number, bottom: number, top: number, near?: number, far?: number): Matrix4;
|
|
72
|
+
setOrtho(left: number, right: number, bottom: number, top: number, near?: number, far?: number): this;
|
|
73
|
+
/**
|
|
74
|
+
* create a perspective matrix
|
|
75
|
+
* @param fov
|
|
76
|
+
* @param aspect
|
|
77
|
+
* @param near
|
|
78
|
+
* @param far
|
|
79
|
+
* @returns {Matrix4}
|
|
80
|
+
*/
|
|
81
|
+
static perspective(fov: number, aspect: number, near: number, far: number): Matrix4;
|
|
82
|
+
setPerspective(fov: number, aspect: number, near: number, far: number): void;
|
|
83
|
+
/**
|
|
84
|
+
*
|
|
85
|
+
* @param left
|
|
86
|
+
* @param right
|
|
87
|
+
* @param bottom
|
|
88
|
+
* @param top
|
|
89
|
+
* @param near
|
|
90
|
+
* @param far
|
|
91
|
+
* @returns {Matrix4}
|
|
92
|
+
*/
|
|
93
|
+
static frustum(left: number, right: number, bottom: number, top: number, near?: number, far?: number): Matrix4;
|
|
94
|
+
setFrustum(left: number, right: number, bottom: number, top: number, near?: number, far?: number): void;
|
|
95
|
+
/**
|
|
96
|
+
* transform a vector
|
|
97
|
+
* @param vector
|
|
98
|
+
* @param w include transformation
|
|
99
|
+
*/
|
|
100
|
+
transform(vector: Vector3, w?: number): Vector3;
|
|
101
|
+
/**
|
|
102
|
+
* get the matrix buffer
|
|
103
|
+
* @returns {number[]}
|
|
104
|
+
*/
|
|
105
|
+
buffer(): Float32Array<ArrayBufferLike>;
|
|
106
|
+
/**
|
|
107
|
+
* return look at matrix
|
|
108
|
+
* @param eye
|
|
109
|
+
* @param target
|
|
110
|
+
* @param scale
|
|
111
|
+
* @param up
|
|
112
|
+
* @returns {Matrix4}
|
|
113
|
+
*/
|
|
114
|
+
inverse(): Matrix4;
|
|
115
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export declare abstract class ResourceReference {
|
|
2
|
-
private _reference;
|
|
3
|
-
protected constructor();
|
|
4
|
-
protected abstract destroy(): void;
|
|
5
|
-
retain(): void;
|
|
6
|
-
release(): void;
|
|
7
|
-
get reference(): number;
|
|
8
|
-
}
|
|
1
|
+
export declare abstract class ResourceReference {
|
|
2
|
+
private _reference;
|
|
3
|
+
protected constructor();
|
|
4
|
+
protected abstract destroy(): void;
|
|
5
|
+
retain(): void;
|
|
6
|
+
release(): void;
|
|
7
|
+
get reference(): number;
|
|
8
|
+
}
|
package/dist/engine/Shader.d.ts
CHANGED
|
@@ -1,118 +1,118 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* attribute information to store
|
|
3
|
-
* data for webgl attribute
|
|
4
|
-
*/
|
|
5
|
-
export declare class AttributeInfo {
|
|
6
|
-
name: string;
|
|
7
|
-
size: number;
|
|
8
|
-
offset: number;
|
|
9
|
-
stride: number;
|
|
10
|
-
/**
|
|
11
|
-
* create an attribute information
|
|
12
|
-
* @param name
|
|
13
|
-
* @param size
|
|
14
|
-
* @param offset
|
|
15
|
-
* @param stride
|
|
16
|
-
*/
|
|
17
|
-
constructor(name: string, size: number, offset?: number, stride?: number);
|
|
18
|
-
}
|
|
19
|
-
/**
|
|
20
|
-
* the shader class - for managing shader
|
|
21
|
-
*/
|
|
22
|
-
export declare class Shader {
|
|
23
|
-
private gl;
|
|
24
|
-
/**
|
|
25
|
-
* the program to user
|
|
26
|
-
*/
|
|
27
|
-
program: WebGLProgram;
|
|
28
|
-
fragmentShader: WebGLShader;
|
|
29
|
-
vertexShader: WebGLShader;
|
|
30
|
-
/**
|
|
31
|
-
* current texture unit
|
|
32
|
-
* @type {number}
|
|
33
|
-
*/
|
|
34
|
-
textureUnit: number;
|
|
35
|
-
readonly mvpMatrixUniform: WebGLUniformLocation;
|
|
36
|
-
readonly timeUniform: WebGLUniformLocation;
|
|
37
|
-
readonly enableWaterUniform: WebGLUniformLocation;
|
|
38
|
-
readonly textureUniform: WebGLUniformLocation;
|
|
39
|
-
readonly waterDisplacementUniform: WebGLUniformLocation;
|
|
40
|
-
readonly waterColorUniform: WebGLUniformLocation;
|
|
41
|
-
readonly opacityUniform: WebGLUniformLocation;
|
|
42
|
-
readonly lightColorUniform: WebGLUniformLocation;
|
|
43
|
-
readonly lightPositionUniform: WebGLUniformLocation;
|
|
44
|
-
readonly fogStartUniform: WebGLUniformLocation;
|
|
45
|
-
readonly fogRangeUniform: WebGLUniformLocation;
|
|
46
|
-
readonly fogColorUniform: WebGLUniformLocation;
|
|
47
|
-
readonly shadowMvpMatrixUniform: WebGLUniformLocation;
|
|
48
|
-
readonly shadowMapUniform: WebGLUniformLocation;
|
|
49
|
-
readonly lineWidthUniform: WebGLUniformLocation;
|
|
50
|
-
readonly colorUniform: WebGLUniformLocation;
|
|
51
|
-
readonly textureScaleUniform: WebGLUniformLocation;
|
|
52
|
-
readonly useStrokePatternUniform: WebGLUniformLocation;
|
|
53
|
-
readonly useIconUniform: WebGLUniformLocation;
|
|
54
|
-
readonly radiusUniform: WebGLUniformLocation;
|
|
55
|
-
readonly strokeColorUniform: WebGLUniformLocation;
|
|
56
|
-
readonly outerRadiusUniform: WebGLUniformLocation;
|
|
57
|
-
readonly innerRadiusUniform: WebGLUniformLocation;
|
|
58
|
-
readonly modelMatrixUniform: WebGLUniformLocation;
|
|
59
|
-
readonly cameraDirectionUniform: WebGLUniformLocation;
|
|
60
|
-
readonly lowerLimitUniform: WebGLUniformLocation;
|
|
61
|
-
readonly upperLimitUniform: WebGLUniformLocation;
|
|
62
|
-
readonly skyColorUniform: WebGLUniformLocation;
|
|
63
|
-
readonly texsizeUniform: WebGLUniformLocation;
|
|
64
|
-
readonly pixelScaleUniform: WebGLUniformLocation;
|
|
65
|
-
readonly gammaScaleUniform: WebGLUniformLocation;
|
|
66
|
-
readonly isHaloUniform: WebGLUniformLocation;
|
|
67
|
-
readonly textSizeUniform: WebGLUniformLocation;
|
|
68
|
-
readonly useMaskTextureUniform: WebGLUniformLocation;
|
|
69
|
-
readonly spriteInfoUniform: WebGLUniformLocation;
|
|
70
|
-
readonly paddingUniform: WebGLUniformLocation;
|
|
71
|
-
/**
|
|
72
|
-
* dictionary that stores all attributes
|
|
73
|
-
* @type {{}}
|
|
74
|
-
*/
|
|
75
|
-
attributes: {
|
|
76
|
-
[key: string]: number;
|
|
77
|
-
};
|
|
78
|
-
/**
|
|
79
|
-
* create a shader with sources
|
|
80
|
-
* @param gl
|
|
81
|
-
* @param vertexSource
|
|
82
|
-
* @param fragmentSource
|
|
83
|
-
*/
|
|
84
|
-
constructor(gl: WebGLRenderingContext, vertexSource: string, fragmentSource: string);
|
|
85
|
-
/**
|
|
86
|
-
* load all attributes of this shader
|
|
87
|
-
*/
|
|
88
|
-
loadAttributes(): void;
|
|
89
|
-
/**
|
|
90
|
-
* load a shader with source
|
|
91
|
-
* @param type type of the shader | either VERTEX_SHADER or FRAGMENT_SHADER
|
|
92
|
-
* @param source
|
|
93
|
-
* @returns {WebGLShader}
|
|
94
|
-
*/
|
|
95
|
-
loadShader(type: number, source: string): WebGLShader;
|
|
96
|
-
/**
|
|
97
|
-
* Bind the shader to use
|
|
98
|
-
*/
|
|
99
|
-
bind(): void;
|
|
100
|
-
/**
|
|
101
|
-
* Reset texture unit
|
|
102
|
-
*/
|
|
103
|
-
resetTextureUnit(): void;
|
|
104
|
-
/**
|
|
105
|
-
* Set attributes
|
|
106
|
-
* @param attributeInfos
|
|
107
|
-
*/
|
|
108
|
-
setAttributes(attributeInfos: AttributeInfo[]): void;
|
|
109
|
-
setTexture(location: WebGLUniformLocation, textureId: WebGLTexture): void;
|
|
110
|
-
/**
|
|
111
|
-
* disable all attributes
|
|
112
|
-
*/
|
|
113
|
-
disableAttributes(): void;
|
|
114
|
-
/**
|
|
115
|
-
* destroy this shader to release memory
|
|
116
|
-
*/
|
|
117
|
-
destroy(): void;
|
|
118
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* attribute information to store
|
|
3
|
+
* data for webgl attribute
|
|
4
|
+
*/
|
|
5
|
+
export declare class AttributeInfo {
|
|
6
|
+
name: string;
|
|
7
|
+
size: number;
|
|
8
|
+
offset: number;
|
|
9
|
+
stride: number;
|
|
10
|
+
/**
|
|
11
|
+
* create an attribute information
|
|
12
|
+
* @param name
|
|
13
|
+
* @param size
|
|
14
|
+
* @param offset
|
|
15
|
+
* @param stride
|
|
16
|
+
*/
|
|
17
|
+
constructor(name: string, size: number, offset?: number, stride?: number);
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* the shader class - for managing shader
|
|
21
|
+
*/
|
|
22
|
+
export declare class Shader {
|
|
23
|
+
private gl;
|
|
24
|
+
/**
|
|
25
|
+
* the program to user
|
|
26
|
+
*/
|
|
27
|
+
program: WebGLProgram;
|
|
28
|
+
fragmentShader: WebGLShader;
|
|
29
|
+
vertexShader: WebGLShader;
|
|
30
|
+
/**
|
|
31
|
+
* current texture unit
|
|
32
|
+
* @type {number}
|
|
33
|
+
*/
|
|
34
|
+
textureUnit: number;
|
|
35
|
+
readonly mvpMatrixUniform: WebGLUniformLocation;
|
|
36
|
+
readonly timeUniform: WebGLUniformLocation;
|
|
37
|
+
readonly enableWaterUniform: WebGLUniformLocation;
|
|
38
|
+
readonly textureUniform: WebGLUniformLocation;
|
|
39
|
+
readonly waterDisplacementUniform: WebGLUniformLocation;
|
|
40
|
+
readonly waterColorUniform: WebGLUniformLocation;
|
|
41
|
+
readonly opacityUniform: WebGLUniformLocation;
|
|
42
|
+
readonly lightColorUniform: WebGLUniformLocation;
|
|
43
|
+
readonly lightPositionUniform: WebGLUniformLocation;
|
|
44
|
+
readonly fogStartUniform: WebGLUniformLocation;
|
|
45
|
+
readonly fogRangeUniform: WebGLUniformLocation;
|
|
46
|
+
readonly fogColorUniform: WebGLUniformLocation;
|
|
47
|
+
readonly shadowMvpMatrixUniform: WebGLUniformLocation;
|
|
48
|
+
readonly shadowMapUniform: WebGLUniformLocation;
|
|
49
|
+
readonly lineWidthUniform: WebGLUniformLocation;
|
|
50
|
+
readonly colorUniform: WebGLUniformLocation;
|
|
51
|
+
readonly textureScaleUniform: WebGLUniformLocation;
|
|
52
|
+
readonly useStrokePatternUniform: WebGLUniformLocation;
|
|
53
|
+
readonly useIconUniform: WebGLUniformLocation;
|
|
54
|
+
readonly radiusUniform: WebGLUniformLocation;
|
|
55
|
+
readonly strokeColorUniform: WebGLUniformLocation;
|
|
56
|
+
readonly outerRadiusUniform: WebGLUniformLocation;
|
|
57
|
+
readonly innerRadiusUniform: WebGLUniformLocation;
|
|
58
|
+
readonly modelMatrixUniform: WebGLUniformLocation;
|
|
59
|
+
readonly cameraDirectionUniform: WebGLUniformLocation;
|
|
60
|
+
readonly lowerLimitUniform: WebGLUniformLocation;
|
|
61
|
+
readonly upperLimitUniform: WebGLUniformLocation;
|
|
62
|
+
readonly skyColorUniform: WebGLUniformLocation;
|
|
63
|
+
readonly texsizeUniform: WebGLUniformLocation;
|
|
64
|
+
readonly pixelScaleUniform: WebGLUniformLocation;
|
|
65
|
+
readonly gammaScaleUniform: WebGLUniformLocation;
|
|
66
|
+
readonly isHaloUniform: WebGLUniformLocation;
|
|
67
|
+
readonly textSizeUniform: WebGLUniformLocation;
|
|
68
|
+
readonly useMaskTextureUniform: WebGLUniformLocation;
|
|
69
|
+
readonly spriteInfoUniform: WebGLUniformLocation;
|
|
70
|
+
readonly paddingUniform: WebGLUniformLocation;
|
|
71
|
+
/**
|
|
72
|
+
* dictionary that stores all attributes
|
|
73
|
+
* @type {{}}
|
|
74
|
+
*/
|
|
75
|
+
attributes: {
|
|
76
|
+
[key: string]: number;
|
|
77
|
+
};
|
|
78
|
+
/**
|
|
79
|
+
* create a shader with sources
|
|
80
|
+
* @param gl
|
|
81
|
+
* @param vertexSource
|
|
82
|
+
* @param fragmentSource
|
|
83
|
+
*/
|
|
84
|
+
constructor(gl: WebGLRenderingContext, vertexSource: string, fragmentSource: string);
|
|
85
|
+
/**
|
|
86
|
+
* load all attributes of this shader
|
|
87
|
+
*/
|
|
88
|
+
loadAttributes(): void;
|
|
89
|
+
/**
|
|
90
|
+
* load a shader with source
|
|
91
|
+
* @param type type of the shader | either VERTEX_SHADER or FRAGMENT_SHADER
|
|
92
|
+
* @param source
|
|
93
|
+
* @returns {WebGLShader}
|
|
94
|
+
*/
|
|
95
|
+
loadShader(type: number, source: string): WebGLShader;
|
|
96
|
+
/**
|
|
97
|
+
* Bind the shader to use
|
|
98
|
+
*/
|
|
99
|
+
bind(): void;
|
|
100
|
+
/**
|
|
101
|
+
* Reset texture unit
|
|
102
|
+
*/
|
|
103
|
+
resetTextureUnit(): void;
|
|
104
|
+
/**
|
|
105
|
+
* Set attributes
|
|
106
|
+
* @param attributeInfos
|
|
107
|
+
*/
|
|
108
|
+
setAttributes(attributeInfos: AttributeInfo[]): void;
|
|
109
|
+
setTexture(location: WebGLUniformLocation, textureId: WebGLTexture): void;
|
|
110
|
+
/**
|
|
111
|
+
* disable all attributes
|
|
112
|
+
*/
|
|
113
|
+
disableAttributes(): void;
|
|
114
|
+
/**
|
|
115
|
+
* destroy this shader to release memory
|
|
116
|
+
*/
|
|
117
|
+
destroy(): void;
|
|
118
|
+
}
|
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
export declare class ShaderSource {
|
|
2
|
-
static lightEffect: string;
|
|
3
|
-
static waterFragment: string;
|
|
4
|
-
static basicVS: string;
|
|
5
|
-
static basicFS: string;
|
|
6
|
-
static rasterFogVS: string;
|
|
7
|
-
static rasterFogFS: string;
|
|
8
|
-
static polylineVS: string;
|
|
9
|
-
static polylineFS: string;
|
|
10
|
-
static fillVS: string;
|
|
11
|
-
static fillFS: string;
|
|
12
|
-
static geoJsonVS: string;
|
|
13
|
-
static geoJsonFS: string;
|
|
14
|
-
static circleVS: string;
|
|
15
|
-
static circleFS: string;
|
|
16
|
-
static markerVS: string;
|
|
17
|
-
static markerFS: string;
|
|
18
|
-
static buildingVS: string;
|
|
19
|
-
static buildingFS: string;
|
|
20
|
-
static buildingSelectionVS: string;
|
|
21
|
-
static buildingSelectionFS: string;
|
|
22
|
-
static debugSelectionVS: string;
|
|
23
|
-
static debugSelectionFS: string;
|
|
24
|
-
static skyVS: string;
|
|
25
|
-
static skyFS: string;
|
|
26
|
-
static shadowMappingVS: string;
|
|
27
|
-
static shadowMappingFS: string;
|
|
28
|
-
static shadowFS: string;
|
|
29
|
-
static raster3DWithShadowVS: string;
|
|
30
|
-
static raster3DWithShadowFS: string;
|
|
31
|
-
static rasterWithShadowVS: string;
|
|
32
|
-
static rasterWithShadowFS: string;
|
|
33
|
-
static buildingWithShadowVS: string;
|
|
34
|
-
static buildingWithShadowFS: string;
|
|
35
|
-
static buildingOutliningFS: string;
|
|
36
|
-
static textLabelVS: string;
|
|
37
|
-
static textLabelFS: string;
|
|
38
|
-
static tileDebugVS: string;
|
|
39
|
-
static tileDebugFS: string;
|
|
40
|
-
static collisionDebugVS: string;
|
|
41
|
-
static collisionDebugFS: string;
|
|
42
|
-
}
|
|
1
|
+
export declare class ShaderSource {
|
|
2
|
+
static lightEffect: string;
|
|
3
|
+
static waterFragment: string;
|
|
4
|
+
static basicVS: string;
|
|
5
|
+
static basicFS: string;
|
|
6
|
+
static rasterFogVS: string;
|
|
7
|
+
static rasterFogFS: string;
|
|
8
|
+
static polylineVS: string;
|
|
9
|
+
static polylineFS: string;
|
|
10
|
+
static fillVS: string;
|
|
11
|
+
static fillFS: string;
|
|
12
|
+
static geoJsonVS: string;
|
|
13
|
+
static geoJsonFS: string;
|
|
14
|
+
static circleVS: string;
|
|
15
|
+
static circleFS: string;
|
|
16
|
+
static markerVS: string;
|
|
17
|
+
static markerFS: string;
|
|
18
|
+
static buildingVS: string;
|
|
19
|
+
static buildingFS: string;
|
|
20
|
+
static buildingSelectionVS: string;
|
|
21
|
+
static buildingSelectionFS: string;
|
|
22
|
+
static debugSelectionVS: string;
|
|
23
|
+
static debugSelectionFS: string;
|
|
24
|
+
static skyVS: string;
|
|
25
|
+
static skyFS: string;
|
|
26
|
+
static shadowMappingVS: string;
|
|
27
|
+
static shadowMappingFS: string;
|
|
28
|
+
static shadowFS: string;
|
|
29
|
+
static raster3DWithShadowVS: string;
|
|
30
|
+
static raster3DWithShadowFS: string;
|
|
31
|
+
static rasterWithShadowVS: string;
|
|
32
|
+
static rasterWithShadowFS: string;
|
|
33
|
+
static buildingWithShadowVS: string;
|
|
34
|
+
static buildingWithShadowFS: string;
|
|
35
|
+
static buildingOutliningFS: string;
|
|
36
|
+
static textLabelVS: string;
|
|
37
|
+
static textLabelFS: string;
|
|
38
|
+
static tileDebugVS: string;
|
|
39
|
+
static tileDebugFS: string;
|
|
40
|
+
static collisionDebugVS: string;
|
|
41
|
+
static collisionDebugFS: string;
|
|
42
|
+
}
|