@cesium/engine 10.1.0 → 11.1.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-EB7PNZTK.js → chunk-26GA3JAM.js} +6 -5
- package/Build/Workers/{chunk-RZLZWKFN.js → chunk-27HUZ7SA.js} +4 -4
- package/Build/Workers/{chunk-A5CODJ4M.js → chunk-2ZGOQXYU.js} +6 -6
- package/Build/Workers/{chunk-TF776XCO.js → chunk-3Q2L65QU.js} +7 -7
- package/Build/Workers/{chunk-NVOABL76.js → chunk-472HQ3EH.js} +5 -5
- package/Build/Workers/{chunk-QX5XS4LC.js → chunk-5ODQSF26.js} +2 -2
- package/Build/Workers/{chunk-4YSNMHZ4.js → chunk-5OOFQLKF.js} +6 -6
- package/Build/Workers/{chunk-OXALEQPI.js → chunk-5PTXS2GO.js} +49 -23
- package/Build/Workers/{chunk-T77JILCU.js → chunk-6CHGCNMW.js} +2 -2
- package/Build/Workers/{chunk-FEVVHITK.js → chunk-76BYBWHP.js} +4 -4
- package/Build/Workers/{chunk-65MZOUNU.js → chunk-7BMOHCPM.js} +13 -13
- package/Build/Workers/{chunk-VE7BFUIX.js → chunk-7JO7GPJN.js} +1 -1
- package/Build/Workers/{chunk-5BLJ5ZM6.js → chunk-7KTQP4VB.js} +5 -5
- package/Build/Workers/{chunk-G5V4GPZE.js → chunk-7O373FFS.js} +8 -34
- package/Build/Workers/{chunk-S3PI2KFM.js → chunk-AD63PIY6.js} +2 -2
- package/Build/Workers/{chunk-6D66DPRV.js → chunk-BHQJ2NT7.js} +6 -6
- package/Build/Workers/{chunk-I2RC4XVN.js → chunk-C6YYBQXW.js} +4 -4
- package/Build/Workers/{chunk-X2ZQ7RJR.js → chunk-CKY7HOHV.js} +9 -9
- package/Build/Workers/{chunk-TO2PVHKI.js → chunk-DHYHSFFJ.js} +2 -2
- package/Build/Workers/{chunk-R6B7UCQB.js → chunk-DI5NGJUP.js} +2 -2
- package/Build/Workers/{chunk-X23FRWHJ.js → chunk-E27BLMDD.js} +7 -9
- package/Build/Workers/{chunk-N4QEHO3U.js → chunk-E63IIM5T.js} +1 -1
- package/Build/Workers/{chunk-BY3E4ONI.js → chunk-E6V6SQZW.js} +6 -6
- package/Build/Workers/{chunk-LSSWVB2X.js → chunk-EJZTDTUH.js} +4 -4
- package/Build/Workers/{chunk-XLTOBCDI.js → chunk-FDOV2LBJ.js} +7 -7
- package/Build/Workers/{chunk-ACRTCBN5.js → chunk-FIGIZHAQ.js} +11 -11
- package/Build/Workers/{chunk-4RMIRG6T.js → chunk-GESF4OXQ.js} +2 -2
- package/Build/Workers/{chunk-PNFHVBSF.js → chunk-GGZJN2TI.js} +16 -15
- package/Build/Workers/{chunk-KV4EQHK4.js → chunk-GNBFYG7F.js} +83 -79
- package/Build/Workers/{chunk-FOZWUH4T.js → chunk-GWCFU2SA.js} +7 -7
- package/Build/Workers/{chunk-Q55ECN3Y.js → chunk-I2ITFFPX.js} +1 -1
- package/Build/Workers/{chunk-XQI7XZHX.js → chunk-IBLIYJZR.js} +6 -6
- package/Build/Workers/{chunk-D2U4RI64.js → chunk-JW4FOI6M.js} +7 -7
- package/Build/Workers/{chunk-2J3JKXCP.js → chunk-K4GQUNB5.js} +9 -5
- package/Build/Workers/{chunk-POSRARY7.js → chunk-M3GMB5OP.js} +10 -10
- package/Build/Workers/{chunk-OOK53QUQ.js → chunk-MXIZJAPH.js} +1 -1
- package/Build/Workers/{chunk-OWGTMVDB.js → chunk-N5KJGGCM.js} +18 -20
- package/Build/Workers/{chunk-J7MQUQJY.js → chunk-NGPPMXRM.js} +12 -7
- package/Build/Workers/{chunk-OOMCT7OL.js → chunk-O3E4OAOE.js} +13 -13
- package/Build/Workers/{chunk-C3Z23UUJ.js → chunk-PGRPDNHG.js} +19 -23
- package/Build/Workers/{chunk-4VFBBNQ3.js → chunk-PRGYLLJT.js} +1 -1
- package/Build/Workers/{chunk-XZZNKIEV.js → chunk-S6MRMMQU.js} +6 -6
- package/Build/Workers/{chunk-76BYYG7N.js → chunk-SMDOP47J.js} +10 -10
- package/Build/Workers/{chunk-ZU334IDQ.js → chunk-TGONEMZO.js} +11 -11
- package/Build/Workers/{chunk-VRZ46QZ5.js → chunk-TKVT5GQM.js} +13 -13
- package/Build/Workers/{chunk-FDCLACT5.js → chunk-U72QNFOJ.js} +15 -25
- package/Build/Workers/{chunk-F3NDOSTZ.js → chunk-VJZB3WAV.js} +7 -7
- package/Build/Workers/{chunk-GPJR7MPQ.js → chunk-VU2MNO7L.js} +7 -7
- package/Build/Workers/{chunk-R4OIEIPE.js → chunk-XY4BATBS.js} +4 -4
- package/Build/Workers/{chunk-T6LPN7RI.js → chunk-YFXQECWV.js} +5 -5
- package/Build/Workers/{chunk-UCIPJSZX.js → chunk-YSGTGQQO.js} +14 -14
- package/Build/Workers/{chunk-BGE4QVG7.js → chunk-YZ733KKS.js} +12 -12
- package/Build/Workers/combineGeometry.js +23 -25
- 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 +25 -26
- 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 +36 -40
- package/Build/Workers/createPolygonOutlineGeometry.js +40 -48
- package/Build/Workers/createPolylineGeometry.js +23 -23
- package/Build/Workers/createPolylineVolumeGeometry.js +32 -31
- package/Build/Workers/createPolylineVolumeOutlineGeometry.js +25 -25
- package/Build/Workers/createRectangleGeometry.js +28 -30
- package/Build/Workers/createRectangleOutlineGeometry.js +19 -19
- 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 +22 -26
- package/Build/Workers/createVerticesFromHeightmap.js +26 -26
- package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +42 -32
- 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/ApproximateTerrainHeights.js +15 -15
- package/Source/Core/ArcGISTiledElevationTerrainProvider.js +33 -35
- package/Source/Core/AttributeCompression.js +12 -12
- package/Source/Core/AxisAlignedBoundingBox.js +2 -2
- package/Source/Core/BingMapsGeocoderService.js +1 -1
- package/Source/Core/BoundingRectangle.js +3 -3
- package/Source/Core/BoundingSphere.js +44 -44
- package/Source/Core/BoxGeometry.js +6 -6
- package/Source/Core/BoxOutlineGeometry.js +3 -3
- package/Source/Core/Cartesian2.js +7 -7
- package/Source/Core/Cartesian3.js +20 -20
- package/Source/Core/Cartesian4.js +8 -8
- package/Source/Core/Cartographic.js +6 -6
- package/Source/Core/CatmullRomSpline.js +6 -6
- package/Source/Core/CesiumTerrainProvider.js +66 -68
- package/Source/Core/Check.d.ts +3 -3
- package/Source/Core/Check.js +11 -11
- package/Source/Core/CircleGeometry.js +6 -6
- package/Source/Core/CircleOutlineGeometry.js +4 -4
- package/Source/Core/Clock.js +4 -4
- package/Source/Core/Color.js +11 -8
- package/Source/Core/ColorGeometryInstanceAttribute.js +1 -1
- package/Source/Core/ComponentDatatype.js +4 -4
- package/Source/Core/CompressedTextureBuffer.js +13 -2
- package/Source/Core/ConstantSpline.js +1 -1
- package/Source/Core/CoplanarPolygonGeometry.js +44 -41
- package/Source/Core/CoplanarPolygonGeometryLibrary.js +5 -5
- package/Source/Core/CoplanarPolygonOutlineGeometry.js +6 -6
- package/Source/Core/CorridorGeometry.js +77 -77
- package/Source/Core/CorridorGeometryLibrary.js +45 -45
- package/Source/Core/CorridorOutlineGeometry.js +16 -16
- package/Source/Core/CullingVolume.js +4 -4
- package/Source/Core/CustomHeightmapTerrainProvider.js +13 -13
- package/Source/Core/CylinderGeometry.js +8 -8
- package/Source/Core/CylinderGeometryLibrary.js +1 -1
- package/Source/Core/CylinderOutlineGeometry.js +4 -4
- package/Source/Core/DeveloperError.js +1 -1
- package/Source/Core/DistanceDisplayConditionGeometryInstanceAttribute.js +20 -21
- package/Source/Core/DoubleEndedPriorityQueue.js +2 -2
- package/Source/Core/EarthOrientationParameters.js +21 -25
- package/Source/Core/EarthOrientationParametersSample.js +1 -1
- package/Source/Core/EllipseGeometry.js +54 -55
- package/Source/Core/EllipseGeometryLibrary.js +12 -12
- package/Source/Core/EllipseOutlineGeometry.js +19 -19
- package/Source/Core/Ellipsoid.js +25 -33
- package/Source/Core/EllipsoidGeodesic.js +17 -16
- package/Source/Core/EllipsoidGeometry.js +9 -8
- package/Source/Core/EllipsoidOutlineGeometry.js +4 -4
- package/Source/Core/EllipsoidRhumbLine.js +33 -32
- package/Source/Core/EllipsoidTangentPlane.js +16 -16
- package/Source/Core/EllipsoidTerrainProvider.js +11 -10
- package/Source/Core/EllipsoidalOccluder.js +110 -130
- package/Source/Core/FeatureDetection.js +4 -4
- package/Source/Core/FrustumGeometry.js +14 -14
- package/Source/Core/FrustumOutlineGeometry.js +4 -4
- package/Source/Core/GeographicTilingScheme.js +6 -6
- package/Source/Core/Geometry.js +15 -17
- package/Source/Core/GeometryAttribute.js +4 -9
- package/Source/Core/GeometryAttributes.js +6 -6
- package/Source/Core/GeometryInstance.js +3 -4
- package/Source/Core/GeometryInstanceAttribute.js +1 -6
- package/Source/Core/GeometryPipeline.js +133 -137
- package/Source/Core/GoogleEarthEnterpriseMetadata.js +19 -20
- package/Source/Core/GoogleEarthEnterpriseTerrainData.js +25 -24
- package/Source/Core/GoogleEarthEnterpriseTerrainProvider.js +17 -21
- package/Source/Core/GoogleEarthEnterpriseTileInformation.js +2 -2
- package/Source/Core/GoogleMaps.js +1 -1
- package/Source/Core/GregorianDate.js +4 -4
- package/Source/Core/GroundPolylineGeometry.js +104 -104
- package/Source/Core/HeadingPitchRoll.js +7 -7
- package/Source/Core/HeightmapTerrainData.js +58 -54
- package/Source/Core/HeightmapTessellator.js +22 -23
- package/Source/Core/HermitePolynomialApproximation.js +8 -8
- package/Source/Core/HermiteSpline.js +11 -11
- package/Source/Core/HilbertOrder.js +1 -1
- package/Source/Core/Iau2006XysData.js +6 -6
- package/Source/Core/IauOrientationAxes.js +2 -2
- package/Source/Core/IauOrientationParameters.js +1 -1
- package/Source/Core/IndexDatatype.js +5 -5
- package/Source/Core/IntersectionTests.js +36 -78
- package/Source/Core/Intersections2D.js +3 -3
- package/Source/Core/Ion.js +1 -1
- package/Source/Core/IonGeocoderService.js +2 -2
- package/Source/Core/IonResource.js +5 -5
- package/Source/Core/Iso8601.js +3 -3
- package/Source/Core/JulianDate.js +23 -33
- package/Source/Core/KTX2Transcoder.js +11 -18
- package/Source/Core/LagrangePolynomialApproximation.js +1 -1
- package/Source/Core/LinearApproximation.js +4 -4
- package/Source/Core/LinearSpline.js +2 -2
- package/Source/Core/Math.js +4 -4
- package/Source/Core/Matrix2.js +3 -3
- package/Source/Core/Matrix3.js +16 -16
- package/Source/Core/Matrix4.js +31 -31
- package/Source/Core/MorphWeightSpline.js +2 -2
- package/Source/Core/NearFarScalar.js +1 -1
- package/Source/Core/Occluder.js +52 -56
- package/Source/Core/OpenCageGeocoderService.js +2 -2
- package/Source/Core/OrientedBoundingBox.js +52 -51
- package/Source/Core/OrthographicFrustum.js +11 -11
- package/Source/Core/OrthographicOffCenterFrustum.js +17 -17
- package/Source/Core/PeliasGeocoderService.js +1 -1
- package/Source/Core/PerspectiveFrustum.js +61 -55
- package/Source/Core/PerspectiveOffCenterFrustum.js +58 -59
- package/Source/Core/PinBuilder.js +1 -1
- package/Source/Core/PixelFormat.js +7 -21
- package/Source/Core/Plane.js +9 -9
- package/Source/Core/PlaneGeometry.js +1 -1
- package/Source/Core/PolygonGeometry.js +95 -94
- package/Source/Core/PolygonGeometryLibrary.js +49 -51
- package/Source/Core/PolygonOutlineGeometry.js +49 -51
- package/Source/Core/PolygonPipeline.js +31 -31
- package/Source/Core/PolylineGeometry.js +10 -10
- package/Source/Core/PolylinePipeline.js +25 -25
- package/Source/Core/PolylineVolumeGeometry.js +9 -9
- package/Source/Core/PolylineVolumeGeometryLibrary.js +51 -51
- package/Source/Core/PolylineVolumeOutlineGeometry.js +6 -6
- package/Source/Core/QuadraticRealPolynomial.js +1 -1
- package/Source/Core/QuantizedMeshTerrainData.js +28 -28
- package/Source/Core/QuarticRealPolynomial.js +1 -1
- package/Source/Core/Quaternion.js +19 -19
- package/Source/Core/QuaternionSpline.js +2 -2
- package/Source/Core/Rectangle.js +34 -13
- package/Source/Core/RectangleCollisionChecker.js +3 -3
- package/Source/Core/RectangleGeometry.js +55 -56
- package/Source/Core/RectangleGeometryLibrary.js +8 -8
- package/Source/Core/RectangleOutlineGeometry.js +20 -20
- package/Source/Core/RequestScheduler.js +6 -6
- package/Source/Core/Resource.js +24 -24
- package/Source/Core/S2Cell.js +16 -80
- package/Source/Core/ScreenSpaceEventHandler.js +54 -53
- package/Source/Core/Simon1994PlanetaryPositions.js +13 -13
- package/Source/Core/SimplePolylineGeometry.js +7 -7
- package/Source/Core/SphereGeometry.js +2 -2
- package/Source/Core/SphereOutlineGeometry.js +3 -3
- package/Source/Core/Spline.js +1 -1
- package/Source/Core/SteppedSpline.js +1 -1
- package/Source/Core/Stereographic.js +9 -9
- package/Source/Core/TaskProcessor.js +13 -13
- package/Source/Core/TerrainEncoding.js +33 -38
- package/Source/Core/TerrainMesh.js +1 -1
- package/Source/Core/TerrainProvider.js +12 -12
- package/Source/Core/TileAvailability.js +28 -28
- package/Source/Core/TileProviderError.js +5 -5
- package/Source/Core/TilingScheme.js +1 -1
- package/Source/Core/TimeInterval.js +4 -4
- package/Source/Core/TimeIntervalCollection.js +16 -15
- package/Source/Core/Tipsify.js +2 -2
- package/Source/Core/Transforms.js +52 -54
- package/Source/Core/TranslationRotationScale.js +1 -1
- package/Source/Core/TridiagonalSystemSolver.js +4 -4
- package/Source/Core/VRTheWorldTerrainProvider.js +28 -26
- package/Source/Core/VertexFormat.js +6 -6
- package/Source/Core/VerticalExaggeration.js +4 -4
- package/Source/Core/VideoSynchronizer.js +1 -1
- package/Source/Core/WallGeometry.js +18 -18
- package/Source/Core/WallGeometryLibrary.js +7 -7
- package/Source/Core/WallOutlineGeometry.js +8 -8
- package/Source/Core/WebMercatorProjection.js +5 -6
- package/Source/Core/WebMercatorTilingScheme.js +13 -13
- package/Source/Core/WireframeIndexGenerator.js +8 -8
- package/Source/Core/arrayRemoveDuplicates.js +1 -1
- package/Source/Core/buildModuleUrl.js +2 -2
- package/Source/Core/decodeGoogleEarthEnterpriseData.js +3 -3
- package/Source/Core/decodeVectorPolylinePositions.js +4 -4
- package/Source/Core/destroyObject.js +1 -1
- package/Source/Core/getJsonFromTypedArray.js +1 -1
- package/Source/Core/getMagic.js +1 -1
- package/Source/Core/loadImageFromTypedArray.js +2 -2
- package/Source/Core/loadKTX2.js +1 -1
- package/Source/Core/pointInsideTriangle.js +1 -1
- package/Source/Core/resizeImageToNextPowerOfTwo.js +1 -1
- package/Source/Core/sampleTerrain.js +7 -7
- package/Source/Core/sampleTerrainMostDetailed.js +7 -7
- package/Source/Core/scaleToGeodeticSurface.js +3 -3
- package/Source/Core/srgbToLinear.js +1 -1
- package/Source/Core/writeTextToCanvas.js +1 -1
- package/Source/DataSources/BillboardGraphics.js +13 -13
- package/Source/DataSources/BillboardVisualizer.js +24 -24
- package/Source/DataSources/BoxGeometryUpdater.js +33 -32
- package/Source/DataSources/BoxGraphics.js +3 -3
- package/Source/DataSources/CallbackPositionProperty.js +173 -0
- package/Source/DataSources/CallbackProperty.js +8 -2
- package/Source/DataSources/Cesium3DTilesetGraphics.js +1 -1
- package/Source/DataSources/Cesium3DTilesetVisualizer.js +6 -6
- package/Source/DataSources/CheckerboardMaterialProperty.js +9 -3
- package/Source/DataSources/ColorMaterialProperty.js +8 -2
- package/Source/DataSources/CompositeEntityCollection.js +14 -15
- package/Source/DataSources/CompositeMaterialProperty.js +10 -11
- package/Source/DataSources/CompositePositionProperty.js +11 -6
- package/Source/DataSources/CompositeProperty.js +7 -7
- package/Source/DataSources/ConstantPositionProperty.js +9 -3
- package/Source/DataSources/CorridorGeometryUpdater.js +61 -56
- package/Source/DataSources/CorridorGraphics.js +6 -6
- package/Source/DataSources/CylinderGeometryUpdater.js +42 -40
- package/Source/DataSources/CylinderGraphics.js +4 -4
- package/Source/DataSources/CzmlDataSource.js +365 -368
- package/Source/DataSources/DataSourceCollection.js +1 -1
- package/Source/DataSources/DataSourceDisplay.js +23 -23
- package/Source/DataSources/DynamicGeometryBatch.js +2 -2
- package/Source/DataSources/DynamicGeometryUpdater.js +14 -18
- package/Source/DataSources/EllipseGeometryUpdater.js +67 -63
- package/Source/DataSources/EllipseGraphics.js +7 -7
- package/Source/DataSources/EllipsoidGeometryUpdater.js +88 -86
- package/Source/DataSources/EllipsoidGraphics.js +5 -5
- package/Source/DataSources/Entity.js +14 -14
- package/Source/DataSources/EntityCluster.js +29 -27
- package/Source/DataSources/EntityCollection.js +7 -7
- package/Source/DataSources/EntityView.js +23 -23
- package/Source/DataSources/GeoJsonDataSource.js +25 -25
- package/Source/DataSources/GeometryUpdater.js +9 -10
- package/Source/DataSources/GeometryUpdaterSet.js +3 -3
- package/Source/DataSources/GeometryVisualizer.js +65 -71
- package/Source/DataSources/GpxDataSource.js +10 -10
- package/Source/DataSources/GridMaterialProperty.js +12 -6
- package/Source/DataSources/GroundGeometryUpdater.js +6 -6
- package/Source/DataSources/ImageMaterialProperty.js +10 -3
- package/Source/DataSources/KmlDataSource.js +212 -212
- package/Source/DataSources/LabelGraphics.js +14 -14
- package/Source/DataSources/LabelVisualizer.js +24 -24
- package/Source/DataSources/MaterialProperty.js +7 -1
- package/Source/DataSources/ModelGraphics.js +37 -17
- package/Source/DataSources/ModelVisualizer.js +41 -32
- package/Source/DataSources/NodeTransformationProperty.js +10 -4
- package/Source/DataSources/PathGraphics.js +2 -2
- package/Source/DataSources/PathVisualizer.js +99 -35
- package/Source/DataSources/PlaneGeometryUpdater.js +38 -37
- package/Source/DataSources/PlaneGraphics.js +2 -2
- package/Source/DataSources/PointGraphics.js +8 -8
- package/Source/DataSources/PointVisualizer.js +29 -29
- package/Source/DataSources/PolygonGeometryUpdater.js +68 -64
- package/Source/DataSources/PolygonGraphics.js +9 -9
- package/Source/DataSources/PolylineArrowMaterialProperty.js +8 -2
- package/Source/DataSources/PolylineDashMaterialProperty.js +11 -5
- package/Source/DataSources/PolylineGeometryUpdater.js +39 -44
- package/Source/DataSources/PolylineGlowMaterialProperty.js +10 -4
- package/Source/DataSources/PolylineGraphics.js +4 -4
- package/Source/DataSources/PolylineOutlineMaterialProperty.js +10 -4
- package/Source/DataSources/PolylineVisualizer.js +39 -43
- package/Source/DataSources/PolylineVolumeGeometryUpdater.js +70 -68
- package/Source/DataSources/PolylineVolumeGraphics.js +2 -2
- package/Source/DataSources/PositionProperty.js +5 -4
- package/Source/DataSources/PositionPropertyArray.js +10 -4
- package/Source/DataSources/Property.js +2 -2
- package/Source/DataSources/PropertyArray.js +6 -6
- package/Source/DataSources/PropertyBag.js +10 -9
- package/Source/DataSources/RectangleGeometryUpdater.js +68 -63
- package/Source/DataSources/RectangleGraphics.js +6 -6
- package/Source/DataSources/ReferenceProperty.js +13 -7
- package/Source/DataSources/Rotation.js +2 -2
- package/Source/DataSources/SampledPositionProperty.js +13 -7
- package/Source/DataSources/SampledProperty.js +22 -20
- package/Source/DataSources/ScaledPositionProperty.js +8 -2
- package/Source/DataSources/StaticGeometryColorBatch.js +41 -41
- package/Source/DataSources/StaticGeometryPerMaterialBatch.js +40 -40
- package/Source/DataSources/StaticGroundGeometryColorBatch.js +26 -27
- package/Source/DataSources/StaticGroundGeometryPerMaterialBatch.js +46 -44
- package/Source/DataSources/StaticGroundPolylinePerMaterialBatch.js +44 -43
- package/Source/DataSources/StaticOutlineGeometryBatch.js +28 -29
- package/Source/DataSources/StripeMaterialProperty.js +9 -3
- package/Source/DataSources/TerrainOffsetProperty.js +20 -11
- package/Source/DataSources/TimeIntervalCollectionPositionProperty.js +35 -31
- package/Source/DataSources/TimeIntervalCollectionProperty.js +6 -6
- package/Source/DataSources/VelocityOrientationProperty.js +9 -4
- package/Source/DataSources/VelocityVectorProperty.js +7 -9
- package/Source/DataSources/WallGeometryUpdater.js +25 -25
- package/Source/DataSources/WallGraphics.js +4 -4
- package/Source/DataSources/createPropertyDescriptor.js +3 -3
- package/Source/DataSources/exportKml.js +90 -86
- package/Source/DataSources/getElement.js +1 -1
- package/Source/DataSources/heightReferenceOnEntityPropertyChanged.js +4 -4
- package/Source/Renderer/AutomaticUniforms.js +3 -18
- package/Source/Renderer/Buffer.js +18 -18
- package/Source/Renderer/ClearCommand.js +1 -1
- package/Source/Renderer/ComputeEngine.js +1 -1
- package/Source/Renderer/Context.js +55 -40
- package/Source/Renderer/CubeMap.js +332 -354
- package/Source/Renderer/CubeMapFace.js +43 -65
- package/Source/Renderer/DrawCommand.js +50 -5
- package/Source/Renderer/Framebuffer.js +48 -49
- package/Source/Renderer/FramebufferManager.js +40 -34
- package/Source/Renderer/MultisampleFramebuffer.js +35 -14
- package/Source/Renderer/PixelDatatype.js +23 -0
- package/Source/Renderer/RenderState.js +36 -36
- package/Source/Renderer/Renderbuffer.js +3 -3
- package/Source/Renderer/Sampler.js +9 -15
- package/Source/Renderer/ShaderBuilder.js +8 -8
- package/Source/Renderer/ShaderCache.js +11 -15
- package/Source/Renderer/ShaderFunction.js +1 -1
- package/Source/Renderer/ShaderProgram.js +22 -15
- package/Source/Renderer/ShaderSource.js +40 -40
- package/Source/Renderer/Texture.js +455 -380
- package/Source/Renderer/UniformState.js +68 -80
- package/Source/Renderer/VertexArray.js +20 -20
- package/Source/Renderer/VertexArrayFacade.js +15 -16
- package/Source/Renderer/createUniform.js +1 -1
- package/Source/Renderer/createUniformArray.js +4 -4
- package/Source/Renderer/demodernizeShader.js +7 -5
- package/Source/Renderer/loadCubeMap.js +3 -8
- package/Source/Scene/ArcGisMapServerImageryProvider.js +39 -45
- package/Source/Scene/ArcGisMapService.js +4 -7
- package/Source/Scene/AutoExposure.js +4 -5
- package/Source/Scene/Axis.js +6 -6
- package/Source/Scene/B3dmParser.js +9 -9
- package/Source/Scene/BatchTable.js +7 -7
- package/Source/Scene/BatchTableHierarchy.js +62 -59
- package/Source/Scene/BatchTexture.js +2 -2
- package/Source/Scene/Billboard.js +45 -43
- package/Source/Scene/BillboardCollection.js +81 -83
- package/Source/Scene/BingMapsImageryProvider.js +13 -13
- package/Source/Scene/BoundingVolumeSemantics.js +10 -10
- package/Source/Scene/BoxEmitter.js +1 -1
- package/Source/Scene/BufferLoader.js +1 -1
- package/Source/Scene/Camera.js +161 -164
- package/Source/Scene/CameraEventAggregator.js +67 -23
- package/Source/Scene/CameraFlightPath.js +25 -25
- package/Source/Scene/Cesium3DTile.js +89 -95
- package/Source/Scene/Cesium3DTileBatchTable.js +61 -61
- package/Source/Scene/Cesium3DTileContentFactory.js +7 -7
- package/Source/Scene/Cesium3DTileFeature.js +1 -1
- package/Source/Scene/Cesium3DTileFeatureTable.js +8 -8
- package/Source/Scene/Cesium3DTileOptimizations.js +1 -1
- package/Source/Scene/Cesium3DTilePointFeature.js +11 -11
- package/Source/Scene/Cesium3DTileStyle.js +26 -24
- package/Source/Scene/Cesium3DTilesVoxelProvider.js +14 -20
- package/Source/Scene/Cesium3DTileset.js +81 -83
- package/Source/Scene/Cesium3DTilesetBaseTraversal.js +8 -16
- package/Source/Scene/Cesium3DTilesetCache.js +2 -2
- package/Source/Scene/Cesium3DTilesetHeatmap.js +5 -5
- package/Source/Scene/Cesium3DTilesetMetadata.js +2 -2
- package/Source/Scene/Cesium3DTilesetMostDetailedTraversal.js +2 -2
- package/Source/Scene/Cesium3DTilesetSkipTraversal.js +8 -12
- package/Source/Scene/Cesium3DTilesetStatistics.js +1 -1
- package/Source/Scene/Cesium3DTilesetTraversal.js +8 -10
- package/Source/Scene/ClassificationPrimitive.js +70 -69
- package/Source/Scene/ClippingPlaneCollection.js +39 -41
- package/Source/Scene/ClippingPolygon.js +8 -8
- package/Source/Scene/ClippingPolygonCollection.js +62 -63
- package/Source/Scene/CloudCollection.js +3 -10
- package/Source/Scene/Composite3DTileContent.js +6 -6
- package/Source/Scene/ConditionsExpression.js +5 -5
- package/Source/Scene/ContentMetadata.js +4 -4
- package/Source/Scene/CreditDisplay.js +8 -8
- package/Source/Scene/CumulusCloud.js +4 -4
- package/Source/Scene/DebugAppearance.js +2 -2
- package/Source/Scene/DebugCameraPrimitive.js +2 -2
- package/Source/Scene/DebugInspector.js +3 -3
- package/Source/Scene/DebugModelMatrixPrimitive.js +4 -4
- package/Source/Scene/DepthPlane.js +7 -7
- package/Source/Scene/DerivedCommand.js +422 -238
- package/Source/Scene/DiscardMissingTileImagePolicy.js +1 -1
- package/Source/Scene/DracoLoader.js +3 -3
- package/Source/Scene/EllipsoidPrimitive.js +7 -7
- package/Source/Scene/EllipsoidSurfaceAppearance.js +3 -3
- package/Source/Scene/Empty3DTileContent.js +1 -1
- package/Source/Scene/Expression.js +91 -91
- package/Source/Scene/Fog.js +8 -41
- package/Source/Scene/FrameRateMonitor.js +22 -22
- package/Source/Scene/FrameState.js +31 -0
- package/Source/Scene/Geometry3DTileContent.js +20 -20
- package/Source/Scene/GetFeatureInfoFormat.js +15 -14
- package/Source/Scene/Globe.js +33 -28
- package/Source/Scene/GlobeDepth.js +95 -66
- package/Source/Scene/GlobeSurfaceShaderSet.js +41 -34
- package/Source/Scene/GlobeSurfaceTile.js +33 -33
- package/Source/Scene/GlobeSurfaceTileProvider.js +132 -127
- package/Source/Scene/GlobeTranslucency.js +4 -4
- package/Source/Scene/GlobeTranslucencyFramebuffer.js +9 -9
- package/Source/Scene/GlobeTranslucencyState.js +53 -55
- package/Source/Scene/GltfBufferViewLoader.js +2 -2
- package/Source/Scene/GltfIndexBufferLoader.js +5 -5
- package/Source/Scene/GltfJsonLoader.js +2 -2
- package/Source/Scene/GltfLoader.js +177 -100
- package/Source/Scene/GltfStructuralMetadataLoader.js +9 -8
- package/Source/Scene/GltfTextureLoader.js +5 -5
- package/Source/Scene/GltfVertexBufferLoader.js +12 -13
- package/Source/Scene/GoogleEarthEnterpriseImageryProvider.js +9 -9
- package/Source/Scene/GoogleEarthEnterpriseMapsProvider.js +9 -9
- package/Source/Scene/GridImageryProvider.js +2 -2
- package/Source/Scene/GroundPolylinePrimitive.js +38 -39
- package/Source/Scene/GroundPrimitive.js +47 -45
- package/Source/Scene/GroupMetadata.js +4 -4
- package/Source/Scene/I3SDataProvider.js +12 -12
- package/Source/Scene/I3SDecoder.js +7 -8
- package/Source/Scene/I3SField.js +8 -8
- package/Source/Scene/I3SGeometry.js +14 -14
- package/Source/Scene/I3SLayer.js +26 -20
- package/Source/Scene/I3SNode.js +17 -17
- package/Source/Scene/I3SSublayer.js +4 -4
- package/Source/Scene/I3SSymbology.js +8 -8
- package/Source/Scene/I3dmParser.js +9 -9
- package/Source/Scene/ImageBasedLighting.js +58 -56
- package/Source/Scene/Imagery.js +3 -3
- package/Source/Scene/ImageryLayer.js +64 -66
- package/Source/Scene/ImageryLayerCollection.js +13 -15
- package/Source/Scene/ImageryLayerFeatureInfo.js +19 -20
- package/Source/Scene/ImageryProvider.js +1 -1
- package/Source/Scene/Implicit3DTileContent.js +34 -37
- package/Source/Scene/ImplicitAvailabilityBitstream.js +2 -2
- package/Source/Scene/ImplicitMetadataView.js +2 -2
- package/Source/Scene/ImplicitSubtree.js +29 -30
- package/Source/Scene/ImplicitSubtreeCache.js +1 -1
- package/Source/Scene/ImplicitSubtreeMetadata.js +5 -5
- package/Source/Scene/ImplicitTileCoordinates.js +11 -11
- package/Source/Scene/ImplicitTileset.js +2 -2
- package/Source/Scene/InvertClassification.js +7 -7
- package/Source/Scene/IonImageryProvider.js +6 -6
- package/Source/Scene/JobScheduler.js +4 -4
- package/Source/Scene/Label.js +31 -31
- package/Source/Scene/LabelCollection.js +17 -15
- package/Source/Scene/MapboxImageryProvider.js +3 -3
- package/Source/Scene/MapboxStyleImageryProvider.js +4 -4
- package/Source/Scene/Material.js +50 -29
- package/Source/Scene/MaterialAppearance.js +4 -4
- package/Source/Scene/Megatexture.js +21 -24
- package/Source/Scene/MetadataClassProperty.js +11 -11
- package/Source/Scene/MetadataComponentType.js +1 -1
- package/Source/Scene/MetadataEntity.js +8 -8
- package/Source/Scene/MetadataEnum.js +1 -1
- package/Source/Scene/MetadataPicking.js +305 -0
- package/Source/Scene/MetadataSchemaLoader.js +1 -1
- package/Source/Scene/MetadataTable.js +2 -2
- package/Source/Scene/MetadataTableProperty.js +22 -22
- package/Source/Scene/Model/AlphaPipelineStage.js +2 -2
- package/Source/Scene/Model/AtmospherePipelineStage.js +3 -3
- package/Source/Scene/Model/B3dmLoader.js +8 -8
- package/Source/Scene/Model/BatchTexturePipelineStage.js +2 -2
- package/Source/Scene/Model/CPUStylingPipelineStage.js +4 -4
- package/Source/Scene/Model/ClassificationModelDrawCommand.js +8 -8
- package/Source/Scene/Model/ClassificationPipelineStage.js +5 -5
- package/Source/Scene/Model/CustomShader.js +9 -9
- package/Source/Scene/Model/CustomShaderPipelineStage.js +37 -38
- package/Source/Scene/Model/DequantizationPipelineStage.js +5 -5
- package/Source/Scene/Model/Extensions/Gpm/AnchorPointDirect.js +61 -0
- package/Source/Scene/Model/Extensions/Gpm/AnchorPointIndirect.js +77 -0
- package/Source/Scene/Model/Extensions/Gpm/CorrelationGroup.js +81 -0
- package/Source/Scene/Model/Extensions/Gpm/GltfGpmLoader.js +248 -0
- package/Source/Scene/Model/Extensions/Gpm/GltfGpmLocal.js +179 -0
- package/Source/Scene/Model/Extensions/Gpm/GltfMeshPrimitiveGpmLoader.js +548 -0
- package/Source/Scene/Model/Extensions/Gpm/MeshPrimitiveGpmLocal.js +28 -0
- package/Source/Scene/Model/Extensions/Gpm/PpeMetadata.js +79 -0
- package/Source/Scene/Model/Extensions/Gpm/PpeSource.js +75 -0
- package/Source/Scene/Model/Extensions/Gpm/PpeTexture.js +127 -0
- package/Source/Scene/Model/Extensions/Gpm/Spdcf.js +103 -0
- package/Source/Scene/Model/Extensions/Gpm/StorageType.js +30 -0
- package/Source/Scene/Model/FeatureIdPipelineStage.js +40 -40
- package/Source/Scene/Model/GeoJsonLoader.js +17 -17
- package/Source/Scene/Model/GeometryPipelineStage.js +23 -24
- package/Source/Scene/Model/I3dmLoader.js +36 -36
- package/Source/Scene/Model/ImageBasedLightingPipelineStage.js +22 -30
- package/Source/Scene/Model/InstancingPipelineStage.js +86 -86
- package/Source/Scene/Model/LightingPipelineStage.js +4 -4
- package/Source/Scene/Model/MaterialPipelineStage.js +78 -93
- package/Source/Scene/Model/MetadataPickingPipelineStage.js +96 -0
- package/Source/Scene/Model/MetadataPipelineStage.js +39 -47
- package/Source/Scene/Model/Model.js +134 -54
- package/Source/Scene/Model/Model3DTileContent.js +32 -13
- package/Source/Scene/Model/ModelAnimationChannel.js +2 -2
- package/Source/Scene/Model/ModelAnimationCollection.js +9 -9
- package/Source/Scene/Model/ModelArticulation.js +2 -2
- package/Source/Scene/Model/ModelArticulationStage.js +4 -4
- package/Source/Scene/Model/ModelClippingPlanesPipelineStage.js +11 -11
- package/Source/Scene/Model/ModelClippingPolygonsPipelineStage.js +6 -6
- package/Source/Scene/Model/ModelColorPipelineStage.js +12 -13
- package/Source/Scene/Model/ModelDrawCommand.js +5 -5
- package/Source/Scene/Model/{buildDrawCommand.js → ModelDrawCommands.js} +85 -28
- package/Source/Scene/Model/ModelFeatureTable.js +5 -5
- package/Source/Scene/Model/ModelMatrixUpdateStage.js +24 -12
- package/Source/Scene/Model/ModelRenderResources.js +1 -1
- package/Source/Scene/Model/ModelRuntimeNode.js +15 -15
- package/Source/Scene/Model/ModelRuntimePrimitive.js +8 -5
- package/Source/Scene/Model/ModelSceneGraph.js +42 -43
- package/Source/Scene/Model/ModelSilhouettePipelineStage.js +4 -4
- package/Source/Scene/Model/ModelSkin.js +4 -4
- package/Source/Scene/Model/ModelSplitterPipelineStage.js +8 -9
- package/Source/Scene/Model/ModelUtility.js +5 -5
- package/Source/Scene/Model/MorphTargetsPipelineStage.js +18 -18
- package/Source/Scene/Model/NodeRenderResources.js +1 -1
- package/Source/Scene/Model/NodeStatisticsPipelineStage.js +1 -1
- package/Source/Scene/Model/PickingPipelineStage.js +5 -5
- package/Source/Scene/Model/PntsLoader.js +7 -7
- package/Source/Scene/Model/PointCloudStylingPipelineStage.js +22 -23
- package/Source/Scene/Model/PrimitiveOutlineGenerator.js +6 -6
- package/Source/Scene/Model/PrimitiveOutlinePipelineStage.js +7 -7
- package/Source/Scene/Model/PrimitiveRenderResources.js +3 -3
- package/Source/Scene/Model/PrimitiveStatisticsPipelineStage.js +1 -1
- package/Source/Scene/Model/SceneMode2DPipelineStage.js +23 -23
- package/Source/Scene/Model/SelectedFeatureIdPipelineStage.js +10 -14
- package/Source/Scene/Model/SkinningPipelineStage.js +5 -5
- package/Source/Scene/Model/StyleCommandsNeeded.js +1 -1
- package/Source/Scene/Model/TextureManager.js +2 -2
- package/Source/Scene/Model/TextureUniform.js +3 -3
- package/Source/Scene/Model/TilesetPipelineStage.js +2 -2
- package/Source/Scene/Model/VerticalExaggerationPipelineStage.js +4 -4
- package/Source/Scene/Model/WireframePipelineStage.js +7 -7
- package/Source/Scene/Model/pickModel.js +26 -26
- package/Source/Scene/ModelComponents.js +13 -4
- package/Source/Scene/Moon.js +6 -5
- package/Source/Scene/Multiple3DTileContent.js +15 -14
- package/Source/Scene/OIT.js +48 -97
- package/Source/Scene/OpenStreetMapImageryProvider.js +8 -7
- package/Source/Scene/OrderedGroundPrimitiveCollection.js +2 -2
- package/Source/Scene/Particle.js +3 -3
- package/Source/Scene/ParticleEmitter.js +1 -1
- package/Source/Scene/ParticleSystem.js +32 -32
- package/Source/Scene/PerInstanceColorAppearance.js +1 -1
- package/Source/Scene/PickDepth.js +16 -4
- package/Source/Scene/PickDepthFramebuffer.js +1 -1
- package/Source/Scene/PickFramebuffer.js +24 -12
- package/Source/Scene/PickedMetadataInfo.js +39 -0
- package/Source/Scene/Picking.js +270 -120
- package/Source/Scene/PntsParser.js +28 -28
- package/Source/Scene/PointCloud.js +39 -38
- package/Source/Scene/PointCloudEyeDomeLighting.js +6 -6
- package/Source/Scene/PointCloudShading.js +3 -3
- package/Source/Scene/PointPrimitive.js +31 -28
- package/Source/Scene/PointPrimitiveCollection.js +34 -33
- package/Source/Scene/Polyline.js +9 -9
- package/Source/Scene/PolylineCollection.js +55 -57
- package/Source/Scene/PolylineColorAppearance.js +3 -3
- package/Source/Scene/PolylineMaterialAppearance.js +3 -3
- package/Source/Scene/PostProcessStage.js +95 -115
- package/Source/Scene/PostProcessStageCollection.js +73 -49
- package/Source/Scene/PostProcessStageComposite.js +2 -2
- package/Source/Scene/PostProcessStageLibrary.js +30 -4
- package/Source/Scene/PostProcessStageTextureCache.js +10 -10
- package/Source/Scene/Primitive.js +93 -93
- package/Source/Scene/PrimitiveCollection.js +1 -1
- package/Source/Scene/PrimitiveLoadPlan.js +1 -1
- package/Source/Scene/PrimitivePipeline.js +30 -30
- package/Source/Scene/PropertyTable.js +5 -5
- package/Source/Scene/PropertyTextureProperty.js +36 -7
- package/Source/Scene/QuadtreePrimitive.js +56 -58
- package/Source/Scene/QuadtreeTile.js +4 -4
- package/Source/Scene/QuadtreeTileProvider.js +1 -1
- package/Source/Scene/ResourceCache.js +7 -7
- package/Source/Scene/ResourceCacheKey.js +15 -15
- package/Source/Scene/Scene.js +897 -677
- package/Source/Scene/SceneFramebuffer.js +2 -2
- package/Source/Scene/SceneTransforms.js +30 -92
- package/Source/Scene/SceneTransitioner.js +47 -47
- package/Source/Scene/ScreenSpaceCameraController.js +171 -157
- package/Source/Scene/SensorVolumePortionToDisplay.js +1 -1
- package/Source/Scene/ShadowMap.js +71 -72
- package/Source/Scene/ShadowMapShader.js +9 -9
- package/Source/Scene/ShadowVolumeAppearance.js +39 -39
- package/Source/Scene/SingleTileImageryProvider.js +3 -3
- package/Source/Scene/SkyAtmosphere.js +8 -8
- package/Source/Scene/SkyBox.js +17 -24
- package/Source/Scene/SpatialNode.js +13 -13
- package/Source/Scene/SpecularEnvironmentCubeMap.js +240 -0
- package/Source/Scene/SphereEmitter.js +1 -1
- package/Source/Scene/StructuralMetadata.js +1 -1
- package/Source/Scene/StyleExpression.js +1 -1
- package/Source/Scene/Sun.js +11 -7
- package/Source/Scene/SunPostProcess.js +6 -6
- package/Source/Scene/TerrainFillMesh.js +157 -156
- package/Source/Scene/TextureAtlas.js +11 -11
- package/Source/Scene/TileBoundingRegion.js +31 -31
- package/Source/Scene/TileBoundingS2Cell.js +37 -40
- package/Source/Scene/TileBoundingSphere.js +2 -2
- package/Source/Scene/TileCoordinatesImageryProvider.js +3 -3
- package/Source/Scene/TileImagery.js +7 -11
- package/Source/Scene/TileMapServiceImageryProvider.js +26 -25
- package/Source/Scene/TileMetadata.js +4 -4
- package/Source/Scene/TileOrientedBoundingBox.js +6 -6
- package/Source/Scene/Tileset3DTileContent.js +1 -1
- package/Source/Scene/TilesetMetadata.js +4 -4
- package/Source/Scene/TimeDynamicImagery.js +3 -3
- package/Source/Scene/TimeDynamicPointCloud.js +9 -9
- package/Source/Scene/Tonemapper.js +35 -23
- package/Source/Scene/TranslucentTileClassification.js +48 -58
- package/Source/Scene/TweenCollection.js +9 -9
- package/Source/Scene/UrlTemplateImageryProvider.js +23 -23
- package/Source/Scene/Vector3DTileClampedPolylines.js +21 -21
- package/Source/Scene/Vector3DTileContent.js +38 -39
- package/Source/Scene/Vector3DTileGeometry.js +11 -8
- package/Source/Scene/Vector3DTilePoints.js +18 -22
- package/Source/Scene/Vector3DTilePolygons.js +6 -6
- package/Source/Scene/Vector3DTilePolylines.js +8 -8
- package/Source/Scene/Vector3DTilePrimitive.js +30 -31
- package/Source/Scene/View.js +111 -80
- package/Source/Scene/VoxelBoxShape.js +34 -34
- package/Source/Scene/VoxelCell.js +7 -7
- package/Source/Scene/VoxelContent.js +1 -1
- package/Source/Scene/VoxelCylinderShape.js +48 -48
- package/Source/Scene/VoxelEllipsoidShape.js +83 -97
- package/Source/Scene/VoxelPrimitive.js +80 -109
- package/Source/Scene/VoxelRenderResources.js +13 -16
- package/Source/Scene/VoxelTraversal.js +41 -41
- package/Source/Scene/WebMapServiceImageryProvider.js +12 -12
- package/Source/Scene/WebMapTileServiceImageryProvider.js +8 -8
- package/Source/Scene/buildVoxelDrawCommands.js +10 -14
- package/Source/Scene/computeFlyToLocationForRectangle.js +7 -5
- package/Source/Scene/createBillboardPointCallback.js +2 -2
- package/Source/Scene/createElevationBandMaterial.js +8 -8
- package/Source/Scene/createGooglePhotorealistic3DTileset.js +1 -1
- package/Source/Scene/createOsmBuildingsAsync.js +1 -1
- package/Source/Scene/createTangentSpaceDebugPrimitive.js +7 -7
- package/Source/Scene/findContentMetadata.js +2 -2
- package/Source/Scene/findTileMetadata.js +2 -2
- package/Source/Scene/getBinaryAccessor.js +1 -1
- package/Source/Scene/getClipAndStyleCode.js +1 -1
- package/Source/Scene/getClippingFunction.js +1 -1
- package/Source/Scene/getMetadataClassProperty.js +43 -0
- package/Source/Scene/parseBatchTable.js +21 -24
- package/Source/Scene/parseFeatureMetadataLegacy.js +3 -3
- package/Source/Scene/parseStructuralMetadata.js +3 -3
- package/Source/Scene/processVoxelProperties.js +28 -33
- package/Source/Shaders/Builtin/CzmBuiltins.js +2 -2
- package/Source/Shaders/Builtin/Functions/packDepth.glsl +2 -2
- package/Source/Shaders/Builtin/Functions/packDepth.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/Functions/unpackDepth.glsl +3 -3
- package/Source/Shaders/Builtin/Functions/unpackDepth.js +3 -3
- package/Source/Shaders/Builtin/Functions/windowToEyeCoordinates.glsl +1 -1
- package/Source/Shaders/Builtin/Functions/windowToEyeCoordinates.js +1 -1
- package/Source/Shaders/Builtin/Functions/writeLogDepth.glsl +2 -2
- package/Source/Shaders/Builtin/Functions/writeLogDepth.js +2 -2
- package/Source/Shaders/Builtin/Structs/materialInput.glsl +2 -0
- package/Source/Shaders/Builtin/Structs/materialInput.js +2 -0
- package/Source/Shaders/DepthPlaneVS.glsl +1 -1
- package/Source/Shaders/DepthPlaneVS.js +1 -1
- 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/Model/ModelFS.glsl +26 -0
- package/Source/Shaders/Model/ModelFS.js +26 -0
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.glsl +4 -0
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.js +4 -0
- package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.glsl +59 -59
- package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.js +60 -60
- 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 +10 -9
- package/Source/Workers/combineGeometry.js +3 -4
- package/Source/Workers/createCircleGeometry.js +2 -2
- package/Source/Workers/createCircleOutlineGeometry.js +2 -2
- package/Source/Workers/createCoplanarPolygonOutlineGeometry.js +1 -1
- package/Source/Workers/createCorridorOutlineGeometry.js +2 -2
- package/Source/Workers/createEllipsoidOutlineGeometry.js +1 -1
- package/Source/Workers/createGeometry.js +4 -5
- package/Source/Workers/createGroundPolylineGeometry.js +1 -1
- package/Source/Workers/createPolylineVolumeGeometry.js +2 -2
- package/Source/Workers/createPolylineVolumeOutlineGeometry.js +4 -4
- package/Source/Workers/createRectangleOutlineGeometry.js +1 -1
- package/Source/Workers/createSimplePolylineGeometry.js +2 -2
- package/Source/Workers/createTaskProcessorWorker.js +1 -1
- package/Source/Workers/createVectorTileClampedPolylines.js +30 -30
- package/Source/Workers/createVectorTileGeometries.js +18 -18
- package/Source/Workers/createVectorTilePoints.js +3 -3
- package/Source/Workers/createVectorTilePolygons.js +11 -11
- package/Source/Workers/createVectorTilePolylines.js +7 -7
- package/Source/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +29 -30
- package/Source/Workers/createVerticesFromQuantizedTerrainMesh.js +60 -60
- package/Source/Workers/decodeDraco.js +23 -23
- package/Source/Workers/decodeGoogleEarthEnterprisePacket.js +3 -3
- package/Source/Workers/decodeI3S.js +53 -53
- package/Source/Workers/transcodeKTX2.js +9 -9
- package/Source/Workers/transferTypedArrayTest.js +1 -1
- package/Source/Workers/upsampleQuantizedTerrainMesh.js +37 -36
- package/index.d.ts +620 -136
- package/index.js +221 -205
- package/package.json +3 -3
- package/Build/Workers/chunk-2GEAGYUY.js +0 -1477
- 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-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
|
@@ -137,6 +137,14 @@ function ScreenSpaceCameraController(scene) {
|
|
|
137
137
|
* @default {@link Number.POSITIVE_INFINITY}
|
|
138
138
|
*/
|
|
139
139
|
this.maximumZoomDistance = Number.POSITIVE_INFINITY;
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* A multiplier for the speed at which the camera will zoom.
|
|
143
|
+
* @type {Number}
|
|
144
|
+
* @default 5.0
|
|
145
|
+
*/
|
|
146
|
+
this.zoomFactor = 5.0;
|
|
147
|
+
|
|
140
148
|
/**
|
|
141
149
|
* The input that allows the user to pan around the map. This only applies in 2D and Columbus view modes.
|
|
142
150
|
* <p>
|
|
@@ -234,7 +242,7 @@ function ScreenSpaceCameraController(scene) {
|
|
|
234
242
|
* @default 4000.0 or scene.ellipsoid.minimumRadius * 0.00063
|
|
235
243
|
*/
|
|
236
244
|
this.minimumPickingTerrainDistanceWithInertia = Ellipsoid.WGS84.equals(
|
|
237
|
-
ellipsoid
|
|
245
|
+
ellipsoid,
|
|
238
246
|
)
|
|
239
247
|
? 4000.0
|
|
240
248
|
: ellipsoid.minimumRadius * 0.00063;
|
|
@@ -320,11 +328,10 @@ function ScreenSpaceCameraController(scene) {
|
|
|
320
328
|
|
|
321
329
|
const projection = scene.mapProjection;
|
|
322
330
|
this._maxCoord = projection.project(
|
|
323
|
-
new Cartographic(Math.PI, CesiumMath.PI_OVER_TWO)
|
|
331
|
+
new Cartographic(Math.PI, CesiumMath.PI_OVER_TWO),
|
|
324
332
|
);
|
|
325
333
|
|
|
326
334
|
// Constants, Make any of these public?
|
|
327
|
-
this._zoomFactor = 5.0;
|
|
328
335
|
this._rotateFactor = undefined;
|
|
329
336
|
this._rotateRateRangeAdjustment = undefined;
|
|
330
337
|
this._maximumRotateRate = 1.77;
|
|
@@ -348,7 +355,7 @@ function sameMousePosition(movement) {
|
|
|
348
355
|
return Cartesian2.equalsEpsilon(
|
|
349
356
|
movement.startPosition,
|
|
350
357
|
movement.endPosition,
|
|
351
|
-
CesiumMath.EPSILON14
|
|
358
|
+
CesiumMath.EPSILON14,
|
|
352
359
|
);
|
|
353
360
|
}
|
|
354
361
|
|
|
@@ -365,7 +372,7 @@ function maintainInertia(
|
|
|
365
372
|
decayCoef,
|
|
366
373
|
action,
|
|
367
374
|
object,
|
|
368
|
-
lastMovementName
|
|
375
|
+
lastMovementName,
|
|
369
376
|
) {
|
|
370
377
|
let movementState = object[lastMovementName];
|
|
371
378
|
if (!defined(movementState)) {
|
|
@@ -403,18 +410,18 @@ function maintainInertia(
|
|
|
403
410
|
|
|
404
411
|
movementState.startPosition = Cartesian2.clone(
|
|
405
412
|
lastMovement.startPosition,
|
|
406
|
-
movementState.startPosition
|
|
413
|
+
movementState.startPosition,
|
|
407
414
|
);
|
|
408
415
|
|
|
409
416
|
movementState.endPosition = Cartesian2.multiplyByScalar(
|
|
410
417
|
movementState.motion,
|
|
411
418
|
d,
|
|
412
|
-
movementState.endPosition
|
|
419
|
+
movementState.endPosition,
|
|
413
420
|
);
|
|
414
421
|
movementState.endPosition = Cartesian2.add(
|
|
415
422
|
movementState.startPosition,
|
|
416
423
|
movementState.endPosition,
|
|
417
|
-
movementState.endPosition
|
|
424
|
+
movementState.endPosition,
|
|
418
425
|
);
|
|
419
426
|
|
|
420
427
|
// If value from the decreasing exponential function is close to zero,
|
|
@@ -424,7 +431,7 @@ function maintainInertia(
|
|
|
424
431
|
isNaN(movementState.endPosition.y) ||
|
|
425
432
|
Cartesian2.distance(
|
|
426
433
|
movementState.startPosition,
|
|
427
|
-
movementState.endPosition
|
|
434
|
+
movementState.endPosition,
|
|
428
435
|
) < 0.5
|
|
429
436
|
) {
|
|
430
437
|
return;
|
|
@@ -466,7 +473,7 @@ function reactToInput(
|
|
|
466
473
|
eventTypes,
|
|
467
474
|
action,
|
|
468
475
|
inertiaConstant,
|
|
469
|
-
inertiaStateName
|
|
476
|
+
inertiaStateName,
|
|
470
477
|
) {
|
|
471
478
|
if (!defined(eventTypes)) {
|
|
472
479
|
return;
|
|
@@ -502,7 +509,7 @@ function reactToInput(
|
|
|
502
509
|
inertiaConstant,
|
|
503
510
|
action,
|
|
504
511
|
controller,
|
|
505
|
-
inertiaStateName
|
|
512
|
+
inertiaStateName,
|
|
506
513
|
);
|
|
507
514
|
}
|
|
508
515
|
}
|
|
@@ -544,14 +551,14 @@ function handleZoom(
|
|
|
544
551
|
movement,
|
|
545
552
|
zoomFactor,
|
|
546
553
|
distanceMeasure,
|
|
547
|
-
unitPositionDotDirection
|
|
554
|
+
unitPositionDotDirection,
|
|
548
555
|
) {
|
|
549
556
|
let percentage = 1.0;
|
|
550
557
|
if (defined(unitPositionDotDirection)) {
|
|
551
558
|
percentage = CesiumMath.clamp(
|
|
552
559
|
Math.abs(unitPositionDotDirection),
|
|
553
560
|
0.25,
|
|
554
|
-
1.0
|
|
561
|
+
1.0,
|
|
555
562
|
);
|
|
556
563
|
}
|
|
557
564
|
|
|
@@ -570,7 +577,7 @@ function handleZoom(
|
|
|
570
577
|
zoomRate = CesiumMath.clamp(
|
|
571
578
|
zoomRate,
|
|
572
579
|
object._minimumZoomRate,
|
|
573
|
-
object._maximumZoomRate
|
|
580
|
+
object._maximumZoomRate,
|
|
574
581
|
);
|
|
575
582
|
|
|
576
583
|
let rangeWindowRatio = diff / object._scene.canvas.clientHeight;
|
|
@@ -616,7 +623,7 @@ function handleZoom(
|
|
|
616
623
|
|
|
617
624
|
const sameStartPosition = defaultValue(
|
|
618
625
|
movement.inertiaEnabled,
|
|
619
|
-
Cartesian2.equals(startPosition, object._zoomMouseStart)
|
|
626
|
+
Cartesian2.equals(startPosition, object._zoomMouseStart),
|
|
620
627
|
);
|
|
621
628
|
let zoomingOnVector = object._zoomingOnVector;
|
|
622
629
|
let rotatingZoom = object._rotatingZoom;
|
|
@@ -625,23 +632,25 @@ function handleZoom(
|
|
|
625
632
|
if (!sameStartPosition) {
|
|
626
633
|
object._zoomMouseStart = Cartesian2.clone(
|
|
627
634
|
startPosition,
|
|
628
|
-
object._zoomMouseStart
|
|
635
|
+
object._zoomMouseStart,
|
|
629
636
|
);
|
|
630
637
|
|
|
631
638
|
// When camera transform is set, such as tracking an entity, object._globe will be undefined, and no position should be picked
|
|
632
639
|
if (defined(object._globe) && mode === SceneMode.SCENE2D) {
|
|
633
|
-
pickedPosition = camera.getPickRay(
|
|
634
|
-
|
|
640
|
+
pickedPosition = camera.getPickRay(
|
|
641
|
+
startPosition,
|
|
642
|
+
scratchZoomPickRay,
|
|
643
|
+
).origin;
|
|
635
644
|
pickedPosition = Cartesian3.fromElements(
|
|
636
645
|
pickedPosition.y,
|
|
637
646
|
pickedPosition.z,
|
|
638
|
-
pickedPosition.x
|
|
647
|
+
pickedPosition.x,
|
|
639
648
|
);
|
|
640
649
|
} else if (defined(object._globe)) {
|
|
641
650
|
pickedPosition = pickPosition(
|
|
642
651
|
object,
|
|
643
652
|
startPosition,
|
|
644
|
-
scratchPickCartesian
|
|
653
|
+
scratchPickCartesian,
|
|
645
654
|
);
|
|
646
655
|
}
|
|
647
656
|
|
|
@@ -649,7 +658,7 @@ function handleZoom(
|
|
|
649
658
|
object._useZoomWorldPosition = true;
|
|
650
659
|
object._zoomWorldPosition = Cartesian3.clone(
|
|
651
660
|
pickedPosition,
|
|
652
|
-
object._zoomWorldPosition
|
|
661
|
+
object._zoomWorldPosition,
|
|
653
662
|
);
|
|
654
663
|
} else {
|
|
655
664
|
object._useZoomWorldPosition = false;
|
|
@@ -685,7 +694,7 @@ function handleZoom(
|
|
|
685
694
|
const direction = Cartesian3.subtract(
|
|
686
695
|
worldPosition,
|
|
687
696
|
endPosition,
|
|
688
|
-
scratchZoomDirection
|
|
697
|
+
scratchZoomDirection,
|
|
689
698
|
);
|
|
690
699
|
Cartesian3.normalize(direction, direction);
|
|
691
700
|
|
|
@@ -698,23 +707,25 @@ function handleZoom(
|
|
|
698
707
|
(camera.position.x < 0.0 && savedX > 0.0) ||
|
|
699
708
|
(camera.position.x > 0.0 && savedX < 0.0)
|
|
700
709
|
) {
|
|
701
|
-
pickedPosition = camera.getPickRay(
|
|
702
|
-
|
|
710
|
+
pickedPosition = camera.getPickRay(
|
|
711
|
+
startPosition,
|
|
712
|
+
scratchZoomPickRay,
|
|
713
|
+
).origin;
|
|
703
714
|
pickedPosition = Cartesian3.fromElements(
|
|
704
715
|
pickedPosition.y,
|
|
705
716
|
pickedPosition.z,
|
|
706
|
-
pickedPosition.x
|
|
717
|
+
pickedPosition.x,
|
|
707
718
|
);
|
|
708
719
|
object._zoomWorldPosition = Cartesian3.clone(
|
|
709
720
|
pickedPosition,
|
|
710
|
-
object._zoomWorldPosition
|
|
721
|
+
object._zoomWorldPosition,
|
|
711
722
|
);
|
|
712
723
|
}
|
|
713
724
|
}
|
|
714
725
|
} else if (mode === SceneMode.SCENE3D) {
|
|
715
726
|
const cameraPositionNormal = Cartesian3.normalize(
|
|
716
727
|
camera.position,
|
|
717
|
-
scratchCameraPositionNormal
|
|
728
|
+
scratchCameraPositionNormal,
|
|
718
729
|
);
|
|
719
730
|
if (
|
|
720
731
|
object._cameraUnderground ||
|
|
@@ -733,7 +744,7 @@ function handleZoom(
|
|
|
733
744
|
const centerPosition = pickPosition(
|
|
734
745
|
object,
|
|
735
746
|
centerPixel,
|
|
736
|
-
scratchCenterPosition
|
|
747
|
+
scratchCenterPosition,
|
|
737
748
|
);
|
|
738
749
|
// If centerPosition is not defined, it means the globe does not cover the center position of screen
|
|
739
750
|
|
|
@@ -765,7 +776,7 @@ function handleZoom(
|
|
|
765
776
|
Cartesian3.add(
|
|
766
777
|
cameraPosition,
|
|
767
778
|
Cartesian3.multiplyByScalar(forward, 1000, scratchCartesian),
|
|
768
|
-
center
|
|
779
|
+
center,
|
|
769
780
|
);
|
|
770
781
|
|
|
771
782
|
const positionToTarget = scratchPositionToTarget;
|
|
@@ -776,7 +787,7 @@ function handleZoom(
|
|
|
776
787
|
|
|
777
788
|
const alphaDot = Cartesian3.dot(
|
|
778
789
|
cameraPositionNormal,
|
|
779
|
-
positionToTargetNormal
|
|
790
|
+
positionToTargetNormal,
|
|
780
791
|
);
|
|
781
792
|
if (alphaDot >= 0.0) {
|
|
782
793
|
// We zoomed past the target, and this zoom is not valid anymore.
|
|
@@ -788,23 +799,22 @@ function handleZoom(
|
|
|
788
799
|
const cameraDistance = Cartesian3.magnitude(cameraPosition);
|
|
789
800
|
const targetDistance = Cartesian3.magnitude(target);
|
|
790
801
|
const remainingDistance = cameraDistance - distance;
|
|
791
|
-
const positionToTargetDistance =
|
|
792
|
-
positionToTarget
|
|
793
|
-
);
|
|
802
|
+
const positionToTargetDistance =
|
|
803
|
+
Cartesian3.magnitude(positionToTarget);
|
|
794
804
|
|
|
795
805
|
const gamma = Math.asin(
|
|
796
806
|
CesiumMath.clamp(
|
|
797
807
|
(positionToTargetDistance / targetDistance) * Math.sin(alpha),
|
|
798
808
|
-1.0,
|
|
799
|
-
1.0
|
|
800
|
-
)
|
|
809
|
+
1.0,
|
|
810
|
+
),
|
|
801
811
|
);
|
|
802
812
|
const delta = Math.asin(
|
|
803
813
|
CesiumMath.clamp(
|
|
804
814
|
(remainingDistance / targetDistance) * Math.sin(alpha),
|
|
805
815
|
-1.0,
|
|
806
|
-
1.0
|
|
807
|
-
)
|
|
816
|
+
1.0,
|
|
817
|
+
),
|
|
808
818
|
);
|
|
809
819
|
const beta = gamma - delta + alpha;
|
|
810
820
|
|
|
@@ -816,20 +826,20 @@ function handleZoom(
|
|
|
816
826
|
|
|
817
827
|
Cartesian3.normalize(
|
|
818
828
|
Cartesian3.cross(up, right, scratchCartesian),
|
|
819
|
-
forward
|
|
829
|
+
forward,
|
|
820
830
|
);
|
|
821
831
|
|
|
822
832
|
// Calculate new position to move to
|
|
823
833
|
Cartesian3.multiplyByScalar(
|
|
824
834
|
Cartesian3.normalize(center, scratchCartesian),
|
|
825
835
|
Cartesian3.magnitude(center) - distance,
|
|
826
|
-
center
|
|
836
|
+
center,
|
|
827
837
|
);
|
|
828
838
|
Cartesian3.normalize(cameraPosition, cameraPosition);
|
|
829
839
|
Cartesian3.multiplyByScalar(
|
|
830
840
|
cameraPosition,
|
|
831
841
|
remainingDistance,
|
|
832
|
-
cameraPosition
|
|
842
|
+
cameraPosition,
|
|
833
843
|
);
|
|
834
844
|
|
|
835
845
|
// Pan
|
|
@@ -839,24 +849,24 @@ function handleZoom(
|
|
|
839
849
|
Cartesian3.multiplyByScalar(
|
|
840
850
|
up,
|
|
841
851
|
Math.cos(beta) - 1,
|
|
842
|
-
scratchCartesianTwo
|
|
852
|
+
scratchCartesianTwo,
|
|
843
853
|
),
|
|
844
854
|
Cartesian3.multiplyByScalar(
|
|
845
855
|
forward,
|
|
846
856
|
Math.sin(beta),
|
|
847
|
-
scratchCartesianThree
|
|
857
|
+
scratchCartesianThree,
|
|
848
858
|
),
|
|
849
|
-
scratchCartesian
|
|
859
|
+
scratchCartesian,
|
|
850
860
|
),
|
|
851
861
|
remainingDistance,
|
|
852
|
-
pMid
|
|
862
|
+
pMid,
|
|
853
863
|
);
|
|
854
864
|
Cartesian3.add(cameraPosition, pMid, cameraPosition);
|
|
855
865
|
|
|
856
866
|
Cartesian3.normalize(center, up);
|
|
857
867
|
Cartesian3.normalize(
|
|
858
868
|
Cartesian3.cross(up, right, scratchCartesian),
|
|
859
|
-
forward
|
|
869
|
+
forward,
|
|
860
870
|
);
|
|
861
871
|
|
|
862
872
|
const cMid = scratchCenterMovement;
|
|
@@ -865,17 +875,17 @@ function handleZoom(
|
|
|
865
875
|
Cartesian3.multiplyByScalar(
|
|
866
876
|
up,
|
|
867
877
|
Math.cos(beta) - 1,
|
|
868
|
-
scratchCartesianTwo
|
|
878
|
+
scratchCartesianTwo,
|
|
869
879
|
),
|
|
870
880
|
Cartesian3.multiplyByScalar(
|
|
871
881
|
forward,
|
|
872
882
|
Math.sin(beta),
|
|
873
|
-
scratchCartesianThree
|
|
883
|
+
scratchCartesianThree,
|
|
874
884
|
),
|
|
875
|
-
scratchCartesian
|
|
885
|
+
scratchCartesian,
|
|
876
886
|
),
|
|
877
887
|
Cartesian3.magnitude(center),
|
|
878
|
-
cMid
|
|
888
|
+
cMid,
|
|
879
889
|
);
|
|
880
890
|
Cartesian3.add(center, cMid, center);
|
|
881
891
|
|
|
@@ -887,7 +897,7 @@ function handleZoom(
|
|
|
887
897
|
// Set new direction
|
|
888
898
|
Cartesian3.normalize(
|
|
889
899
|
Cartesian3.subtract(center, cameraPosition, scratchCartesian),
|
|
890
|
-
camera.direction
|
|
900
|
+
camera.direction,
|
|
891
901
|
);
|
|
892
902
|
Cartesian3.clone(camera.direction, camera.direction);
|
|
893
903
|
|
|
@@ -901,11 +911,11 @@ function handleZoom(
|
|
|
901
911
|
} else {
|
|
902
912
|
const positionNormal = Cartesian3.normalize(
|
|
903
913
|
centerPosition,
|
|
904
|
-
scratchPositionNormal
|
|
914
|
+
scratchPositionNormal,
|
|
905
915
|
);
|
|
906
916
|
const pickedNormal = Cartesian3.normalize(
|
|
907
917
|
object._zoomWorldPosition,
|
|
908
|
-
scratchPickNormal
|
|
918
|
+
scratchPickNormal,
|
|
909
919
|
);
|
|
910
920
|
const dotProduct = Cartesian3.dot(pickedNormal, positionNormal);
|
|
911
921
|
|
|
@@ -914,7 +924,7 @@ function handleZoom(
|
|
|
914
924
|
const axis = Cartesian3.cross(
|
|
915
925
|
pickedNormal,
|
|
916
926
|
positionNormal,
|
|
917
|
-
scratchZoomAxis
|
|
927
|
+
scratchZoomAxis,
|
|
918
928
|
);
|
|
919
929
|
|
|
920
930
|
const denom =
|
|
@@ -936,7 +946,7 @@ function handleZoom(
|
|
|
936
946
|
const zoomMouseStart = SceneTransforms.worldToWindowCoordinates(
|
|
937
947
|
scene,
|
|
938
948
|
object._zoomWorldPosition,
|
|
939
|
-
scratchZoomOffset
|
|
949
|
+
scratchZoomOffset,
|
|
940
950
|
);
|
|
941
951
|
if (
|
|
942
952
|
mode !== SceneMode.COLUMBUS_VIEW &&
|
|
@@ -954,7 +964,7 @@ function handleZoom(
|
|
|
954
964
|
rayDirection.y,
|
|
955
965
|
rayDirection.z,
|
|
956
966
|
rayDirection.x,
|
|
957
|
-
rayDirection
|
|
967
|
+
rayDirection,
|
|
958
968
|
);
|
|
959
969
|
}
|
|
960
970
|
|
|
@@ -977,8 +987,10 @@ const scratchTranslateP0 = new Cartesian3();
|
|
|
977
987
|
function translate2D(controller, startPosition, movement) {
|
|
978
988
|
const scene = controller._scene;
|
|
979
989
|
const camera = scene.camera;
|
|
980
|
-
let start = camera.getPickRay(
|
|
981
|
-
.
|
|
990
|
+
let start = camera.getPickRay(
|
|
991
|
+
movement.startPosition,
|
|
992
|
+
translate2DStart,
|
|
993
|
+
).origin;
|
|
982
994
|
let end = camera.getPickRay(movement.endPosition, translate2DEnd).origin;
|
|
983
995
|
|
|
984
996
|
start = Cartesian3.fromElements(start.y, start.z, start.x, start);
|
|
@@ -1005,8 +1017,8 @@ function zoom2D(controller, startPosition, movement) {
|
|
|
1005
1017
|
controller,
|
|
1006
1018
|
startPosition,
|
|
1007
1019
|
movement,
|
|
1008
|
-
controller.
|
|
1009
|
-
camera.getMagnitude()
|
|
1020
|
+
controller.zoomFactor,
|
|
1021
|
+
camera.getMagnitude(),
|
|
1010
1022
|
);
|
|
1011
1023
|
}
|
|
1012
1024
|
|
|
@@ -1082,7 +1094,7 @@ function update2D(controller) {
|
|
|
1082
1094
|
controller.zoomEventTypes,
|
|
1083
1095
|
zoom2D,
|
|
1084
1096
|
controller.inertiaZoom,
|
|
1085
|
-
"_lastInertiaZoomMovement"
|
|
1097
|
+
"_lastInertiaZoomMovement",
|
|
1086
1098
|
);
|
|
1087
1099
|
if (rotatable2D) {
|
|
1088
1100
|
reactToInput(
|
|
@@ -1091,7 +1103,7 @@ function update2D(controller) {
|
|
|
1091
1103
|
controller.translateEventTypes,
|
|
1092
1104
|
twist2D,
|
|
1093
1105
|
controller.inertiaSpin,
|
|
1094
|
-
"_lastInertiaSpinMovement"
|
|
1106
|
+
"_lastInertiaSpinMovement",
|
|
1095
1107
|
);
|
|
1096
1108
|
}
|
|
1097
1109
|
} else {
|
|
@@ -1101,7 +1113,7 @@ function update2D(controller) {
|
|
|
1101
1113
|
controller.translateEventTypes,
|
|
1102
1114
|
translate2D,
|
|
1103
1115
|
controller.inertiaTranslate,
|
|
1104
|
-
"_lastInertiaTranslateMovement"
|
|
1116
|
+
"_lastInertiaTranslateMovement",
|
|
1105
1117
|
);
|
|
1106
1118
|
reactToInput(
|
|
1107
1119
|
controller,
|
|
@@ -1109,7 +1121,7 @@ function update2D(controller) {
|
|
|
1109
1121
|
controller.zoomEventTypes,
|
|
1110
1122
|
zoom2D,
|
|
1111
1123
|
controller.inertiaZoom,
|
|
1112
|
-
"_lastInertiaZoomMovement"
|
|
1124
|
+
"_lastInertiaZoomMovement",
|
|
1113
1125
|
);
|
|
1114
1126
|
if (rotatable2D) {
|
|
1115
1127
|
reactToInput(
|
|
@@ -1118,7 +1130,7 @@ function update2D(controller) {
|
|
|
1118
1130
|
controller.tiltEventTypes,
|
|
1119
1131
|
twist2D,
|
|
1120
1132
|
controller.inertiaSpin,
|
|
1121
|
-
"_lastInertiaTiltMovement"
|
|
1133
|
+
"_lastInertiaTiltMovement",
|
|
1122
1134
|
);
|
|
1123
1135
|
}
|
|
1124
1136
|
}
|
|
@@ -1137,7 +1149,7 @@ function pickPosition(controller, mousePosition, result) {
|
|
|
1137
1149
|
if (scene.pickPositionSupported) {
|
|
1138
1150
|
depthIntersection = scene.pickPositionWorldCoordinates(
|
|
1139
1151
|
mousePosition,
|
|
1140
|
-
scratchDepthIntersection
|
|
1152
|
+
scratchDepthIntersection,
|
|
1141
1153
|
);
|
|
1142
1154
|
}
|
|
1143
1155
|
|
|
@@ -1151,7 +1163,7 @@ function pickPosition(controller, mousePosition, result) {
|
|
|
1151
1163
|
ray,
|
|
1152
1164
|
scene,
|
|
1153
1165
|
cullBackFaces,
|
|
1154
|
-
scratchRayIntersection
|
|
1166
|
+
scratchRayIntersection,
|
|
1155
1167
|
);
|
|
1156
1168
|
|
|
1157
1169
|
const pickDistance = defined(depthIntersection)
|
|
@@ -1180,7 +1192,7 @@ function getDistanceFromSurface(controller) {
|
|
|
1180
1192
|
if (mode === SceneMode.SCENE3D) {
|
|
1181
1193
|
const cartographic = ellipsoid.cartesianToCartographic(
|
|
1182
1194
|
camera.position,
|
|
1183
|
-
scratchDistanceCartographic
|
|
1195
|
+
scratchDistanceCartographic,
|
|
1184
1196
|
);
|
|
1185
1197
|
if (defined(cartographic)) {
|
|
1186
1198
|
height = cartographic.height;
|
|
@@ -1215,7 +1227,7 @@ function getTiltCenterUnderground(controller, ray, pickedPosition, result) {
|
|
|
1215
1227
|
const maximumDistance = CesiumMath.clamp(
|
|
1216
1228
|
distanceFromSurface * 5.0,
|
|
1217
1229
|
controller._minimumUndergroundPickDistance,
|
|
1218
|
-
controller._maximumUndergroundPickDistance
|
|
1230
|
+
controller._maximumUndergroundPickDistance,
|
|
1219
1231
|
);
|
|
1220
1232
|
|
|
1221
1233
|
if (distance > maximumDistance) {
|
|
@@ -1231,7 +1243,7 @@ function getStrafeStartPositionUnderground(
|
|
|
1231
1243
|
controller,
|
|
1232
1244
|
ray,
|
|
1233
1245
|
pickedPosition,
|
|
1234
|
-
result
|
|
1246
|
+
result,
|
|
1235
1247
|
) {
|
|
1236
1248
|
let distance;
|
|
1237
1249
|
if (!defined(pickedPosition)) {
|
|
@@ -1256,7 +1268,7 @@ function continueStrafing(controller, movement) {
|
|
|
1256
1268
|
const inertialDelta = Cartesian2.subtract(
|
|
1257
1269
|
movement.endPosition,
|
|
1258
1270
|
movement.startPosition,
|
|
1259
|
-
scratchInertialDelta
|
|
1271
|
+
scratchInertialDelta,
|
|
1260
1272
|
);
|
|
1261
1273
|
const endPosition = controller._strafeEndMousePosition;
|
|
1262
1274
|
Cartesian2.add(endPosition, inertialDelta, endPosition);
|
|
@@ -1299,7 +1311,7 @@ function translateCV(controller, startPosition, movement) {
|
|
|
1299
1311
|
const cameraUnderground = controller._cameraUnderground;
|
|
1300
1312
|
const startMouse = Cartesian2.clone(
|
|
1301
1313
|
movement.startPosition,
|
|
1302
|
-
translateCVStartMouse
|
|
1314
|
+
translateCVStartMouse,
|
|
1303
1315
|
);
|
|
1304
1316
|
const endMouse = Cartesian2.clone(movement.endPosition, translateCVEndMouse);
|
|
1305
1317
|
let startRay = camera.getPickRay(startMouse, translateCVStartRay);
|
|
@@ -1326,7 +1338,7 @@ function translateCV(controller, startPosition, movement) {
|
|
|
1326
1338
|
controller,
|
|
1327
1339
|
startRay,
|
|
1328
1340
|
globePos,
|
|
1329
|
-
translateCVStartPos
|
|
1341
|
+
translateCVStartPos,
|
|
1330
1342
|
);
|
|
1331
1343
|
}
|
|
1332
1344
|
Cartesian2.clone(startPosition, controller._strafeMousePosition);
|
|
@@ -1343,14 +1355,14 @@ function translateCV(controller, startPosition, movement) {
|
|
|
1343
1355
|
const startPlanePos = IntersectionTests.rayPlane(
|
|
1344
1356
|
startRay,
|
|
1345
1357
|
plane,
|
|
1346
|
-
translateCVStartPos
|
|
1358
|
+
translateCVStartPos,
|
|
1347
1359
|
);
|
|
1348
1360
|
|
|
1349
1361
|
const endRay = camera.getPickRay(endMouse, translateCVEndRay);
|
|
1350
1362
|
const endPlanePos = IntersectionTests.rayPlane(
|
|
1351
1363
|
endRay,
|
|
1352
1364
|
plane,
|
|
1353
|
-
translateCVEndPos
|
|
1365
|
+
translateCVEndPos,
|
|
1354
1366
|
);
|
|
1355
1367
|
|
|
1356
1368
|
if (!defined(startPlanePos) || !defined(endPlanePos)) {
|
|
@@ -1363,7 +1375,7 @@ function translateCV(controller, startPosition, movement) {
|
|
|
1363
1375
|
const diff = Cartesian3.subtract(
|
|
1364
1376
|
startPlanePos,
|
|
1365
1377
|
endPlanePos,
|
|
1366
|
-
translateCVDifference
|
|
1378
|
+
translateCVDifference,
|
|
1367
1379
|
);
|
|
1368
1380
|
const temp = diff.x;
|
|
1369
1381
|
diff.x = diff.y;
|
|
@@ -1460,7 +1472,7 @@ function rotateCVOnPlane(controller, startPosition, movement) {
|
|
|
1460
1472
|
const transform = Transforms.eastNorthUpToFixedFrame(
|
|
1461
1473
|
center,
|
|
1462
1474
|
ellipsoid,
|
|
1463
|
-
rotateCVTransform
|
|
1475
|
+
rotateCVTransform,
|
|
1464
1476
|
);
|
|
1465
1477
|
|
|
1466
1478
|
const oldGlobe = controller._globe;
|
|
@@ -1547,7 +1559,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1547
1559
|
const verticalCenter = IntersectionTests.rayPlane(
|
|
1548
1560
|
ray,
|
|
1549
1561
|
plane,
|
|
1550
|
-
rotateCVVerticalCenter
|
|
1562
|
+
rotateCVVerticalCenter,
|
|
1551
1563
|
);
|
|
1552
1564
|
|
|
1553
1565
|
const projection = camera._projection;
|
|
@@ -1560,7 +1572,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1560
1572
|
const transform = Transforms.eastNorthUpToFixedFrame(
|
|
1561
1573
|
center,
|
|
1562
1574
|
ellipsoid,
|
|
1563
|
-
rotateCVTransform
|
|
1575
|
+
rotateCVTransform,
|
|
1564
1576
|
);
|
|
1565
1577
|
|
|
1566
1578
|
let verticalTransform;
|
|
@@ -1569,7 +1581,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1569
1581
|
verticalCenter.y,
|
|
1570
1582
|
verticalCenter.z,
|
|
1571
1583
|
verticalCenter.x,
|
|
1572
|
-
verticalCenter
|
|
1584
|
+
verticalCenter,
|
|
1573
1585
|
);
|
|
1574
1586
|
cart = projection.unproject(verticalCenter, rotateCVCart);
|
|
1575
1587
|
ellipsoid.cartographicToCartesian(cart, verticalCenter);
|
|
@@ -1577,7 +1589,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1577
1589
|
verticalTransform = Transforms.eastNorthUpToFixedFrame(
|
|
1578
1590
|
verticalCenter,
|
|
1579
1591
|
ellipsoid,
|
|
1580
|
-
rotateCVVerticalTransform
|
|
1592
|
+
rotateCVVerticalTransform,
|
|
1581
1593
|
);
|
|
1582
1594
|
} else {
|
|
1583
1595
|
verticalTransform = transform;
|
|
@@ -1598,7 +1610,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1598
1610
|
const tangent = Cartesian3.cross(
|
|
1599
1611
|
Cartesian3.UNIT_Z,
|
|
1600
1612
|
Cartesian3.normalize(camera.position, rotateCVCartesian3),
|
|
1601
|
-
rotateCVCartesian3
|
|
1613
|
+
rotateCVCartesian3,
|
|
1602
1614
|
);
|
|
1603
1615
|
const dot = Cartesian3.dot(camera.right, tangent);
|
|
1604
1616
|
|
|
@@ -1629,7 +1641,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1629
1641
|
const right = Cartesian3.cross(
|
|
1630
1642
|
camera.direction,
|
|
1631
1643
|
camera.constrainedAxis,
|
|
1632
|
-
tilt3DCartesian3
|
|
1644
|
+
tilt3DCartesian3,
|
|
1633
1645
|
);
|
|
1634
1646
|
if (
|
|
1635
1647
|
!Cartesian3.equalsEpsilon(right, Cartesian3.ZERO, CesiumMath.EPSILON6)
|
|
@@ -1656,7 +1668,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1656
1668
|
|
|
1657
1669
|
const originalPosition = Cartesian3.clone(
|
|
1658
1670
|
camera.positionWC,
|
|
1659
|
-
rotateCVCartesian3
|
|
1671
|
+
rotateCVCartesian3,
|
|
1660
1672
|
);
|
|
1661
1673
|
|
|
1662
1674
|
if (controller.enableCollisionDetection) {
|
|
@@ -1673,7 +1685,7 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1673
1685
|
Cartesian3.multiplyByScalar(
|
|
1674
1686
|
camera.position,
|
|
1675
1687
|
Math.sqrt(magSqrd),
|
|
1676
|
-
camera.position
|
|
1688
|
+
camera.position,
|
|
1677
1689
|
);
|
|
1678
1690
|
}
|
|
1679
1691
|
|
|
@@ -1681,14 +1693,14 @@ function rotateCVOnTerrain(controller, startPosition, movement) {
|
|
|
1681
1693
|
const axis = Cartesian3.cross(
|
|
1682
1694
|
originalPosition,
|
|
1683
1695
|
camera.position,
|
|
1684
|
-
originalPosition
|
|
1696
|
+
originalPosition,
|
|
1685
1697
|
);
|
|
1686
1698
|
Cartesian3.normalize(axis, axis);
|
|
1687
1699
|
|
|
1688
1700
|
const quaternion = Quaternion.fromAxisAngle(
|
|
1689
1701
|
axis,
|
|
1690
1702
|
angle,
|
|
1691
|
-
rotateCVQuaternion
|
|
1703
|
+
rotateCVQuaternion,
|
|
1692
1704
|
);
|
|
1693
1705
|
const rotation = Matrix3.fromQuaternion(quaternion, rotateCVMatrix);
|
|
1694
1706
|
Matrix3.multiplyByVector(rotation, camera.direction, camera.direction);
|
|
@@ -1744,7 +1756,7 @@ function zoomCV(controller, startPosition, movement) {
|
|
|
1744
1756
|
const distanceUnderground = getZoomDistanceUnderground(
|
|
1745
1757
|
controller,
|
|
1746
1758
|
ray,
|
|
1747
|
-
height
|
|
1759
|
+
height,
|
|
1748
1760
|
);
|
|
1749
1761
|
if (defined(distance)) {
|
|
1750
1762
|
distance = Math.min(distance, distanceUnderground);
|
|
@@ -1763,8 +1775,8 @@ function zoomCV(controller, startPosition, movement) {
|
|
|
1763
1775
|
controller,
|
|
1764
1776
|
startPosition,
|
|
1765
1777
|
movement,
|
|
1766
|
-
controller.
|
|
1767
|
-
distance
|
|
1778
|
+
controller.zoomFactor,
|
|
1779
|
+
distance,
|
|
1768
1780
|
);
|
|
1769
1781
|
}
|
|
1770
1782
|
|
|
@@ -1779,7 +1791,7 @@ function updateCV(controller) {
|
|
|
1779
1791
|
controller.rotateEventTypes,
|
|
1780
1792
|
rotate3D,
|
|
1781
1793
|
controller.inertiaSpin,
|
|
1782
|
-
"_lastInertiaSpinMovement"
|
|
1794
|
+
"_lastInertiaSpinMovement",
|
|
1783
1795
|
);
|
|
1784
1796
|
reactToInput(
|
|
1785
1797
|
controller,
|
|
@@ -1787,7 +1799,7 @@ function updateCV(controller) {
|
|
|
1787
1799
|
controller.zoomEventTypes,
|
|
1788
1800
|
zoom3D,
|
|
1789
1801
|
controller.inertiaZoom,
|
|
1790
|
-
"_lastInertiaZoomMovement"
|
|
1802
|
+
"_lastInertiaZoomMovement",
|
|
1791
1803
|
);
|
|
1792
1804
|
} else {
|
|
1793
1805
|
const tweens = controller._tweens;
|
|
@@ -1802,7 +1814,7 @@ function updateCV(controller) {
|
|
|
1802
1814
|
controller.tiltEventTypes,
|
|
1803
1815
|
rotateCV,
|
|
1804
1816
|
controller.inertiaSpin,
|
|
1805
|
-
"_lastInertiaTiltMovement"
|
|
1817
|
+
"_lastInertiaTiltMovement",
|
|
1806
1818
|
);
|
|
1807
1819
|
reactToInput(
|
|
1808
1820
|
controller,
|
|
@@ -1810,7 +1822,7 @@ function updateCV(controller) {
|
|
|
1810
1822
|
controller.translateEventTypes,
|
|
1811
1823
|
translateCV,
|
|
1812
1824
|
controller.inertiaTranslate,
|
|
1813
|
-
"_lastInertiaTranslateMovement"
|
|
1825
|
+
"_lastInertiaTranslateMovement",
|
|
1814
1826
|
);
|
|
1815
1827
|
reactToInput(
|
|
1816
1828
|
controller,
|
|
@@ -1818,13 +1830,13 @@ function updateCV(controller) {
|
|
|
1818
1830
|
controller.zoomEventTypes,
|
|
1819
1831
|
zoomCV,
|
|
1820
1832
|
controller.inertiaZoom,
|
|
1821
|
-
"_lastInertiaZoomMovement"
|
|
1833
|
+
"_lastInertiaZoomMovement",
|
|
1822
1834
|
);
|
|
1823
1835
|
reactToInput(
|
|
1824
1836
|
controller,
|
|
1825
1837
|
controller.enableLook,
|
|
1826
1838
|
controller.lookEventTypes,
|
|
1827
|
-
look3D
|
|
1839
|
+
look3D,
|
|
1828
1840
|
);
|
|
1829
1841
|
|
|
1830
1842
|
if (
|
|
@@ -1832,7 +1844,7 @@ function updateCV(controller) {
|
|
|
1832
1844
|
!tweens.contains(controller._tween)
|
|
1833
1845
|
) {
|
|
1834
1846
|
const tween = camera.createCorrectPositionTween(
|
|
1835
|
-
controller.bounceAnimationTime
|
|
1847
|
+
controller.bounceAnimationTime,
|
|
1836
1848
|
);
|
|
1837
1849
|
if (defined(tween)) {
|
|
1838
1850
|
controller._tween = tweens.add(tween);
|
|
@@ -1862,12 +1874,12 @@ function strafe(controller, movement, strafeStartPosition) {
|
|
|
1862
1874
|
const plane = Plane.fromPointNormal(
|
|
1863
1875
|
strafeStartPosition,
|
|
1864
1876
|
direction,
|
|
1865
|
-
scratchStrafePlane
|
|
1877
|
+
scratchStrafePlane,
|
|
1866
1878
|
);
|
|
1867
1879
|
const intersection = IntersectionTests.rayPlane(
|
|
1868
1880
|
ray,
|
|
1869
1881
|
plane,
|
|
1870
|
-
scratchStrafeIntersection
|
|
1882
|
+
scratchStrafeIntersection,
|
|
1871
1883
|
);
|
|
1872
1884
|
if (!defined(intersection)) {
|
|
1873
1885
|
return;
|
|
@@ -1934,7 +1946,7 @@ function spin3D(controller, startPosition, movement) {
|
|
|
1934
1946
|
|
|
1935
1947
|
const height = ellipsoid.cartesianToCartographic(
|
|
1936
1948
|
camera.positionWC,
|
|
1937
|
-
scratchCartographic
|
|
1949
|
+
scratchCartographic,
|
|
1938
1950
|
).height;
|
|
1939
1951
|
const globe = controller._globe;
|
|
1940
1952
|
|
|
@@ -1942,13 +1954,13 @@ function spin3D(controller, startPosition, movement) {
|
|
|
1942
1954
|
const mousePos = pickPosition(
|
|
1943
1955
|
controller,
|
|
1944
1956
|
movement.startPosition,
|
|
1945
|
-
scratchMousePosition
|
|
1957
|
+
scratchMousePosition,
|
|
1946
1958
|
);
|
|
1947
1959
|
if (defined(mousePos)) {
|
|
1948
1960
|
let strafing = false;
|
|
1949
1961
|
const ray = camera.getPickRay(
|
|
1950
1962
|
movement.startPosition,
|
|
1951
|
-
pickGlobeScratchRay
|
|
1963
|
+
pickGlobeScratchRay,
|
|
1952
1964
|
);
|
|
1953
1965
|
|
|
1954
1966
|
if (cameraUnderground) {
|
|
@@ -1991,8 +2003,8 @@ function spin3D(controller, startPosition, movement) {
|
|
|
1991
2003
|
camera.pickEllipsoid(
|
|
1992
2004
|
movement.startPosition,
|
|
1993
2005
|
controller._ellipsoid,
|
|
1994
|
-
spin3DPick
|
|
1995
|
-
)
|
|
2006
|
+
spin3DPick,
|
|
2007
|
+
),
|
|
1996
2008
|
)
|
|
1997
2009
|
) {
|
|
1998
2010
|
pan3D(controller, startPosition, movement, controller._ellipsoid);
|
|
@@ -2014,7 +2026,7 @@ function rotate3D(
|
|
|
2014
2026
|
movement,
|
|
2015
2027
|
constrainedAxis,
|
|
2016
2028
|
rotateOnlyVertical,
|
|
2017
|
-
rotateOnlyHorizontal
|
|
2029
|
+
rotateOnlyHorizontal,
|
|
2018
2030
|
) {
|
|
2019
2031
|
rotateOnlyVertical = defaultValue(rotateOnlyVertical, false);
|
|
2020
2032
|
rotateOnlyHorizontal = defaultValue(rotateOnlyHorizontal, false);
|
|
@@ -2047,7 +2059,7 @@ function rotate3D(
|
|
|
2047
2059
|
phiWindowRatio = Math.min(phiWindowRatio, controller.maximumMovementRatio);
|
|
2048
2060
|
thetaWindowRatio = Math.min(
|
|
2049
2061
|
thetaWindowRatio,
|
|
2050
|
-
controller.maximumMovementRatio
|
|
2062
|
+
controller.maximumMovementRatio,
|
|
2051
2063
|
);
|
|
2052
2064
|
|
|
2053
2065
|
const deltaPhi = rotateRate * phiWindowRatio * Math.PI * 2.0;
|
|
@@ -2082,15 +2094,15 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2082
2094
|
|
|
2083
2095
|
const startMousePosition = Cartesian2.clone(
|
|
2084
2096
|
movement.startPosition,
|
|
2085
|
-
pan3DStartMousePosition
|
|
2097
|
+
pan3DStartMousePosition,
|
|
2086
2098
|
);
|
|
2087
2099
|
const endMousePosition = Cartesian2.clone(
|
|
2088
2100
|
movement.endPosition,
|
|
2089
|
-
pan3DEndMousePosition
|
|
2101
|
+
pan3DEndMousePosition,
|
|
2090
2102
|
);
|
|
2091
2103
|
const height = ellipsoid.cartesianToCartographic(
|
|
2092
2104
|
camera.positionWC,
|
|
2093
|
-
scratchCartographic
|
|
2105
|
+
scratchCartographic,
|
|
2094
2106
|
).height;
|
|
2095
2107
|
|
|
2096
2108
|
let p0, p1;
|
|
@@ -2106,7 +2118,7 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2106
2118
|
!defined(controller._globe) &&
|
|
2107
2119
|
!Cartesian2.equalsEpsilon(
|
|
2108
2120
|
startMousePosition,
|
|
2109
|
-
controller._panLastMousePosition
|
|
2121
|
+
controller._panLastMousePosition,
|
|
2110
2122
|
)
|
|
2111
2123
|
) {
|
|
2112
2124
|
p0 = pickPosition(controller, startMousePosition, pan3DP0);
|
|
@@ -2117,7 +2129,7 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2117
2129
|
const toCenterProj = Cartesian3.multiplyByScalar(
|
|
2118
2130
|
camera.directionWC,
|
|
2119
2131
|
Cartesian3.dot(camera.directionWC, toCenter),
|
|
2120
|
-
pan3DTemp1
|
|
2132
|
+
pan3DTemp1,
|
|
2121
2133
|
);
|
|
2122
2134
|
const distanceToNearPlane = Cartesian3.magnitude(toCenterProj);
|
|
2123
2135
|
const pixelDimensions = camera.frustum.getPixelDimensions(
|
|
@@ -2125,33 +2137,35 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2125
2137
|
scene.drawingBufferHeight,
|
|
2126
2138
|
distanceToNearPlane,
|
|
2127
2139
|
scene.pixelRatio,
|
|
2128
|
-
pan3DPixelDimensions
|
|
2140
|
+
pan3DPixelDimensions,
|
|
2129
2141
|
);
|
|
2130
2142
|
|
|
2131
2143
|
const dragDelta = Cartesian2.subtract(
|
|
2132
2144
|
endMousePosition,
|
|
2133
2145
|
startMousePosition,
|
|
2134
|
-
pan3DDiffMousePosition
|
|
2146
|
+
pan3DDiffMousePosition,
|
|
2135
2147
|
);
|
|
2136
2148
|
|
|
2137
2149
|
// Move the camera to the the distance the cursor moved in worldspace
|
|
2138
2150
|
const right = Cartesian3.multiplyByScalar(
|
|
2139
2151
|
camera.rightWC,
|
|
2140
2152
|
dragDelta.x * pixelDimensions.x,
|
|
2141
|
-
pan3DTemp1
|
|
2153
|
+
pan3DTemp1,
|
|
2142
2154
|
);
|
|
2143
2155
|
|
|
2144
2156
|
// Move the camera towards the picked position in worldspace as the camera is pointed towards a horizon view
|
|
2145
2157
|
const cameraPositionNormal = Cartesian3.normalize(
|
|
2146
2158
|
camera.positionWC,
|
|
2147
|
-
scratchCameraPositionNormal
|
|
2159
|
+
scratchCameraPositionNormal,
|
|
2148
2160
|
);
|
|
2149
|
-
const endPickDirection = camera.getPickRay(
|
|
2150
|
-
|
|
2161
|
+
const endPickDirection = camera.getPickRay(
|
|
2162
|
+
endMousePosition,
|
|
2163
|
+
panRay,
|
|
2164
|
+
).direction;
|
|
2151
2165
|
const endPickProj = Cartesian3.subtract(
|
|
2152
2166
|
endPickDirection,
|
|
2153
2167
|
Cartesian3.projectVector(endPickDirection, camera.rightWC, pan3DTemp2),
|
|
2154
|
-
pan3DTemp2
|
|
2168
|
+
pan3DTemp2,
|
|
2155
2169
|
);
|
|
2156
2170
|
const angle = Cartesian3.angleBetween(endPickProj, camera.directionWC);
|
|
2157
2171
|
let forward = 1.0;
|
|
@@ -2159,7 +2173,7 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2159
2173
|
forward = Math.max(Math.tan(angle), 0.1); // Clamp so we don't make the magnitude infinitely large when the angle is small
|
|
2160
2174
|
}
|
|
2161
2175
|
let dot = Math.abs(
|
|
2162
|
-
Cartesian3.dot(camera.directionWC, cameraPositionNormal)
|
|
2176
|
+
Cartesian3.dot(camera.directionWC, cameraPositionNormal),
|
|
2163
2177
|
);
|
|
2164
2178
|
const magnitude =
|
|
2165
2179
|
((-dragDelta.y * pixelDimensions.y * 2.0) / Math.sqrt(forward)) *
|
|
@@ -2167,7 +2181,7 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2167
2181
|
const direction = Cartesian3.multiplyByScalar(
|
|
2168
2182
|
endPickDirection,
|
|
2169
2183
|
magnitude,
|
|
2170
|
-
pan3DTemp2
|
|
2184
|
+
pan3DTemp2,
|
|
2171
2185
|
);
|
|
2172
2186
|
|
|
2173
2187
|
// Move the camera up the distance the cursor moved in worldspace as the camera is pointed towards the center
|
|
@@ -2175,7 +2189,7 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2175
2189
|
const up = Cartesian3.multiplyByScalar(
|
|
2176
2190
|
camera.upWC,
|
|
2177
2191
|
-dragDelta.y * (1.0 - dot) * pixelDimensions.y,
|
|
2178
|
-
pan3DTemp3
|
|
2192
|
+
pan3DTemp3,
|
|
2179
2193
|
);
|
|
2180
2194
|
|
|
2181
2195
|
p1 = Cartesian3.add(p0, right, pan3DP1);
|
|
@@ -2260,11 +2274,11 @@ function pan3D(controller, startPosition, movement, ellipsoid) {
|
|
|
2260
2274
|
const planeNormal = Cartesian3.cross(basis0, east, pan3DTemp0);
|
|
2261
2275
|
const side0 = Cartesian3.dot(
|
|
2262
2276
|
planeNormal,
|
|
2263
|
-
Cartesian3.subtract(p0, basis0, pan3DTemp1)
|
|
2277
|
+
Cartesian3.subtract(p0, basis0, pan3DTemp1),
|
|
2264
2278
|
);
|
|
2265
2279
|
const side1 = Cartesian3.dot(
|
|
2266
2280
|
planeNormal,
|
|
2267
|
-
Cartesian3.subtract(p1, basis0, pan3DTemp1)
|
|
2281
|
+
Cartesian3.subtract(p1, basis0, pan3DTemp1),
|
|
2268
2282
|
);
|
|
2269
2283
|
|
|
2270
2284
|
let deltaTheta;
|
|
@@ -2318,7 +2332,7 @@ function zoom3D(controller, startPosition, movement) {
|
|
|
2318
2332
|
let intersection;
|
|
2319
2333
|
const height = ellipsoid.cartesianToCartographic(
|
|
2320
2334
|
camera.position,
|
|
2321
|
-
zoom3DCartographic
|
|
2335
|
+
zoom3DCartographic,
|
|
2322
2336
|
).height;
|
|
2323
2337
|
|
|
2324
2338
|
const approachingCollision =
|
|
@@ -2342,7 +2356,7 @@ function zoom3D(controller, startPosition, movement) {
|
|
|
2342
2356
|
const distanceUnderground = getZoomDistanceUnderground(
|
|
2343
2357
|
controller,
|
|
2344
2358
|
ray,
|
|
2345
|
-
height
|
|
2359
|
+
height,
|
|
2346
2360
|
);
|
|
2347
2361
|
if (defined(distance)) {
|
|
2348
2362
|
distance = Math.min(distance, distanceUnderground);
|
|
@@ -2357,15 +2371,15 @@ function zoom3D(controller, startPosition, movement) {
|
|
|
2357
2371
|
|
|
2358
2372
|
const unitPosition = Cartesian3.normalize(
|
|
2359
2373
|
camera.position,
|
|
2360
|
-
zoom3DUnitPosition
|
|
2374
|
+
zoom3DUnitPosition,
|
|
2361
2375
|
);
|
|
2362
2376
|
handleZoom(
|
|
2363
2377
|
controller,
|
|
2364
2378
|
startPosition,
|
|
2365
2379
|
movement,
|
|
2366
|
-
controller.
|
|
2380
|
+
controller.zoomFactor,
|
|
2367
2381
|
distance,
|
|
2368
|
-
Cartesian3.dot(unitPosition, camera.direction)
|
|
2382
|
+
Cartesian3.dot(unitPosition, camera.direction),
|
|
2369
2383
|
);
|
|
2370
2384
|
}
|
|
2371
2385
|
|
|
@@ -2401,7 +2415,7 @@ function tilt3D(controller, startPosition, movement) {
|
|
|
2401
2415
|
if (controller._looking) {
|
|
2402
2416
|
const up = controller._ellipsoid.geodeticSurfaceNormal(
|
|
2403
2417
|
camera.position,
|
|
2404
|
-
tilt3DLookUp
|
|
2418
|
+
tilt3DLookUp,
|
|
2405
2419
|
);
|
|
2406
2420
|
look3D(controller, startPosition, movement, up);
|
|
2407
2421
|
return;
|
|
@@ -2410,7 +2424,7 @@ function tilt3D(controller, startPosition, movement) {
|
|
|
2410
2424
|
const ellipsoid = controller._ellipsoid;
|
|
2411
2425
|
const cartographic = ellipsoid.cartesianToCartographic(
|
|
2412
2426
|
camera.position,
|
|
2413
|
-
tilt3DCart
|
|
2427
|
+
tilt3DCart,
|
|
2414
2428
|
);
|
|
2415
2429
|
|
|
2416
2430
|
if (
|
|
@@ -2433,7 +2447,7 @@ function tilt3DOnEllipsoid(controller, startPosition, movement) {
|
|
|
2433
2447
|
const minHeight = controller.minimumZoomDistance * 0.25;
|
|
2434
2448
|
const height = ellipsoid.cartesianToCartographic(
|
|
2435
2449
|
camera.positionWC,
|
|
2436
|
-
tilt3DOnEllipsoidCartographic
|
|
2450
|
+
tilt3DOnEllipsoidCartographic,
|
|
2437
2451
|
).height;
|
|
2438
2452
|
if (
|
|
2439
2453
|
height - minHeight - 1.0 < CesiumMath.EPSILON3 &&
|
|
@@ -2456,25 +2470,25 @@ function tilt3DOnEllipsoid(controller, startPosition, movement) {
|
|
|
2456
2470
|
} else if (height > controller._minimumTrackBallHeight) {
|
|
2457
2471
|
const grazingAltitudeLocation = IntersectionTests.grazingAltitudeLocation(
|
|
2458
2472
|
ray,
|
|
2459
|
-
ellipsoid
|
|
2473
|
+
ellipsoid,
|
|
2460
2474
|
);
|
|
2461
2475
|
if (!defined(grazingAltitudeLocation)) {
|
|
2462
2476
|
return;
|
|
2463
2477
|
}
|
|
2464
2478
|
const grazingAltitudeCart = ellipsoid.cartesianToCartographic(
|
|
2465
2479
|
grazingAltitudeLocation,
|
|
2466
|
-
tilt3DCart
|
|
2480
|
+
tilt3DCart,
|
|
2467
2481
|
);
|
|
2468
2482
|
grazingAltitudeCart.height = 0.0;
|
|
2469
2483
|
center = ellipsoid.cartographicToCartesian(
|
|
2470
2484
|
grazingAltitudeCart,
|
|
2471
|
-
tilt3DCenter
|
|
2485
|
+
tilt3DCenter,
|
|
2472
2486
|
);
|
|
2473
2487
|
} else {
|
|
2474
2488
|
controller._looking = true;
|
|
2475
2489
|
const up = controller._ellipsoid.geodeticSurfaceNormal(
|
|
2476
2490
|
camera.position,
|
|
2477
|
-
tilt3DLookUp
|
|
2491
|
+
tilt3DLookUp,
|
|
2478
2492
|
);
|
|
2479
2493
|
look3D(controller, startPosition, movement, up);
|
|
2480
2494
|
Cartesian2.clone(startPosition, controller._tiltCenterMousePosition);
|
|
@@ -2484,7 +2498,7 @@ function tilt3DOnEllipsoid(controller, startPosition, movement) {
|
|
|
2484
2498
|
const transform = Transforms.eastNorthUpToFixedFrame(
|
|
2485
2499
|
center,
|
|
2486
2500
|
ellipsoid,
|
|
2487
|
-
tilt3DTransform
|
|
2501
|
+
tilt3DTransform,
|
|
2488
2502
|
);
|
|
2489
2503
|
|
|
2490
2504
|
const oldGlobe = controller._globe;
|
|
@@ -2529,13 +2543,13 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2529
2543
|
if (!defined(intersection)) {
|
|
2530
2544
|
const cartographic = ellipsoid.cartesianToCartographic(
|
|
2531
2545
|
camera.position,
|
|
2532
|
-
tilt3DCart
|
|
2546
|
+
tilt3DCart,
|
|
2533
2547
|
);
|
|
2534
2548
|
if (cartographic.height <= controller._minimumTrackBallHeight) {
|
|
2535
2549
|
controller._looking = true;
|
|
2536
2550
|
const up = controller._ellipsoid.geodeticSurfaceNormal(
|
|
2537
2551
|
camera.position,
|
|
2538
|
-
tilt3DLookUp
|
|
2552
|
+
tilt3DLookUp,
|
|
2539
2553
|
);
|
|
2540
2554
|
look3D(controller, startPosition, movement, up);
|
|
2541
2555
|
Cartesian2.clone(startPosition, controller._tiltCenterMousePosition);
|
|
@@ -2581,12 +2595,12 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2581
2595
|
const transform = Transforms.eastNorthUpToFixedFrame(
|
|
2582
2596
|
center,
|
|
2583
2597
|
ellipsoid,
|
|
2584
|
-
tilt3DTransform
|
|
2598
|
+
tilt3DTransform,
|
|
2585
2599
|
);
|
|
2586
2600
|
const verticalTransform = Transforms.eastNorthUpToFixedFrame(
|
|
2587
2601
|
verticalCenter,
|
|
2588
2602
|
newEllipsoid,
|
|
2589
|
-
tilt3DVerticalTransform
|
|
2603
|
+
tilt3DVerticalTransform,
|
|
2590
2604
|
);
|
|
2591
2605
|
|
|
2592
2606
|
const oldGlobe = controller._globe;
|
|
@@ -2604,7 +2618,7 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2604
2618
|
const tangent = Cartesian3.cross(
|
|
2605
2619
|
verticalCenter,
|
|
2606
2620
|
camera.positionWC,
|
|
2607
|
-
tilt3DCartesian3
|
|
2621
|
+
tilt3DCartesian3,
|
|
2608
2622
|
);
|
|
2609
2623
|
const dot = Cartesian3.dot(camera.rightWC, tangent);
|
|
2610
2624
|
|
|
@@ -2635,7 +2649,7 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2635
2649
|
const right = Cartesian3.cross(
|
|
2636
2650
|
camera.direction,
|
|
2637
2651
|
camera.constrainedAxis,
|
|
2638
|
-
tilt3DCartesian3
|
|
2652
|
+
tilt3DCartesian3,
|
|
2639
2653
|
);
|
|
2640
2654
|
if (
|
|
2641
2655
|
!Cartesian3.equalsEpsilon(right, Cartesian3.ZERO, CesiumMath.EPSILON6)
|
|
@@ -2662,7 +2676,7 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2662
2676
|
|
|
2663
2677
|
const originalPosition = Cartesian3.clone(
|
|
2664
2678
|
camera.positionWC,
|
|
2665
|
-
tilt3DCartesian3
|
|
2679
|
+
tilt3DCartesian3,
|
|
2666
2680
|
);
|
|
2667
2681
|
|
|
2668
2682
|
if (controller.enableCollisionDetection) {
|
|
@@ -2679,7 +2693,7 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2679
2693
|
Cartesian3.multiplyByScalar(
|
|
2680
2694
|
camera.position,
|
|
2681
2695
|
Math.sqrt(magSqrd),
|
|
2682
|
-
camera.position
|
|
2696
|
+
camera.position,
|
|
2683
2697
|
);
|
|
2684
2698
|
}
|
|
2685
2699
|
|
|
@@ -2687,7 +2701,7 @@ function tilt3DOnTerrain(controller, startPosition, movement) {
|
|
|
2687
2701
|
const axis = Cartesian3.cross(
|
|
2688
2702
|
originalPosition,
|
|
2689
2703
|
camera.position,
|
|
2690
|
-
originalPosition
|
|
2704
|
+
originalPosition,
|
|
2691
2705
|
);
|
|
2692
2706
|
Cartesian3.normalize(axis, axis);
|
|
2693
2707
|
|
|
@@ -2798,17 +2812,17 @@ function look3D(controller, startPosition, movement, rotationAxis) {
|
|
|
2798
2812
|
const direction = camera.direction;
|
|
2799
2813
|
const negativeRotationAxis = Cartesian3.negate(
|
|
2800
2814
|
rotationAxis,
|
|
2801
|
-
look3DNegativeRot
|
|
2815
|
+
look3DNegativeRot,
|
|
2802
2816
|
);
|
|
2803
2817
|
const northParallel = Cartesian3.equalsEpsilon(
|
|
2804
2818
|
direction,
|
|
2805
2819
|
rotationAxis,
|
|
2806
|
-
CesiumMath.EPSILON2
|
|
2820
|
+
CesiumMath.EPSILON2,
|
|
2807
2821
|
);
|
|
2808
2822
|
const southParallel = Cartesian3.equalsEpsilon(
|
|
2809
2823
|
direction,
|
|
2810
2824
|
negativeRotationAxis,
|
|
2811
|
-
CesiumMath.EPSILON2
|
|
2825
|
+
CesiumMath.EPSILON2,
|
|
2812
2826
|
);
|
|
2813
2827
|
if (!northParallel && !southParallel) {
|
|
2814
2828
|
dot = Cartesian3.dot(direction, rotationAxis);
|
|
@@ -2840,7 +2854,7 @@ function update3D(controller) {
|
|
|
2840
2854
|
controller.rotateEventTypes,
|
|
2841
2855
|
spin3D,
|
|
2842
2856
|
controller.inertiaSpin,
|
|
2843
|
-
"_lastInertiaSpinMovement"
|
|
2857
|
+
"_lastInertiaSpinMovement",
|
|
2844
2858
|
);
|
|
2845
2859
|
reactToInput(
|
|
2846
2860
|
controller,
|
|
@@ -2848,7 +2862,7 @@ function update3D(controller) {
|
|
|
2848
2862
|
controller.zoomEventTypes,
|
|
2849
2863
|
zoom3D,
|
|
2850
2864
|
controller.inertiaZoom,
|
|
2851
|
-
"_lastInertiaZoomMovement"
|
|
2865
|
+
"_lastInertiaZoomMovement",
|
|
2852
2866
|
);
|
|
2853
2867
|
reactToInput(
|
|
2854
2868
|
controller,
|
|
@@ -2856,13 +2870,13 @@ function update3D(controller) {
|
|
|
2856
2870
|
controller.tiltEventTypes,
|
|
2857
2871
|
tilt3D,
|
|
2858
2872
|
controller.inertiaSpin,
|
|
2859
|
-
"_lastInertiaTiltMovement"
|
|
2873
|
+
"_lastInertiaTiltMovement",
|
|
2860
2874
|
);
|
|
2861
2875
|
reactToInput(
|
|
2862
2876
|
controller,
|
|
2863
2877
|
controller.enableLook,
|
|
2864
2878
|
controller.lookEventTypes,
|
|
2865
|
-
look3D
|
|
2879
|
+
look3D,
|
|
2866
2880
|
);
|
|
2867
2881
|
}
|
|
2868
2882
|
|
|
@@ -2937,7 +2951,7 @@ function adjustHeightForTerrain(controller, cameraChanged) {
|
|
|
2937
2951
|
Cartesian3.multiplyByScalar(
|
|
2938
2952
|
camera.position,
|
|
2939
2953
|
Math.max(mag, controller.minimumZoomDistance),
|
|
2940
|
-
camera.position
|
|
2954
|
+
camera.position,
|
|
2941
2955
|
);
|
|
2942
2956
|
Cartesian3.normalize(camera.direction, camera.direction);
|
|
2943
2957
|
Cartesian3.cross(camera.direction, camera.up, camera.right);
|
|
@@ -2986,17 +3000,17 @@ ScreenSpaceCameraController.prototype.update = function () {
|
|
|
2986
3000
|
this._minimumCollisionTerrainHeight = VerticalExaggeration.getHeight(
|
|
2987
3001
|
this.minimumCollisionTerrainHeight,
|
|
2988
3002
|
verticalExaggeration,
|
|
2989
|
-
verticalExaggerationRelativeHeight
|
|
3003
|
+
verticalExaggerationRelativeHeight,
|
|
2990
3004
|
);
|
|
2991
3005
|
this._minimumPickingTerrainHeight = VerticalExaggeration.getHeight(
|
|
2992
3006
|
this.minimumPickingTerrainHeight,
|
|
2993
3007
|
verticalExaggeration,
|
|
2994
|
-
verticalExaggerationRelativeHeight
|
|
3008
|
+
verticalExaggerationRelativeHeight,
|
|
2995
3009
|
);
|
|
2996
3010
|
this._minimumTrackBallHeight = VerticalExaggeration.getHeight(
|
|
2997
3011
|
this.minimumTrackBallHeight,
|
|
2998
3012
|
verticalExaggeration,
|
|
2999
|
-
verticalExaggerationRelativeHeight
|
|
3013
|
+
verticalExaggerationRelativeHeight,
|
|
3000
3014
|
);
|
|
3001
3015
|
|
|
3002
3016
|
this._cameraUnderground = scene.cameraUnderground && defined(this._globe);
|
|
@@ -3008,11 +3022,11 @@ ScreenSpaceCameraController.prototype.update = function () {
|
|
|
3008
3022
|
this._adjustedHeightForTerrain = false;
|
|
3009
3023
|
const previousPosition = Cartesian3.clone(
|
|
3010
3024
|
camera.positionWC,
|
|
3011
|
-
scratchPreviousPosition
|
|
3025
|
+
scratchPreviousPosition,
|
|
3012
3026
|
);
|
|
3013
3027
|
const previousDirection = Cartesian3.clone(
|
|
3014
3028
|
camera.directionWC,
|
|
3015
|
-
scratchPreviousDirection
|
|
3029
|
+
scratchPreviousDirection,
|
|
3016
3030
|
);
|
|
3017
3031
|
|
|
3018
3032
|
if (mode === SceneMode.SCENE2D) {
|