@openglobus/og 0.28.7 → 1.0.0-rc2
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/LICENSE.md +218 -4
- package/README.md +31 -18
- package/lib/Deferred.d.ts +2 -2
- package/lib/Events.d.ts +1 -1
- package/lib/Globe.d.ts +8 -5
- package/lib/Object3d.d.ts +17 -14
- package/lib/Popup.d.ts +2 -2
- package/lib/assets/LabelWorker.worker-DYd7xn3M.js.map +1 -0
- package/lib/assets/PlainSegmentWorker.worker-JsKldq-e.js.map +1 -0
- package/lib/assets/TerrainWorker.worker-CqUJvMOv.js.map +1 -0
- package/lib/bv/index.d.ts +2 -2
- package/lib/camera/Camera.d.ts +280 -27
- package/lib/camera/Frustum.d.ts +100 -15
- package/lib/camera/PlanetCamera.d.ts +93 -8
- package/lib/camera/index.d.ts +2 -2
- package/lib/control/CameraFrameComposer.d.ts +2 -2
- package/lib/control/CameraFrameHandler.d.ts +1 -1
- package/lib/control/CompassButton.d.ts +2 -2
- package/lib/control/EarthCoordinates.d.ts +5 -2
- package/lib/control/FramebufferPreview.d.ts +3 -3
- package/lib/control/GeoImageDragControl.d.ts +1 -1
- package/lib/control/LayerAnimation.d.ts +2 -2
- package/lib/control/LayerSwitcher.d.ts +3 -0
- package/lib/control/Lighting.d.ts +4 -2
- package/lib/control/Navigation.d.ts +15 -11
- package/lib/control/OrthoSwitcher.d.ts +18 -0
- package/lib/control/SimpleTouchNavigation.d.ts +44 -0
- package/lib/control/Sun.d.ts +4 -2
- package/lib/control/TouchNavigation.d.ts +4 -8
- package/lib/control/atmosphere/Atmosphere.d.ts +2 -0
- package/lib/control/atmosphere/AtmosphereConfig.d.ts +2 -6
- package/lib/control/cameraDepthHandler/CameraDepthHandler.d.ts +17 -3
- package/lib/control/cameraDepthHandler/camera_depth.d.ts +2 -2
- package/lib/control/drawing/LineStringDrawingScene.d.ts +1 -0
- package/lib/control/drawing/PolygonDrawingScene.d.ts +14 -14
- package/lib/control/elevationProfile/ElevationProfile.d.ts +1 -1
- package/lib/control/elevationProfile/ElevationProfileLegend.d.ts +1 -1
- package/lib/control/elevationProfile/ElevationProfileScene.d.ts +9 -12
- package/lib/control/elevationProfile/ElevationProfileView.d.ts +16 -5
- package/lib/control/entityEditor/EntityEditor.d.ts +19 -0
- package/lib/control/{geoObjectEditor/GeoObjectEditorDialog.d.ts → entityEditor/EntityEditorDialog.d.ts} +9 -8
- package/lib/control/{geoObjectEditor/GeoObjectEditorScene.d.ts → entityEditor/EntityEditorScene.d.ts} +12 -12
- package/lib/control/{geoObjectEditor → entityEditor}/colors.d.ts +2 -2
- package/lib/control/entityTree/EntityTree.d.ts +46 -0
- package/lib/control/entityTree/EntityTreeView.d.ts +24 -0
- package/lib/control/heightRuler/HeightRulerScene.d.ts +3 -2
- package/lib/control/index.d.ts +5 -3
- package/lib/control/ruler/RulerScene.d.ts +8 -8
- package/lib/control/selection/SelectionScene.d.ts +6 -6
- package/lib/control/timeline/TimelineControl.d.ts +2 -2
- package/lib/control/timeline/TimelineModel.d.ts +1 -1
- package/lib/control/timeline/TimelineView.d.ts +52 -13
- package/lib/control/visibleExtent/segment.d.ts +7 -0
- package/lib/ellipsoid/index.d.ts +4 -4
- package/lib/entity/Entity.d.ts +114 -100
- package/lib/entity/EntityCollection.d.ts +95 -70
- package/lib/entity/{BaseBillboard.d.ts → billboard/BaseBillboard.d.ts} +16 -17
- package/lib/entity/{BaseBillboardHandler.d.ts → billboard/BaseBillboardHandler.d.ts} +24 -9
- package/lib/entity/{Billboard.d.ts → billboard/Billboard.d.ts} +11 -7
- package/lib/entity/{BillboardHandler.d.ts → billboard/BillboardHandler.d.ts} +1 -1
- package/lib/entity/{GeoObject.d.ts → geoObject/GeoObject.d.ts} +7 -6
- package/lib/entity/{GeoObjectHandler.d.ts → geoObject/GeoObjectHandler.d.ts} +29 -11
- package/lib/entity/{InstanceData.d.ts → geoObject/InstanceData.d.ts} +18 -13
- package/lib/entity/{Geometry.d.ts → geometry/Geometry.d.ts} +10 -10
- package/lib/entity/{GeometryHandler.d.ts → geometry/GeometryHandler.d.ts} +7 -7
- package/lib/entity/index.d.ts +8 -8
- package/lib/entity/{Label.d.ts → label/Label.d.ts} +12 -13
- package/lib/entity/{LabelHandler.d.ts → label/LabelHandler.d.ts} +31 -7
- package/lib/entity/{LabelWorker.d.ts → label/LabelWorker.d.ts} +3 -3
- package/lib/entity/{PointCloud.d.ts → pointCloud/PointCloud.d.ts} +18 -12
- package/lib/entity/{PointCloudHandler.d.ts → pointCloud/PointCloudHandler.d.ts} +4 -4
- package/lib/entity/polyline/Polyline.d.ts +242 -0
- package/lib/entity/polyline/PolylineBatchRenderer.d.ts +443 -0
- package/lib/entity/{PolylineHandler.d.ts → polyline/PolylineHandler.d.ts} +19 -7
- package/lib/entity/{Ray.d.ts → ray/Ray.d.ts} +27 -9
- package/lib/entity/{RayHandler.d.ts → ray/RayHandler.d.ts} +18 -8
- package/lib/entity/{Strip.d.ts → strip/Strip.d.ts} +21 -17
- package/lib/entity/{StripHandler.d.ts → strip/StripHandler.d.ts} +11 -6
- package/lib/index.d.ts +47 -42
- package/lib/layer/BaseGeoImage.d.ts +20 -17
- package/lib/layer/CanvasTiles.d.ts +14 -12
- package/lib/layer/GeoImage.d.ts +1 -1
- package/lib/layer/GeoTexture2d.d.ts +2 -2
- package/lib/layer/KML.d.ts +19 -18
- package/lib/layer/Layer.d.ts +72 -53
- package/lib/layer/Vector.d.ts +47 -30
- package/lib/layer/WMS.d.ts +1 -1
- package/lib/layer/XYZ.d.ts +11 -12
- package/lib/layer/index.d.ts +12 -12
- package/lib/math/Line2.d.ts +1 -1
- package/lib/math/Line3.d.ts +1 -1
- package/lib/math/Mat3.d.ts +3 -13
- package/lib/math/Mat4.d.ts +16 -10
- package/lib/math/Plane.d.ts +1 -1
- package/lib/math/Quat.d.ts +14 -12
- package/lib/math/Ray.d.ts +4 -3
- package/lib/math/Vec2.d.ts +25 -17
- package/lib/math/Vec3.d.ts +33 -31
- package/lib/math/Vec4.d.ts +1 -1
- package/lib/math/coder.d.ts +1 -1
- package/lib/math/index.d.ts +13 -14
- package/lib/mercator.d.ts +4 -4
- package/lib/og.css +1 -1
- package/lib/og.es.js +1 -1
- package/lib/og.es.js.map +1 -1
- package/lib/quadTree/EntityCollectionNode.d.ts +10 -10
- package/lib/quadTree/EntityCollectionsTreeStrategy.d.ts +5 -5
- package/lib/quadTree/QuadTreeStrategy.d.ts +3 -4
- package/lib/quadTree/earth/EarthEntityCollectionNodeLonLat.d.ts +4 -4
- package/lib/quadTree/earth/EarthEntityCollectionsTreeStrategy.d.ts +4 -4
- package/lib/renderer/AtmosphereDeferredShading.d.ts +12 -0
- package/lib/renderer/IDeferredShadingPass.d.ts +8 -0
- package/lib/renderer/ITransparencyPass.d.ts +8 -0
- package/lib/renderer/PhongDeferredShading.d.ts +16 -0
- package/lib/renderer/Renderer.d.ts +166 -99
- package/lib/renderer/RendererEvents.d.ts +15 -5
- package/lib/renderer/WOITPass.d.ts +14 -0
- package/lib/res/fonts/Ephesis-Regular.json +1 -0
- package/lib/res/fonts/Ephesis-Regular.png +0 -0
- package/lib/res/fonts/Karla-Bold.json +1 -0
- package/lib/res/fonts/Karla-Bold.png +0 -0
- package/lib/res/fonts/Karla-Italic.json +1 -0
- package/lib/res/fonts/Karla-Italic.png +0 -0
- package/lib/res/fonts/Karla-Light.json +1 -0
- package/lib/res/fonts/Karla-Light.png +0 -0
- package/lib/res/fonts/Karla-Medium.json +1 -0
- package/lib/res/fonts/Karla-Medium.png +0 -0
- package/lib/res/fonts/Roboto-Regular.json +1 -37147
- package/lib/res/fonts/Roboto-Regular.png +0 -0
- package/lib/res/fonts/arial.json +1 -4321
- package/lib/res/fonts/arial.png +0 -0
- package/lib/res/night-4326.png +0 -0
- package/lib/res/night.png +0 -0
- package/lib/scene/AltitudeNearPlaneStrategy.d.ts +17 -0
- package/lib/scene/Axes.d.ts +4 -3
- package/lib/scene/Planet.d.ts +244 -69
- package/lib/scene/{RenderNode.d.ts → Scene.d.ts} +49 -46
- package/lib/scene/SkyBox.d.ts +5 -3
- package/lib/scene/index.d.ts +2 -2
- package/lib/segment/Segment.d.ts +29 -15
- package/lib/segment/SegmentLonLat.d.ts +0 -1
- package/lib/shadeModeConstants.d.ts +7 -0
- package/lib/shaders/applyDeferredDepth.d.ts +2 -0
- package/lib/shaders/atmos/atmos.d.ts +3 -3
- package/lib/shaders/billboard/billboard.d.ts +4 -3
- package/lib/shaders/deferredShading/deferredShading.d.ts +2 -0
- package/lib/shaders/deferredShading/deferredShadingAtmos.d.ts +3 -0
- package/lib/shaders/depth.d.ts +2 -2
- package/lib/shaders/geo_object/geo_object.d.ts +8 -4
- package/lib/shaders/label/label.d.ts +4 -4
- package/lib/shaders/pointCloud.d.ts +2 -2
- package/lib/shaders/polyline/polyline.d.ts +7 -3
- package/lib/shaders/ray/ray.d.ts +3 -2
- package/lib/shaders/screenFrame.d.ts +2 -2
- package/lib/shaders/segment/segment.d.ts +7 -0
- package/lib/shaders/skybox.d.ts +2 -2
- package/lib/shaders/strip/strip.d.ts +3 -0
- package/lib/shaders/tone_mapping/toneMapping.d.ts +2 -2
- package/lib/shaders/weightedOITResolve.d.ts +2 -0
- package/lib/terrain/BilTerrain.d.ts +1 -1
- package/lib/terrain/EmptyTerrain.d.ts +5 -6
- package/lib/terrain/GlobusTerrain.d.ts +18 -23
- package/lib/terrain/RgbTerrain.d.ts +8 -8
- package/lib/terrain/index.d.ts +5 -5
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/ui/Button.d.ts +7 -5
- package/lib/ui/ButtonGroup.d.ts +1 -1
- package/lib/ui/Checkbox.d.ts +2 -2
- package/lib/ui/Color.d.ts +2 -2
- package/lib/ui/Dialog.d.ts +30 -3
- package/lib/ui/Input.d.ts +7 -2
- package/lib/ui/Slider.d.ts +5 -2
- package/lib/ui/ToggleButton.d.ts +2 -2
- package/lib/ui/View.d.ts +1 -1
- package/lib/ui/icons.d.ts +1 -1
- package/lib/ui/index.d.ts +9 -9
- package/lib/utils/FontAtlas.d.ts +57 -8
- package/lib/utils/GeoImageCreator.d.ts +2 -2
- package/lib/utils/ImagesCacheManager.d.ts +3 -3
- package/lib/utils/Loader.d.ts +2 -2
- package/lib/utils/PlainSegmentWorker.d.ts +2 -2
- package/lib/utils/TerrainWorker.d.ts +2 -2
- package/lib/utils/TextureAtlas.d.ts +7 -2
- package/lib/utils/TextureResourceManager.d.ts +162 -0
- package/lib/utils/VectorTileCreator.d.ts +1 -1
- package/lib/utils/colorSpace.d.ts +9 -0
- package/lib/utils/gltf/gltfParser.d.ts +9 -2
- package/lib/utils/gltf/types.d.ts +20 -2
- package/lib/utils/shared.d.ts +11 -5
- package/lib/utils/textureResourceMeta.d.ts +9 -0
- package/lib/webgl/BaseFramebuffer.d.ts +7 -0
- package/lib/webgl/Framebuffer.d.ts +9 -6
- package/lib/webgl/Handler.d.ts +81 -99
- package/lib/webgl/ShaderProgram.d.ts +190 -0
- package/lib/webgl/index.d.ts +2 -2
- package/lib/webgl/variableHandlers.d.ts +2 -1
- package/package.json +77 -76
- package/lib/assets/LabelWorker.worker-BT1uJgYn.js.map +0 -1
- package/lib/assets/PlainSegmentWorker.worker-CT1cj8jj.js.map +0 -1
- package/lib/assets/TerrainWorker.worker-DmikdfB2.js.map +0 -1
- package/lib/control/OldMouseNavigation.d.ts +0 -65
- package/lib/control/ZoomControl.d.ts +0 -28
- package/lib/control/geoObjectEditor/GeoObjectEditor.d.ts +0 -13
- package/lib/control/visibleExtent/drawnode.d.ts +0 -7
- package/lib/entity/Polyline.d.ts +0 -417
- package/lib/light/LightSource.d.ts +0 -36
- package/lib/res/fonts/Roboto-Regular.ttf.cfg +0 -1340
- package/lib/res/fonts/Roboto-Regular.ttf.png +0 -0
- package/lib/res/fonts/arial.ttf.cfg +0 -1570
- package/lib/res/fonts/arial.ttf.png +0 -0
- package/lib/scene/BaseNode.d.ts +0 -61
- package/lib/shaders/drawnode/drawnode.d.ts +0 -8
- package/lib/webgl/Program.d.ts +0 -161
- package/lib/webgl/ProgramController.d.ts +0 -87
- /package/lib/control/{geoObjectEditor → entityEditor}/ArrowEntity.d.ts +0 -0
- /package/lib/control/{geoObjectEditor → entityEditor}/AxisTrackEntity.d.ts +0 -0
- /package/lib/control/{geoObjectEditor → entityEditor}/MoveAxisEntity.d.ts +0 -0
- /package/lib/control/{geoObjectEditor → entityEditor}/MovePlaneEntity.d.ts +0 -0
- /package/lib/control/{geoObjectEditor → entityEditor}/RotateEntity.d.ts +0 -0
- /package/lib/entity/{LabelWorker.worker.d.ts → label/LabelWorker.worker.d.ts} +0 -0
package/lib/layer/Layer.d.ts
CHANGED
|
@@ -23,7 +23,7 @@ export interface ILayerParams {
|
|
|
23
23
|
fading?: boolean;
|
|
24
24
|
height?: number;
|
|
25
25
|
textureFilter?: string;
|
|
26
|
-
|
|
26
|
+
colorSpace?: string | number;
|
|
27
27
|
pickingEnabled?: boolean;
|
|
28
28
|
preLoadZoomLevels?: number[];
|
|
29
29
|
extent?: Extent | [[number, number], [number, number]];
|
|
@@ -33,51 +33,67 @@ export interface ILayerParams {
|
|
|
33
33
|
shininess?: number;
|
|
34
34
|
nightTextureCoefficient?: number;
|
|
35
35
|
iconSrc?: string | null;
|
|
36
|
+
waitForParentMaterial?: boolean;
|
|
36
37
|
}
|
|
37
38
|
/**
|
|
38
39
|
* @class
|
|
39
40
|
* Base class; normally only used for creating subclasses and not instantiated in apps.
|
|
40
41
|
* A visual representation of raster or vector map data well known as a layer.
|
|
41
42
|
* @class
|
|
42
|
-
* @param {
|
|
43
|
-
* @param {
|
|
43
|
+
* @param {string|null} [name="noname"] - Layer name.
|
|
44
|
+
* @param {ILayerParams} [options={}] - Layer options.
|
|
45
|
+
* @param {*} [options.properties={}] - Custom user properties.
|
|
46
|
+
* @param {number} [options.labelMaxLetters] - Label max letters (reserved for specific layer implementations).
|
|
47
|
+
* @param {boolean} [options.hideInLayerSwitcher=false] - Presence in LayerSwitcher control.
|
|
44
48
|
* @param {number} [options.opacity=1.0] - Layer opacity.
|
|
45
49
|
* @param {number} [options.minZoom=0] - Minimal visibility zoom level.
|
|
46
|
-
* @param {number} [options.maxZoom=
|
|
47
|
-
* @param {string} [options.attribution] - Layer attribution
|
|
48
|
-
* @param {
|
|
50
|
+
* @param {number} [options.maxZoom=50] - Maximal visibility zoom level.
|
|
51
|
+
* @param {string} [options.attribution=""] - Layer attribution shown in the attribution area.
|
|
52
|
+
* @param {number} [options.zIndex=0] - Layer z-index.
|
|
53
|
+
* @param {boolean} [options.isBaseLayer=false] - Base layer flag.
|
|
54
|
+
* @param {Array.<IDefaultTextureParams>} [options.defaultTextures=[null, null]] - Default textures.
|
|
49
55
|
* @param {boolean} [options.visibility=true] - Layer visibility.
|
|
50
|
-
* @param {boolean} [options.
|
|
51
|
-
* @param {
|
|
52
|
-
* @param {
|
|
53
|
-
* @param {string} [options.
|
|
54
|
-
* @param {
|
|
55
|
-
* @
|
|
56
|
-
* @
|
|
57
|
-
* @
|
|
58
|
-
* @
|
|
59
|
-
* @
|
|
60
|
-
* @
|
|
61
|
-
* @
|
|
62
|
-
* @
|
|
63
|
-
* @
|
|
64
|
-
* @fires
|
|
65
|
-
* @fires
|
|
66
|
-
* @fires
|
|
67
|
-
* @fires
|
|
68
|
-
* @fires
|
|
69
|
-
* @fires
|
|
70
|
-
* @fires
|
|
71
|
-
* @fires
|
|
72
|
-
* @fires
|
|
73
|
-
* @fires
|
|
74
|
-
* @fires
|
|
75
|
-
* @fires
|
|
76
|
-
* @fires
|
|
77
|
-
* @fires
|
|
78
|
-
* @fires
|
|
79
|
-
* @fires
|
|
80
|
-
* @fires
|
|
56
|
+
* @param {boolean} [options.fading=false] - Enables fade-in/fade-out opacity transitions.
|
|
57
|
+
* @param {number} [options.height=0] - Height over the ground.
|
|
58
|
+
* @param {string} [options.textureFilter="mipmap"] - Image texture filter. Available values: "nearest", "linear", "mipmap" and "anisotropic".
|
|
59
|
+
* @param {string|number} [options.colorSpace="srgb"] - Layer color space. Available values: "linear", "srgb", 0, 1.
|
|
60
|
+
* @param {boolean} [options.pickingEnabled=true] - Enables layer picking.
|
|
61
|
+
* @param {number[]} [options.preLoadZoomLevels=[0, 1]] - Zoom levels to preload when layer becomes visible.
|
|
62
|
+
* @param {Extent|Array.<Array.<number>>} [options.extent=[[-180.0, -90.0], [180.0, 90.0]]] - Visible extent.
|
|
63
|
+
* @param {string|NumberArray3|Vec3} [options.ambient] - Ambient color.
|
|
64
|
+
* @param {string|NumberArray3|Vec3} [options.diffuse] - Diffuse color.
|
|
65
|
+
* @param {string|NumberArray3|Vec3} [options.specular] - Specular color.
|
|
66
|
+
* @param {number} [options.shininess=20.0] - Specular shininess coefficient.
|
|
67
|
+
* @param {number} [options.nightTextureCoefficient=1.0] - Night texture blending coefficient.
|
|
68
|
+
* @param {string|null} [options.iconSrc=null] - Icon for LayerSwitcher.
|
|
69
|
+
* @param {boolean} [options.waitForParentMaterial=true] - Wait for parent material while loading current tile material.
|
|
70
|
+
* @fires visibilitychange
|
|
71
|
+
* @fires baselayerchange
|
|
72
|
+
* @fires add
|
|
73
|
+
* @fires remove
|
|
74
|
+
* @fires mousemove
|
|
75
|
+
* @fires mouseenter
|
|
76
|
+
* @fires mouseleave
|
|
77
|
+
* @fires lclick
|
|
78
|
+
* @fires rclick
|
|
79
|
+
* @fires mclick
|
|
80
|
+
* @fires ldblclick
|
|
81
|
+
* @fires rdblclick
|
|
82
|
+
* @fires mdblclick
|
|
83
|
+
* @fires lup
|
|
84
|
+
* @fires rup
|
|
85
|
+
* @fires mup
|
|
86
|
+
* @fires ldown
|
|
87
|
+
* @fires rdown
|
|
88
|
+
* @fires mdown
|
|
89
|
+
* @fires lhold
|
|
90
|
+
* @fires rhold
|
|
91
|
+
* @fires mhold
|
|
92
|
+
* @fires mousewheel
|
|
93
|
+
* @fires touchmove
|
|
94
|
+
* @fires touchstart
|
|
95
|
+
* @fires touchend
|
|
96
|
+
* @fires doubletouch
|
|
81
97
|
*/
|
|
82
98
|
declare class Layer {
|
|
83
99
|
static __counter__: number;
|
|
@@ -163,7 +179,7 @@ declare class Layer {
|
|
|
163
179
|
*/
|
|
164
180
|
_height: number;
|
|
165
181
|
protected _textureFilter: string;
|
|
166
|
-
protected
|
|
182
|
+
protected _colorSpace: number;
|
|
167
183
|
_internalFormat: number | null;
|
|
168
184
|
/**
|
|
169
185
|
* Visible degrees extent.
|
|
@@ -191,7 +207,9 @@ declare class Layer {
|
|
|
191
207
|
_specular: Float32Array | null;
|
|
192
208
|
isVector: boolean;
|
|
193
209
|
protected _iconSrc: string | null;
|
|
210
|
+
waitForParentMaterial: boolean;
|
|
194
211
|
constructor(name?: string | null, options?: ILayerParams);
|
|
212
|
+
static getColorSpace(colorSpace?: string | number): number;
|
|
195
213
|
get iconSrc(): string | null;
|
|
196
214
|
set iconSrc(src: string | null);
|
|
197
215
|
set diffuse(rgb: string | NumberArray3 | Vec3 | null | undefined);
|
|
@@ -213,13 +231,13 @@ declare class Layer {
|
|
|
213
231
|
* Returns true if a layer has imagery tiles.
|
|
214
232
|
* @public
|
|
215
233
|
* @virtual
|
|
216
|
-
* @returns {boolean}
|
|
234
|
+
* @returns {boolean} Imagery tiles flag.
|
|
217
235
|
*/
|
|
218
236
|
hasImageryTiles(): boolean;
|
|
219
237
|
/**
|
|
220
238
|
* Gets layer identifier.
|
|
221
239
|
* @public
|
|
222
|
-
* @returns {
|
|
240
|
+
* @returns {number} Layer object id.
|
|
223
241
|
*/
|
|
224
242
|
getID(): number;
|
|
225
243
|
get id(): number;
|
|
@@ -231,7 +249,7 @@ declare class Layer {
|
|
|
231
249
|
* Compares layers instances.
|
|
232
250
|
* @public
|
|
233
251
|
* @param {Layer} layer - Layer instance to compare.
|
|
234
|
-
* @returns {boolean}
|
|
252
|
+
* @returns {boolean} Returns true if the layer is the same instance as the input.
|
|
235
253
|
*/
|
|
236
254
|
isEqual(layer: Layer): boolean;
|
|
237
255
|
/**
|
|
@@ -255,9 +273,9 @@ declare class Layer {
|
|
|
255
273
|
*/
|
|
256
274
|
addTo(planet: Planet): void;
|
|
257
275
|
/**
|
|
258
|
-
* Removes from planet.
|
|
276
|
+
* Removes from a planet.
|
|
259
277
|
* @public
|
|
260
|
-
* @returns {Layer}
|
|
278
|
+
* @returns {Layer} This layer.
|
|
261
279
|
*/
|
|
262
280
|
remove(): this;
|
|
263
281
|
/**
|
|
@@ -272,13 +290,13 @@ declare class Layer {
|
|
|
272
290
|
/**
|
|
273
291
|
* Sets layer attribution text.
|
|
274
292
|
* @public
|
|
275
|
-
* @param {string} html - HTML
|
|
293
|
+
* @param {string} html - HTML string that represents layer attribution.
|
|
276
294
|
*/
|
|
277
295
|
setAttribution(html: string): void;
|
|
278
296
|
/**
|
|
279
297
|
* Gets layer attribution.
|
|
280
298
|
* @public
|
|
281
|
-
* @returns {string} Layer attribution
|
|
299
|
+
* @returns {string} Layer attribution.
|
|
282
300
|
*/
|
|
283
301
|
getAttribution(): string;
|
|
284
302
|
/**
|
|
@@ -290,7 +308,7 @@ declare class Layer {
|
|
|
290
308
|
/**
|
|
291
309
|
* Gets layer height.
|
|
292
310
|
* @public
|
|
293
|
-
* @returns {number}
|
|
311
|
+
* @returns {number}
|
|
294
312
|
*/
|
|
295
313
|
getHeight(): number;
|
|
296
314
|
/**
|
|
@@ -302,22 +320,22 @@ declare class Layer {
|
|
|
302
320
|
/**
|
|
303
321
|
* Gets z-index.
|
|
304
322
|
* @public
|
|
305
|
-
* @returns {number}
|
|
323
|
+
* @returns {number}
|
|
306
324
|
*/
|
|
307
325
|
getZIndex(): number;
|
|
308
326
|
/**
|
|
309
|
-
*
|
|
327
|
+
* Sets z-index to the maximum value relative to other layers on the planet.
|
|
310
328
|
* @public
|
|
311
329
|
*/
|
|
312
330
|
bringToFront(): void;
|
|
313
331
|
/**
|
|
314
332
|
* Returns true if the layer is a base.
|
|
315
333
|
* @public
|
|
316
|
-
* @returns {boolean}
|
|
334
|
+
* @returns {boolean} Base layer flag.
|
|
317
335
|
*/
|
|
318
336
|
isBaseLayer(): boolean;
|
|
319
337
|
/**
|
|
320
|
-
* Sets base layer type
|
|
338
|
+
* Sets base layer type flag.
|
|
321
339
|
* @public
|
|
322
340
|
* @param {boolean} isBaseLayer -
|
|
323
341
|
*/
|
|
@@ -338,7 +356,7 @@ declare class Layer {
|
|
|
338
356
|
/**
|
|
339
357
|
* Gets layer visibility.
|
|
340
358
|
* @public
|
|
341
|
-
* @returns {boolean}
|
|
359
|
+
* @returns {boolean} Layer visibility.
|
|
342
360
|
*/
|
|
343
361
|
getVisibility(): boolean;
|
|
344
362
|
/**
|
|
@@ -350,13 +368,13 @@ declare class Layer {
|
|
|
350
368
|
/**
|
|
351
369
|
* Gets layer extent.
|
|
352
370
|
* @public
|
|
353
|
-
* @
|
|
371
|
+
* @returns {Extent} Layer geodetic extent.
|
|
354
372
|
*/
|
|
355
373
|
getExtent(): Extent;
|
|
356
374
|
/**
|
|
357
375
|
* Gets layer web-mercator extent.
|
|
358
376
|
* @public
|
|
359
|
-
* @
|
|
377
|
+
* @returns {Extent} Layer extent.
|
|
360
378
|
*/
|
|
361
379
|
getExtentMerc(): Extent;
|
|
362
380
|
/**
|
|
@@ -384,6 +402,7 @@ declare class Layer {
|
|
|
384
402
|
}
|
|
385
403
|
export type LayerEventsList = [
|
|
386
404
|
"visibilitychange",
|
|
405
|
+
"baselayerchange",
|
|
387
406
|
"add",
|
|
388
407
|
"remove",
|
|
389
408
|
"mousemove",
|
package/lib/layer/Vector.d.ts
CHANGED
|
@@ -3,16 +3,17 @@ import type { IEntityParams } from "../entity/Entity";
|
|
|
3
3
|
import { EntityCollection } from "../entity/EntityCollection";
|
|
4
4
|
import { EntityCollectionsTreeStrategy } from "../quadTree/EntityCollectionsTreeStrategy";
|
|
5
5
|
import type { EventsHandler } from "../Events";
|
|
6
|
-
import { GeometryHandler } from "../entity/GeometryHandler";
|
|
6
|
+
import { GeometryHandler } from "../entity/geometry/GeometryHandler";
|
|
7
7
|
import { Layer } from "./Layer";
|
|
8
8
|
import type { ILayerParams, LayerEventsList } from "./Layer";
|
|
9
9
|
import type { NumberArray3 } from "../math/Vec3";
|
|
10
10
|
import { Planet } from "../scene/Planet";
|
|
11
11
|
import { Material } from "./Material";
|
|
12
12
|
import type { NumberArray4 } from "../math/Vec4";
|
|
13
|
+
import { type ShadeMode, type ShadeModeInput } from "../shadeModeConstants";
|
|
13
14
|
export interface IVectorParams extends ILayerParams {
|
|
14
15
|
entities?: Entity[] | IEntityParams[];
|
|
15
|
-
|
|
16
|
+
depthOffset?: number;
|
|
16
17
|
nodeCapacity?: number;
|
|
17
18
|
relativeToGround?: boolean;
|
|
18
19
|
clampToGround?: boolean;
|
|
@@ -20,8 +21,9 @@ export interface IVectorParams extends ILayerParams {
|
|
|
20
21
|
pickingScale?: number | NumberArray3;
|
|
21
22
|
scaleByDistance?: NumberArray3;
|
|
22
23
|
labelMaxLetters?: number;
|
|
23
|
-
|
|
24
|
+
shadeMode?: ShadeModeInput;
|
|
24
25
|
depthOrder?: number;
|
|
26
|
+
disableCullFace?: boolean;
|
|
25
27
|
}
|
|
26
28
|
type VectorEventsList = [
|
|
27
29
|
"draw",
|
|
@@ -30,37 +32,47 @@ type VectorEventsList = [
|
|
|
30
32
|
];
|
|
31
33
|
export type VectorEventsType = EventsHandler<VectorEventsList> & EventsHandler<LayerEventsList>;
|
|
32
34
|
/**
|
|
33
|
-
* Vector layer
|
|
35
|
+
* Vector layer is an alternative entity storage. Used for geospatial data rendering like
|
|
34
36
|
* points, lines, polygons, geometry objects etc.
|
|
35
37
|
* @class
|
|
36
38
|
* @extends {Layer}
|
|
37
39
|
* @param {string} [name="noname"] - Layer name.
|
|
38
40
|
* @param {IVectorParams} [options] - Layer options:
|
|
39
|
-
* @param {number} [options.minZoom=0] - Minimal visible zoom.
|
|
40
|
-
* @param {number} [options.maxZoom=50] - Maximal visible zoom.
|
|
41
|
+
* @param {number} [options.minZoom=0] - Minimal visible zoom.
|
|
42
|
+
* @param {number} [options.maxZoom=50] - Maximal visible zoom.
|
|
41
43
|
* @param {string} [options.attribution] - Layer attribution.
|
|
42
|
-
* @param {
|
|
43
|
-
* @param {boolean} [options.visibility=true] - Layer visibility.
|
|
44
|
-
* @param {boolean} [options.isBaseLayer=false] - Layer base layer.
|
|
45
|
-
* @param {
|
|
44
|
+
* @param {number} [options.zIndex=0] - Layer Z-order index.
|
|
45
|
+
* @param {boolean} [options.visibility=true] - Layer visibility.
|
|
46
|
+
* @param {boolean} [options.isBaseLayer=false] - Layer base layer.
|
|
47
|
+
* @param {number} [options.opacity=1.0] - Layer opacity.
|
|
48
|
+
* @param {boolean} [options.pickingEnabled=true] - Enables/disables picking.
|
|
49
|
+
* @param {boolean} [options.fading=false] - Enables layer fade-in/fade-out transition logic.
|
|
50
|
+
* @param {number} [options.height=0] - Layer height level used for rendering order.
|
|
51
|
+
* @param {Array.<Entity|IEntityParams>} [options.entities] - Entities array or entity init params.
|
|
46
52
|
* @param {Array.<number>} [options.scaleByDistance] - Scale by distance parameters. (exactly 3 entries)
|
|
47
53
|
* First index - near distance to the entity, after entity becomes full scale.
|
|
48
54
|
* Second index - far distance to the entity, when entity becomes zero scale.
|
|
49
55
|
* Third index - far distance to the entity, when entity becomes invisible.
|
|
50
|
-
*
|
|
51
|
-
* @param {number} [options.
|
|
52
|
-
* @param {
|
|
53
|
-
* @param {boolean} [options.
|
|
54
|
-
* @param {boolean} [options.
|
|
55
|
-
* @param {
|
|
56
|
+
* Default is `[MAX32, MAX32, MAX32]` (no distance scaling).
|
|
57
|
+
* @param {number|Array.<number>} [options.pickingScale=[1,1,1]] - Picking scale value or xyz scale array.
|
|
58
|
+
* @param {number} [options.nodeCapacity=60] - Maximum entities quantity in a quadtree node.
|
|
59
|
+
* @param {boolean} [options.async=true] - Asynchronous vector data handling before rendering.
|
|
60
|
+
* @param {boolean} [options.clampToGround=false] - Clamp vector data to the ground.
|
|
61
|
+
* @param {boolean} [options.relativeToGround=false] - Place vector data relative to the ground relief.
|
|
62
|
+
* @param {number} [options.labelMaxLetters=24] - Maximum label letters per line for label entities.
|
|
63
|
+
* @param {Number} [options.depthOffset=0.0] - Signed world-space depth offset along the camera ray.
|
|
64
|
+
* Negative values move geometry closer to the camera, positive values move it farther.
|
|
65
|
+
* @param {number|string} [options.shadeMode=1] - Geo object shading: 0/none unlit, 0.5/phong, 1/pbr.
|
|
66
|
+
* @param {number} [options.depthOrder=0] - Rendering order group for vector collections.
|
|
67
|
+
* @param {boolean} [options.disableCullFace=false] - Disables back-face culling for geo object rendering.
|
|
56
68
|
*
|
|
57
|
-
* //@fires
|
|
58
|
-
* @fires
|
|
59
|
-
* @fires
|
|
60
|
-
* @fires
|
|
61
|
-
* @fires
|
|
62
|
-
* @fires
|
|
63
|
-
* @fires
|
|
69
|
+
* //@fires entitymove
|
|
70
|
+
* @fires draw
|
|
71
|
+
* @fires add
|
|
72
|
+
* @fires remove
|
|
73
|
+
* @fires entityadd
|
|
74
|
+
* @fires entityremove
|
|
75
|
+
* @fires visibilitychange
|
|
64
76
|
*/
|
|
65
77
|
declare class Vector extends Layer {
|
|
66
78
|
events: VectorEventsType;
|
|
@@ -109,18 +121,23 @@ declare class Vector extends Layer {
|
|
|
109
121
|
_geometryHandler: GeometryHandler;
|
|
110
122
|
protected _entityCollectionsTreeStrategy: EntityCollectionsTreeStrategy | null;
|
|
111
123
|
/**
|
|
112
|
-
*
|
|
124
|
+
* Signed world-space depth offset along the camera ray.
|
|
125
|
+
* Negative values move geometry closer to the camera, positive values move it farther.
|
|
126
|
+
* 0.0 means no offset.
|
|
113
127
|
* @public
|
|
114
128
|
* @type {Number}
|
|
115
129
|
*/
|
|
116
|
-
|
|
130
|
+
depthOffset: number;
|
|
117
131
|
protected _labelMaxLetters: number;
|
|
118
|
-
protected
|
|
132
|
+
protected _shadeMode: ShadeMode;
|
|
133
|
+
protected _disableCullFace: boolean;
|
|
119
134
|
constructor(name?: string | null, options?: IVectorParams);
|
|
120
135
|
get depthOrder(): number;
|
|
121
136
|
set depthOrder(d: number);
|
|
122
|
-
get
|
|
123
|
-
set
|
|
137
|
+
get shadeMode(): ShadeMode;
|
|
138
|
+
set shadeMode(m: ShadeModeInput);
|
|
139
|
+
get disableCullFace(): boolean;
|
|
140
|
+
set disableCullFace(v: boolean);
|
|
124
141
|
get labelMaxLetters(): number;
|
|
125
142
|
get instanceName(): string;
|
|
126
143
|
protected _bindPicking(): void;
|
|
@@ -134,7 +151,7 @@ declare class Vector extends Layer {
|
|
|
134
151
|
/**
|
|
135
152
|
* Returns stored entities.
|
|
136
153
|
* @public
|
|
137
|
-
* @returns {Array.<Entity>}
|
|
154
|
+
* @returns {Array.<Entity>} Stored entities.
|
|
138
155
|
*/
|
|
139
156
|
getEntities(): Entity[];
|
|
140
157
|
/**
|
|
@@ -169,7 +186,7 @@ declare class Vector extends Layer {
|
|
|
169
186
|
*/
|
|
170
187
|
removeEntity(entity: Entity): this;
|
|
171
188
|
/**
|
|
172
|
-
*
|
|
189
|
+
* Sets layer picking events active.
|
|
173
190
|
* @public
|
|
174
191
|
* @param {boolean} picking - Picking enable flag.
|
|
175
192
|
*/
|
package/lib/layer/WMS.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ interface IWMSParams extends IXYZParams {
|
|
|
18
18
|
* @param {number} [options.opacity=1.0] - Layer opacity.
|
|
19
19
|
* @param {number} [options.minZoom=0] - Minimal visibility zoom level.
|
|
20
20
|
* @param {number} [options.maxZoom=0] - Maximal visibility zoom level.
|
|
21
|
-
* @param {string} [options.attribution] - Layer attribution
|
|
21
|
+
* @param {string} [options.attribution] - Layer attribution shown in the attribution area.
|
|
22
22
|
* @param {boolean} [options.isBaseLayer=false] - Base layer flag.
|
|
23
23
|
* @param {boolean} [options.visibility=true] - Layer visibility.
|
|
24
24
|
* @param {string} options.url - WMS url source.
|
package/lib/layer/XYZ.d.ts
CHANGED
|
@@ -18,10 +18,7 @@ export interface IXYZParams extends ILayerParams {
|
|
|
18
18
|
*/
|
|
19
19
|
cache?: FetchCache;
|
|
20
20
|
}
|
|
21
|
-
type XYZEventsList = [
|
|
22
|
-
"load",
|
|
23
|
-
"loadend"
|
|
24
|
-
];
|
|
21
|
+
type XYZEventsList = ["load", "loadend"];
|
|
25
22
|
type XYZEventsType = EventsHandler<XYZEventsList> & EventsHandler<LayerEventsList>;
|
|
26
23
|
/**
|
|
27
24
|
* Represents an imagery tiles source provider.
|
|
@@ -35,16 +32,16 @@ type XYZEventsType = EventsHandler<XYZEventsList> & EventsHandler<LayerEventsLis
|
|
|
35
32
|
* @param {number} [options.maxZoom=0] - Maximal visibility zoom level.
|
|
36
33
|
* @param {number} [options.minNativeZoom=0] - Minimal available zoom level.
|
|
37
34
|
* @param {number} [options.maxNativeZoom=19] - Maximal available zoom level.
|
|
38
|
-
* @param {string} [options.attribution] - Layer attribution
|
|
35
|
+
* @param {string} [options.attribution] - Layer attribution shown in the attribution area.
|
|
39
36
|
* @param {boolean} [options.isBaseLayer=false] - Base layer flag.
|
|
40
37
|
* @param {boolean} [options.visibility=true] - Layer visibility.
|
|
41
38
|
* @param {string} [options.crossOrigin=true] - If true, all tiles will have their crossOrigin attribute set to ''.
|
|
42
39
|
* @param {string} options.url - Tile url source template(see example below).
|
|
43
|
-
* @param {string} options.textureFilter -
|
|
44
|
-
* @param {Function} options.urlRewrite -
|
|
40
|
+
* @param {string} options.textureFilter - Texture WebGL filter: NEAREST, LINEAR, MIPMAP, ANISOTROPIC.
|
|
41
|
+
* @param {Function} options.urlRewrite - URL rewrite function.
|
|
45
42
|
*
|
|
46
|
-
* @fires
|
|
47
|
-
* @fires
|
|
43
|
+
* @fires load
|
|
44
|
+
* @fires loadend
|
|
48
45
|
*
|
|
49
46
|
* @example <caption>Creates OpenStreetMap base tile layer</caption>
|
|
50
47
|
* new og.layer.XYZ("OpenStreetMap", {
|
|
@@ -83,7 +80,7 @@ export declare class XYZ extends Layer {
|
|
|
83
80
|
* @private
|
|
84
81
|
* @param {Segment} segment - Segment to load.
|
|
85
82
|
* @param {string} url - Created url.
|
|
86
|
-
* @returns {string}
|
|
83
|
+
* @returns {string} URL query string.
|
|
87
84
|
*/
|
|
88
85
|
protected _urlRewriteCallback: Function | null;
|
|
89
86
|
protected _requestsPeerSubdomains: number;
|
|
@@ -130,7 +127,7 @@ export declare class XYZ extends Layer {
|
|
|
130
127
|
* @protected
|
|
131
128
|
* @virtual
|
|
132
129
|
* @param {Segment} segment - Creates specific url for current segment.
|
|
133
|
-
* @returns {string}
|
|
130
|
+
* @returns {string} URL string.
|
|
134
131
|
*/
|
|
135
132
|
protected _createUrl(segment: Segment): string;
|
|
136
133
|
protected _getSubdomain(): string;
|
|
@@ -138,7 +135,7 @@ export declare class XYZ extends Layer {
|
|
|
138
135
|
* Returns actual url query string.
|
|
139
136
|
* @protected
|
|
140
137
|
* @param {Segment} segment - Segment that loads image data.
|
|
141
|
-
* @returns {string}
|
|
138
|
+
* @returns {string} URL string.
|
|
142
139
|
*/
|
|
143
140
|
protected _getHTTPRequestString(segment: Segment): any;
|
|
144
141
|
/**
|
|
@@ -148,6 +145,8 @@ export declare class XYZ extends Layer {
|
|
|
148
145
|
*/
|
|
149
146
|
setUrlRewriteCallback(ur: Function): void;
|
|
150
147
|
applyMaterial(material: Material, forceLoading?: boolean): NumberArray4;
|
|
148
|
+
protected _apllyMaterialDefault(material: Material, forceLoading?: boolean): NumberArray4;
|
|
149
|
+
protected _applyMaterialFast(material: Material, forceLoading?: boolean): NumberArray4;
|
|
151
150
|
clearMaterial(material: Material): void;
|
|
152
151
|
/**
|
|
153
152
|
* @protected
|
package/lib/layer/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
4
|
-
export * from
|
|
5
|
-
export * from
|
|
6
|
-
export * from
|
|
7
|
-
export * from
|
|
8
|
-
export * from
|
|
9
|
-
export * from
|
|
10
|
-
export * from
|
|
11
|
-
export * from
|
|
12
|
-
export * from
|
|
1
|
+
export * from "./CanvasTiles";
|
|
2
|
+
export * from "./GeoImage";
|
|
3
|
+
export * from "./GeoTexture2d";
|
|
4
|
+
export * from "./GeoVideo";
|
|
5
|
+
export * from "./KML";
|
|
6
|
+
export * from "./Layer";
|
|
7
|
+
export * from "./Vector";
|
|
8
|
+
export * from "./WMS";
|
|
9
|
+
export * from "./XYZ";
|
|
10
|
+
export * from "./Material";
|
|
11
|
+
export * from "./OpenStreetMap";
|
|
12
|
+
export * from "./Bing";
|
package/lib/math/Line2.d.ts
CHANGED
package/lib/math/Line3.d.ts
CHANGED
package/lib/math/Mat3.d.ts
CHANGED
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
import { Mat4 } from "./Mat4";
|
|
2
2
|
import { Vec3 } from "./Vec3";
|
|
3
|
-
export type NumberArray9 = [
|
|
4
|
-
number,
|
|
5
|
-
number,
|
|
6
|
-
number,
|
|
7
|
-
number,
|
|
8
|
-
number,
|
|
9
|
-
number,
|
|
10
|
-
number,
|
|
11
|
-
number,
|
|
12
|
-
number
|
|
13
|
-
];
|
|
3
|
+
export type NumberArray9 = [number, number, number, number, number, number, number, number, number];
|
|
14
4
|
/**
|
|
15
5
|
* Class represents a 3x3 matrix.
|
|
16
6
|
* @class
|
|
@@ -58,7 +48,7 @@ export declare class Mat3 {
|
|
|
58
48
|
/**
|
|
59
49
|
* Multiply to 3d vector.
|
|
60
50
|
* @public
|
|
61
|
-
* @
|
|
51
|
+
* @param {Vec3} p - 3D vector.
|
|
62
52
|
* @returns {Vec3}
|
|
63
53
|
*/
|
|
64
54
|
mulVec(p: Vec3): Vec3;
|
|
@@ -72,6 +62,6 @@ export declare class Mat3 {
|
|
|
72
62
|
/**
|
|
73
63
|
* Mat3 factory.
|
|
74
64
|
* @static
|
|
75
|
-
* @
|
|
65
|
+
* @returns {Mat3}
|
|
76
66
|
*/
|
|
77
67
|
export declare function mat3(): Mat3;
|
package/lib/math/Mat4.d.ts
CHANGED
|
@@ -39,11 +39,11 @@ export declare class Mat4 {
|
|
|
39
39
|
*/
|
|
40
40
|
static identity(): Mat4;
|
|
41
41
|
/**
|
|
42
|
-
*
|
|
42
|
+
* Returns a rotation matrix around a point.
|
|
43
43
|
* @public
|
|
44
|
-
* @param {number} angle - Rotation angle in radians
|
|
45
|
-
* @param {Vec3} [center] -
|
|
46
|
-
* @param {Vec3} [up] -
|
|
44
|
+
* @param {number} angle - Rotation angle in radians.
|
|
45
|
+
* @param {Vec3} [center] - Rotation center point.
|
|
46
|
+
* @param {Vec3} [up] - Up axis.
|
|
47
47
|
*/
|
|
48
48
|
static getRotationAroundPoint(angle: number, center?: Vec3, up?: Vec3): Mat4;
|
|
49
49
|
static getRotation(angle: number, up?: Vec3): Mat4;
|
|
@@ -67,7 +67,7 @@ export declare class Mat4 {
|
|
|
67
67
|
* Copy matrix.
|
|
68
68
|
* @public
|
|
69
69
|
* @param {Mat4} a - Matrix to copy.
|
|
70
|
-
* @
|
|
70
|
+
* @returns {Mat4}
|
|
71
71
|
*/
|
|
72
72
|
copy(a: Mat4): Mat4;
|
|
73
73
|
/**
|
|
@@ -95,7 +95,7 @@ export declare class Mat4 {
|
|
|
95
95
|
* @public
|
|
96
96
|
* @returns {Mat3} -
|
|
97
97
|
*/
|
|
98
|
-
toInverseMatrix3(): Mat3
|
|
98
|
+
toInverseMatrix3(res: Mat3): Mat3;
|
|
99
99
|
/**
|
|
100
100
|
* Creates an inverse matrix of the current.
|
|
101
101
|
* @public
|
|
@@ -136,10 +136,10 @@ export declare class Mat4 {
|
|
|
136
136
|
*/
|
|
137
137
|
translateToPosition(v: Vec3): Mat4;
|
|
138
138
|
/**
|
|
139
|
-
*
|
|
139
|
+
* Rotates the current matrix around an axis by an angle.
|
|
140
140
|
* @public
|
|
141
|
-
* @param {Vec3} u -
|
|
142
|
-
* @param {number} angle -
|
|
141
|
+
* @param {Vec3} u - Rotation axis.
|
|
142
|
+
* @param {number} angle - Rotation angle in radians.
|
|
143
143
|
* @returns {Mat4} -
|
|
144
144
|
*/
|
|
145
145
|
rotate(u: Vec3, angle: number): Mat4;
|
|
@@ -178,6 +178,12 @@ export declare class Mat4 {
|
|
|
178
178
|
* @returns {Mat4} -
|
|
179
179
|
*/
|
|
180
180
|
setPerspective(left: number, right: number, bottom: number, top: number, near: number, far: number): Mat4;
|
|
181
|
+
/**
|
|
182
|
+
* Infinite reverse-Z perspective.
|
|
183
|
+
* By default uses WebGL clip space (NDC z in [-1, 1]); with `zeroToOne=true` uses EXT_clip_control ZERO_TO_ONE (NDC z in [0, 1]).
|
|
184
|
+
* Use with gl.clearDepth(0), gl.depthFunc(GL_GREATER). Far plane is not used in the matrix (culling only).
|
|
185
|
+
*/
|
|
186
|
+
setPerspectiveReverseInfinite(left: number, right: number, bottom: number, top: number, near: number, zeroToOne?: boolean): Mat4;
|
|
181
187
|
/**
|
|
182
188
|
* Creates current orthographic projection matrix.
|
|
183
189
|
* @public
|
|
@@ -187,7 +193,7 @@ export declare class Mat4 {
|
|
|
187
193
|
* @param {number} top -
|
|
188
194
|
* @param {number} near -
|
|
189
195
|
* @param {number} far -
|
|
190
|
-
* @
|
|
196
|
+
* @returns {Mat4} -
|
|
191
197
|
*/
|
|
192
198
|
setOrthographic(left: number, right: number, bottom: number, top: number, near: number, far: number): Mat4;
|
|
193
199
|
/**
|