@openglobus/og 0.24.2 → 0.25.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/lib/{js/Globe.d.ts → Globe.d.ts} +16 -18
- package/lib/{js/Object3d.d.ts → Object3d.d.ts} +1 -1
- package/lib/{@openglobus/js/camera → camera}/Camera.d.ts +16 -22
- package/lib/{@openglobus/js/camera → camera}/Frustum.d.ts +1 -1
- package/lib/control/CameraFrameComposer.d.ts +35 -0
- package/lib/control/KeyboardNavigation.d.ts +32 -0
- package/lib/control/MouseWheelZoomControl.d.ts +1 -0
- package/lib/{js/control → control/atmosphere}/Atmosphere.d.ts +9 -6
- package/lib/{@openglobus/js/control → control/atmosphere}/AtmosphereConfig.d.ts +6 -6
- package/lib/{js/control → control}/index.d.ts +3 -1
- package/lib/control/object3dManager/Object3dCollection.d.ts +21 -0
- package/lib/control/object3dManager/Object3dCollectionView.d.ts +15 -0
- package/lib/control/object3dManager/Object3dItemView.d.ts +10 -0
- package/lib/control/object3dManager/Object3dManager.d.ts +28 -0
- package/lib/control/object3dManager/Object3dManagerDialog.d.ts +23 -0
- package/lib/{js/control → control}/visibleExtent/Segment.d.ts +3 -3
- package/lib/entity/LabelWorker.worker.d.ts +1 -0
- package/lib/{@openglobus/js/index.d.ts → index.d.ts} +1 -0
- package/lib/og.css +1 -0
- package/lib/og.es.js +1 -0
- package/lib/{@openglobus/js/renderer → renderer}/Renderer.d.ts +28 -28
- package/lib/{@openglobus/js/scene → scene}/Planet.d.ts +3 -3
- package/lib/{@openglobus/js/segment → segment}/Segment.d.ts +1 -1
- package/lib/{js/segment → segment}/segmentHelper.d.ts +1 -1
- package/lib/{@openglobus/js/shaders → shaders/atmos}/atmos.d.ts +7 -5
- package/lib/{@openglobus/js/shaders → shaders/billboard}/billboard.d.ts +1 -1
- package/lib/shaders/drawnode/drawnode.d.ts +8 -0
- package/lib/{@openglobus/js/shaders/geoObject.d.ts → shaders/geo_object/geo_object.d.ts} +1 -1
- package/lib/{@openglobus/js/shaders → shaders/label}/label.d.ts +1 -1
- package/lib/{@openglobus/js/shaders → shaders/polyline}/polyline.d.ts +1 -1
- package/lib/shaders/ray/ray.d.ts +2 -0
- package/lib/{@openglobus/js/shaders → shaders/tone_mapping}/toneMapping.d.ts +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/lib/{@openglobus/js/ui → ui}/Dialog.d.ts +1 -1
- package/lib/{@openglobus/js/ui → ui}/View.d.ts +1 -0
- package/lib/{@openglobus/js/utils → utils}/BaseWorker.d.ts +2 -2
- package/lib/utils/PlainSegmentWorker.worker.d.ts +1 -0
- package/lib/utils/TerrainWorker.worker.d.ts +1 -0
- package/lib/{@openglobus/js/utils → utils}/objParser.d.ts +1 -1
- package/lib/{js/utils → utils}/shared.d.ts +16 -0
- package/lib/{js/webgl → webgl}/Framebuffer.d.ts +21 -5
- package/lib/{@openglobus/js/webgl → webgl}/Handler.d.ts +0 -1
- package/package.json +76 -68
- package/res/fonts/Ephesis-Regular.json +4648 -0
- package/res/fonts/Ephesis-Regular.ttf.cfg +1282 -0
- package/res/fonts/Ephesis-Regular.ttf.png +0 -0
- package/res/fonts/Karla-Bold.json +5252 -0
- package/res/fonts/Karla-Bold.ttf.cfg +920 -0
- package/res/fonts/Karla-Bold.ttf.png +0 -0
- package/res/fonts/Karla-Light.json +5252 -0
- package/res/fonts/Karla-Light.ttf.cfg +830 -0
- package/res/fonts/Karla-Light.ttf.png +0 -0
- package/res/fonts/Karla-Medium.json +5252 -0
- package/res/fonts/Karla-Medium.ttf.cfg +1196 -0
- package/res/fonts/Karla-Medium.ttf.png +0 -0
- package/res/fonts/NotoSansArabic-Regular.json +3332 -0
- package/res/fonts/NotoSansArabic-Regular.ttf.cfg +1370 -0
- package/res/fonts/NotoSansArabic-Regular.ttf.png +0 -0
- package/res/fonts/Roboto-Regular.json +37147 -0
- package/res/fonts/Roboto-Regular.ttf.cfg +1340 -0
- package/res/fonts/Roboto-Regular.ttf.png +0 -0
- package/res/fonts/arial.js +4325 -0
- package/res/fonts/arial.json +4321 -0
- package/res/fonts/arial.ttf.cfg +1570 -0
- package/res/fonts/arial.ttf.png +0 -0
- package/res/night-4326.png +0 -0
- package/res/night.png +0 -0
- package/res/spec.png +0 -0
- package/css/og.css +0 -1342
- package/lib/@openglobus/js/Globe.d.ts +0 -145
- package/lib/@openglobus/js/Object3d.d.ts +0 -81
- package/lib/@openglobus/js/control/Atmosphere.d.ts +0 -40
- package/lib/@openglobus/js/control/KeyboardNavigation.d.ts +0 -28
- package/lib/@openglobus/js/control/index.d.ts +0 -30
- package/lib/@openglobus/js/segment/segmentHelper.d.ts +0 -18
- package/lib/@openglobus/js/shaders/bloom.d.ts +0 -2
- package/lib/@openglobus/js/shaders/blur.d.ts +0 -3
- package/lib/@openglobus/js/shaders/drawnode.d.ts +0 -10
- package/lib/@openglobus/js/shaders/lumFilter.d.ts +0 -2
- package/lib/@openglobus/js/shaders/ray.d.ts +0 -2
- package/lib/@openglobus/js/shaders/utils.d.ts +0 -1
- package/lib/@openglobus/js/utils/shared.d.ts +0 -287
- package/lib/@openglobus/js/webgl/Framebuffer.d.ts +0 -97
- package/lib/@openglobus/og.css +0 -1
- package/lib/@openglobus/og.esm.js +0 -2
- package/lib/@openglobus/og.esm.js.map +0 -1
- package/lib/@openglobus/og.umd.js +0 -2
- package/lib/@openglobus/og.umd.js.map +0 -1
- package/lib/js/Clock.d.ts +0 -106
- package/lib/js/Clock.js +0 -141
- package/lib/js/Deferred.d.ts +0 -6
- package/lib/js/Deferred.js +0 -13
- package/lib/js/Events.d.ts +0 -90
- package/lib/js/Events.js +0 -145
- package/lib/js/Extent.d.ts +0 -145
- package/lib/js/Extent.js +0 -278
- package/lib/js/Globe.js +0 -289
- package/lib/js/ImageCanvas.d.ts +0 -128
- package/lib/js/ImageCanvas.js +0 -203
- package/lib/js/Lock.d.ts +0 -15
- package/lib/js/Lock.js +0 -27
- package/lib/js/LonLat.d.ts +0 -128
- package/lib/js/LonLat.js +0 -192
- package/lib/js/Object3d.js +0 -508
- package/lib/js/Popup.d.ts +0 -49
- package/lib/js/Popup.js +0 -160
- package/lib/js/QueueArray.d.ts +0 -16
- package/lib/js/QueueArray.js +0 -63
- package/lib/js/Rectangle.d.ts +0 -76
- package/lib/js/Rectangle.js +0 -77
- package/lib/js/Stack.d.ts +0 -20
- package/lib/js/Stack.js +0 -42
- package/lib/js/astro/astro.d.ts +0 -39
- package/lib/js/astro/astro.js +0 -43
- package/lib/js/astro/earth.d.ts +0 -8
- package/lib/js/astro/earth.js +0 -75
- package/lib/js/astro/jd.d.ts +0 -234
- package/lib/js/astro/jd.js +0 -416
- package/lib/js/astro/orbit.d.ts +0 -5
- package/lib/js/astro/orbit.js +0 -104
- package/lib/js/astro/rotation.d.ts +0 -2
- package/lib/js/astro/rotation.js +0 -25
- package/lib/js/bv/Box.d.ts +0 -32
- package/lib/js/bv/Box.js +0 -53
- package/lib/js/bv/Sphere.d.ts +0 -37
- package/lib/js/bv/Sphere.js +0 -31
- package/lib/js/bv/index.d.ts +0 -3
- package/lib/js/bv/index.js +0 -3
- package/lib/js/camera/Camera.d.ts +0 -361
- package/lib/js/camera/Camera.js +0 -541
- package/lib/js/camera/Frustum.d.ts +0 -142
- package/lib/js/camera/Frustum.js +0 -246
- package/lib/js/camera/PlanetCamera.d.ts +0 -247
- package/lib/js/camera/PlanetCamera.js +0 -513
- package/lib/js/camera/index.d.ts +0 -3
- package/lib/js/camera/index.js +0 -3
- package/lib/js/cons.d.ts +0 -40
- package/lib/js/cons.js +0 -92
- package/lib/js/control/Atmosphere.js +0 -401
- package/lib/js/control/AtmosphereConfig.d.ts +0 -59
- package/lib/js/control/AtmosphereConfig.js +0 -348
- package/lib/js/control/CameraLock.d.ts +0 -38
- package/lib/js/control/CameraLock.js +0 -216
- package/lib/js/control/CompassButton.d.ts +0 -16
- package/lib/js/control/CompassButton.js +0 -118
- package/lib/js/control/Control.d.ts +0 -100
- package/lib/js/control/Control.js +0 -137
- package/lib/js/control/DebugInfo.d.ts +0 -25
- package/lib/js/control/DebugInfo.js +0 -318
- package/lib/js/control/DrawingSwitcher.d.ts +0 -13
- package/lib/js/control/DrawingSwitcher.js +0 -94
- package/lib/js/control/EarthCoordinates.d.ts +0 -41
- package/lib/js/control/EarthCoordinates.js +0 -161
- package/lib/js/control/GeoImageDragControl.d.ts +0 -22
- package/lib/js/control/GeoImageDragControl.js +0 -102
- package/lib/js/control/KeyboardNavigation.d.ts +0 -28
- package/lib/js/control/KeyboardNavigation.js +0 -143
- package/lib/js/control/LayerAnimation.d.ts +0 -71
- package/lib/js/control/LayerAnimation.js +0 -283
- package/lib/js/control/LayerSwitcher.d.ts +0 -38
- package/lib/js/control/LayerSwitcher.js +0 -151
- package/lib/js/control/Lighting.d.ts +0 -54
- package/lib/js/control/Lighting.js +0 -459
- package/lib/js/control/MouseNavigation.d.ts +0 -76
- package/lib/js/control/MouseNavigation.js +0 -414
- package/lib/js/control/MouseWheelZoomControl.d.ts +0 -0
- package/lib/js/control/MouseWheelZoomControl.js +0 -270
- package/lib/js/control/OldMouseNavigation.d.ts +0 -65
- package/lib/js/control/OldMouseNavigation.js +0 -368
- package/lib/js/control/RulerSwitcher.d.ts +0 -18
- package/lib/js/control/RulerSwitcher.js +0 -57
- package/lib/js/control/ScaleControl.d.ts +0 -25
- package/lib/js/control/ScaleControl.js +0 -97
- package/lib/js/control/SegmentBoundVisualization.d.ts +0 -13
- package/lib/js/control/SegmentBoundVisualization.js +0 -37
- package/lib/js/control/ShowFps.d.ts +0 -10
- package/lib/js/control/ShowFps.js +0 -20
- package/lib/js/control/SimpleNavigation.d.ts +0 -43
- package/lib/js/control/SimpleNavigation.js +0 -196
- package/lib/js/control/SimpleSkyBackground.d.ts +0 -18
- package/lib/js/control/SimpleSkyBackground.js +0 -187
- package/lib/js/control/Sun.d.ts +0 -34
- package/lib/js/control/Sun.js +0 -117
- package/lib/js/control/ToggleWireframe.d.ts +0 -15
- package/lib/js/control/ToggleWireframe.js +0 -28
- package/lib/js/control/TouchNavigation.d.ts +0 -53
- package/lib/js/control/TouchNavigation.js +0 -266
- package/lib/js/control/ZoomControl.d.ts +0 -28
- package/lib/js/control/ZoomControl.js +0 -86
- package/lib/js/control/drawing/DrawingControl.d.ts +0 -12
- package/lib/js/control/drawing/DrawingControl.js +0 -35
- package/lib/js/control/drawing/LineStringDrawingScene.d.ts +0 -15
- package/lib/js/control/drawing/LineStringDrawingScene.js +0 -139
- package/lib/js/control/drawing/PolygonDrawingScene.d.ts +0 -98
- package/lib/js/control/drawing/PolygonDrawingScene.js +0 -533
- package/lib/js/control/elevationProfile/ElevationProfile.d.ts +0 -77
- package/lib/js/control/elevationProfile/ElevationProfile.js +0 -248
- package/lib/js/control/elevationProfile/ElevationProfileButtonsView.d.ts +0 -15
- package/lib/js/control/elevationProfile/ElevationProfileButtonsView.js +0 -61
- package/lib/js/control/elevationProfile/ElevationProfileControl.d.ts +0 -33
- package/lib/js/control/elevationProfile/ElevationProfileControl.js +0 -151
- package/lib/js/control/elevationProfile/ElevationProfileLegend.d.ts +0 -20
- package/lib/js/control/elevationProfile/ElevationProfileLegend.js +0 -82
- package/lib/js/control/elevationProfile/ElevationProfileScene.d.ts +0 -80
- package/lib/js/control/elevationProfile/ElevationProfileScene.js +0 -542
- package/lib/js/control/elevationProfile/ElevationProfileView.d.ts +0 -65
- package/lib/js/control/elevationProfile/ElevationProfileView.js +0 -504
- package/lib/js/control/elevationProfile/PointListDialog.d.ts +0 -12
- package/lib/js/control/elevationProfile/PointListDialog.js +0 -57
- package/lib/js/control/geoObjectEditor/ArrowEntity.d.ts +0 -15
- package/lib/js/control/geoObjectEditor/ArrowEntity.js +0 -59
- package/lib/js/control/geoObjectEditor/AxisTrackEntity.d.ts +0 -9
- package/lib/js/control/geoObjectEditor/AxisTrackEntity.js +0 -93
- package/lib/js/control/geoObjectEditor/GeoObjectEditor.d.ts +0 -13
- package/lib/js/control/geoObjectEditor/GeoObjectEditor.js +0 -30
- package/lib/js/control/geoObjectEditor/GeoObjectEditorDialog.d.ts +0 -69
- package/lib/js/control/geoObjectEditor/GeoObjectEditorDialog.js +0 -488
- package/lib/js/control/geoObjectEditor/GeoObjectEditorScene.d.ts +0 -127
- package/lib/js/control/geoObjectEditor/GeoObjectEditorScene.js +0 -549
- package/lib/js/control/geoObjectEditor/MoveAxisEntity.d.ts +0 -17
- package/lib/js/control/geoObjectEditor/MoveAxisEntity.js +0 -107
- package/lib/js/control/geoObjectEditor/MovePlaneEntity.d.ts +0 -7
- package/lib/js/control/geoObjectEditor/MovePlaneEntity.js +0 -31
- package/lib/js/control/geoObjectEditor/RotateEntity.d.ts +0 -9
- package/lib/js/control/geoObjectEditor/RotateEntity.js +0 -105
- package/lib/js/control/geoObjectEditor/colors.d.ts +0 -8
- package/lib/js/control/geoObjectEditor/colors.js +0 -8
- package/lib/js/control/heightRuler/HeightRuler.d.ts +0 -7
- package/lib/js/control/heightRuler/HeightRuler.js +0 -11
- package/lib/js/control/heightRuler/HeightRulerScene.d.ts +0 -35
- package/lib/js/control/heightRuler/HeightRulerScene.js +0 -181
- package/lib/js/control/heightRuler/HeightRulerSwitcher.d.ts +0 -6
- package/lib/js/control/heightRuler/HeightRulerSwitcher.js +0 -13
- package/lib/js/control/index.js +0 -30
- package/lib/js/control/ruler/Ruler.d.ts +0 -14
- package/lib/js/control/ruler/Ruler.js +0 -23
- package/lib/js/control/ruler/RulerScene.d.ts +0 -88
- package/lib/js/control/ruler/RulerScene.js +0 -324
- package/lib/js/control/selection/Selection.d.ts +0 -56
- package/lib/js/control/selection/Selection.js +0 -78
- package/lib/js/control/selection/SelectionScene.d.ts +0 -44
- package/lib/js/control/selection/SelectionScene.js +0 -272
- package/lib/js/control/timeline/TimelineControl.d.ts +0 -18
- package/lib/js/control/timeline/TimelineControl.js +0 -81
- package/lib/js/control/timeline/TimelineModel.d.ts +0 -41
- package/lib/js/control/timeline/TimelineModel.js +0 -104
- package/lib/js/control/timeline/TimelineView.d.ts +0 -86
- package/lib/js/control/timeline/TimelineView.js +0 -363
- package/lib/js/control/timeline/timelineUtils.d.ts +0 -12
- package/lib/js/control/timeline/timelineUtils.js +0 -112
- package/lib/js/control/visibleExtent/Segment.js +0 -1301
- package/lib/js/control/visibleExtent/VisibleExtent.js +0 -56
- package/lib/js/control/visibleExtent/drawnode.d.ts +0 -7
- package/lib/js/control/visibleExtent/drawnode.js +0 -718
- package/lib/js/ellipsoid/Ellipsoid.d.ts +0 -194
- package/lib/js/ellipsoid/Ellipsoid.js +0 -459
- package/lib/js/ellipsoid/index.d.ts +0 -4
- package/lib/js/ellipsoid/index.js +0 -4
- package/lib/js/ellipsoid/mars.d.ts +0 -6
- package/lib/js/ellipsoid/mars.js +0 -6
- package/lib/js/ellipsoid/moon.d.ts +0 -6
- package/lib/js/ellipsoid/moon.js +0 -6
- package/lib/js/ellipsoid/wgs84.d.ts +0 -6
- package/lib/js/ellipsoid/wgs84.js +0 -6
- package/lib/js/entity/BaseBillboard.d.ts +0 -225
- package/lib/js/entity/BaseBillboard.js +0 -284
- package/lib/js/entity/BaseBillboardHandler.d.ts +0 -81
- package/lib/js/entity/BaseBillboardHandler.js +0 -546
- package/lib/js/entity/Billboard.d.ts +0 -114
- package/lib/js/entity/Billboard.js +0 -127
- package/lib/js/entity/BillboardHandler.d.ts +0 -15
- package/lib/js/entity/BillboardHandler.js +0 -103
- package/lib/js/entity/Entity.d.ts +0 -630
- package/lib/js/entity/Entity.js +0 -957
- package/lib/js/entity/EntityCollection.d.ts +0 -368
- package/lib/js/entity/EntityCollection.js +0 -655
- package/lib/js/entity/GeoObject.d.ts +0 -257
- package/lib/js/entity/GeoObject.js +0 -318
- package/lib/js/entity/GeoObjectHandler.d.ts +0 -81
- package/lib/js/entity/GeoObjectHandler.js +0 -515
- package/lib/js/entity/Geometry.d.ts +0 -125
- package/lib/js/entity/Geometry.js +0 -291
- package/lib/js/entity/GeometryHandler.d.ts +0 -86
- package/lib/js/entity/GeometryHandler.js +0 -745
- package/lib/js/entity/InstanceData.d.ts +0 -76
- package/lib/js/entity/InstanceData.js +0 -347
- package/lib/js/entity/Label.d.ts +0 -230
- package/lib/js/entity/Label.js +0 -322
- package/lib/js/entity/LabelHandler.d.ts +0 -65
- package/lib/js/entity/LabelHandler.js +0 -696
- package/lib/js/entity/LabelWorker.d.ts +0 -15
- package/lib/js/entity/LabelWorker.js +0 -163
- package/lib/js/entity/PointCloud.d.ts +0 -179
- package/lib/js/entity/PointCloud.js +0 -327
- package/lib/js/entity/PointCloudHandler.d.ts +0 -42
- package/lib/js/entity/PointCloudHandler.js +0 -82
- package/lib/js/entity/Polyline.d.ts +0 -360
- package/lib/js/entity/Polyline.js +0 -1635
- package/lib/js/entity/PolylineHandler.d.ts +0 -29
- package/lib/js/entity/PolylineHandler.js +0 -103
- package/lib/js/entity/Ray.d.ts +0 -135
- package/lib/js/entity/Ray.js +0 -171
- package/lib/js/entity/RayHandler.d.ts +0 -70
- package/lib/js/entity/RayHandler.js +0 -496
- package/lib/js/entity/Strip.d.ts +0 -141
- package/lib/js/entity/Strip.js +0 -417
- package/lib/js/entity/StripHandler.d.ts +0 -42
- package/lib/js/entity/StripHandler.js +0 -110
- package/lib/js/entity/index.d.ts +0 -10
- package/lib/js/entity/index.js +0 -10
- package/lib/js/index.d.ts +0 -34
- package/lib/js/index.js +0 -34
- package/lib/js/input/KeyboardHandler.d.ts +0 -33
- package/lib/js/input/KeyboardHandler.js +0 -159
- package/lib/js/input/MouseHandler.d.ts +0 -17
- package/lib/js/input/MouseHandler.js +0 -92
- package/lib/js/input/TouchHandler.d.ts +0 -11
- package/lib/js/input/TouchHandler.js +0 -42
- package/lib/js/input/input.d.ts +0 -3
- package/lib/js/input/input.js +0 -47
- package/lib/js/layer/BaseGeoImage.d.ts +0 -146
- package/lib/js/layer/BaseGeoImage.js +0 -382
- package/lib/js/layer/Bing.d.ts +0 -5
- package/lib/js/layer/Bing.js +0 -41
- package/lib/js/layer/CanvasTiles.d.ts +0 -104
- package/lib/js/layer/CanvasTiles.js +0 -292
- package/lib/js/layer/GeoImage.d.ts +0 -62
- package/lib/js/layer/GeoImage.js +0 -133
- package/lib/js/layer/GeoTexture2d.d.ts +0 -18
- package/lib/js/layer/GeoTexture2d.js +0 -37
- package/lib/js/layer/GeoVideo.d.ts +0 -69
- package/lib/js/layer/GeoVideo.js +0 -157
- package/lib/js/layer/KML.d.ts +0 -74
- package/lib/js/layer/KML.js +0 -303
- package/lib/js/layer/Layer.d.ts +0 -416
- package/lib/js/layer/Layer.js +0 -734
- package/lib/js/layer/Material.d.ts +0 -34
- package/lib/js/layer/Material.js +0 -69
- package/lib/js/layer/OpenStreetMap.d.ts +0 -5
- package/lib/js/layer/OpenStreetMap.js +0 -19
- package/lib/js/layer/Vector.d.ts +0 -240
- package/lib/js/layer/Vector.js +0 -767
- package/lib/js/layer/WMS.d.ts +0 -76
- package/lib/js/layer/WMS.js +0 -112
- package/lib/js/layer/XYZ.d.ts +0 -149
- package/lib/js/layer/XYZ.js +0 -299
- package/lib/js/layer/index.d.ts +0 -12
- package/lib/js/layer/index.js +0 -12
- package/lib/js/light/LightSource.d.ts +0 -36
- package/lib/js/light/LightSource.js +0 -86
- package/lib/js/math/Line2.d.ts +0 -11
- package/lib/js/math/Line2.js +0 -21
- package/lib/js/math/Line3.d.ts +0 -28
- package/lib/js/math/Line3.js +0 -85
- package/lib/js/math/Mat3.d.ts +0 -77
- package/lib/js/math/Mat3.js +0 -139
- package/lib/js/math/Mat4.d.ts +0 -204
- package/lib/js/math/Mat4.js +0 -487
- package/lib/js/math/Plane.d.ts +0 -22
- package/lib/js/math/Plane.js +0 -118
- package/lib/js/math/Quat.d.ts +0 -393
- package/lib/js/math/Quat.js +0 -794
- package/lib/js/math/Ray.d.ts +0 -72
- package/lib/js/math/Ray.js +0 -211
- package/lib/js/math/Vec2.d.ts +0 -332
- package/lib/js/math/Vec2.js +0 -495
- package/lib/js/math/Vec3.d.ts +0 -488
- package/lib/js/math/Vec3.js +0 -828
- package/lib/js/math/Vec4.d.ts +0 -163
- package/lib/js/math/Vec4.js +0 -211
- package/lib/js/math/coder.d.ts +0 -53
- package/lib/js/math/coder.js +0 -101
- package/lib/js/math/index.d.ts +0 -14
- package/lib/js/math/index.js +0 -11
- package/lib/js/math.d.ts +0 -266
- package/lib/js/math.js +0 -379
- package/lib/js/mercator.d.ts +0 -92
- package/lib/js/mercator.js +0 -120
- package/lib/js/proj/EPSG3857.d.ts +0 -9
- package/lib/js/proj/EPSG3857.js +0 -9
- package/lib/js/proj/EPSG4326.d.ts +0 -9
- package/lib/js/proj/EPSG4326.js +0 -9
- package/lib/js/proj/Proj.d.ts +0 -43
- package/lib/js/proj/Proj.js +0 -38
- package/lib/js/proj/equi.d.ts +0 -9
- package/lib/js/proj/equi.js +0 -9
- package/lib/js/quadTree/EPSG4326/EPSG4326QuadTreeStrategy.d.ts +0 -6
- package/lib/js/quadTree/EPSG4326/EPSG4326QuadTreeStrategy.js +0 -16
- package/lib/js/quadTree/EntityCollectionNode.d.ts +0 -46
- package/lib/js/quadTree/EntityCollectionNode.js +0 -262
- package/lib/js/quadTree/EntityCollectionsTreeStrategy.d.ts +0 -25
- package/lib/js/quadTree/EntityCollectionsTreeStrategy.js +0 -49
- package/lib/js/quadTree/Node.d.ts +0 -80
- package/lib/js/quadTree/Node.js +0 -712
- package/lib/js/quadTree/QuadTreeStrategy.d.ts +0 -39
- package/lib/js/quadTree/QuadTreeStrategy.js +0 -98
- package/lib/js/quadTree/earth/EarthEntityCollectionNodeLonLat.d.ts +0 -19
- package/lib/js/quadTree/earth/EarthEntityCollectionNodeLonLat.js +0 -74
- package/lib/js/quadTree/earth/EarthEntityCollectionsTreeStrategy.d.ts +0 -19
- package/lib/js/quadTree/earth/EarthEntityCollectionsTreeStrategy.js +0 -103
- package/lib/js/quadTree/earth/EarthQuadTreeStrategy.d.ts +0 -27
- package/lib/js/quadTree/earth/EarthQuadTreeStrategy.js +0 -77
- package/lib/js/quadTree/equi/EquiEntityCollectionNodeLonLat.d.ts +0 -18
- package/lib/js/quadTree/equi/EquiEntityCollectionNodeLonLat.js +0 -70
- package/lib/js/quadTree/equi/EquiEntityCollectionsTreeStrategy.d.ts +0 -17
- package/lib/js/quadTree/equi/EquiEntityCollectionsTreeStrategy.js +0 -75
- package/lib/js/quadTree/equi/EquiQuadTreeStrategy.d.ts +0 -19
- package/lib/js/quadTree/equi/EquiQuadTreeStrategy.js +0 -62
- package/lib/js/quadTree/index.d.ts +0 -12
- package/lib/js/quadTree/index.js +0 -12
- package/lib/js/quadTree/quadTree.d.ts +0 -40
- package/lib/js/quadTree/quadTree.js +0 -66
- package/lib/js/quadTree/wgs84/Wgs84QuadTreeStrategy.d.ts +0 -6
- package/lib/js/quadTree/wgs84/Wgs84QuadTreeStrategy.js +0 -15
- package/lib/js/renderer/Renderer.d.ts +0 -343
- package/lib/js/renderer/Renderer.js +0 -969
- package/lib/js/renderer/RendererEvents.d.ts +0 -245
- package/lib/js/renderer/RendererEvents.js +0 -870
- package/lib/js/scene/Axes.d.ts +0 -12
- package/lib/js/scene/Axes.js +0 -59
- package/lib/js/scene/BaseNode.d.ts +0 -61
- package/lib/js/scene/BaseNode.js +0 -69
- package/lib/js/scene/Planet.d.ts +0 -641
- package/lib/js/scene/Planet.js +0 -1617
- package/lib/js/scene/RenderNode.d.ts +0 -135
- package/lib/js/scene/RenderNode.js +0 -313
- package/lib/js/scene/SkyBox.d.ts +0 -13
- package/lib/js/scene/SkyBox.js +0 -87
- package/lib/js/scene/index.d.ts +0 -5
- package/lib/js/scene/index.js +0 -5
- package/lib/js/segment/Segment.d.ts +0 -289
- package/lib/js/segment/Segment.js +0 -1212
- package/lib/js/segment/SegmentLonLat.d.ts +0 -40
- package/lib/js/segment/SegmentLonLat.js +0 -111
- package/lib/js/segment/SegmentLonLatEqui.d.ts +0 -13
- package/lib/js/segment/SegmentLonLatEqui.js +0 -46
- package/lib/js/segment/Slice.d.ts +0 -13
- package/lib/js/segment/Slice.js +0 -33
- package/lib/js/segment/segmentHelper.js +0 -180
- package/lib/js/shaders/atmos.d.ts +0 -20
- package/lib/js/shaders/atmos.js +0 -326
- package/lib/js/shaders/billboard.d.ts +0 -3
- package/lib/js/shaders/billboard.js +0 -214
- package/lib/js/shaders/bloom.d.ts +0 -2
- package/lib/js/shaders/bloom.js +0 -32
- package/lib/js/shaders/blur.d.ts +0 -3
- package/lib/js/shaders/blur.js +0 -68
- package/lib/js/shaders/depth.d.ts +0 -2
- package/lib/js/shaders/depth.js +0 -40
- package/lib/js/shaders/drawnode.d.ts +0 -10
- package/lib/js/shaders/drawnode.js +0 -1008
- package/lib/js/shaders/geoObject.d.ts +0 -4
- package/lib/js/shaders/geoObject.js +0 -294
- package/lib/js/shaders/label.d.ts +0 -4
- package/lib/js/shaders/label.js +0 -589
- package/lib/js/shaders/lumFilter.d.ts +0 -2
- package/lib/js/shaders/lumFilter.js +0 -36
- package/lib/js/shaders/pointCloud.d.ts +0 -2
- package/lib/js/shaders/pointCloud.js +0 -32
- package/lib/js/shaders/polyline.d.ts +0 -3
- package/lib/js/shaders/polyline.js +0 -364
- package/lib/js/shaders/ray.d.ts +0 -2
- package/lib/js/shaders/ray.js +0 -80
- package/lib/js/shaders/screenFrame.d.ts +0 -2
- package/lib/js/shaders/screenFrame.js +0 -26
- package/lib/js/shaders/skybox.d.ts +0 -2
- package/lib/js/shaders/skybox.js +0 -28
- package/lib/js/shaders/toneMapping.d.ts +0 -2
- package/lib/js/shaders/toneMapping.js +0 -85
- package/lib/js/shaders/utils.d.ts +0 -1
- package/lib/js/shaders/utils.js +0 -97
- package/lib/js/terrain/BilTerrain.d.ts +0 -19
- package/lib/js/terrain/BilTerrain.js +0 -153
- package/lib/js/terrain/EmptyTerrain.d.ts +0 -113
- package/lib/js/terrain/EmptyTerrain.js +0 -113
- package/lib/js/terrain/Geoid.d.ts +0 -33
- package/lib/js/terrain/Geoid.js +0 -191
- package/lib/js/terrain/GlobusRgbTerrain.d.ts +0 -7
- package/lib/js/terrain/GlobusRgbTerrain.js +0 -25
- package/lib/js/terrain/GlobusTerrain.d.ts +0 -140
- package/lib/js/terrain/GlobusTerrain.js +0 -351
- package/lib/js/terrain/RgbTerrain.d.ts +0 -43
- package/lib/js/terrain/RgbTerrain.js +0 -428
- package/lib/js/terrain/index.d.ts +0 -6
- package/lib/js/terrain/index.js +0 -6
- package/lib/js/ui/Button.d.ts +0 -33
- package/lib/js/ui/Button.js +0 -78
- package/lib/js/ui/ButtonGroup.d.ts +0 -16
- package/lib/js/ui/ButtonGroup.js +0 -41
- package/lib/js/ui/Checkbox.d.ts +0 -32
- package/lib/js/ui/Checkbox.js +0 -110
- package/lib/js/ui/Color.d.ts +0 -23
- package/lib/js/ui/Color.js +0 -59
- package/lib/js/ui/Dialog.d.ts +0 -59
- package/lib/js/ui/Dialog.js +0 -193
- package/lib/js/ui/Input.d.ts +0 -33
- package/lib/js/ui/Input.js +0 -107
- package/lib/js/ui/Slider.d.ts +0 -39
- package/lib/js/ui/Slider.js +0 -129
- package/lib/js/ui/ToggleButton.d.ts +0 -21
- package/lib/js/ui/ToggleButton.js +0 -42
- package/lib/js/ui/View.d.ts +0 -39
- package/lib/js/ui/View.js +0 -157
- package/lib/js/ui/icons.d.ts +0 -1
- package/lib/js/ui/icons.js +0 -3
- package/lib/js/utils/BaseWorker.d.ts +0 -14
- package/lib/js/utils/BaseWorker.js +0 -47
- package/lib/js/utils/FontAtlas.d.ts +0 -82
- package/lib/js/utils/FontAtlas.js +0 -220
- package/lib/js/utils/GeoImageCreator.d.ts +0 -34
- package/lib/js/utils/GeoImageCreator.js +0 -163
- package/lib/js/utils/ImagesCacheManager.d.ts +0 -22
- package/lib/js/utils/ImagesCacheManager.js +0 -63
- package/lib/js/utils/Loader.d.ts +0 -63
- package/lib/js/utils/Loader.js +0 -156
- package/lib/js/utils/NormalMapCreator.d.ts +0 -53
- package/lib/js/utils/NormalMapCreator.js +0 -310
- package/lib/js/utils/PlainSegmentWorker.d.ts +0 -24
- package/lib/js/utils/PlainSegmentWorker.js +0 -385
- package/lib/js/utils/TerrainWorker.d.ts +0 -28
- package/lib/js/utils/TerrainWorker.js +0 -551
- package/lib/js/utils/TextureAtlas.d.ts +0 -115
- package/lib/js/utils/TextureAtlas.js +0 -231
- package/lib/js/utils/VectorTileCreator.d.ts +0 -18
- package/lib/js/utils/VectorTileCreator.js +0 -320
- package/lib/js/utils/colorTable.d.ts +0 -3
- package/lib/js/utils/colorTable.js +0 -143
- package/lib/js/utils/earcut.d.ts +0 -7
- package/lib/js/utils/earcut.js +0 -536
- package/lib/js/utils/objParser.d.ts +0 -56
- package/lib/js/utils/objParser.js +0 -293
- package/lib/js/utils/shared.js +0 -961
- package/lib/js/utils/units.d.ts +0 -16
- package/lib/js/utils/units.js +0 -61
- package/lib/js/webgl/BaseFramebuffer.d.ts +0 -52
- package/lib/js/webgl/BaseFramebuffer.js +0 -88
- package/lib/js/webgl/Framebuffer.js +0 -256
- package/lib/js/webgl/Handler.d.ts +0 -491
- package/lib/js/webgl/Handler.js +0 -1035
- package/lib/js/webgl/Multisample.d.ts +0 -28
- package/lib/js/webgl/Multisample.js +0 -77
- package/lib/js/webgl/Program.d.ts +0 -159
- package/lib/js/webgl/Program.js +0 -306
- package/lib/js/webgl/ProgramController.d.ts +0 -87
- package/lib/js/webgl/ProgramController.js +0 -110
- package/lib/js/webgl/index.d.ts +0 -6
- package/lib/js/webgl/index.js +0 -6
- package/lib/js/webgl/types.d.ts +0 -9
- package/lib/js/webgl/types.js +0 -26
- package/lib/js/webgl/variableHandlers.d.ts +0 -22
- package/lib/js/webgl/variableHandlers.js +0 -78
- /package/lib/{@openglobus/js/Clock.d.ts → Clock.d.ts} +0 -0
- /package/lib/{@openglobus/js/Deferred.d.ts → Deferred.d.ts} +0 -0
- /package/lib/{@openglobus/js/Events.d.ts → Events.d.ts} +0 -0
- /package/lib/{@openglobus/js/Extent.d.ts → Extent.d.ts} +0 -0
- /package/lib/{@openglobus/js/ImageCanvas.d.ts → ImageCanvas.d.ts} +0 -0
- /package/lib/{@openglobus/js/Lock.d.ts → Lock.d.ts} +0 -0
- /package/lib/{@openglobus/js/LonLat.d.ts → LonLat.d.ts} +0 -0
- /package/lib/{@openglobus/js/Popup.d.ts → Popup.d.ts} +0 -0
- /package/lib/{@openglobus/js/QueueArray.d.ts → QueueArray.d.ts} +0 -0
- /package/lib/{@openglobus/js/Rectangle.d.ts → Rectangle.d.ts} +0 -0
- /package/lib/{@openglobus/js/Stack.d.ts → Stack.d.ts} +0 -0
- /package/lib/{@openglobus/js/astro → astro}/astro.d.ts +0 -0
- /package/lib/{@openglobus/js/astro → astro}/earth.d.ts +0 -0
- /package/lib/{@openglobus/js/astro → astro}/jd.d.ts +0 -0
- /package/lib/{@openglobus/js/astro → astro}/orbit.d.ts +0 -0
- /package/lib/{@openglobus/js/astro → astro}/rotation.d.ts +0 -0
- /package/lib/{@openglobus/js/bv → bv}/Box.d.ts +0 -0
- /package/lib/{@openglobus/js/bv → bv}/Sphere.d.ts +0 -0
- /package/lib/{@openglobus/js/bv → bv}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/camera → camera}/PlanetCamera.d.ts +0 -0
- /package/lib/{@openglobus/js/camera → camera}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/cons.d.ts → cons.d.ts} +0 -0
- /package/lib/{@openglobus/js/control → control}/CameraLock.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/CompassButton.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/Control.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/DebugInfo.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/DrawingSwitcher.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/EarthCoordinates.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/GeoImageDragControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/LayerAnimation.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/LayerSwitcher.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/Lighting.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/MouseNavigation.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/OldMouseNavigation.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/RulerSwitcher.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ScaleControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/SegmentBoundVisualization.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ShowFps.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/SimpleNavigation.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/SimpleSkyBackground.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/Sun.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ToggleWireframe.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/TouchNavigation.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ZoomControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/drawing/DrawingControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/drawing/LineStringDrawingScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/drawing/PolygonDrawingScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfile.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfileButtonsView.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfileControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfileLegend.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfileScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/ElevationProfileView.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/elevationProfile/PointListDialog.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/ArrowEntity.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/AxisTrackEntity.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/GeoObjectEditor.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/GeoObjectEditorDialog.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/GeoObjectEditorScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/MoveAxisEntity.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/MovePlaneEntity.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/RotateEntity.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/geoObjectEditor/colors.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/heightRuler/HeightRuler.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/heightRuler/HeightRulerScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/heightRuler/HeightRulerSwitcher.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ruler/Ruler.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/ruler/RulerScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/selection/Selection.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/selection/SelectionScene.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/timeline/TimelineControl.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/timeline/TimelineModel.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/timeline/TimelineView.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/timeline/timelineUtils.d.ts +0 -0
- /package/lib/{js/control → control}/visibleExtent/VisibleExtent.d.ts +0 -0
- /package/lib/{@openglobus/js/control → control}/visibleExtent/drawnode.d.ts +0 -0
- /package/lib/{@openglobus/js/ellipsoid → ellipsoid}/Ellipsoid.d.ts +0 -0
- /package/lib/{@openglobus/js/ellipsoid → ellipsoid}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/ellipsoid → ellipsoid}/mars.d.ts +0 -0
- /package/lib/{@openglobus/js/ellipsoid → ellipsoid}/moon.d.ts +0 -0
- /package/lib/{@openglobus/js/ellipsoid → ellipsoid}/wgs84.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/BaseBillboard.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/BaseBillboardHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Billboard.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/BillboardHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Entity.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/EntityCollection.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/GeoObject.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/GeoObjectHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Geometry.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/GeometryHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/InstanceData.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Label.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/LabelHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/LabelWorker.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/PointCloud.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/PointCloudHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Polyline.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/PolylineHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Ray.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/RayHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/Strip.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/StripHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/entity → entity}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/input → input}/KeyboardHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/input → input}/MouseHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/input → input}/TouchHandler.d.ts +0 -0
- /package/lib/{@openglobus/js/input → input}/input.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/BaseGeoImage.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/Bing.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/CanvasTiles.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/GeoImage.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/GeoTexture2d.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/GeoVideo.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/KML.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/Layer.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/Material.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/OpenStreetMap.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/Vector.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/WMS.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/XYZ.d.ts +0 -0
- /package/lib/{@openglobus/js/layer → layer}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/light → light}/LightSource.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Line2.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Line3.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Mat3.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Mat4.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Plane.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Quat.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Ray.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Vec2.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Vec3.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/Vec4.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/coder.d.ts +0 -0
- /package/lib/{@openglobus/js/math → math}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/math.d.ts → math.d.ts} +0 -0
- /package/lib/{@openglobus/js/mercator.d.ts → mercator.d.ts} +0 -0
- /package/lib/{@openglobus/js/proj → proj}/EPSG3857.d.ts +0 -0
- /package/lib/{@openglobus/js/proj → proj}/EPSG4326.d.ts +0 -0
- /package/lib/{@openglobus/js/proj → proj}/Proj.d.ts +0 -0
- /package/lib/{@openglobus/js/proj → proj}/equi.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/EPSG4326/EPSG4326QuadTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/EntityCollectionNode.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/EntityCollectionsTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/Node.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/QuadTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/earth/EarthEntityCollectionNodeLonLat.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/earth/EarthEntityCollectionsTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/earth/EarthQuadTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/equi/EquiEntityCollectionNodeLonLat.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/equi/EquiEntityCollectionsTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/equi/EquiQuadTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/quadTree.d.ts +0 -0
- /package/lib/{@openglobus/js/quadTree → quadTree}/wgs84/Wgs84QuadTreeStrategy.d.ts +0 -0
- /package/lib/{@openglobus/js/renderer → renderer}/RendererEvents.d.ts +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Ephesis-Regular.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Ephesis-Regular.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Ephesis-Regular.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Bold.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Bold.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Bold.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Light.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Light.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Light.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Medium.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Medium.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Karla-Medium.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/NotoSansArabic-Regular.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/NotoSansArabic-Regular.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/NotoSansArabic-Regular.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Roboto-Regular.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Roboto-Regular.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/Roboto-Regular.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/fonts/arial.js +0 -0
- /package/lib/{@openglobus/res → res}/fonts/arial.json +0 -0
- /package/lib/{@openglobus/res → res}/fonts/arial.ttf.cfg +0 -0
- /package/lib/{@openglobus/res → res}/fonts/arial.ttf.png +0 -0
- /package/lib/{@openglobus/res → res}/night-4326.png +0 -0
- /package/lib/{@openglobus/res → res}/night.png +0 -0
- /package/lib/{@openglobus/res → res}/spec.png +0 -0
- /package/lib/{@openglobus/js/scene → scene}/Axes.d.ts +0 -0
- /package/lib/{@openglobus/js/scene → scene}/BaseNode.d.ts +0 -0
- /package/lib/{@openglobus/js/scene → scene}/RenderNode.d.ts +0 -0
- /package/lib/{@openglobus/js/scene → scene}/SkyBox.d.ts +0 -0
- /package/lib/{@openglobus/js/scene → scene}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/segment → segment}/SegmentLonLat.d.ts +0 -0
- /package/lib/{@openglobus/js/segment → segment}/SegmentLonLatEqui.d.ts +0 -0
- /package/lib/{@openglobus/js/segment → segment}/Slice.d.ts +0 -0
- /package/lib/{@openglobus/js/shaders → shaders}/depth.d.ts +0 -0
- /package/lib/{@openglobus/js/shaders → shaders}/pointCloud.d.ts +0 -0
- /package/lib/{@openglobus/js/shaders → shaders}/screenFrame.d.ts +0 -0
- /package/lib/{@openglobus/js/shaders → shaders}/skybox.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/BilTerrain.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/EmptyTerrain.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/Geoid.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/GlobusRgbTerrain.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/GlobusTerrain.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/RgbTerrain.d.ts +0 -0
- /package/lib/{@openglobus/js/terrain → terrain}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/Button.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/ButtonGroup.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/Checkbox.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/Color.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/Input.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/Slider.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/ToggleButton.d.ts +0 -0
- /package/lib/{@openglobus/js/ui → ui}/icons.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/FontAtlas.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/GeoImageCreator.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/ImagesCacheManager.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/Loader.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/NormalMapCreator.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/PlainSegmentWorker.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/TerrainWorker.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/TextureAtlas.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/VectorTileCreator.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/colorTable.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/earcut.d.ts +0 -0
- /package/lib/{@openglobus/js/utils → utils}/units.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/BaseFramebuffer.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/Multisample.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/Program.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/ProgramController.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/index.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/types.d.ts +0 -0
- /package/lib/{@openglobus/js/webgl → webgl}/variableHandlers.d.ts +0 -0
package/lib/js/math/Mat4.js
DELETED
|
@@ -1,487 +0,0 @@
|
|
|
1
|
-
import { Mat3 } from "./Mat3";
|
|
2
|
-
import { Quat } from "./Quat";
|
|
3
|
-
import { Vec3 } from "./Vec3";
|
|
4
|
-
import { Vec4 } from "./Vec4";
|
|
5
|
-
/**
|
|
6
|
-
* Class represents a 4x4 matrix.
|
|
7
|
-
* @class
|
|
8
|
-
*/
|
|
9
|
-
export class Mat4 {
|
|
10
|
-
constructor() {
|
|
11
|
-
/**
|
|
12
|
-
* A 4x4 matrix, index-able as a column-major order array.
|
|
13
|
-
* @public
|
|
14
|
-
* @type {Array.<number>}
|
|
15
|
-
*/
|
|
16
|
-
this._m = [
|
|
17
|
-
0, 0, 0, 0,
|
|
18
|
-
0, 0, 0, 0,
|
|
19
|
-
0, 0, 0, 0,
|
|
20
|
-
0, 0, 0, 0
|
|
21
|
-
];
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Returns identity matrix instance.
|
|
25
|
-
* @static
|
|
26
|
-
* @returns {Mat4} -
|
|
27
|
-
*/
|
|
28
|
-
static identity() {
|
|
29
|
-
let res = new Mat4();
|
|
30
|
-
res._m[0] = 1;
|
|
31
|
-
res._m[1] = 0;
|
|
32
|
-
res._m[2] = 0;
|
|
33
|
-
res._m[3] = 0;
|
|
34
|
-
res._m[4] = 0;
|
|
35
|
-
res._m[5] = 1;
|
|
36
|
-
res._m[6] = 0;
|
|
37
|
-
res._m[7] = 0;
|
|
38
|
-
res._m[8] = 0;
|
|
39
|
-
res._m[9] = 0;
|
|
40
|
-
res._m[10] = 1;
|
|
41
|
-
res._m[11] = 0;
|
|
42
|
-
res._m[12] = 0;
|
|
43
|
-
res._m[13] = 0;
|
|
44
|
-
res._m[14] = 0;
|
|
45
|
-
res._m[15] = 1;
|
|
46
|
-
return res;
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* Get rotation matrix around the point
|
|
50
|
-
* @public
|
|
51
|
-
* @param {number} angle - Rotation angle in radians
|
|
52
|
-
* @param {Vec3} [center] - Point that the camera rotates around
|
|
53
|
-
* @param {Vec3} [up] - Camera up vector
|
|
54
|
-
*/
|
|
55
|
-
static getRotationAroundPoint(angle, center = Vec3.ZERO, up = Vec3.UP) {
|
|
56
|
-
let rot = Mat4.getRotation(angle, up);
|
|
57
|
-
let tr = new Mat4().setIdentity().translate(center);
|
|
58
|
-
let ntr = new Mat4().setIdentity().translate(center.negateTo());
|
|
59
|
-
return tr.mul(rot).mul(ntr);
|
|
60
|
-
}
|
|
61
|
-
static getRotation(angle, up = Vec3.UP) {
|
|
62
|
-
return new Mat4().setRotation(up, angle);
|
|
63
|
-
}
|
|
64
|
-
/**
|
|
65
|
-
* Sets column-major order array matrix.
|
|
66
|
-
* @public
|
|
67
|
-
* @param {Array.<number>} m - Matrix array.
|
|
68
|
-
* @returns {Mat4} -
|
|
69
|
-
*/
|
|
70
|
-
set(m) {
|
|
71
|
-
this._m[0] = m[0];
|
|
72
|
-
this._m[1] = m[1];
|
|
73
|
-
this._m[2] = m[2];
|
|
74
|
-
this._m[3] = m[3];
|
|
75
|
-
this._m[4] = m[4];
|
|
76
|
-
this._m[5] = m[5];
|
|
77
|
-
this._m[6] = m[6];
|
|
78
|
-
this._m[7] = m[7];
|
|
79
|
-
this._m[8] = m[8];
|
|
80
|
-
this._m[9] = m[9];
|
|
81
|
-
this._m[10] = m[10];
|
|
82
|
-
this._m[11] = m[11];
|
|
83
|
-
this._m[12] = m[12];
|
|
84
|
-
this._m[13] = m[13];
|
|
85
|
-
this._m[14] = m[14];
|
|
86
|
-
this._m[15] = m[15];
|
|
87
|
-
return this;
|
|
88
|
-
}
|
|
89
|
-
/**
|
|
90
|
-
* Duplicates a Matrix3 instance.
|
|
91
|
-
* @public
|
|
92
|
-
* @returns {Mat4} -
|
|
93
|
-
*/
|
|
94
|
-
clone() {
|
|
95
|
-
let res = new Mat4();
|
|
96
|
-
res.set(this._m);
|
|
97
|
-
return res;
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* Copy matrix.
|
|
101
|
-
* @public
|
|
102
|
-
* @param {Mat4} a - Matrix to copy.
|
|
103
|
-
* @return {Mat4}
|
|
104
|
-
*/
|
|
105
|
-
copy(a) {
|
|
106
|
-
return this.set(a._m);
|
|
107
|
-
}
|
|
108
|
-
/**
|
|
109
|
-
* Converts to 3x3 matrix.
|
|
110
|
-
* @public
|
|
111
|
-
* @returns {Mat3} -
|
|
112
|
-
*/
|
|
113
|
-
getMat3() {
|
|
114
|
-
let res = new Mat3();
|
|
115
|
-
let a = this._m, b = res._m;
|
|
116
|
-
b[0] = a[0];
|
|
117
|
-
b[1] = a[1];
|
|
118
|
-
b[2] = a[2];
|
|
119
|
-
b[3] = a[4];
|
|
120
|
-
b[4] = a[5];
|
|
121
|
-
b[5] = a[6];
|
|
122
|
-
b[6] = a[8];
|
|
123
|
-
b[7] = a[9];
|
|
124
|
-
b[8] = a[10];
|
|
125
|
-
return res;
|
|
126
|
-
}
|
|
127
|
-
/**
|
|
128
|
-
* Multiply to 3d vector.
|
|
129
|
-
* @public
|
|
130
|
-
* @param {Vec3} p - 3d vector.
|
|
131
|
-
* @returns {Vec3} -
|
|
132
|
-
*/
|
|
133
|
-
mulVec3(p) {
|
|
134
|
-
let d = p.x, e = p.y, g = p.z;
|
|
135
|
-
return new Vec3(this._m[0] * d + this._m[4] * e + this._m[8] * g + this._m[12], this._m[1] * d + this._m[5] * e + this._m[9] * g + this._m[13], this._m[2] * d + this._m[6] * e + this._m[10] * g + this._m[14]);
|
|
136
|
-
}
|
|
137
|
-
/**
|
|
138
|
-
* Multiply to 4d vector.
|
|
139
|
-
* @public
|
|
140
|
-
* @param {Vec4} p - 4d vector.
|
|
141
|
-
* @returns {Vec4} -
|
|
142
|
-
*/
|
|
143
|
-
mulVec4(p) {
|
|
144
|
-
let d = p.x, e = p.y, g = p.z, f = p.w;
|
|
145
|
-
return new Vec4(this._m[0] * d + this._m[4] * e + this._m[8] * g + this._m[12] * f, this._m[1] * d + this._m[5] * e + this._m[9] * g + this._m[13] * f, this._m[2] * d + this._m[6] * e + this._m[10] * g + this._m[14] * f, this._m[3] * d + this._m[7] * e + this._m[11] * g + this._m[15] * f);
|
|
146
|
-
}
|
|
147
|
-
/**
|
|
148
|
-
* Creates an inverse 3x3 matrix of the current.
|
|
149
|
-
* @public
|
|
150
|
-
* @returns {Mat3} -
|
|
151
|
-
*/
|
|
152
|
-
toInverseMatrix3() {
|
|
153
|
-
let a = this._m;
|
|
154
|
-
let c = a[0], d = a[1], e = a[2], g = a[4], f = a[5], h = a[6], i = a[8], j = a[9], k = a[10], l = k * f - h * j, o = -k * g + h * i, m = j * g - f * i, n = c * l + d * o + e * m;
|
|
155
|
-
if (!n) {
|
|
156
|
-
return;
|
|
157
|
-
}
|
|
158
|
-
n = 1.0 / n;
|
|
159
|
-
let res = new Mat3();
|
|
160
|
-
res._m[0] = l * n;
|
|
161
|
-
res._m[1] = (-k * d + e * j) * n;
|
|
162
|
-
res._m[2] = (h * d - e * f) * n;
|
|
163
|
-
res._m[3] = o * n;
|
|
164
|
-
res._m[4] = (k * c - e * i) * n;
|
|
165
|
-
res._m[5] = (-h * c + e * g) * n;
|
|
166
|
-
res._m[6] = m * n;
|
|
167
|
-
res._m[7] = (-j * c + d * i) * n;
|
|
168
|
-
res._m[8] = (f * c - d * g) * n;
|
|
169
|
-
return res;
|
|
170
|
-
}
|
|
171
|
-
/**
|
|
172
|
-
* Creates an inverse matrix of the current.
|
|
173
|
-
* @public
|
|
174
|
-
* @returns {Mat4} -
|
|
175
|
-
*/
|
|
176
|
-
inverseTo(res = new Mat4()) {
|
|
177
|
-
let c = this._m[0], d = this._m[1], e = this._m[2], g = this._m[3], f = this._m[4], h = this._m[5], i = this._m[6], j = this._m[7], k = this._m[8], l = this._m[9], o = this._m[10], m = this._m[11], n = this._m[12], p = this._m[13], r = this._m[14], s = this._m[15], A = c * h - d * f, B = c * i - e * f, t = c * j - g * f, u = d * i - e * h, v = d * j - g * h, w = e * j - g * i, x = k * p - l * n, y = k * r - o * n, z = k * s - m * n, C = l * r - o * p, D = l * s - m * p, E = o * s - m * r, q = 1 / (A * E - B * D + t * C + u * z - v * y + w * x);
|
|
178
|
-
res._m[0] = (h * E - i * D + j * C) * q;
|
|
179
|
-
res._m[1] = (-d * E + e * D - g * C) * q;
|
|
180
|
-
res._m[2] = (p * w - r * v + s * u) * q;
|
|
181
|
-
res._m[3] = (-l * w + o * v - m * u) * q;
|
|
182
|
-
res._m[4] = (-f * E + i * z - j * y) * q;
|
|
183
|
-
res._m[5] = (c * E - e * z + g * y) * q;
|
|
184
|
-
res._m[6] = (-n * w + r * t - s * B) * q;
|
|
185
|
-
res._m[7] = (k * w - o * t + m * B) * q;
|
|
186
|
-
res._m[8] = (f * D - h * z + j * x) * q;
|
|
187
|
-
res._m[9] = (-c * D + d * z - g * x) * q;
|
|
188
|
-
res._m[10] = (n * v - p * t + s * A) * q;
|
|
189
|
-
res._m[11] = (-k * v + l * t - m * A) * q;
|
|
190
|
-
res._m[12] = (-f * C + h * y - i * x) * q;
|
|
191
|
-
res._m[13] = (c * C - d * y + e * x) * q;
|
|
192
|
-
res._m[14] = (-n * u + p * B - r * A) * q;
|
|
193
|
-
res._m[15] = (k * u - l * B + o * A) * q;
|
|
194
|
-
return res;
|
|
195
|
-
}
|
|
196
|
-
/**
|
|
197
|
-
* Creates a transposed matrix of the current.
|
|
198
|
-
* @public
|
|
199
|
-
* @returns {Mat4} -
|
|
200
|
-
*/
|
|
201
|
-
transposeTo() {
|
|
202
|
-
let res = new Mat4();
|
|
203
|
-
res._m[0] = this._m[0];
|
|
204
|
-
res._m[1] = this._m[4];
|
|
205
|
-
res._m[2] = this._m[8];
|
|
206
|
-
res._m[3] = this._m[12];
|
|
207
|
-
res._m[4] = this._m[1];
|
|
208
|
-
res._m[5] = this._m[5];
|
|
209
|
-
res._m[6] = this._m[9];
|
|
210
|
-
res._m[7] = this._m[13];
|
|
211
|
-
res._m[8] = this._m[2];
|
|
212
|
-
res._m[9] = this._m[6];
|
|
213
|
-
res._m[10] = this._m[10];
|
|
214
|
-
res._m[11] = this._m[14];
|
|
215
|
-
res._m[12] = this._m[3];
|
|
216
|
-
res._m[13] = this._m[7];
|
|
217
|
-
res._m[14] = this._m[11];
|
|
218
|
-
res._m[15] = this._m[15];
|
|
219
|
-
return res;
|
|
220
|
-
}
|
|
221
|
-
/**
|
|
222
|
-
* Sets matrix to identity.
|
|
223
|
-
* @public
|
|
224
|
-
* @returns {Mat4} -
|
|
225
|
-
*/
|
|
226
|
-
setIdentity() {
|
|
227
|
-
this._m[0] = 1;
|
|
228
|
-
this._m[1] = 0;
|
|
229
|
-
this._m[2] = 0;
|
|
230
|
-
this._m[3] = 0;
|
|
231
|
-
this._m[4] = 0;
|
|
232
|
-
this._m[5] = 1;
|
|
233
|
-
this._m[6] = 0;
|
|
234
|
-
this._m[7] = 0;
|
|
235
|
-
this._m[8] = 0;
|
|
236
|
-
this._m[9] = 0;
|
|
237
|
-
this._m[10] = 1;
|
|
238
|
-
this._m[11] = 0;
|
|
239
|
-
this._m[12] = 0;
|
|
240
|
-
this._m[13] = 0;
|
|
241
|
-
this._m[14] = 0;
|
|
242
|
-
this._m[15] = 1;
|
|
243
|
-
return this;
|
|
244
|
-
}
|
|
245
|
-
/**
|
|
246
|
-
* Computes the product of two matrices.
|
|
247
|
-
* @public
|
|
248
|
-
* @param {Mat4} mx - Matrix to multiply.
|
|
249
|
-
* @returns {Mat4} -
|
|
250
|
-
*/
|
|
251
|
-
mul(mx) {
|
|
252
|
-
let d = this._m[0], e = this._m[1], g = this._m[2], f = this._m[3], h = this._m[4], i = this._m[5], j = this._m[6], k = this._m[7], l = this._m[8], o = this._m[9], m = this._m[10], n = this._m[11], p = this._m[12], r = this._m[13], s = this._m[14], a = this._m[15];
|
|
253
|
-
let A = mx._m[0], B = mx._m[1], t = mx._m[2], u = mx._m[3], v = mx._m[4], w = mx._m[5], x = mx._m[6], y = mx._m[7], z = mx._m[8], C = mx._m[9], D = mx._m[10], E = mx._m[11], q = mx._m[12], F = mx._m[13], G = mx._m[14], b = mx._m[15];
|
|
254
|
-
let res = new Mat4();
|
|
255
|
-
res._m[0] = A * d + B * h + t * l + u * p;
|
|
256
|
-
res._m[1] = A * e + B * i + t * o + u * r;
|
|
257
|
-
res._m[2] = A * g + B * j + t * m + u * s;
|
|
258
|
-
res._m[3] = A * f + B * k + t * n + u * a;
|
|
259
|
-
res._m[4] = v * d + w * h + x * l + y * p;
|
|
260
|
-
res._m[5] = v * e + w * i + x * o + y * r;
|
|
261
|
-
res._m[6] = v * g + w * j + x * m + y * s;
|
|
262
|
-
res._m[7] = v * f + w * k + x * n + y * a;
|
|
263
|
-
res._m[8] = z * d + C * h + D * l + E * p;
|
|
264
|
-
res._m[9] = z * e + C * i + D * o + E * r;
|
|
265
|
-
res._m[10] = z * g + C * j + D * m + E * s;
|
|
266
|
-
res._m[11] = z * f + C * k + D * n + E * a;
|
|
267
|
-
res._m[12] = q * d + F * h + G * l + b * p;
|
|
268
|
-
res._m[13] = q * e + F * i + G * o + b * r;
|
|
269
|
-
res._m[14] = q * g + F * j + G * m + b * s;
|
|
270
|
-
res._m[15] = q * f + F * k + G * n + b * a;
|
|
271
|
-
return res;
|
|
272
|
-
}
|
|
273
|
-
/**
|
|
274
|
-
* Add translation vector to the current matrix.
|
|
275
|
-
* @public
|
|
276
|
-
* @param {Vec3} v - Translate vector.
|
|
277
|
-
* @returns {Mat4} -
|
|
278
|
-
*/
|
|
279
|
-
translate(v) {
|
|
280
|
-
let d = v.x, e = v.y, b = v.z;
|
|
281
|
-
let a = this._m;
|
|
282
|
-
a[12] = a[0] * d + a[4] * e + a[8] * b + a[12];
|
|
283
|
-
a[13] = a[1] * d + a[5] * e + a[9] * b + a[13];
|
|
284
|
-
a[14] = a[2] * d + a[6] * e + a[10] * b + a[14];
|
|
285
|
-
a[15] = a[3] * d + a[7] * e + a[11] * b + a[15];
|
|
286
|
-
return this;
|
|
287
|
-
}
|
|
288
|
-
/**
|
|
289
|
-
* Sets translation matrix to the position.
|
|
290
|
-
* @public
|
|
291
|
-
* @param {Vec3} v - Translate to position.
|
|
292
|
-
* @returns {Mat4} -
|
|
293
|
-
*/
|
|
294
|
-
translateToPosition(v) {
|
|
295
|
-
let a = this._m;
|
|
296
|
-
a[12] = v.x;
|
|
297
|
-
a[13] = v.y;
|
|
298
|
-
a[14] = v.z;
|
|
299
|
-
return this;
|
|
300
|
-
}
|
|
301
|
-
/**
|
|
302
|
-
* Rotate current matrix around the aligned axis and angle.
|
|
303
|
-
* @public
|
|
304
|
-
* @param {Vec3} u - Aligned axis.
|
|
305
|
-
* @param {number} angle - Aligned axis angle in radians.
|
|
306
|
-
* @returns {Mat4} -
|
|
307
|
-
*/
|
|
308
|
-
rotate(u, angle) {
|
|
309
|
-
let c = Math.cos(angle), s = Math.sin(angle);
|
|
310
|
-
let rot = new Mat4();
|
|
311
|
-
let mx = rot._m;
|
|
312
|
-
mx[0] = c + (1 - c) * u.x * u.x;
|
|
313
|
-
mx[1] = (1 - c) * u.y * u.x - s * u.z;
|
|
314
|
-
mx[2] = (1 - c) * u.z * u.x + s * u.y;
|
|
315
|
-
mx[3] = 0;
|
|
316
|
-
mx[4] = (1 - c) * u.x * u.y + s * u.z;
|
|
317
|
-
mx[5] = c + (1 - c) * u.y * u.y;
|
|
318
|
-
mx[6] = (1 - c) * u.z * u.y - s * u.x;
|
|
319
|
-
mx[7] = 0;
|
|
320
|
-
mx[8] = (1 - c) * u.x * u.z - s * u.y;
|
|
321
|
-
mx[9] = (1 - c) * u.y * u.z + s * u.x;
|
|
322
|
-
mx[10] = c + (1 - c) * u.z * u.z;
|
|
323
|
-
mx[11] = 0;
|
|
324
|
-
mx[12] = 0;
|
|
325
|
-
mx[13] = 0;
|
|
326
|
-
mx[14] = 0;
|
|
327
|
-
mx[15] = 1;
|
|
328
|
-
return this.mul(rot);
|
|
329
|
-
}
|
|
330
|
-
/**
|
|
331
|
-
* Sets current rotation matrix around the aligned axis and angle.
|
|
332
|
-
* @public
|
|
333
|
-
* @param {Vec3} u - Aligned axis.
|
|
334
|
-
* @param {number} angle - Aligned axis angle in radians.
|
|
335
|
-
* @returns {Mat4} -
|
|
336
|
-
*/
|
|
337
|
-
setRotation(u, angle) {
|
|
338
|
-
let c = Math.cos(angle), s = Math.sin(angle);
|
|
339
|
-
let mx = this._m;
|
|
340
|
-
mx[0] = c + (1 - c) * u.x * u.x;
|
|
341
|
-
mx[1] = (1 - c) * u.y * u.x - s * u.z;
|
|
342
|
-
mx[2] = (1 - c) * u.z * u.x + s * u.y;
|
|
343
|
-
mx[3] = 0;
|
|
344
|
-
mx[4] = (1 - c) * u.x * u.y + s * u.z;
|
|
345
|
-
mx[5] = c + (1 - c) * u.y * u.y;
|
|
346
|
-
mx[6] = (1 - c) * u.z * u.y - s * u.x;
|
|
347
|
-
mx[7] = 0;
|
|
348
|
-
mx[8] = (1 - c) * u.x * u.z - s * u.y;
|
|
349
|
-
mx[9] = (1 - c) * u.y * u.z + s * u.x;
|
|
350
|
-
mx[10] = c + (1 - c) * u.z * u.z;
|
|
351
|
-
mx[11] = 0;
|
|
352
|
-
mx[12] = 0;
|
|
353
|
-
mx[13] = 0;
|
|
354
|
-
mx[14] = 0;
|
|
355
|
-
mx[15] = 1;
|
|
356
|
-
return this;
|
|
357
|
-
}
|
|
358
|
-
/**
|
|
359
|
-
* Gets the rotation matrix from one vector to another.
|
|
360
|
-
* @public
|
|
361
|
-
* @param {Vec3} a - First vector.
|
|
362
|
-
* @param {Vec3} b - Second vector.
|
|
363
|
-
* @returns {Mat4} -
|
|
364
|
-
*/
|
|
365
|
-
rotateBetweenVectors(a, b) {
|
|
366
|
-
let q = Quat.getRotationBetweenVectors(a, b);
|
|
367
|
-
return q.getMat4();
|
|
368
|
-
}
|
|
369
|
-
/**
|
|
370
|
-
* Scale current matrix to the vector values.
|
|
371
|
-
* @public
|
|
372
|
-
* @param {Vec3} v - Scale vector.
|
|
373
|
-
* @returns {Mat4} -
|
|
374
|
-
*/
|
|
375
|
-
scale(v) {
|
|
376
|
-
let mx = this._m;
|
|
377
|
-
mx[0] = mx[0] * v.x;
|
|
378
|
-
mx[1] = mx[1] * v.x;
|
|
379
|
-
mx[2] = mx[2] * v.x;
|
|
380
|
-
mx[3] = mx[3] * v.x;
|
|
381
|
-
mx[4] = mx[4] * v.y;
|
|
382
|
-
mx[5] = mx[5] * v.y;
|
|
383
|
-
mx[6] = mx[6] * v.y;
|
|
384
|
-
mx[7] = mx[7] * v.y;
|
|
385
|
-
mx[8] = mx[8] * v.z;
|
|
386
|
-
mx[9] = mx[9] * v.z;
|
|
387
|
-
mx[10] = mx[10] * v.z;
|
|
388
|
-
mx[11] = mx[11] * v.z;
|
|
389
|
-
return this;
|
|
390
|
-
}
|
|
391
|
-
/**
|
|
392
|
-
* Sets perspective projection matrix frustum values.
|
|
393
|
-
* @public
|
|
394
|
-
* @param {number} left -
|
|
395
|
-
* @param {number} right -
|
|
396
|
-
* @param {number} bottom -
|
|
397
|
-
* @param {number} top -
|
|
398
|
-
* @param {number} near -
|
|
399
|
-
* @param {number} far -
|
|
400
|
-
* @returns {Mat4} -
|
|
401
|
-
*/
|
|
402
|
-
setPerspective(left, right, bottom, top, near, far) {
|
|
403
|
-
let h = right - left, i = top - bottom, j = near - far, n2 = 2 * near;
|
|
404
|
-
let mm = this._m;
|
|
405
|
-
mm[0] = n2 / h;
|
|
406
|
-
mm[1] = 0;
|
|
407
|
-
mm[2] = 0;
|
|
408
|
-
mm[3] = 0;
|
|
409
|
-
mm[4] = 0;
|
|
410
|
-
mm[5] = n2 / i;
|
|
411
|
-
mm[6] = 0;
|
|
412
|
-
mm[7] = 0;
|
|
413
|
-
mm[8] = (right + left) / h;
|
|
414
|
-
mm[9] = (top + bottom) / i;
|
|
415
|
-
mm[10] = (far + near) / j;
|
|
416
|
-
mm[11] = -1;
|
|
417
|
-
mm[12] = 0;
|
|
418
|
-
mm[13] = 0;
|
|
419
|
-
mm[14] = (n2 * far) / j;
|
|
420
|
-
mm[15] = 0;
|
|
421
|
-
return this;
|
|
422
|
-
}
|
|
423
|
-
/**
|
|
424
|
-
* Creates current orthographic projection matrix.
|
|
425
|
-
* @public
|
|
426
|
-
* @param {number} left -
|
|
427
|
-
* @param {number} right -
|
|
428
|
-
* @param {number} bottom -
|
|
429
|
-
* @param {number} top -
|
|
430
|
-
* @param {number} near -
|
|
431
|
-
* @param {number} far -
|
|
432
|
-
* @return {Mat4} -
|
|
433
|
-
*/
|
|
434
|
-
setOrtho(left, right, bottom, top, near, far) {
|
|
435
|
-
let lr = 1.0 / (left - right), bt = 1.0 / (bottom - top), nf = 1.0 / (near - far), m = this._m;
|
|
436
|
-
m[0] = -2.0 * lr;
|
|
437
|
-
m[1] = 0;
|
|
438
|
-
m[2] = 0;
|
|
439
|
-
m[3] = 0;
|
|
440
|
-
m[4] = 0;
|
|
441
|
-
m[5] = -2.0 * bt;
|
|
442
|
-
m[6] = 0;
|
|
443
|
-
m[7] = 0;
|
|
444
|
-
m[8] = 0;
|
|
445
|
-
m[9] = 0;
|
|
446
|
-
m[10] = 2.0 * nf;
|
|
447
|
-
m[11] = 0;
|
|
448
|
-
m[12] = (left + right) * lr;
|
|
449
|
-
m[13] = (top + bottom) * bt;
|
|
450
|
-
m[14] = (far + near) * nf;
|
|
451
|
-
m[15] = 1.0;
|
|
452
|
-
return this;
|
|
453
|
-
}
|
|
454
|
-
/**
|
|
455
|
-
* Sets current rotation matrix by euler's angles.
|
|
456
|
-
* @public
|
|
457
|
-
* @param {number} ax - Rotation angle in radians around X axis.
|
|
458
|
-
* @param {number} ay - Rotation angle in radians around Y axis.
|
|
459
|
-
* @param {number} az - Rotation angle in radians around Z axis.
|
|
460
|
-
* @returns {Mat4} -
|
|
461
|
-
*/
|
|
462
|
-
eulerToMatrix(ax, ay, az) {
|
|
463
|
-
let a = Math.cos(ax), b = Math.sin(ax), c = Math.cos(ay), d = Math.sin(ay), e = Math.cos(az), f = Math.sin(az);
|
|
464
|
-
let ad = a * d, bd = b * d;
|
|
465
|
-
let mat = this._m;
|
|
466
|
-
mat[0] = c * e;
|
|
467
|
-
mat[1] = -c * f;
|
|
468
|
-
mat[2] = -d;
|
|
469
|
-
mat[4] = -bd * e + a * f;
|
|
470
|
-
mat[5] = bd * f + a * e;
|
|
471
|
-
mat[6] = -b * c;
|
|
472
|
-
mat[8] = ad * e + b * f;
|
|
473
|
-
mat[9] = -ad * f + b * e;
|
|
474
|
-
mat[10] = a * c;
|
|
475
|
-
mat[3] = mat[7] = mat[11] = mat[12] = mat[13] = mat[14] = 0;
|
|
476
|
-
mat[15] = 1;
|
|
477
|
-
return this;
|
|
478
|
-
}
|
|
479
|
-
}
|
|
480
|
-
/**
|
|
481
|
-
* Mat4 factory.
|
|
482
|
-
* @static
|
|
483
|
-
* @returns {Mat4} -
|
|
484
|
-
*/
|
|
485
|
-
export function mat4() {
|
|
486
|
-
return new Mat4();
|
|
487
|
-
}
|
package/lib/js/math/Plane.d.ts
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Vec3 } from "./Vec3";
|
|
2
|
-
import { Line3 } from "./Line3";
|
|
3
|
-
/**
|
|
4
|
-
* Plane class.
|
|
5
|
-
* @constructor
|
|
6
|
-
* @param {Vec3} [p] - Plane point.
|
|
7
|
-
* @param {Vec3} [n] - Planet normal.
|
|
8
|
-
*/
|
|
9
|
-
declare class Plane {
|
|
10
|
-
p: Vec3;
|
|
11
|
-
n: Vec3;
|
|
12
|
-
constructor(p?: Vec3, n?: Vec3);
|
|
13
|
-
setByPoints(v0: Vec3, v1: Vec3, v2: Vec3): Plane;
|
|
14
|
-
static fromPoints(v0: Vec3, v1: Vec3, v2: Vec3): Plane;
|
|
15
|
-
set(p: Vec3, n: Vec3): void;
|
|
16
|
-
getNormal(): Vec3;
|
|
17
|
-
distance(p: Vec3): number;
|
|
18
|
-
getProjection(v: Vec3, def?: Vec3): Vec3;
|
|
19
|
-
getProjectionPoint(p: Vec3, vh?: Vec3): Vec3;
|
|
20
|
-
getIntersection(Pn1: Plane, Pn2: Plane, L: Line3): number;
|
|
21
|
-
}
|
|
22
|
-
export { Plane };
|
package/lib/js/math/Plane.js
DELETED
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import { EPS5 } from "../math";
|
|
2
|
-
import { Vec3 } from "./Vec3";
|
|
3
|
-
const DISJOINT = 0;
|
|
4
|
-
const COINCIDE = 1;
|
|
5
|
-
const INTERSECT = 2;
|
|
6
|
-
/**
|
|
7
|
-
* Plane class.
|
|
8
|
-
* @constructor
|
|
9
|
-
* @param {Vec3} [p] - Plane point.
|
|
10
|
-
* @param {Vec3} [n] - Planet normal.
|
|
11
|
-
*/
|
|
12
|
-
class Plane {
|
|
13
|
-
constructor(p, n) {
|
|
14
|
-
this.p = p ? p.clone() : new Vec3();
|
|
15
|
-
this.n = n ? n.clone() : (this.p.isZero() ? Vec3.UP : this.p.getNormal());
|
|
16
|
-
}
|
|
17
|
-
setByPoints(v0, v1, v2) {
|
|
18
|
-
let u = Vec3.sub(v1, v0);
|
|
19
|
-
let v = Vec3.sub(v2, v0);
|
|
20
|
-
this.n = u.cross(v);
|
|
21
|
-
this.p.copy(v0);
|
|
22
|
-
return this;
|
|
23
|
-
}
|
|
24
|
-
static fromPoints(v0, v1, v2) {
|
|
25
|
-
return new Plane().setByPoints(v0, v1, v2);
|
|
26
|
-
}
|
|
27
|
-
set(p, n) {
|
|
28
|
-
this.p.copy(p);
|
|
29
|
-
this.n.copy(n);
|
|
30
|
-
}
|
|
31
|
-
getNormal() {
|
|
32
|
-
return this.n.clone();
|
|
33
|
-
}
|
|
34
|
-
distance(p) {
|
|
35
|
-
let pp = this.getProjection(p);
|
|
36
|
-
return p.distance(pp);
|
|
37
|
-
}
|
|
38
|
-
getProjection(v, def) {
|
|
39
|
-
return Vec3.proj_b_to_plane(v, this.n, def);
|
|
40
|
-
}
|
|
41
|
-
getProjectionPoint(p, vh) {
|
|
42
|
-
let v = p.sub(this.p), n = this.n, dist = v.dot(n);
|
|
43
|
-
if (vh) {
|
|
44
|
-
vh.copy(n.scale(dist));
|
|
45
|
-
}
|
|
46
|
-
else {
|
|
47
|
-
vh = n.scale(dist);
|
|
48
|
-
}
|
|
49
|
-
return p.sub(vh);
|
|
50
|
-
}
|
|
51
|
-
getIntersection(Pn1, Pn2, L) {
|
|
52
|
-
let u = Pn1.n.cross(Pn2.n);
|
|
53
|
-
let ax = u.x >= 0 ? u.x : -u.x;
|
|
54
|
-
let ay = u.y >= 0 ? u.y : -u.y;
|
|
55
|
-
let az = u.z >= 0 ? u.z : -u.z;
|
|
56
|
-
// test if the two planes are parallel
|
|
57
|
-
if (ax + ay + az < EPS5) {
|
|
58
|
-
// Pn1 and Pn2 are near parallel
|
|
59
|
-
// test if disjoint or coincide
|
|
60
|
-
let v = Pn2.p.sub(Pn1.p);
|
|
61
|
-
if (Pn1.n.dot(v) == 0) {
|
|
62
|
-
// Pn2.V0 lies in Pn1
|
|
63
|
-
return COINCIDE; // Pn1 and Pn2 coincide
|
|
64
|
-
}
|
|
65
|
-
else {
|
|
66
|
-
return DISJOINT; // Pn1 and Pn2 are disjoint
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
// Pn1 and Pn2 intersect in a line
|
|
70
|
-
// first determine max abs coordinate of cross product
|
|
71
|
-
let maxc; // max coordinate
|
|
72
|
-
if (ax > ay) {
|
|
73
|
-
if (ax > az) {
|
|
74
|
-
maxc = 1;
|
|
75
|
-
}
|
|
76
|
-
else {
|
|
77
|
-
maxc = 3;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
else {
|
|
81
|
-
if (ay > az) {
|
|
82
|
-
maxc = 2;
|
|
83
|
-
}
|
|
84
|
-
else {
|
|
85
|
-
maxc = 3;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
// next, to get a point on the intersect line
|
|
89
|
-
// zero the max coord, and solve for the other two
|
|
90
|
-
let iP = new Vec3(); // intersect point
|
|
91
|
-
let d1, d2; // the constants in the 2 plane equations
|
|
92
|
-
d1 = -Pn1.n.dot(Pn1.p); // note: could be pre-stored with plane
|
|
93
|
-
d2 = -Pn2.n.dot(Pn2.p); // ditto
|
|
94
|
-
// select max coordinate
|
|
95
|
-
if (maxc === 1) {
|
|
96
|
-
// intersect with x=0
|
|
97
|
-
iP.x = 0;
|
|
98
|
-
iP.y = (d2 * Pn1.n.z - d1 * Pn2.n.z) / u.x;
|
|
99
|
-
iP.z = (d1 * Pn2.n.y - d2 * Pn1.n.y) / u.x;
|
|
100
|
-
}
|
|
101
|
-
else if (maxc === 2) {
|
|
102
|
-
// intersect with y=0
|
|
103
|
-
iP.x = (d1 * Pn2.n.z - d2 * Pn1.n.z) / u.y;
|
|
104
|
-
iP.y = 0;
|
|
105
|
-
iP.z = (d2 * Pn1.n.x - d1 * Pn2.n.x) / u.y;
|
|
106
|
-
}
|
|
107
|
-
else if (maxc === 3) {
|
|
108
|
-
// intersect with z=0
|
|
109
|
-
iP.x = (d2 * Pn1.n.y - d1 * Pn2.n.y) / u.z;
|
|
110
|
-
iP.y = (d1 * Pn2.n.x - d2 * Pn1.n.x) / u.z;
|
|
111
|
-
iP.z = 0;
|
|
112
|
-
}
|
|
113
|
-
L.p0.copy(iP);
|
|
114
|
-
L.p1.copy(iP.add(u));
|
|
115
|
-
return INTERSECT;
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
export { Plane };
|