@openglobus/og 0.11.1 → 0.11.6
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/package.json +18 -20
- package/src/og/Clock.js +11 -11
- package/src/og/Deferred.js +1 -1
- package/src/og/Events.js +9 -7
- package/src/og/Extent.js +117 -72
- package/src/og/Globe.js +35 -22
- package/src/og/ImageCanvas.js +24 -18
- package/src/og/Lock.js +2 -2
- package/src/og/LonLat.js +40 -37
- package/src/og/Popup.js +21 -15
- package/src/og/QueueArray.js +7 -3
- package/src/og/Rectangle.js +11 -6
- package/src/og/Stack.js +8 -5
- package/src/og/ajax.js +21 -33
- package/src/og/astro/astro.js +5 -5
- package/src/og/astro/earth.js +23 -17
- package/src/og/astro/jd.js +44 -39
- package/src/og/astro/orbit.js +20 -18
- package/src/og/astro/rotation.js +17 -8
- package/src/og/bv/Box.js +7 -3
- package/src/og/bv/Sphere.js +17 -9
- package/src/og/camera/Camera.js +137 -86
- package/src/og/camera/Frustum.js +30 -19
- package/src/og/camera/PlanetCamera.js +30 -26
- package/src/og/control/CompassButton.js +8 -2
- package/src/og/control/Control.js +13 -11
- package/src/og/control/DebugInfo.js +4 -1
- package/src/og/control/EarthCoordinates.js +62 -41
- package/src/og/control/EarthNavigation.js +20 -22
- package/src/og/control/GeoImageDragControl.js +1 -1
- package/src/og/control/KeyboardNavigation.js +12 -12
- package/src/og/control/LayerSwitcher.js +24 -23
- package/src/og/control/Lighting.js +1 -1
- package/src/og/control/MouseNavigation.js +1 -1
- package/src/og/control/ScaleControl.js +1 -1
- package/src/og/control/SegmentBoundVisualization.js +8 -9
- package/src/og/control/ShowFps.js +15 -10
- package/src/og/control/SimpleNavigation.js +8 -10
- package/src/og/control/Sun.js +25 -15
- package/src/og/control/ToggleWireframe.js +5 -5
- package/src/og/control/TouchNavigation.js +58 -45
- package/src/og/control/ZoomControl.js +41 -25
- package/src/og/control/index.js +4 -0
- package/src/og/ellipsoid/Ellipsoid.js +181 -85
- package/src/og/ellipsoid/wgs84.js +4 -4
- package/src/og/entity/BaseBillboard.js +97 -44
- package/src/og/entity/Billboard.js +15 -11
- package/src/og/entity/BillboardHandler.js +314 -64
- package/src/og/entity/Entity.js +106 -74
- package/src/og/entity/EntityCollection.js +72 -49
- package/src/og/entity/GeoObject.js +228 -0
- package/src/og/entity/GeoObjectHandler.js +910 -0
- package/src/og/entity/Geometry.js +29 -26
- package/src/og/entity/GeometryHandler.js +598 -126
- package/src/og/entity/Label.js +74 -40
- package/src/og/entity/LabelHandler.js +47 -246
- package/src/og/entity/LabelWorker.js +213 -0
- package/src/og/entity/Object3d.js +504 -0
- package/src/og/entity/PointCloud.js +81 -33
- package/src/og/entity/PointCloudHandler.js +9 -9
- package/src/og/entity/Polyline.js +39 -39
- package/src/og/entity/Ray.js +61 -28
- package/src/og/entity/ShapeHandler.js +1 -1
- package/src/og/entity/Strip.js +77 -48
- package/src/og/entity/StripHandler.js +27 -27
- package/src/og/entity/index.js +8 -16
- package/src/og/input/KeyboardHandler.js +107 -104
- package/src/og/input/MouseHandler.js +81 -78
- package/src/og/input/TouchHandler.js +55 -51
- package/src/og/layer/BaseGeoImage.js +61 -30
- package/src/og/layer/CanvasTiles.js +26 -24
- package/src/og/layer/GeoImage.js +10 -10
- package/src/og/layer/GeoTexture2d.js +1 -1
- package/src/og/layer/GeoVideo.js +3 -3
- package/src/og/layer/KML.js +66 -40
- package/src/og/layer/Layer.js +27 -17
- package/src/og/layer/Material.js +93 -61
- package/src/og/layer/Vector.js +118 -72
- package/src/og/layer/WMS.js +36 -19
- package/src/og/layer/XYZ.js +55 -48
- package/src/og/light/LightSource.js +47 -40
- package/src/og/math/Line2.js +24 -24
- package/src/og/math/Line3.js +103 -102
- package/src/og/math/Mat3.js +134 -121
- package/src/og/math/Mat4.js +603 -459
- package/src/og/math/Plane.js +21 -20
- package/src/og/math/Quat.js +980 -927
- package/src/og/math/Ray.js +195 -187
- package/src/og/math/Vec2.js +127 -117
- package/src/og/math/Vec3.js +206 -176
- package/src/og/math/Vec4.js +49 -53
- package/src/og/math/coder.js +18 -18
- package/src/og/math.js +12 -12
- package/src/og/mercator.js +11 -11
- package/src/og/proj/EPSG3857.js +4 -4
- package/src/og/proj/EPSG4326.js +4 -4
- package/src/og/proj/Proj.js +31 -31
- package/src/og/quadTree/EntityCollectionNode.js +310 -300
- package/src/og/quadTree/Node.js +1008 -993
- package/src/og/renderer/Renderer.js +768 -747
- package/src/og/renderer/RendererEvents.js +9 -6
- package/src/og/scene/Axes.js +1 -1
- package/src/og/scene/BaseNode.js +8 -9
- package/src/og/scene/Planet.js +115 -87
- package/src/og/scene/RenderNode.js +29 -22
- package/src/og/scene/SkyBox.js +1 -1
- package/src/og/segment/Segment.js +1886 -1878
- package/src/og/segment/SegmentLonLat.js +298 -268
- package/src/og/segment/segmentHelper.js +11 -11
- package/src/og/shaders/bloom.js +1 -1
- package/src/og/shaders/blur.js +2 -2
- package/src/og/shaders/depth.js +1 -1
- package/src/og/shaders/geoObject.js +211 -0
- package/src/og/shaders/label.js +1 -1
- package/src/og/shaders/lumFilter.js +1 -1
- package/src/og/shaders/pointCloud.js +42 -42
- package/src/og/shaders/screenFrame.js +1 -1
- package/src/og/shaders/shape.js +15 -21
- package/src/og/shaders/skybox.js +37 -37
- package/src/og/shaders/toneMapping.js +1 -1
- package/src/og/shapes/BaseShape.js +129 -57
- package/src/og/shapes/Icosphere.js +30 -15
- package/src/og/shapes/Sphere.js +13 -16
- package/src/og/terrain/BilTerrain.js +2 -1
- package/src/og/terrain/EmptyTerrain.js +2 -2
- package/src/og/terrain/Geoid.js +2 -2
- package/src/og/terrain/GlobusTerrain.js +10 -10
- package/src/og/terrain/MapboxTerrain.js +1 -1
- package/src/og/utils/GeoImageCreator.js +9 -9
- package/src/og/utils/Loader.js +6 -6
- package/src/og/utils/NormalMapCreator.js +13 -13
- package/src/og/utils/TerrainWorker.js +1 -1
- package/src/og/utils/TextureAtlas.js +20 -22
- package/src/og/utils/VectorTileCreator.js +5 -5
- package/src/og/utils/earcut.js +1 -1
- package/src/og/utils/shared.js +15 -15
- package/src/og/webgl/Framebuffer.js +101 -53
- package/src/og/webgl/Handler.js +125 -85
- package/src/og/webgl/Multisample.js +55 -27
- package/src/og/webgl/Program.js +80 -35
- package/src/og/webgl/ProgramController.js +27 -23
- package/src/og/webgl/callbacks.js +8 -8
- package/types/Clock.d.ts +6 -2
- package/types/Deferred.d.ts +1 -1
- package/types/Events.d.ts +8 -4
- package/types/Extent.d.ts +37 -33
- package/types/Globe.d.ts +15 -13
- package/types/ImageCanvas.d.ts +5 -3
- package/types/LonLat.d.ts +24 -24
- package/types/Popup.d.ts +4 -0
- package/types/QueueArray.d.ts +6 -2
- package/types/Rectangle.d.ts +10 -4
- package/types/Stack.d.ts +4 -0
- package/types/ajax.d.ts +1 -1
- package/types/astro/earth.d.ts +3 -2
- package/types/bv/Box.d.ts +10 -5
- package/types/bv/Sphere.d.ts +13 -7
- package/types/camera/Camera.d.ts +90 -81
- package/types/camera/Frustum.d.ts +26 -22
- package/types/camera/PlanetCamera.d.ts +49 -53
- package/types/control/CompassButton.d.ts +4 -4
- package/types/control/Control.d.ts +7 -4
- package/types/control/DebugInfo.d.ts +3 -4
- package/types/control/EarthCoordinates.d.ts +6 -6
- package/types/control/EarthNavigation.d.ts +42 -0
- package/types/control/KeyboardNavigation.d.ts +3 -4
- package/types/control/LayerSwitcher.d.ts +3 -5
- package/types/control/Lighting.d.ts +3 -3
- package/types/control/MouseNavigation.d.ts +47 -0
- package/types/control/ScaleControl.d.ts +3 -3
- package/types/control/ShowFps.d.ts +3 -4
- package/types/control/SimpleNavigation.d.ts +3 -6
- package/types/control/Sun.d.ts +8 -10
- package/types/control/ToggleWireframe.d.ts +3 -3
- package/types/control/TouchNavigation.d.ts +48 -0
- package/types/control/ZoomControl.d.ts +3 -4
- package/types/control/index.d.ts +3 -1
- package/types/ellipsoid/Ellipsoid.d.ts +47 -43
- package/types/ellipsoid/wgs84.d.ts +3 -2
- package/types/entity/BaseBillboard.d.ts +41 -34
- package/types/entity/Billboard.d.ts +7 -7
- package/types/entity/BillboardHandler.d.ts +4 -0
- package/types/entity/Entity.d.ts +101 -83
- package/types/entity/EntityCollection.d.ts +57 -43
- package/types/entity/GeoObject.d.ts +111 -0
- package/types/entity/GeoObjectHandler.d.ts +77 -0
- package/types/entity/Geometry.d.ts +9 -7
- package/types/entity/GeometryHandler.d.ts +2 -2
- package/types/entity/Label.d.ts +24 -29
- package/types/entity/LabelHandler.d.ts +9 -2
- package/types/entity/LabelWorker.d.ts +9 -0
- package/types/entity/PointCloud.d.ts +8 -8
- package/types/entity/PointCloudHandler.d.ts +3 -3
- package/types/entity/Polyline.d.ts +58 -55
- package/types/entity/Ray.d.ts +19 -18
- package/types/entity/Strip.d.ts +8 -7
- package/types/entity/StripHandler.d.ts +3 -3
- package/types/entity/index.d.ts +7 -7
- package/types/input/KeyboardHandler.d.ts +10 -0
- package/types/input/MouseHandler.d.ts +5 -0
- package/types/input/TouchHandler.d.ts +5 -0
- package/types/layer/BaseGeoImage.d.ts +23 -35
- package/types/layer/CanvasTiles.d.ts +15 -22
- package/types/layer/GeoImage.d.ts +5 -18
- package/types/layer/GeoVideo.d.ts +5 -30
- package/types/layer/KML.d.ts +20 -15
- package/types/layer/Layer.d.ts +326 -0
- package/types/layer/Material.d.ts +45 -0
- package/types/layer/Vector.d.ts +208 -0
- package/types/layer/WMS.d.ts +4 -7
- package/types/layer/XYZ.d.ts +19 -25
- package/types/light/LightSource.d.ts +54 -53
- package/types/math/Line2.d.ts +11 -0
- package/types/math/Line3.d.ts +10 -0
- package/types/math/Mat3.d.ts +30 -18
- package/types/math/Mat4.d.ts +71 -52
- package/types/math/Plane.d.ts +5 -4
- package/types/math/Quat.d.ts +379 -0
- package/types/math/Ray.d.ts +82 -0
- package/types/math/Vec2.d.ts +102 -101
- package/types/math/Vec3.d.ts +143 -142
- package/types/math/Vec4.d.ts +40 -39
- package/types/math/coder.d.ts +12 -11
- package/types/math.d.ts +8 -8
- package/types/mercator.d.ts +3 -3
- package/types/proj/EPSG3857.d.ts +3 -2
- package/types/proj/EPSG4326.d.ts +3 -2
- package/types/proj/Proj.d.ts +42 -0
- package/types/quadTree/EntityCollectionNode.d.ts +34 -0
- package/types/quadTree/Node.d.ts +61 -0
- package/types/renderer/Renderer.d.ts +300 -0
- package/types/renderer/RendererEvents.d.ts +10 -7
- package/types/scene/BaseNode.d.ts +9 -9
- package/types/scene/Planet.d.ts +131 -126
- package/types/scene/RenderNode.d.ts +22 -23
- package/types/segment/Segment.d.ts +279 -0
- package/types/segment/SegmentLonLat.d.ts +16 -0
- package/types/shaders/geoObject.d.ts +3 -0
- package/types/shapes/BaseShape.d.ts +43 -40
- package/types/shapes/Sphere.d.ts +7 -7
- package/types/terrain/BilTerrain.d.ts +0 -1
- package/types/terrain/EmptyTerrain.d.ts +4 -4
- package/types/terrain/GlobusTerrain.d.ts +17 -54
- package/types/terrain/MapboxTerrain.d.ts +0 -1
- package/types/utils/GeoImageCreator.d.ts +3 -2
- package/types/utils/TextureAtlas.d.ts +8 -8
- package/types/utils/shared.d.ts +25 -24
- package/types/webgl/Framebuffer.d.ts +5 -5
- package/types/webgl/Handler.d.ts +68 -43
- package/types/webgl/Multisample.d.ts +5 -5
- package/types/webgl/Program.d.ts +8 -2
- package/types/webgl/ProgramController.d.ts +18 -13
- package/src/og/inherits.js +0 -8
- package/src/og/utils/polylabel.js +0 -176
- package/types/inherits.d.ts +0 -4
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* PointCloud object.
|
|
3
3
|
* @class
|
|
4
4
|
* @param {*} [options] - Point cloud options:
|
|
5
|
-
* @param {Array.<Array.<number
|
|
5
|
+
* @param {Array.<Array.<number>>} [options.points] - Points cartesian coordinates array,
|
|
6
6
|
* where first three is cartesian coordinates, next fourth is a RGBA color, and last is an point properties.
|
|
7
7
|
* @param {number} [options.pointSize] - Point screen size in pixels.
|
|
8
8
|
* @param {number} [options.pickingDistance] - Point border picking size in screen pixels.
|
|
@@ -50,13 +50,13 @@ export class PointCloud {
|
|
|
50
50
|
/**
|
|
51
51
|
* Parent collection render node.
|
|
52
52
|
* @private
|
|
53
|
-
* @type {
|
|
53
|
+
* @type {RenderNode}
|
|
54
54
|
*/
|
|
55
55
|
private _renderNode;
|
|
56
56
|
/**
|
|
57
57
|
* Entity instance that holds this point cloud.
|
|
58
58
|
* @private
|
|
59
|
-
* @type {
|
|
59
|
+
* @type {Entity}
|
|
60
60
|
*/
|
|
61
61
|
private _entity;
|
|
62
62
|
/**
|
|
@@ -89,7 +89,7 @@ export class PointCloud {
|
|
|
89
89
|
/**
|
|
90
90
|
* Handler that stores and renders this object.
|
|
91
91
|
* @private
|
|
92
|
-
* @type {
|
|
92
|
+
* @type {PointCloudHandler}
|
|
93
93
|
*/
|
|
94
94
|
private _handler;
|
|
95
95
|
_handlerIndex: number;
|
|
@@ -120,9 +120,9 @@ export class PointCloud {
|
|
|
120
120
|
/**
|
|
121
121
|
* Assign rendering scene node.
|
|
122
122
|
* @public
|
|
123
|
-
* @param {
|
|
123
|
+
* @param {RenderNode} renderNode - Assigned render node.
|
|
124
124
|
*/
|
|
125
|
-
public setRenderNode(renderNode:
|
|
125
|
+
public setRenderNode(renderNode: RenderNode): void;
|
|
126
126
|
/**
|
|
127
127
|
* Removes from entity.
|
|
128
128
|
* @public
|
|
@@ -131,11 +131,11 @@ export class PointCloud {
|
|
|
131
131
|
/**
|
|
132
132
|
* Adds points to render.
|
|
133
133
|
* @public
|
|
134
|
-
* @param {Array.<Array<number
|
|
134
|
+
* @param {Array.<Array<number>>} points - Point cloud array.
|
|
135
135
|
* @example
|
|
136
136
|
* var points = [[0, 0, 0, 255, 255, 255, 255, { 'name': 'White point' }], [100, 100, 0, 255, 0, 0, 255, { 'name': 'Red point' }]];
|
|
137
137
|
*/
|
|
138
|
-
public setPoints(points: Array<Array<number
|
|
138
|
+
public setPoints(points: Array<Array<number>>): void;
|
|
139
139
|
setPointPosition(index: any, x: any, y: any, z: any): void;
|
|
140
140
|
setPointColor(index: any, r: any, g: any, b: any, a: any): void;
|
|
141
141
|
addPoints(points: any): void;
|
|
@@ -11,19 +11,19 @@ export class PointCloudHandler {
|
|
|
11
11
|
/**
|
|
12
12
|
* Parent collection
|
|
13
13
|
* @private
|
|
14
|
-
* @type {
|
|
14
|
+
* @type {EntityCollection}
|
|
15
15
|
*/
|
|
16
16
|
private _entityCollection;
|
|
17
17
|
/**
|
|
18
18
|
* Renderer
|
|
19
19
|
* @private
|
|
20
|
-
* @type {
|
|
20
|
+
* @type {Renderer}
|
|
21
21
|
*/
|
|
22
22
|
private _renderer;
|
|
23
23
|
/**
|
|
24
24
|
* Point cloud array
|
|
25
25
|
* @private
|
|
26
|
-
* @type {Array.<
|
|
26
|
+
* @type {Array.<PointCloud>}
|
|
27
27
|
*/
|
|
28
28
|
private _pointClouds;
|
|
29
29
|
__staticId: number;
|
|
@@ -4,63 +4,63 @@
|
|
|
4
4
|
* @param {Object} [options] - Polyline options:
|
|
5
5
|
* @param {number} [options.thickness] - Thickness in screen pixels 1.5 is default.
|
|
6
6
|
* @param {Number} [options.altitude] - Relative to ground layers altitude value.
|
|
7
|
-
* @param {
|
|
7
|
+
* @param {Vec4} [options.color] - RGBA color.
|
|
8
8
|
* @param {Boolean} [options.opacity] - Line opacity.
|
|
9
9
|
* @param {Boolean} [options.visibility] - Polyline visibility. True default.
|
|
10
10
|
* @param {Boolean} [options.isClosed] - Closed geometry type identificator.
|
|
11
|
-
* @param {Array.<Array.<number
|
|
12
|
-
* @param {Array.<Array.<number
|
|
13
|
-
* @param {Array.<Array.<number
|
|
11
|
+
* @param {Array.<Array.<number>>} [options.pathLonLat] - Polyline geodetic coordinates array. [[0,0,0], [1,1,1],...]
|
|
12
|
+
* @param {Array.<Array.<number>>} [options.path3v] - LinesString cartesian coordinates array. [[0,0,0], [1,1,1],...]
|
|
13
|
+
* @param {Array.<Array.<number>>} [options.pathColors] - Coordinates color. [[1,0,0,1], [0,1,0,1],...] for right and green colors.
|
|
14
14
|
*/
|
|
15
15
|
export class Polyline {
|
|
16
16
|
static set _staticCounter(arg: any);
|
|
17
17
|
static get _staticCounter(): any;
|
|
18
18
|
/**
|
|
19
19
|
* Appends to the line array new cartesian coordinates line data.
|
|
20
|
-
* @param {Array.<Array.<number
|
|
20
|
+
* @param {Array.<Array.<number>>} path3v - Line coordinates path array. [[0,0,0], [1,1,1],...]
|
|
21
21
|
* @param {Boolean} isClosed - Identificator for the closed line data creation.
|
|
22
22
|
* @param {Number[]} outVertices - Out vertices data array.
|
|
23
23
|
* @param {Number[]} outOrders - Out vertices orders data array.
|
|
24
24
|
* @param {Number[]} outIndexes - Out vertices indexes data array.
|
|
25
|
-
* @param {
|
|
26
|
-
* @param {Array.<Array.<
|
|
27
|
-
* @param {Array.<Array.<
|
|
28
|
-
* @param {Array.<Array.<
|
|
29
|
-
* @param {
|
|
25
|
+
* @param {Ellipsoid} [ellipsoid] - Ellipsoid to coordinates transformation.
|
|
26
|
+
* @param {Array.<Array.<LonLat>>} [outTransformedPathLonLat] - Geodetic coordinates out array.
|
|
27
|
+
* @param {Array.<Array.<LonLat>>} [outPath3v] - Cartesian coordinates out array.
|
|
28
|
+
* @param {Array.<Array.<LonLat>>} [outTransformedPathMerc] - Mercator coordinates out array.
|
|
29
|
+
* @param {Extent} [outExtent] - Geodetic line extent.
|
|
30
30
|
* @param {Array} [outColors]
|
|
31
31
|
* @static
|
|
32
32
|
*/
|
|
33
|
-
static appendLineData3v(path3v: Array<Array<number
|
|
33
|
+
static appendLineData3v(path3v: Array<Array<number>>, pathColors: any, defaultColor: any, isClosed: boolean, outVerticesHigh: any, outVerticesLow: any, outOrders: number[], outIndexes: number[], ellipsoid?: Ellipsoid, outTransformedPathLonLat?: Array<Array<LonLat>>, outPath3v?: Array<Array<LonLat>>, outTransformedPathMerc?: Array<Array<LonLat>>, outExtent?: Extent, outColors?: any[]): void;
|
|
34
34
|
/**
|
|
35
35
|
* Appends to the line new cartesian coordinates point data.
|
|
36
|
-
* @param {Array.<Array.<number
|
|
36
|
+
* @param {Array.<Array.<number>>} path3v - Line coordinates path array. [[0,0,0], [1,1,1],...]
|
|
37
37
|
* @param {Boolean} isClosed - Identificator for the closed line data creation.
|
|
38
38
|
* @param {Number[]} outVertices - Out vertices data array.
|
|
39
39
|
* @param {Number[]} outOrders - Out vertices orders data array.
|
|
40
40
|
* @param {Number[]} outIndexes - Out vertices indexes data array.
|
|
41
|
-
* @param {
|
|
42
|
-
* @param {Array.<Array.<
|
|
43
|
-
* @param {Array.<Array.<
|
|
44
|
-
* @param {Array.<Array.<
|
|
45
|
-
* @param {
|
|
41
|
+
* @param {Ellipsoid} [ellipsoid] - Ellipsoid to coordinates transformation.
|
|
42
|
+
* @param {Array.<Array.<LonLat>>} [outTransformedPathLonLat] - Geodetic coordinates out array.
|
|
43
|
+
* @param {Array.<Array.<LonLat>>} [outPath3v] - Cartesian coordinates out array.
|
|
44
|
+
* @param {Array.<Array.<LonLat>>} [outTransformedPathMerc] - Mercator coordinates out array.
|
|
45
|
+
* @param {Extent} [outExtent] - Geodetic line extent.
|
|
46
46
|
* @static
|
|
47
47
|
*/
|
|
48
|
-
static appendPoint3v(path3v: Array<Array<number
|
|
48
|
+
static appendPoint3v(path3v: Array<Array<number>>, point3v: any, pathColors: any, color: any, isClosed: boolean, outVerticesHigh: any, outVerticesLow: any, outColors: any, outOrders: number[], outIndexes: number[], ellipsoid?: Ellipsoid, outTransformedPathLonLat?: Array<Array<LonLat>>, outTransformedPathMerc?: Array<Array<LonLat>>, outExtent?: Extent): void;
|
|
49
49
|
/**
|
|
50
50
|
* Appends to the line array new geodetic coordinates line data.
|
|
51
|
-
* @param {Array.<Array.<number
|
|
51
|
+
* @param {Array.<Array.<number>>} pathLonLat - Line geodetic coordinates path array. [[0,0,0], [1,1,1],...]
|
|
52
52
|
* @param {Boolean} isClosed - Identificator for the closed line data creation.
|
|
53
53
|
* @param {Number[]} outVertices - Out vertices data array.
|
|
54
54
|
* @param {Number[]} outOrders - Out vertices orders data array.
|
|
55
55
|
* @param {Number[]} outIndexes - Out indexes data array.
|
|
56
|
-
* @param {
|
|
57
|
-
* @param {Array.<Array.<
|
|
58
|
-
* @param {Array.<Array.<
|
|
59
|
-
* @param {Array.<Array.<
|
|
60
|
-
* @param {
|
|
56
|
+
* @param {Ellipsoid} ellipsoid - Ellipsoid to coordinates transformation.
|
|
57
|
+
* @param {Array.<Array.<number>>} outTransformedPathCartesian - Cartesian coordinates out array. [[0,0,0], [1,1,1],...]
|
|
58
|
+
* @param {Array.<Array.<LonLat>>} outPathLonLat - Geographic coordinates out array.
|
|
59
|
+
* @param {Array.<Array.<LonLat>>} outTransformedPathMerc - Mercator coordinates out array.
|
|
60
|
+
* @param {Extent} outExtent - Geodetic line extent.
|
|
61
61
|
* @static
|
|
62
62
|
*/
|
|
63
|
-
static appendLineDataLonLat(pathLonLat: Array<Array<number
|
|
63
|
+
static appendLineDataLonLat(pathLonLat: Array<Array<number>>, pathColors: any, defaultColor: any, isClosed: boolean, outVerticesHigh: any, outVerticesLow: any, outOrders: number[], outIndexes: number[], ellipsoid: Ellipsoid, outTransformedPathCartesian: Array<Array<number>>, outPathLonLat: Array<Array<LonLat>>, outTransformedPathMerc: Array<Array<LonLat>>, outExtent: Extent, outColors: any): void;
|
|
64
64
|
constructor(options: any);
|
|
65
65
|
/**
|
|
66
66
|
* Object unic identifier.
|
|
@@ -79,9 +79,9 @@ export class Polyline {
|
|
|
79
79
|
/**
|
|
80
80
|
* Polyline RGBA color.
|
|
81
81
|
* @public
|
|
82
|
-
* @type {Array<
|
|
82
|
+
* @type {Array<number>} - (exactly 4 entries)
|
|
83
83
|
*/
|
|
84
|
-
public _defaultColor: Array<number
|
|
84
|
+
public _defaultColor: Array<number>;
|
|
85
85
|
/**
|
|
86
86
|
* Polyline visibility.
|
|
87
87
|
* @public
|
|
@@ -97,29 +97,29 @@ export class Polyline {
|
|
|
97
97
|
/**
|
|
98
98
|
* Polyline cartesian coordinates.
|
|
99
99
|
* @private
|
|
100
|
-
* @type {Array.<
|
|
100
|
+
* @type {Array.<Vec3>}
|
|
101
101
|
*/
|
|
102
102
|
private _path3v;
|
|
103
103
|
_pathLengths: any[];
|
|
104
104
|
/**
|
|
105
105
|
* Polyline geodetic degrees coordiantes.
|
|
106
106
|
* @private
|
|
107
|
-
* @type {Array.<
|
|
107
|
+
* @type {Array.<LonLat>}
|
|
108
108
|
*/
|
|
109
109
|
private _pathLonLat;
|
|
110
110
|
/**
|
|
111
111
|
* Polyline geodetic mercator coordinates.
|
|
112
112
|
* @private
|
|
113
|
-
* @type {Array.<
|
|
113
|
+
* @type {Array.<LonLat>}
|
|
114
114
|
*/
|
|
115
115
|
private _pathLonLatMerc;
|
|
116
116
|
_pathColors: any;
|
|
117
117
|
/**
|
|
118
118
|
* Polyline geodetic extent.
|
|
119
119
|
* @protected
|
|
120
|
-
* @type {
|
|
120
|
+
* @type {Extent}
|
|
121
121
|
*/
|
|
122
|
-
protected _extent:
|
|
122
|
+
protected _extent: Extent;
|
|
123
123
|
_verticesHigh: any[];
|
|
124
124
|
_verticesLow: any[];
|
|
125
125
|
_orders: any[];
|
|
@@ -135,13 +135,13 @@ export class Polyline {
|
|
|
135
135
|
/**
|
|
136
136
|
* Entity instance that holds this Polyline.
|
|
137
137
|
* @private
|
|
138
|
-
* @type {
|
|
138
|
+
* @type {Entity}
|
|
139
139
|
*/
|
|
140
140
|
private _entity;
|
|
141
141
|
/**
|
|
142
142
|
* Handler that stores and renders this Polyline object.
|
|
143
143
|
* @private
|
|
144
|
-
* @type {
|
|
144
|
+
* @type {PolylineHandler}
|
|
145
145
|
*/
|
|
146
146
|
private _handler;
|
|
147
147
|
_handlerIndex: number;
|
|
@@ -152,13 +152,13 @@ export class Polyline {
|
|
|
152
152
|
* @protected
|
|
153
153
|
* @param {pg.math.Vector3[]} path3v - Cartesian coordinates.
|
|
154
154
|
*/
|
|
155
|
-
protected _setEqualPath3v(path3v:
|
|
155
|
+
protected _setEqualPath3v(path3v: pg.math.Vector3[]): void;
|
|
156
156
|
/**
|
|
157
157
|
* Sets polyline with geodetic coordinates.
|
|
158
158
|
* @protected
|
|
159
|
-
* @param {
|
|
159
|
+
* @param {LonLat[]} pathLonLat - Geodetic polyline path coordinates.
|
|
160
160
|
*/
|
|
161
|
-
protected _setEqualPathLonLat(pathLonLat:
|
|
161
|
+
protected _setEqualPathLonLat(pathLonLat: LonLat[]): void;
|
|
162
162
|
setPointLonLat(lonlat: any, index: any, segmentIndex: any): void;
|
|
163
163
|
setPoint3v(coordinates: any, index: any, segmentIndex: any, skipLonLat: any): void;
|
|
164
164
|
_resizePathLengths(index?: number): void;
|
|
@@ -168,23 +168,23 @@ export class Polyline {
|
|
|
168
168
|
/**
|
|
169
169
|
* Adds a new cartesian point in the end of the path in a last line segment.
|
|
170
170
|
* @public
|
|
171
|
-
* @param {
|
|
171
|
+
* @param {Vec3} point3v - New coordinate.
|
|
172
172
|
*/
|
|
173
|
-
public appendPoint3v(point3v:
|
|
173
|
+
public appendPoint3v(point3v: Vec3, color: any, skipEllipsoid: any): void;
|
|
174
174
|
/**
|
|
175
175
|
* Adds a new cartesian point in the end of the path.
|
|
176
176
|
* @public
|
|
177
|
-
* @param {
|
|
177
|
+
* @param {Vec3} point3v - New coordinate.
|
|
178
178
|
* @param {number} [multiLineIndex=0] - Path part index, first by default.
|
|
179
179
|
*/
|
|
180
|
-
public addPoint3v(point3v:
|
|
180
|
+
public addPoint3v(point3v: Vec3, multiLineIndex?: number): void;
|
|
181
181
|
/**
|
|
182
182
|
* Adds a new geodetic point in the end of the path.
|
|
183
183
|
* @public
|
|
184
|
-
* @param {
|
|
184
|
+
* @param {LonLat} lonLat - New coordinate.
|
|
185
185
|
* @param {number} [multiLineIndex=0] - Path part index, first by default.
|
|
186
186
|
*/
|
|
187
|
-
public addPointLonLat(lonLat:
|
|
187
|
+
public addPointLonLat(lonLat: LonLat, multiLineIndex?: number): void;
|
|
188
188
|
/**
|
|
189
189
|
* Clear Polyline object data.
|
|
190
190
|
* @public
|
|
@@ -224,9 +224,9 @@ export class Polyline {
|
|
|
224
224
|
/**
|
|
225
225
|
* Assign with render node.
|
|
226
226
|
* @public
|
|
227
|
-
* @param {
|
|
227
|
+
* @param {RenderNode} renderNode -
|
|
228
228
|
*/
|
|
229
|
-
public setRenderNode(renderNode:
|
|
229
|
+
public setRenderNode(renderNode: RenderNode): void;
|
|
230
230
|
/**
|
|
231
231
|
* @protected
|
|
232
232
|
*/
|
|
@@ -242,36 +242,36 @@ export class Polyline {
|
|
|
242
242
|
/**
|
|
243
243
|
* Returns polyline geodetic extent.
|
|
244
244
|
* @public
|
|
245
|
-
* @returns {
|
|
245
|
+
* @returns {Extent} - Geodetic extent
|
|
246
246
|
*/
|
|
247
|
-
public getExtent():
|
|
247
|
+
public getExtent(): Extent;
|
|
248
248
|
/**
|
|
249
249
|
* Returns path cartesian coordinates.
|
|
250
|
-
* @return {Array.<
|
|
250
|
+
* @return {Array.<Vec3>} Polyline path.
|
|
251
251
|
*/
|
|
252
|
-
getPath3v(): Array<
|
|
252
|
+
getPath3v(): Array<Vec3>;
|
|
253
253
|
/**
|
|
254
254
|
* Returns geodetic path coordinates.
|
|
255
|
-
* @return {Array.<
|
|
255
|
+
* @return {Array.<LonLat>} Polyline path.
|
|
256
256
|
*/
|
|
257
|
-
getPathLonLat(): Array<
|
|
257
|
+
getPathLonLat(): Array<LonLat>;
|
|
258
258
|
getPathColors(): any;
|
|
259
259
|
setPathColors(pathColors: any): void;
|
|
260
260
|
setColorHTML(htmlColor: any): void;
|
|
261
261
|
/**
|
|
262
262
|
* Sets geodetic coordinates.
|
|
263
263
|
* @public
|
|
264
|
-
* @param {Array.<Array.<number
|
|
264
|
+
* @param {Array.<Array.<number>>} pathLonLat - Polyline path cartesian coordinates. (exactly 3 entries)
|
|
265
265
|
* @param {Boolean} [forceEqual=false] - Makes assigning faster for size equal coordinates array.
|
|
266
266
|
*/
|
|
267
|
-
public setPathLonLat(pathLonLat: Array<Array<number
|
|
267
|
+
public setPathLonLat(pathLonLat: Array<Array<number>>, forceEqual?: boolean): void;
|
|
268
268
|
/**
|
|
269
269
|
* Sets Polyline cartesian coordinates.
|
|
270
270
|
* @public
|
|
271
|
-
* @param {Array.<Array.<number
|
|
271
|
+
* @param {Array.<Array.<number>>} path3v - Polyline path cartesian coordinates. (exactly 3 entries)
|
|
272
272
|
* @param {Boolean} [forceEqual=false] - Makes assigning faster for size equal coordinates array.
|
|
273
273
|
*/
|
|
274
|
-
public setPath3v(path3v: Array<Array<number
|
|
274
|
+
public setPath3v(path3v: Array<Array<number>>, pathColors: any, forceEqual?: boolean): void;
|
|
275
275
|
draw(): void;
|
|
276
276
|
drawPicking(): void;
|
|
277
277
|
/**
|
|
@@ -301,3 +301,6 @@ export class Polyline {
|
|
|
301
301
|
protected _createIndexBuffer(): void;
|
|
302
302
|
_createColorsBuffer(): void;
|
|
303
303
|
}
|
|
304
|
+
import { Extent } from "../Extent.js";
|
|
305
|
+
import { LonLat } from "../LonLat.js";
|
|
306
|
+
import { Vec3 } from "../math/Vec3.js";
|
package/types/entity/Ray.d.ts
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* Ray class.
|
|
3
3
|
* @class
|
|
4
4
|
* @param {Object} [options] - Options:
|
|
5
|
-
* @param {
|
|
6
|
-
* @param {
|
|
7
|
-
* @param {
|
|
8
|
-
* @param {
|
|
5
|
+
* @param {Vec3|Array.<number>} [options.startPosition] - Ray start point position.
|
|
6
|
+
* @param {Vec3|Array.<number>} [options.endPosition] - Ray end point position.
|
|
7
|
+
* @param {Vec3|Array.<number>} [options.startColor] - Ray start point color.
|
|
8
|
+
* @param {Vec3|Array.<number>} [options.endColor] - Ray end point color.
|
|
9
9
|
* @param {boolean} [options.visibility] - Visibility.
|
|
10
10
|
*/
|
|
11
11
|
export class Ray {
|
|
@@ -37,15 +37,15 @@ export class Ray {
|
|
|
37
37
|
/**
|
|
38
38
|
* Entity instance that holds this billboard.
|
|
39
39
|
* @protected
|
|
40
|
-
* @type {
|
|
40
|
+
* @type {Entity}
|
|
41
41
|
*/
|
|
42
|
-
protected _entity:
|
|
42
|
+
protected _entity: Entity;
|
|
43
43
|
/**
|
|
44
44
|
* Handler that stores and renders this billboard object.
|
|
45
45
|
* @protected
|
|
46
|
-
* @type {
|
|
46
|
+
* @type {BillboardHandler}
|
|
47
47
|
*/
|
|
48
|
-
protected _handler:
|
|
48
|
+
protected _handler: BillboardHandler;
|
|
49
49
|
/**
|
|
50
50
|
* Billboard handler array index.
|
|
51
51
|
* @protected
|
|
@@ -63,9 +63,9 @@ export class Ray {
|
|
|
63
63
|
/**
|
|
64
64
|
* Sets ray start position.
|
|
65
65
|
* @public
|
|
66
|
-
* @param {
|
|
66
|
+
* @param {Vec3} position - Cartesian coordinates.
|
|
67
67
|
*/
|
|
68
|
-
public setStartPosition3v(position:
|
|
68
|
+
public setStartPosition3v(position: Vec3): void;
|
|
69
69
|
/**
|
|
70
70
|
* Sets ray end position.
|
|
71
71
|
* @public
|
|
@@ -77,9 +77,9 @@ export class Ray {
|
|
|
77
77
|
/**
|
|
78
78
|
* Sets ray end position.
|
|
79
79
|
* @public
|
|
80
|
-
* @param {
|
|
80
|
+
* @param {Vec3} position - Cartesian coordinates.
|
|
81
81
|
*/
|
|
82
|
-
public setEndPosition3v(position:
|
|
82
|
+
public setEndPosition3v(position: Vec3): void;
|
|
83
83
|
setLength(length: any): void;
|
|
84
84
|
setThickness(thickness: any): void;
|
|
85
85
|
setColors4v(startColor: any, endColor: any): void;
|
|
@@ -87,15 +87,15 @@ export class Ray {
|
|
|
87
87
|
/**
|
|
88
88
|
* Returns ray start position.
|
|
89
89
|
* @public
|
|
90
|
-
* @returns {
|
|
90
|
+
* @returns {Vec3}
|
|
91
91
|
*/
|
|
92
|
-
public getStartPosition():
|
|
92
|
+
public getStartPosition(): Vec3;
|
|
93
93
|
/**
|
|
94
94
|
* Returns ray end position.
|
|
95
95
|
* @public
|
|
96
|
-
* @returns {
|
|
96
|
+
* @returns {Vec3}
|
|
97
97
|
*/
|
|
98
|
-
public getEndPosition():
|
|
98
|
+
public getEndPosition(): Vec3;
|
|
99
99
|
/**
|
|
100
100
|
* Sets billboard visibility.
|
|
101
101
|
* @public
|
|
@@ -116,8 +116,9 @@ export class Ray {
|
|
|
116
116
|
/**
|
|
117
117
|
* Sets billboard picking color.
|
|
118
118
|
* @public
|
|
119
|
-
* @param {
|
|
119
|
+
* @param {Vec3} color - Picking color.
|
|
120
120
|
*/
|
|
121
|
-
public setPickingColor3v(color:
|
|
121
|
+
public setPickingColor3v(color: Vec3): void;
|
|
122
122
|
}
|
|
123
123
|
import { Vec3 } from "../math/Vec3.js";
|
|
124
|
+
import { Entity } from "./Entity.js";
|
package/types/entity/Strip.d.ts
CHANGED
|
@@ -35,13 +35,13 @@ export class Strip {
|
|
|
35
35
|
/**
|
|
36
36
|
* Parent collection render node.
|
|
37
37
|
* @private
|
|
38
|
-
* @type {
|
|
38
|
+
* @type {RenderNode}
|
|
39
39
|
*/
|
|
40
40
|
private _renderNode;
|
|
41
41
|
/**
|
|
42
42
|
* Entity instance that holds this strip.
|
|
43
43
|
* @private
|
|
44
|
-
* @type {
|
|
44
|
+
* @type {Entity}
|
|
45
45
|
*/
|
|
46
46
|
private _entity;
|
|
47
47
|
_verticesHighBuffer: any;
|
|
@@ -56,16 +56,16 @@ export class Strip {
|
|
|
56
56
|
/**
|
|
57
57
|
* Handler that stores and renders this object.
|
|
58
58
|
* @private
|
|
59
|
-
* @type {
|
|
59
|
+
* @type {StripHandler}
|
|
60
60
|
*/
|
|
61
61
|
private _handler;
|
|
62
62
|
_handlerIndex: number;
|
|
63
63
|
/**
|
|
64
64
|
* Assign picking color.
|
|
65
65
|
* @protected
|
|
66
|
-
* @param {
|
|
66
|
+
* @param {Vec3} color - Picking RGB color.
|
|
67
67
|
*/
|
|
68
|
-
protected setPickingColor3v(color:
|
|
68
|
+
protected setPickingColor3v(color: Vec3): void;
|
|
69
69
|
/**
|
|
70
70
|
* Clears object
|
|
71
71
|
* @public
|
|
@@ -91,9 +91,9 @@ export class Strip {
|
|
|
91
91
|
/**
|
|
92
92
|
* Assign rendering scene node.
|
|
93
93
|
* @public
|
|
94
|
-
* @param {
|
|
94
|
+
* @param {RenderNode} renderNode - Assigned render node.
|
|
95
95
|
*/
|
|
96
|
-
public setRenderNode(renderNode:
|
|
96
|
+
public setRenderNode(renderNode: RenderNode): void;
|
|
97
97
|
/**
|
|
98
98
|
* Removes from entity.
|
|
99
99
|
* @public
|
|
@@ -116,3 +116,4 @@ export class Strip {
|
|
|
116
116
|
setPath(path: any): void;
|
|
117
117
|
insertEdge3v(p0: any, p1: any, index: any): void;
|
|
118
118
|
}
|
|
119
|
+
import { Vec3 } from "../math/Vec3.js";
|
|
@@ -11,19 +11,19 @@ export class StripHandler {
|
|
|
11
11
|
/**
|
|
12
12
|
* Parent collection
|
|
13
13
|
* @private
|
|
14
|
-
* @type {
|
|
14
|
+
* @type {EntityCollection}
|
|
15
15
|
*/
|
|
16
16
|
private _entityCollection;
|
|
17
17
|
/**
|
|
18
18
|
* Renderer
|
|
19
19
|
* @private
|
|
20
|
-
* @type {
|
|
20
|
+
* @type {Renderer}
|
|
21
21
|
*/
|
|
22
22
|
private _renderer;
|
|
23
23
|
/**
|
|
24
24
|
* Point cloud array
|
|
25
25
|
* @private
|
|
26
|
-
* @type {Array.<
|
|
26
|
+
* @type {Array.<Strip>}
|
|
27
27
|
*/
|
|
28
28
|
private _strips;
|
|
29
29
|
__staticId: number;
|
package/types/entity/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { Entity } from "./Entity";
|
|
2
|
-
import { EntityCollection } from "./EntityCollection";
|
|
3
|
-
import { Billboard } from "./Billboard";
|
|
4
|
-
import { Geometry } from "./Geometry";
|
|
5
|
-
import { Label } from "./Label";
|
|
6
|
-
import { PointCloud } from "./PointCloud";
|
|
7
|
-
import { Polyline } from "./Polyline";
|
|
1
|
+
import { Entity } from "./Entity.js";
|
|
2
|
+
import { EntityCollection } from "./EntityCollection.js";
|
|
3
|
+
import { Billboard } from "./Billboard.js";
|
|
4
|
+
import { Geometry } from "./Geometry.js";
|
|
5
|
+
import { Label } from "./Label.js";
|
|
6
|
+
import { PointCloud } from "./PointCloud.js";
|
|
7
|
+
import { Polyline } from "./Polyline.js";
|
|
8
8
|
export { Entity, EntityCollection, Billboard, Geometry, Label, PointCloud, Polyline };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export class KeyboardHandler {
|
|
2
|
+
removeEvent: (events: any, callback: any) => void;
|
|
3
|
+
setActivity: (activity: any) => void;
|
|
4
|
+
releaseKeys: () => void;
|
|
5
|
+
addEvent: (event: any, sender: any, callback: any, keyCode: any, priority: any) => void;
|
|
6
|
+
isKeyPressed: (keyCode: any) => any;
|
|
7
|
+
handleKeyDown: () => void;
|
|
8
|
+
handleKeyUp: () => void;
|
|
9
|
+
handleEvents: () => void;
|
|
10
|
+
}
|