@cesium/engine 10.1.0 → 11.0.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/Build/Workers/{chunk-N4QEHO3U.js → chunk-2EDC3QGH.js} +1 -1
- package/Build/Workers/{chunk-NVOABL76.js → chunk-2MKRG7L7.js} +5 -5
- package/Build/Workers/{chunk-X23FRWHJ.js → chunk-2RZYNSMR.js} +6 -6
- package/Build/Workers/{chunk-TO2PVHKI.js → chunk-4NBRIKB3.js} +2 -2
- package/Build/Workers/{chunk-5BLJ5ZM6.js → chunk-4TK5YR6Q.js} +5 -5
- package/Build/Workers/{chunk-TF776XCO.js → chunk-54VC7SCM.js} +7 -7
- package/Build/Workers/{chunk-2GEAGYUY.js → chunk-5IY5BXCT.js} +13 -13
- package/Build/Workers/{chunk-OXALEQPI.js → chunk-6FFGOENI.js} +10 -7
- package/Build/Workers/{chunk-65MZOUNU.js → chunk-6PJIHPQB.js} +13 -13
- package/Build/Workers/{chunk-FOZWUH4T.js → chunk-6ZREIBKS.js} +7 -7
- package/Build/Workers/{chunk-BY3E4ONI.js → chunk-AI3O7UN2.js} +6 -6
- package/Build/Workers/{chunk-XQI7XZHX.js → chunk-AS7P4BHI.js} +6 -6
- package/Build/Workers/{chunk-PNFHVBSF.js → chunk-AUM45VEG.js} +16 -15
- package/Build/Workers/{chunk-VRZ46QZ5.js → chunk-BBO6BGLC.js} +13 -13
- package/Build/Workers/{chunk-POSRARY7.js → chunk-BH5ZEN4I.js} +10 -10
- package/Build/Workers/{chunk-A5CODJ4M.js → chunk-BJ3WF5RW.js} +6 -6
- package/Build/Workers/{chunk-Q55ECN3Y.js → chunk-BUOFSNFW.js} +1 -1
- package/Build/Workers/{chunk-QX5XS4LC.js → chunk-BZXF3GNX.js} +2 -2
- package/Build/Workers/{chunk-T6LPN7RI.js → chunk-DJXXI7UF.js} +5 -5
- package/Build/Workers/{chunk-C3Z23UUJ.js → chunk-DVAIU7A4.js} +17 -17
- package/Build/Workers/{chunk-X2ZQ7RJR.js → chunk-FJT3ERV7.js} +9 -9
- package/Build/Workers/{chunk-UCIPJSZX.js → chunk-GOHDOWU5.js} +14 -14
- package/Build/Workers/{chunk-R4OIEIPE.js → chunk-HA6TZ3XT.js} +4 -4
- package/Build/Workers/{chunk-ACRTCBN5.js → chunk-HBZSCVZC.js} +11 -11
- package/Build/Workers/{chunk-BGE4QVG7.js → chunk-HC7RYWPZ.js} +12 -12
- package/Build/Workers/{chunk-VE7BFUIX.js → chunk-HFMJM3SX.js} +1 -1
- package/Build/Workers/{chunk-OOK53QUQ.js → chunk-HFPMX5L2.js} +1 -1
- package/Build/Workers/{chunk-6D66DPRV.js → chunk-HO2NTC7I.js} +6 -6
- package/Build/Workers/{chunk-F3NDOSTZ.js → chunk-HZPMWR4H.js} +7 -7
- package/Build/Workers/{chunk-I2RC4XVN.js → chunk-IBG5FVXC.js} +4 -4
- package/Build/Workers/{chunk-FEVVHITK.js → chunk-IXLNNST6.js} +4 -4
- package/Build/Workers/{chunk-4YSNMHZ4.js → chunk-JYUCC5NV.js} +6 -6
- package/Build/Workers/{chunk-FDCLACT5.js → chunk-KFW4UNQH.js} +10 -10
- package/Build/Workers/{chunk-R6B7UCQB.js → chunk-KKAEXHDY.js} +2 -2
- package/Build/Workers/{chunk-D2U4RI64.js → chunk-L6FARMF6.js} +7 -7
- package/Build/Workers/{chunk-OOMCT7OL.js → chunk-N3BIL6WA.js} +13 -13
- package/Build/Workers/{chunk-XZZNKIEV.js → chunk-O5SSW3B3.js} +6 -6
- package/Build/Workers/{chunk-S3PI2KFM.js → chunk-OC4MYPVW.js} +2 -2
- package/Build/Workers/{chunk-XLTOBCDI.js → chunk-OOA6GXKD.js} +7 -7
- package/Build/Workers/{chunk-GPJR7MPQ.js → chunk-OSCHEWSG.js} +7 -7
- package/Build/Workers/{chunk-RZLZWKFN.js → chunk-QGT2GMOK.js} +4 -4
- package/Build/Workers/{chunk-OWGTMVDB.js → chunk-RFQYEYAL.js} +17 -17
- package/Build/Workers/{chunk-LSSWVB2X.js → chunk-RJF5ZP76.js} +4 -4
- package/Build/Workers/{chunk-EB7PNZTK.js → chunk-SIZXFNJY.js} +6 -5
- package/Build/Workers/{chunk-G5V4GPZE.js → chunk-SRZJCF7G.js} +9 -9
- package/Build/Workers/{chunk-T77JILCU.js → chunk-T4MB73MC.js} +2 -2
- package/Build/Workers/{chunk-4RMIRG6T.js → chunk-TTI2SUWJ.js} +2 -2
- package/Build/Workers/{chunk-4VFBBNQ3.js → chunk-VHJ5ESXF.js} +1 -1
- package/Build/Workers/{chunk-2J3JKXCP.js → chunk-VSFFJGTA.js} +9 -5
- package/Build/Workers/{chunk-ZU334IDQ.js → chunk-WQRXRDCZ.js} +11 -11
- package/Build/Workers/{chunk-J7MQUQJY.js → chunk-WXDGOYTT.js} +12 -7
- package/Build/Workers/{chunk-76BYYG7N.js → chunk-XLCZE6DD.js} +10 -10
- package/Build/Workers/combineGeometry.js +22 -22
- package/Build/Workers/createBoxGeometry.js +16 -16
- package/Build/Workers/createBoxOutlineGeometry.js +14 -14
- package/Build/Workers/createCircleGeometry.js +24 -24
- package/Build/Workers/createCircleOutlineGeometry.js +17 -17
- package/Build/Workers/createCoplanarPolygonGeometry.js +31 -31
- package/Build/Workers/createCoplanarPolygonOutlineGeometry.js +29 -29
- package/Build/Workers/createCorridorGeometry.js +27 -27
- package/Build/Workers/createCorridorOutlineGeometry.js +26 -26
- package/Build/Workers/createCylinderGeometry.js +18 -18
- package/Build/Workers/createCylinderOutlineGeometry.js +16 -16
- package/Build/Workers/createEllipseGeometry.js +24 -24
- package/Build/Workers/createEllipseOutlineGeometry.js +17 -17
- package/Build/Workers/createEllipsoidGeometry.js +17 -17
- package/Build/Workers/createEllipsoidOutlineGeometry.js +16 -16
- package/Build/Workers/createFrustumGeometry.js +16 -16
- package/Build/Workers/createFrustumOutlineGeometry.js +16 -16
- package/Build/Workers/createGeometry.js +22 -22
- package/Build/Workers/createGroundPolylineGeometry.js +20 -20
- package/Build/Workers/createPlaneGeometry.js +14 -14
- package/Build/Workers/createPlaneOutlineGeometry.js +13 -13
- package/Build/Workers/createPolygonGeometry.js +30 -30
- package/Build/Workers/createPolygonOutlineGeometry.js +28 -28
- package/Build/Workers/createPolylineGeometry.js +23 -23
- package/Build/Workers/createPolylineVolumeGeometry.js +29 -29
- package/Build/Workers/createPolylineVolumeOutlineGeometry.js +25 -25
- package/Build/Workers/createRectangleGeometry.js +25 -25
- package/Build/Workers/createRectangleOutlineGeometry.js +18 -18
- package/Build/Workers/createSimplePolylineGeometry.js +21 -21
- package/Build/Workers/createSphereGeometry.js +17 -17
- package/Build/Workers/createSphereOutlineGeometry.js +16 -16
- package/Build/Workers/createTaskProcessorWorker.js +3 -3
- package/Build/Workers/createVectorTileClampedPolylines.js +13 -13
- package/Build/Workers/createVectorTileGeometries.js +22 -22
- package/Build/Workers/createVectorTilePoints.js +12 -12
- package/Build/Workers/createVectorTilePolygons.js +20 -20
- package/Build/Workers/createVectorTilePolylines.js +13 -13
- package/Build/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +20 -20
- package/Build/Workers/createVerticesFromHeightmap.js +24 -20
- package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +17 -17
- package/Build/Workers/createWallGeometry.js +22 -22
- package/Build/Workers/createWallOutlineGeometry.js +21 -21
- package/Build/Workers/decodeDraco.js +11 -11
- package/Build/Workers/decodeGoogleEarthEnterprisePacket.js +28 -5
- package/Build/Workers/decodeI3S.js +10 -10
- package/Build/Workers/transcodeKTX2.js +19 -18
- package/Build/Workers/transferTypedArrayTest.js +1 -1
- package/Build/Workers/upsampleQuantizedTerrainMesh.js +20 -20
- package/Source/Core/CompressedTextureBuffer.js +11 -0
- package/Source/Core/Ion.js +1 -1
- package/Source/Core/KTX2Transcoder.js +9 -16
- package/Source/Core/PixelFormat.js +1 -15
- package/Source/DataSources/CallbackProperty.js +8 -2
- package/Source/DataSources/CheckerboardMaterialProperty.js +7 -1
- package/Source/DataSources/ColorMaterialProperty.js +7 -1
- package/Source/DataSources/CompositeMaterialProperty.js +5 -4
- package/Source/DataSources/CompositePositionProperty.js +7 -1
- package/Source/DataSources/CompositeProperty.js +5 -5
- package/Source/DataSources/ConstantPositionProperty.js +7 -1
- package/Source/DataSources/Entity.js +1 -1
- package/Source/DataSources/GridMaterialProperty.js +7 -1
- package/Source/DataSources/ImageMaterialProperty.js +8 -1
- package/Source/DataSources/MaterialProperty.js +7 -1
- package/Source/DataSources/NodeTransformationProperty.js +7 -1
- package/Source/DataSources/PolylineArrowMaterialProperty.js +7 -1
- package/Source/DataSources/PolylineDashMaterialProperty.js +7 -1
- package/Source/DataSources/PolylineGlowMaterialProperty.js +7 -1
- package/Source/DataSources/PolylineOutlineMaterialProperty.js +7 -1
- package/Source/DataSources/PositionProperty.js +1 -1
- package/Source/DataSources/PositionPropertyArray.js +7 -1
- package/Source/DataSources/Property.js +1 -1
- package/Source/DataSources/PropertyArray.js +5 -5
- package/Source/DataSources/PropertyBag.js +5 -4
- package/Source/DataSources/ReferenceProperty.js +7 -1
- package/Source/DataSources/SampledPositionProperty.js +7 -1
- package/Source/DataSources/SampledProperty.js +6 -4
- package/Source/DataSources/ScaledPositionProperty.js +6 -0
- package/Source/DataSources/StripeMaterialProperty.js +7 -1
- package/Source/DataSources/TerrainOffsetProperty.js +9 -0
- package/Source/DataSources/TimeIntervalCollectionPositionProperty.js +7 -1
- package/Source/DataSources/TimeIntervalCollectionProperty.js +5 -5
- package/Source/DataSources/VelocityOrientationProperty.js +6 -1
- package/Source/DataSources/VelocityVectorProperty.js +3 -5
- package/Source/Renderer/AutomaticUniforms.js +2 -17
- package/Source/Renderer/Context.js +15 -0
- package/Source/Renderer/CubeMap.js +326 -348
- package/Source/Renderer/CubeMapFace.js +26 -48
- package/Source/Renderer/PixelDatatype.js +23 -0
- package/Source/Renderer/Sampler.js +7 -13
- package/Source/Renderer/ShaderProgram.js +7 -0
- package/Source/Renderer/Texture.js +396 -332
- package/Source/Renderer/UniformState.js +3 -22
- package/Source/Renderer/demodernizeShader.js +2 -0
- package/Source/Renderer/loadCubeMap.js +3 -8
- package/Source/Scene/ArcGisMapService.js +1 -1
- package/Source/Scene/CameraEventAggregator.js +49 -5
- package/Source/Scene/Globe.js +1 -1
- package/Source/Scene/GlobeSurfaceShaderSet.js +29 -24
- package/Source/Scene/GlobeSurfaceTileProvider.js +5 -3
- package/Source/Scene/ImageBasedLighting.js +34 -34
- package/Source/Scene/Label.js +2 -2
- package/Source/Scene/Material.js +24 -2
- package/Source/Scene/Model/ImageBasedLightingPipelineStage.js +7 -15
- package/Source/Scene/PostProcessStageCollection.js +45 -15
- package/Source/Scene/PostProcessStageLibrary.js +26 -0
- package/Source/Scene/Scene.js +20 -22
- package/Source/Scene/SceneTransforms.js +0 -62
- package/Source/Scene/ScreenSpaceCameraController.js +11 -4
- package/Source/Scene/SkyBox.js +13 -19
- package/Source/Scene/SpecularEnvironmentCubeMap.js +240 -0
- package/Source/Scene/Tonemapper.js +35 -23
- package/Source/Scene/VoxelPrimitive.js +0 -29
- package/Source/Scene/VoxelRenderResources.js +0 -3
- package/Source/Shaders/Builtin/CzmBuiltins.js +2 -2
- package/Source/Shaders/Builtin/Functions/pbrLighting.glsl +2 -2
- package/Source/Shaders/Builtin/Functions/pbrLighting.js +2 -2
- package/Source/Shaders/Builtin/Functions/pbrNeutralTonemapping.glsl +23 -0
- package/Source/Shaders/Builtin/Functions/pbrNeutralTonemapping.js +25 -0
- package/Source/Shaders/Builtin/Functions/textureCube.glsl +21 -2
- package/Source/Shaders/Builtin/Functions/textureCube.js +21 -2
- package/Source/Shaders/Builtin/Structs/materialInput.glsl +2 -0
- package/Source/Shaders/Builtin/Structs/materialInput.js +2 -0
- package/Source/Shaders/GlobeFS.glsl +10 -4
- package/Source/Shaders/GlobeFS.js +10 -4
- package/Source/Shaders/Materials/WaterMaskMaterial.glsl +15 -0
- package/Source/Shaders/Materials/WaterMaskMaterial.js +17 -0
- package/Source/Shaders/Model/AtmosphereStageFS.glsl +1 -1
- package/Source/Shaders/Model/AtmosphereStageFS.js +1 -1
- package/Source/Shaders/Model/ImageBasedLightingStageFS.glsl +40 -29
- package/Source/Shaders/Model/ImageBasedLightingStageFS.js +40 -29
- package/Source/Shaders/Model/LightingStageFS.glsl +2 -2
- package/Source/Shaders/Model/LightingStageFS.js +2 -2
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.glsl +4 -0
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.js +4 -0
- package/Source/Shaders/PostProcessStages/FilmicTonemapping.glsl +4 -0
- package/Source/Shaders/PostProcessStages/FilmicTonemapping.js +4 -0
- package/Source/Shaders/PostProcessStages/ModifiedReinhardTonemapping.glsl +4 -0
- package/Source/Shaders/PostProcessStages/ModifiedReinhardTonemapping.js +4 -0
- package/Source/Shaders/PostProcessStages/PbrNeutralTonemapping.glsl +25 -0
- package/Source/Shaders/PostProcessStages/PbrNeutralTonemapping.js +27 -0
- package/Source/Shaders/PostProcessStages/ReinhardTonemapping.glsl +4 -0
- package/Source/Shaders/PostProcessStages/ReinhardTonemapping.js +4 -0
- package/Source/Shaders/SkyAtmosphereFS.glsl +1 -1
- package/Source/Shaders/SkyAtmosphereFS.js +1 -1
- package/Source/Widget/CesiumWidget.js +1 -1
- package/index.d.ts +117 -101
- package/index.js +212 -213
- package/package.json +2 -2
- package/Build/Workers/chunk-3WUV74WM.js +0 -1800
- package/Build/Workers/chunk-4MSUJ4I7.js +0 -456
- package/Build/Workers/chunk-5KWHSZYL.js +0 -834
- package/Build/Workers/chunk-5O6JWQ4E.js +0 -398
- package/Build/Workers/chunk-6OFDHMHR.js +0 -1258
- package/Build/Workers/chunk-AA4GZKOT.js +0 -75
- package/Build/Workers/chunk-B75IEX2S.js +0 -390
- package/Build/Workers/chunk-BAVI3ZS2.js +0 -39
- package/Build/Workers/chunk-BBDZYSZB.js +0 -287
- package/Build/Workers/chunk-C45MU4GZ.js +0 -220
- package/Build/Workers/chunk-CF7P7K7E.js +0 -684
- package/Build/Workers/chunk-D4K27X2M.js +0 -305
- package/Build/Workers/chunk-DKVHRNFY.js +0 -100
- package/Build/Workers/chunk-ELI4BUOT.js +0 -963
- package/Build/Workers/chunk-FQPSOOPH.js +0 -258
- package/Build/Workers/chunk-GNHZH7HP.js +0 -37
- package/Build/Workers/chunk-GWT64LKY.js +0 -171
- package/Build/Workers/chunk-HGEEOMSC.js +0 -157
- package/Build/Workers/chunk-IUROUBPA.js +0 -300
- package/Build/Workers/chunk-JNLWLSTP.js +0 -476
- package/Build/Workers/chunk-JYQNWIQQ.js +0 -44
- package/Build/Workers/chunk-KUN2ZA5X.js +0 -138
- package/Build/Workers/chunk-KV4EQHK4.js +0 -1477
- package/Build/Workers/chunk-LXQ5QAEJ.js +0 -196
- package/Build/Workers/chunk-MBZH7YZ7.js +0 -945
- package/Build/Workers/chunk-MKXWJTFQ.js +0 -781
- package/Build/Workers/chunk-MMV6TO3P.js +0 -101
- package/Build/Workers/chunk-MSKXMXJI.js +0 -500
- package/Build/Workers/chunk-OAPA2RTG.js +0 -239
- package/Build/Workers/chunk-OE4MCOC7.js +0 -421
- package/Build/Workers/chunk-OJF4RTJG.js +0 -634
- package/Build/Workers/chunk-OXSI7N4C.js +0 -768
- package/Build/Workers/chunk-PYHLO636.js +0 -2857
- package/Build/Workers/chunk-QD4KM3GO.js +0 -138
- package/Build/Workers/chunk-QMLTCCYG.js +0 -55
- package/Build/Workers/chunk-QYQIVZBU.js +0 -117
- package/Build/Workers/chunk-R3TKLC6E.js +0 -1075
- package/Build/Workers/chunk-R4ZEWO4I.js +0 -122
- package/Build/Workers/chunk-RCK55EDX.js +0 -691
- package/Build/Workers/chunk-RHBWXX7C.js +0 -629
- package/Build/Workers/chunk-SAPFXU5X.js +0 -102
- package/Build/Workers/chunk-TBBFDFCS.js +0 -368
- package/Build/Workers/chunk-TGY6H6N6.js +0 -163
- package/Build/Workers/chunk-UOEUCKKU.js +0 -59
- package/Build/Workers/chunk-VFBNELXB.js +0 -353
- package/Build/Workers/chunk-VYWUFRRR.js +0 -1052
- package/Build/Workers/chunk-WVSELU6O.js +0 -2716
- package/Build/Workers/chunk-X43SJLQL.js +0 -10364
- package/Build/Workers/chunk-XUOJCLOH.js +0 -511
- package/Build/Workers/chunk-YLYBLJ3Y.js +0 -73
- package/Build/Workers/chunk-ZEE2EIFD.js +0 -430
- package/Build/Workers/chunk-ZIKGV7EL.js +0 -58
- package/Source/Scene/OctahedralProjectedCubeMap.js +0 -444
- package/Source/Shaders/Builtin/Functions/sampleOctahedralProjection.glsl +0 -78
- package/Source/Shaders/Builtin/Functions/sampleOctahedralProjection.js +0 -80
- package/Source/Shaders/OctahedralProjectionAtlasFS.glsl +0 -89
- package/Source/Shaders/OctahedralProjectionAtlasFS.js +0 -91
- package/Source/Shaders/OctahedralProjectionFS.glsl +0 -14
- package/Source/Shaders/OctahedralProjectionFS.js +0 -16
- package/Source/Shaders/OctahedralProjectionVS.glsl +0 -10
- package/Source/Shaders/OctahedralProjectionVS.js +0 -12
|
@@ -1,305 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.120
|
|
5
|
-
*
|
|
6
|
-
* Copyright 2011-2022 Cesium Contributors
|
|
7
|
-
*
|
|
8
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
-
* you may not use this file except in compliance with the License.
|
|
10
|
-
* You may obtain a copy of the License at
|
|
11
|
-
*
|
|
12
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
-
*
|
|
14
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
-
* See the License for the specific language governing permissions and
|
|
18
|
-
* limitations under the License.
|
|
19
|
-
*
|
|
20
|
-
* Columbus View (Pat. Pend.)
|
|
21
|
-
*
|
|
22
|
-
* Portions licensed separately.
|
|
23
|
-
* See https://github.com/CesiumGS/cesium/blob/main/LICENSE.md for full licensing details.
|
|
24
|
-
*/
|
|
25
|
-
|
|
26
|
-
import {
|
|
27
|
-
Quaternion_default
|
|
28
|
-
} from "./chunk-OXALEQPI.js";
|
|
29
|
-
import {
|
|
30
|
-
Cartesian3_default,
|
|
31
|
-
Matrix3_default
|
|
32
|
-
} from "./chunk-T6LPN7RI.js";
|
|
33
|
-
import {
|
|
34
|
-
Math_default
|
|
35
|
-
} from "./chunk-R4OIEIPE.js";
|
|
36
|
-
|
|
37
|
-
// packages/engine/Source/Core/EllipseGeometryLibrary.js
|
|
38
|
-
var EllipseGeometryLibrary = {};
|
|
39
|
-
var rotAxis = new Cartesian3_default();
|
|
40
|
-
var tempVec = new Cartesian3_default();
|
|
41
|
-
var unitQuat = new Quaternion_default();
|
|
42
|
-
var rotMtx = new Matrix3_default();
|
|
43
|
-
function pointOnEllipsoid(theta, rotation, northVec, eastVec, aSqr, ab, bSqr, mag, unitPos, result) {
|
|
44
|
-
const azimuth = theta + rotation;
|
|
45
|
-
Cartesian3_default.multiplyByScalar(eastVec, Math.cos(azimuth), rotAxis);
|
|
46
|
-
Cartesian3_default.multiplyByScalar(northVec, Math.sin(azimuth), tempVec);
|
|
47
|
-
Cartesian3_default.add(rotAxis, tempVec, rotAxis);
|
|
48
|
-
let cosThetaSquared = Math.cos(theta);
|
|
49
|
-
cosThetaSquared = cosThetaSquared * cosThetaSquared;
|
|
50
|
-
let sinThetaSquared = Math.sin(theta);
|
|
51
|
-
sinThetaSquared = sinThetaSquared * sinThetaSquared;
|
|
52
|
-
const radius = ab / Math.sqrt(bSqr * cosThetaSquared + aSqr * sinThetaSquared);
|
|
53
|
-
const angle = radius / mag;
|
|
54
|
-
Quaternion_default.fromAxisAngle(rotAxis, angle, unitQuat);
|
|
55
|
-
Matrix3_default.fromQuaternion(unitQuat, rotMtx);
|
|
56
|
-
Matrix3_default.multiplyByVector(rotMtx, unitPos, result);
|
|
57
|
-
Cartesian3_default.normalize(result, result);
|
|
58
|
-
Cartesian3_default.multiplyByScalar(result, mag, result);
|
|
59
|
-
return result;
|
|
60
|
-
}
|
|
61
|
-
var scratchCartesian1 = new Cartesian3_default();
|
|
62
|
-
var scratchCartesian2 = new Cartesian3_default();
|
|
63
|
-
var scratchCartesian3 = new Cartesian3_default();
|
|
64
|
-
var scratchNormal = new Cartesian3_default();
|
|
65
|
-
EllipseGeometryLibrary.raisePositionsToHeight = function(positions, options, extrude) {
|
|
66
|
-
const ellipsoid = options.ellipsoid;
|
|
67
|
-
const height = options.height;
|
|
68
|
-
const extrudedHeight = options.extrudedHeight;
|
|
69
|
-
const size = extrude ? positions.length / 3 * 2 : positions.length / 3;
|
|
70
|
-
const finalPositions = new Float64Array(size * 3);
|
|
71
|
-
const length = positions.length;
|
|
72
|
-
const bottomOffset = extrude ? length : 0;
|
|
73
|
-
for (let i = 0; i < length; i += 3) {
|
|
74
|
-
const i1 = i + 1;
|
|
75
|
-
const i2 = i + 2;
|
|
76
|
-
const position = Cartesian3_default.fromArray(positions, i, scratchCartesian1);
|
|
77
|
-
ellipsoid.scaleToGeodeticSurface(position, position);
|
|
78
|
-
const extrudedPosition = Cartesian3_default.clone(position, scratchCartesian2);
|
|
79
|
-
const normal = ellipsoid.geodeticSurfaceNormal(position, scratchNormal);
|
|
80
|
-
const scaledNormal = Cartesian3_default.multiplyByScalar(
|
|
81
|
-
normal,
|
|
82
|
-
height,
|
|
83
|
-
scratchCartesian3
|
|
84
|
-
);
|
|
85
|
-
Cartesian3_default.add(position, scaledNormal, position);
|
|
86
|
-
if (extrude) {
|
|
87
|
-
Cartesian3_default.multiplyByScalar(normal, extrudedHeight, scaledNormal);
|
|
88
|
-
Cartesian3_default.add(extrudedPosition, scaledNormal, extrudedPosition);
|
|
89
|
-
finalPositions[i + bottomOffset] = extrudedPosition.x;
|
|
90
|
-
finalPositions[i1 + bottomOffset] = extrudedPosition.y;
|
|
91
|
-
finalPositions[i2 + bottomOffset] = extrudedPosition.z;
|
|
92
|
-
}
|
|
93
|
-
finalPositions[i] = position.x;
|
|
94
|
-
finalPositions[i1] = position.y;
|
|
95
|
-
finalPositions[i2] = position.z;
|
|
96
|
-
}
|
|
97
|
-
return finalPositions;
|
|
98
|
-
};
|
|
99
|
-
var unitPosScratch = new Cartesian3_default();
|
|
100
|
-
var eastVecScratch = new Cartesian3_default();
|
|
101
|
-
var northVecScratch = new Cartesian3_default();
|
|
102
|
-
EllipseGeometryLibrary.computeEllipsePositions = function(options, addFillPositions, addEdgePositions) {
|
|
103
|
-
const semiMinorAxis = options.semiMinorAxis;
|
|
104
|
-
const semiMajorAxis = options.semiMajorAxis;
|
|
105
|
-
const rotation = options.rotation;
|
|
106
|
-
const center = options.center;
|
|
107
|
-
const granularity = options.granularity * 8;
|
|
108
|
-
const aSqr = semiMinorAxis * semiMinorAxis;
|
|
109
|
-
const bSqr = semiMajorAxis * semiMajorAxis;
|
|
110
|
-
const ab = semiMajorAxis * semiMinorAxis;
|
|
111
|
-
const mag = Cartesian3_default.magnitude(center);
|
|
112
|
-
const unitPos = Cartesian3_default.normalize(center, unitPosScratch);
|
|
113
|
-
let eastVec = Cartesian3_default.cross(Cartesian3_default.UNIT_Z, center, eastVecScratch);
|
|
114
|
-
eastVec = Cartesian3_default.normalize(eastVec, eastVec);
|
|
115
|
-
const northVec = Cartesian3_default.cross(unitPos, eastVec, northVecScratch);
|
|
116
|
-
let numPts = 1 + Math.ceil(Math_default.PI_OVER_TWO / granularity);
|
|
117
|
-
const deltaTheta = Math_default.PI_OVER_TWO / (numPts - 1);
|
|
118
|
-
let theta = Math_default.PI_OVER_TWO - numPts * deltaTheta;
|
|
119
|
-
if (theta < 0) {
|
|
120
|
-
numPts -= Math.ceil(Math.abs(theta) / deltaTheta);
|
|
121
|
-
}
|
|
122
|
-
const size = 2 * (numPts * (numPts + 2));
|
|
123
|
-
const positions = addFillPositions ? new Array(size * 3) : void 0;
|
|
124
|
-
let positionIndex = 0;
|
|
125
|
-
let position = scratchCartesian1;
|
|
126
|
-
let reflectedPosition = scratchCartesian2;
|
|
127
|
-
const outerPositionsLength = numPts * 4 * 3;
|
|
128
|
-
let outerRightIndex = outerPositionsLength - 1;
|
|
129
|
-
let outerLeftIndex = 0;
|
|
130
|
-
const outerPositions = addEdgePositions ? new Array(outerPositionsLength) : void 0;
|
|
131
|
-
let i;
|
|
132
|
-
let j;
|
|
133
|
-
let numInterior;
|
|
134
|
-
let t;
|
|
135
|
-
let interiorPosition;
|
|
136
|
-
theta = Math_default.PI_OVER_TWO;
|
|
137
|
-
position = pointOnEllipsoid(
|
|
138
|
-
theta,
|
|
139
|
-
rotation,
|
|
140
|
-
northVec,
|
|
141
|
-
eastVec,
|
|
142
|
-
aSqr,
|
|
143
|
-
ab,
|
|
144
|
-
bSqr,
|
|
145
|
-
mag,
|
|
146
|
-
unitPos,
|
|
147
|
-
position
|
|
148
|
-
);
|
|
149
|
-
if (addFillPositions) {
|
|
150
|
-
positions[positionIndex++] = position.x;
|
|
151
|
-
positions[positionIndex++] = position.y;
|
|
152
|
-
positions[positionIndex++] = position.z;
|
|
153
|
-
}
|
|
154
|
-
if (addEdgePositions) {
|
|
155
|
-
outerPositions[outerRightIndex--] = position.z;
|
|
156
|
-
outerPositions[outerRightIndex--] = position.y;
|
|
157
|
-
outerPositions[outerRightIndex--] = position.x;
|
|
158
|
-
}
|
|
159
|
-
theta = Math_default.PI_OVER_TWO - deltaTheta;
|
|
160
|
-
for (i = 1; i < numPts + 1; ++i) {
|
|
161
|
-
position = pointOnEllipsoid(
|
|
162
|
-
theta,
|
|
163
|
-
rotation,
|
|
164
|
-
northVec,
|
|
165
|
-
eastVec,
|
|
166
|
-
aSqr,
|
|
167
|
-
ab,
|
|
168
|
-
bSqr,
|
|
169
|
-
mag,
|
|
170
|
-
unitPos,
|
|
171
|
-
position
|
|
172
|
-
);
|
|
173
|
-
reflectedPosition = pointOnEllipsoid(
|
|
174
|
-
Math.PI - theta,
|
|
175
|
-
rotation,
|
|
176
|
-
northVec,
|
|
177
|
-
eastVec,
|
|
178
|
-
aSqr,
|
|
179
|
-
ab,
|
|
180
|
-
bSqr,
|
|
181
|
-
mag,
|
|
182
|
-
unitPos,
|
|
183
|
-
reflectedPosition
|
|
184
|
-
);
|
|
185
|
-
if (addFillPositions) {
|
|
186
|
-
positions[positionIndex++] = position.x;
|
|
187
|
-
positions[positionIndex++] = position.y;
|
|
188
|
-
positions[positionIndex++] = position.z;
|
|
189
|
-
numInterior = 2 * i + 2;
|
|
190
|
-
for (j = 1; j < numInterior - 1; ++j) {
|
|
191
|
-
t = j / (numInterior - 1);
|
|
192
|
-
interiorPosition = Cartesian3_default.lerp(
|
|
193
|
-
position,
|
|
194
|
-
reflectedPosition,
|
|
195
|
-
t,
|
|
196
|
-
scratchCartesian3
|
|
197
|
-
);
|
|
198
|
-
positions[positionIndex++] = interiorPosition.x;
|
|
199
|
-
positions[positionIndex++] = interiorPosition.y;
|
|
200
|
-
positions[positionIndex++] = interiorPosition.z;
|
|
201
|
-
}
|
|
202
|
-
positions[positionIndex++] = reflectedPosition.x;
|
|
203
|
-
positions[positionIndex++] = reflectedPosition.y;
|
|
204
|
-
positions[positionIndex++] = reflectedPosition.z;
|
|
205
|
-
}
|
|
206
|
-
if (addEdgePositions) {
|
|
207
|
-
outerPositions[outerRightIndex--] = position.z;
|
|
208
|
-
outerPositions[outerRightIndex--] = position.y;
|
|
209
|
-
outerPositions[outerRightIndex--] = position.x;
|
|
210
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.x;
|
|
211
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.y;
|
|
212
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.z;
|
|
213
|
-
}
|
|
214
|
-
theta = Math_default.PI_OVER_TWO - (i + 1) * deltaTheta;
|
|
215
|
-
}
|
|
216
|
-
for (i = numPts; i > 1; --i) {
|
|
217
|
-
theta = Math_default.PI_OVER_TWO - (i - 1) * deltaTheta;
|
|
218
|
-
position = pointOnEllipsoid(
|
|
219
|
-
-theta,
|
|
220
|
-
rotation,
|
|
221
|
-
northVec,
|
|
222
|
-
eastVec,
|
|
223
|
-
aSqr,
|
|
224
|
-
ab,
|
|
225
|
-
bSqr,
|
|
226
|
-
mag,
|
|
227
|
-
unitPos,
|
|
228
|
-
position
|
|
229
|
-
);
|
|
230
|
-
reflectedPosition = pointOnEllipsoid(
|
|
231
|
-
theta + Math.PI,
|
|
232
|
-
rotation,
|
|
233
|
-
northVec,
|
|
234
|
-
eastVec,
|
|
235
|
-
aSqr,
|
|
236
|
-
ab,
|
|
237
|
-
bSqr,
|
|
238
|
-
mag,
|
|
239
|
-
unitPos,
|
|
240
|
-
reflectedPosition
|
|
241
|
-
);
|
|
242
|
-
if (addFillPositions) {
|
|
243
|
-
positions[positionIndex++] = position.x;
|
|
244
|
-
positions[positionIndex++] = position.y;
|
|
245
|
-
positions[positionIndex++] = position.z;
|
|
246
|
-
numInterior = 2 * (i - 1) + 2;
|
|
247
|
-
for (j = 1; j < numInterior - 1; ++j) {
|
|
248
|
-
t = j / (numInterior - 1);
|
|
249
|
-
interiorPosition = Cartesian3_default.lerp(
|
|
250
|
-
position,
|
|
251
|
-
reflectedPosition,
|
|
252
|
-
t,
|
|
253
|
-
scratchCartesian3
|
|
254
|
-
);
|
|
255
|
-
positions[positionIndex++] = interiorPosition.x;
|
|
256
|
-
positions[positionIndex++] = interiorPosition.y;
|
|
257
|
-
positions[positionIndex++] = interiorPosition.z;
|
|
258
|
-
}
|
|
259
|
-
positions[positionIndex++] = reflectedPosition.x;
|
|
260
|
-
positions[positionIndex++] = reflectedPosition.y;
|
|
261
|
-
positions[positionIndex++] = reflectedPosition.z;
|
|
262
|
-
}
|
|
263
|
-
if (addEdgePositions) {
|
|
264
|
-
outerPositions[outerRightIndex--] = position.z;
|
|
265
|
-
outerPositions[outerRightIndex--] = position.y;
|
|
266
|
-
outerPositions[outerRightIndex--] = position.x;
|
|
267
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.x;
|
|
268
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.y;
|
|
269
|
-
outerPositions[outerLeftIndex++] = reflectedPosition.z;
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
theta = Math_default.PI_OVER_TWO;
|
|
273
|
-
position = pointOnEllipsoid(
|
|
274
|
-
-theta,
|
|
275
|
-
rotation,
|
|
276
|
-
northVec,
|
|
277
|
-
eastVec,
|
|
278
|
-
aSqr,
|
|
279
|
-
ab,
|
|
280
|
-
bSqr,
|
|
281
|
-
mag,
|
|
282
|
-
unitPos,
|
|
283
|
-
position
|
|
284
|
-
);
|
|
285
|
-
const r = {};
|
|
286
|
-
if (addFillPositions) {
|
|
287
|
-
positions[positionIndex++] = position.x;
|
|
288
|
-
positions[positionIndex++] = position.y;
|
|
289
|
-
positions[positionIndex++] = position.z;
|
|
290
|
-
r.positions = positions;
|
|
291
|
-
r.numPts = numPts;
|
|
292
|
-
}
|
|
293
|
-
if (addEdgePositions) {
|
|
294
|
-
outerPositions[outerRightIndex--] = position.z;
|
|
295
|
-
outerPositions[outerRightIndex--] = position.y;
|
|
296
|
-
outerPositions[outerRightIndex--] = position.x;
|
|
297
|
-
r.outerPositions = outerPositions;
|
|
298
|
-
}
|
|
299
|
-
return r;
|
|
300
|
-
};
|
|
301
|
-
var EllipseGeometryLibrary_default = EllipseGeometryLibrary;
|
|
302
|
-
|
|
303
|
-
export {
|
|
304
|
-
EllipseGeometryLibrary_default
|
|
305
|
-
};
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.119
|
|
5
|
-
*
|
|
6
|
-
* Copyright 2011-2022 Cesium Contributors
|
|
7
|
-
*
|
|
8
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
-
* you may not use this file except in compliance with the License.
|
|
10
|
-
* You may obtain a copy of the License at
|
|
11
|
-
*
|
|
12
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
-
*
|
|
14
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
-
* See the License for the specific language governing permissions and
|
|
18
|
-
* limitations under the License.
|
|
19
|
-
*
|
|
20
|
-
* Columbus View (Pat. Pend.)
|
|
21
|
-
*
|
|
22
|
-
* Portions licensed separately.
|
|
23
|
-
* See https://github.com/CesiumGS/cesium/blob/main/LICENSE.md for full licensing details.
|
|
24
|
-
*/
|
|
25
|
-
|
|
26
|
-
import {
|
|
27
|
-
Math_default
|
|
28
|
-
} from "./chunk-MSKXMXJI.js";
|
|
29
|
-
import {
|
|
30
|
-
defaultValue_default
|
|
31
|
-
} from "./chunk-VE7BFUIX.js";
|
|
32
|
-
import {
|
|
33
|
-
Check_default
|
|
34
|
-
} from "./chunk-S3PI2KFM.js";
|
|
35
|
-
import {
|
|
36
|
-
defined_default
|
|
37
|
-
} from "./chunk-AA4GZKOT.js";
|
|
38
|
-
|
|
39
|
-
// packages/engine/Source/Core/arrayRemoveDuplicates.js
|
|
40
|
-
var removeDuplicatesEpsilon = Math_default.EPSILON10;
|
|
41
|
-
function arrayRemoveDuplicates(values, equalsEpsilon, wrapAround, removedIndices) {
|
|
42
|
-
Check_default.defined("equalsEpsilon", equalsEpsilon);
|
|
43
|
-
if (!defined_default(values)) {
|
|
44
|
-
return void 0;
|
|
45
|
-
}
|
|
46
|
-
wrapAround = defaultValue_default(wrapAround, false);
|
|
47
|
-
const storeRemovedIndices = defined_default(removedIndices);
|
|
48
|
-
const length = values.length;
|
|
49
|
-
if (length < 2) {
|
|
50
|
-
return values;
|
|
51
|
-
}
|
|
52
|
-
let i;
|
|
53
|
-
let v0 = values[0];
|
|
54
|
-
let v1;
|
|
55
|
-
let cleanedValues;
|
|
56
|
-
let lastCleanIndex = 0;
|
|
57
|
-
let removedIndexLCI = -1;
|
|
58
|
-
for (i = 1; i < length; ++i) {
|
|
59
|
-
v1 = values[i];
|
|
60
|
-
if (equalsEpsilon(v0, v1, removeDuplicatesEpsilon)) {
|
|
61
|
-
if (!defined_default(cleanedValues)) {
|
|
62
|
-
cleanedValues = values.slice(0, i);
|
|
63
|
-
lastCleanIndex = i - 1;
|
|
64
|
-
removedIndexLCI = 0;
|
|
65
|
-
}
|
|
66
|
-
if (storeRemovedIndices) {
|
|
67
|
-
removedIndices.push(i);
|
|
68
|
-
}
|
|
69
|
-
} else {
|
|
70
|
-
if (defined_default(cleanedValues)) {
|
|
71
|
-
cleanedValues.push(v1);
|
|
72
|
-
lastCleanIndex = i;
|
|
73
|
-
if (storeRemovedIndices) {
|
|
74
|
-
removedIndexLCI = removedIndices.length;
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
v0 = v1;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
if (wrapAround && equalsEpsilon(values[0], values[length - 1], removeDuplicatesEpsilon)) {
|
|
81
|
-
if (storeRemovedIndices) {
|
|
82
|
-
if (defined_default(cleanedValues)) {
|
|
83
|
-
removedIndices.splice(removedIndexLCI, 0, lastCleanIndex);
|
|
84
|
-
} else {
|
|
85
|
-
removedIndices.push(length - 1);
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
if (defined_default(cleanedValues)) {
|
|
89
|
-
cleanedValues.length -= 1;
|
|
90
|
-
} else {
|
|
91
|
-
cleanedValues = values.slice(0, -1);
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
return defined_default(cleanedValues) ? cleanedValues : values;
|
|
95
|
-
}
|
|
96
|
-
var arrayRemoveDuplicates_default = arrayRemoveDuplicates;
|
|
97
|
-
|
|
98
|
-
export {
|
|
99
|
-
arrayRemoveDuplicates_default
|
|
100
|
-
};
|