deeptwins-cesium-engine 0.0.3
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/ThirdParty/Workers/zip-web-worker.js +640 -0
- package/Build/Workers/chunk-2363JE27.js +163 -0
- package/Build/Workers/chunk-23T2IPHV.js +55 -0
- package/Build/Workers/chunk-27SAH2Q2.js +55 -0
- package/Build/Workers/chunk-2AM4E2WD.js +101 -0
- package/Build/Workers/chunk-2H4D4HBM.js +101 -0
- package/Build/Workers/chunk-2KBLMCYQ.js +198 -0
- package/Build/Workers/chunk-2MWF4IES.js +398 -0
- package/Build/Workers/chunk-2O7PRNCW.js +288 -0
- package/Build/Workers/chunk-2RCIRXNI.js +75 -0
- package/Build/Workers/chunk-3JIEAYRM.js +940 -0
- package/Build/Workers/chunk-3VNQVXD6.js +837 -0
- package/Build/Workers/chunk-3XR54LVR.js +75 -0
- package/Build/Workers/chunk-3YTMGEXW.js +1443 -0
- package/Build/Workers/chunk-3ZP3VA4L.js +171 -0
- package/Build/Workers/chunk-4AKOLNCZ.js +139 -0
- package/Build/Workers/chunk-4BHWJWS3.js +171 -0
- package/Build/Workers/chunk-4QSCEADX.js +1800 -0
- package/Build/Workers/chunk-4ZKQXB7T.js +1460 -0
- package/Build/Workers/chunk-4ZX6BO6C.js +476 -0
- package/Build/Workers/chunk-55NHNEI7.js +163 -0
- package/Build/Workers/chunk-5F3SUA6W.js +8366 -0
- package/Build/Workers/chunk-5FBLADWD.js +692 -0
- package/Build/Workers/chunk-5H7FXJTE.js +2719 -0
- package/Build/Workers/chunk-5JKH4AMT.js +58 -0
- package/Build/Workers/chunk-5MTUN2SE.js +642 -0
- package/Build/Workers/chunk-5PWCXSID.js +256 -0
- package/Build/Workers/chunk-5RL7XAZS.js +256 -0
- package/Build/Workers/chunk-5TZVQOFD.js +305 -0
- package/Build/Workers/chunk-67FTKXPJ.js +352 -0
- package/Build/Workers/chunk-6AIBN5NQ.js +1054 -0
- package/Build/Workers/chunk-6D6BOTSA.js +414 -0
- package/Build/Workers/chunk-6FGAWC5J.js +44 -0
- package/Build/Workers/chunk-6HKAPCSO.js +280 -0
- package/Build/Workers/chunk-6UJDVUJ4.js +8366 -0
- package/Build/Workers/chunk-73Q77JO7.js +138 -0
- package/Build/Workers/chunk-7A6QUBKY.js +58 -0
- package/Build/Workers/chunk-7APZZMCL.js +73 -0
- package/Build/Workers/chunk-7BHC3VOI.js +511 -0
- package/Build/Workers/chunk-7GQHESFY.js +368 -0
- package/Build/Workers/chunk-7MVC3OLP.js +58 -0
- package/Build/Workers/chunk-7UNMLR74.js +1800 -0
- package/Build/Workers/chunk-A2QTGP5S.js +55 -0
- package/Build/Workers/chunk-A3FZIBXG.js +55 -0
- package/Build/Workers/chunk-A53R2F2L.js +305 -0
- package/Build/Workers/chunk-A6LIUE7X.js +692 -0
- package/Build/Workers/chunk-A6YFUGJO.js +139 -0
- package/Build/Workers/chunk-AJYWXC6I.js +97 -0
- package/Build/Workers/chunk-ALTIGQTT.js +288 -0
- package/Build/Workers/chunk-AOIO5VUS.js +8366 -0
- package/Build/Workers/chunk-AT2CG6PG.js +3514 -0
- package/Build/Workers/chunk-ATX74V7S.js +55 -0
- package/Build/Workers/chunk-AZPXT6RB.js +1067 -0
- package/Build/Workers/chunk-B7JRBTT6.js +682 -0
- package/Build/Workers/chunk-BALMTCKJ.js +138 -0
- package/Build/Workers/chunk-BBYRID6W.js +352 -0
- package/Build/Workers/chunk-BDX4AYXL.js +162 -0
- package/Build/Workers/chunk-BG2DK4Q5.js +101 -0
- package/Build/Workers/chunk-BSNC3NBZ.js +139 -0
- package/Build/Workers/chunk-BZLYQCIC.js +958 -0
- package/Build/Workers/chunk-C4NX77B5.js +57 -0
- package/Build/Workers/chunk-CHNDJRYA.js +1054 -0
- package/Build/Workers/chunk-CJOV55CW.js +1067 -0
- package/Build/Workers/chunk-COGPE5Z2.js +241 -0
- package/Build/Workers/chunk-CRCK5VX6.js +497 -0
- package/Build/Workers/chunk-CTLQNSVP.js +455 -0
- package/Build/Workers/chunk-CW7W27IZ.js +299 -0
- package/Build/Workers/chunk-DICY26ID.js +2719 -0
- package/Build/Workers/chunk-DLAVWLZW.js +682 -0
- package/Build/Workers/chunk-DMEFNTUV.js +1317 -0
- package/Build/Workers/chunk-DQSJEOZY.js +55 -0
- package/Build/Workers/chunk-F6UXXCPK.js +3514 -0
- package/Build/Workers/chunk-FKIR6F3B.js +97 -0
- package/Build/Workers/chunk-FRBZJJVU.js +2719 -0
- package/Build/Workers/chunk-FRLH26PM.js +940 -0
- package/Build/Workers/chunk-FT6HYEKU.js +3514 -0
- package/Build/Workers/chunk-FYDCQ2VN.js +73 -0
- package/Build/Workers/chunk-G5OKIL5P.js +55 -0
- package/Build/Workers/chunk-G6VHLVWG.js +101 -0
- package/Build/Workers/chunk-GBGV4U6Z.js +219 -0
- package/Build/Workers/chunk-GDU4RZSZ.js +940 -0
- package/Build/Workers/chunk-GJRVCSXV.js +37 -0
- package/Build/Workers/chunk-GKWOUMYA.js +37 -0
- package/Build/Workers/chunk-GNDFFW5Z.js +1443 -0
- package/Build/Workers/chunk-GNQ5BH75.js +352 -0
- package/Build/Workers/chunk-GNQUZV4R.js +171 -0
- package/Build/Workers/chunk-GOCJHCLA.js +352 -0
- package/Build/Workers/chunk-GTY4K4IA.js +219 -0
- package/Build/Workers/chunk-GXBTJBHN.js +102 -0
- package/Build/Workers/chunk-H6Q7E4BQ.js +114 -0
- package/Build/Workers/chunk-HEGESGGY.js +219 -0
- package/Build/Workers/chunk-HG3HIMYL.js +241 -0
- package/Build/Workers/chunk-HGEYVFMI.js +1800 -0
- package/Build/Workers/chunk-HHGOFZVQ.js +124 -0
- package/Build/Workers/chunk-HXEVICMT.js +37 -0
- package/Build/Workers/chunk-HXKUEOOD.js +352 -0
- package/Build/Workers/chunk-I4REFVXB.js +256 -0
- package/Build/Workers/chunk-IL5F6WEE.js +497 -0
- package/Build/Workers/chunk-IOODZNYE.js +629 -0
- package/Build/Workers/chunk-IVLDVV5R.js +788 -0
- package/Build/Workers/chunk-IWP4XCPO.js +778 -0
- package/Build/Workers/chunk-JBTUZNI2.js +398 -0
- package/Build/Workers/chunk-JMSXZ6AI.js +414 -0
- package/Build/Workers/chunk-JTGVXCP2.js +2058 -0
- package/Build/Workers/chunk-JUK2ZSWT.js +198 -0
- package/Build/Workers/chunk-K6HQ5W6R.js +171 -0
- package/Build/Workers/chunk-KC3G7WHZ.js +57 -0
- package/Build/Workers/chunk-KGPKBCGY.js +97 -0
- package/Build/Workers/chunk-KKGD7HAW.js +414 -0
- package/Build/Workers/chunk-KQSN3QZM.js +368 -0
- package/Build/Workers/chunk-KROSQJUA.js +44 -0
- package/Build/Workers/chunk-L4JLDVCM.js +57 -0
- package/Build/Workers/chunk-LAOFDSKL.js +642 -0
- package/Build/Workers/chunk-LIYMRHGR.js +387 -0
- package/Build/Workers/chunk-LKCCQ3AW.js +198 -0
- package/Build/Workers/chunk-LLQFSX7U.js +139 -0
- package/Build/Workers/chunk-LSDXP6EX.js +75 -0
- package/Build/Workers/chunk-LTYK7VYQ.js +138 -0
- package/Build/Workers/chunk-LYMP3LWI.js +387 -0
- package/Build/Workers/chunk-M2WCZSU6.js +241 -0
- package/Build/Workers/chunk-M35VLUHY.js +352 -0
- package/Build/Workers/chunk-MAPGTIYK.js +2058 -0
- package/Build/Workers/chunk-MG6SYM3V.js +455 -0
- package/Build/Workers/chunk-MKMZHRB3.js +788 -0
- package/Build/Workers/chunk-MNR7L6SQ.js +1483 -0
- package/Build/Workers/chunk-MO25ZQ2I.js +958 -0
- package/Build/Workers/chunk-MOCL5YUJ.js +8366 -0
- package/Build/Workers/chunk-MRYY6ETH.js +280 -0
- package/Build/Workers/chunk-NAIA5L2S.js +682 -0
- package/Build/Workers/chunk-NMDV3OGH.js +958 -0
- package/Build/Workers/chunk-NYE77VTA.js +1054 -0
- package/Build/Workers/chunk-O6RZEKHZ.js +778 -0
- package/Build/Workers/chunk-OFOJ5HD6.js +1460 -0
- package/Build/Workers/chunk-OJNNQSZI.js +788 -0
- package/Build/Workers/chunk-OJXQBSG4.js +692 -0
- package/Build/Workers/chunk-OOCGX2OD.js +102 -0
- package/Build/Workers/chunk-OOY3DP7Z.js +788 -0
- package/Build/Workers/chunk-OSDDHXLU.js +1483 -0
- package/Build/Workers/chunk-OVZNLF46.js +241 -0
- package/Build/Workers/chunk-OXFU5HNU.js +162 -0
- package/Build/Workers/chunk-P5CGIJUY.js +73 -0
- package/Build/Workers/chunk-POLLOX2O.js +352 -0
- package/Build/Workers/chunk-POUR54ZW.js +37 -0
- package/Build/Workers/chunk-PR6F33M6.js +682 -0
- package/Build/Workers/chunk-Q6GCDF2J.js +44 -0
- package/Build/Workers/chunk-Q7HIBRGE.js +97 -0
- package/Build/Workers/chunk-QCJPQ5CQ.js +57 -0
- package/Build/Workers/chunk-QDKQNKG3.js +256 -0
- package/Build/Workers/chunk-QDTDTLQY.js +1067 -0
- package/Build/Workers/chunk-QEANVUGT.js +163 -0
- package/Build/Workers/chunk-QFBCIX7J.js +455 -0
- package/Build/Workers/chunk-QIKGPNLN.js +299 -0
- package/Build/Workers/chunk-QTKDUHWH.js +497 -0
- package/Build/Workers/chunk-QUAH3XOT.js +138 -0
- package/Build/Workers/chunk-R4MI537H.js +1443 -0
- package/Build/Workers/chunk-R5GL5C3T.js +1483 -0
- package/Build/Workers/chunk-RBAGNNPN.js +219 -0
- package/Build/Workers/chunk-RH6GMTSG.js +497 -0
- package/Build/Workers/chunk-RHJJWKSH.js +73 -0
- package/Build/Workers/chunk-RHV6AHJW.js +305 -0
- package/Build/Workers/chunk-RUZPDKUX.js +114 -0
- package/Build/Workers/chunk-RXZDTDIY.js +439 -0
- package/Build/Workers/chunk-SCSEVBY4.js +102 -0
- package/Build/Workers/chunk-SKMYTWWS.js +299 -0
- package/Build/Workers/chunk-SKVAQOZZ.js +1443 -0
- package/Build/Workers/chunk-SPA2KPH3.js +368 -0
- package/Build/Workers/chunk-STDNU6SV.js +1460 -0
- package/Build/Workers/chunk-SXOBEELD.js +55 -0
- package/Build/Workers/chunk-SYDXDJY5.js +2058 -0
- package/Build/Workers/chunk-SZ4ALZDU.js +305 -0
- package/Build/Workers/chunk-T2AGEECA.js +387 -0
- package/Build/Workers/chunk-T5ZG4SFF.js +1067 -0
- package/Build/Workers/chunk-TDSVSW5A.js +1460 -0
- package/Build/Workers/chunk-TJF36YYN.js +837 -0
- package/Build/Workers/chunk-TNZHNGKK.js +439 -0
- package/Build/Workers/chunk-TTWIV2BN.js +102 -0
- package/Build/Workers/chunk-TX3TQPIA.js +44 -0
- package/Build/Workers/chunk-TYPTCQPI.js +1317 -0
- package/Build/Workers/chunk-TZA4ZWFC.js +75 -0
- package/Build/Workers/chunk-UFDTAQBE.js +476 -0
- package/Build/Workers/chunk-UG2DPFOL.js +352 -0
- package/Build/Workers/chunk-UG3AH5C3.js +629 -0
- package/Build/Workers/chunk-UPPGWBJU.js +511 -0
- package/Build/Workers/chunk-URGEDZBS.js +476 -0
- package/Build/Workers/chunk-V35NQOJC.js +642 -0
- package/Build/Workers/chunk-VDNDTTCD.js +958 -0
- package/Build/Workers/chunk-VQIKTYAO.js +368 -0
- package/Build/Workers/chunk-VRXHACYU.js +476 -0
- package/Build/Workers/chunk-VTYZVS6I.js +455 -0
- package/Build/Workers/chunk-VVNCCJGH.js +398 -0
- package/Build/Workers/chunk-W4V3BNFU.js +114 -0
- package/Build/Workers/chunk-W4XUEDU5.js +2058 -0
- package/Build/Workers/chunk-W7UYJE5O.js +2719 -0
- package/Build/Workers/chunk-WB4TSSBQ.js +3514 -0
- package/Build/Workers/chunk-WGZVYW2C.js +124 -0
- package/Build/Workers/chunk-WNFIOIKE.js +414 -0
- package/Build/Workers/chunk-WNHOCO2K.js +280 -0
- package/Build/Workers/chunk-WQG2W2WD.js +837 -0
- package/Build/Workers/chunk-WTLYD4FE.js +1483 -0
- package/Build/Workers/chunk-WV2G6UNC.js +940 -0
- package/Build/Workers/chunk-WVC3OW5V.js +629 -0
- package/Build/Workers/chunk-WWQFFOV6.js +299 -0
- package/Build/Workers/chunk-XD7QHRAY.js +288 -0
- package/Build/Workers/chunk-XH6GW5M4.js +58 -0
- package/Build/Workers/chunk-XIX2VR7Z.js +778 -0
- package/Build/Workers/chunk-XJYSONL4.js +1054 -0
- package/Build/Workers/chunk-XP6ASNFM.js +1317 -0
- package/Build/Workers/chunk-XRDMBCX3.js +439 -0
- package/Build/Workers/chunk-XUA6BCV5.js +642 -0
- package/Build/Workers/chunk-XVBMYEYQ.js +124 -0
- package/Build/Workers/chunk-XWOAVRWZ.js +124 -0
- package/Build/Workers/chunk-Y4ALZ4SS.js +198 -0
- package/Build/Workers/chunk-Y4GOZA56.js +163 -0
- package/Build/Workers/chunk-YF2NVO5B.js +837 -0
- package/Build/Workers/chunk-YGVXG7IR.js +114 -0
- package/Build/Workers/chunk-YI7RTZGC.js +280 -0
- package/Build/Workers/chunk-YM4UTBTX.js +1800 -0
- package/Build/Workers/chunk-YP5ZF2MJ.js +162 -0
- package/Build/Workers/chunk-YSSL4KKM.js +387 -0
- package/Build/Workers/chunk-YSYSXSHF.js +629 -0
- package/Build/Workers/chunk-YX562XOB.js +692 -0
- package/Build/Workers/chunk-YZWA5B4R.js +511 -0
- package/Build/Workers/chunk-Z6DFT4D3.js +288 -0
- package/Build/Workers/chunk-Z6PVZUIE.js +398 -0
- package/Build/Workers/chunk-ZAI6LCSI.js +511 -0
- package/Build/Workers/chunk-ZBIINVUF.js +778 -0
- package/Build/Workers/chunk-ZG3TBDRX.js +1317 -0
- package/Build/Workers/chunk-ZGXHZJ75.js +439 -0
- package/Build/Workers/chunk-ZWDOE2JF.js +162 -0
- package/Build/Workers/combineGeometry.js +66 -0
- package/Build/Workers/createBoxGeometry.js +58 -0
- package/Build/Workers/createBoxOutlineGeometry.js +231 -0
- package/Build/Workers/createCircleGeometry.js +201 -0
- package/Build/Workers/createCircleOutlineGeometry.js +147 -0
- package/Build/Workers/createCoplanarPolygonGeometry.js +505 -0
- package/Build/Workers/createCoplanarPolygonOutlineGeometry.js +225 -0
- package/Build/Workers/createCorridorGeometry.js +1258 -0
- package/Build/Workers/createCorridorOutlineGeometry.js +563 -0
- package/Build/Workers/createCylinderGeometry.js +60 -0
- package/Build/Workers/createCylinderOutlineGeometry.js +231 -0
- package/Build/Workers/createEllipseGeometry.js +72 -0
- package/Build/Workers/createEllipseOutlineGeometry.js +65 -0
- package/Build/Workers/createEllipsoidGeometry.js +59 -0
- package/Build/Workers/createEllipsoidOutlineGeometry.js +61 -0
- package/Build/Workers/createFrustumGeometry.js +58 -0
- package/Build/Workers/createFrustumOutlineGeometry.js +234 -0
- package/Build/Workers/createGeometry.js +173 -0
- package/Build/Workers/createGroundPolylineGeometry.js +1602 -0
- package/Build/Workers/createPlaneGeometry.js +223 -0
- package/Build/Workers/createPlaneOutlineGeometry.js +124 -0
- package/Build/Workers/createPolygonGeometry.js +1404 -0
- package/Build/Workers/createPolygonOutlineGeometry.js +532 -0
- package/Build/Workers/createPolylineGeometry.js +491 -0
- package/Build/Workers/createPolylineVolumeGeometry.js +374 -0
- package/Build/Workers/createPolylineVolumeOutlineGeometry.js +272 -0
- package/Build/Workers/createRectangleGeometry.js +1264 -0
- package/Build/Workers/createRectangleOutlineGeometry.js +476 -0
- package/Build/Workers/createSimplePolylineGeometry.js +397 -0
- package/Build/Workers/createSphereGeometry.js +116 -0
- package/Build/Workers/createSphereOutlineGeometry.js +116 -0
- package/Build/Workers/createTaskProcessorWorker.js +32 -0
- package/Build/Workers/createVectorTileClampedPolylines.js +492 -0
- package/Build/Workers/createVectorTileGeometries.js +387 -0
- package/Build/Workers/createVectorTilePoints.js +114 -0
- package/Build/Workers/createVectorTilePolygons.js +386 -0
- package/Build/Workers/createVectorTilePolylines.js +262 -0
- package/Build/Workers/createVerticesFromCesium3DTilesTerrain.js +91 -0
- package/Build/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +565 -0
- package/Build/Workers/createVerticesFromHeightmap.js +2254 -0
- package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +499 -0
- package/Build/Workers/createWallGeometry.js +487 -0
- package/Build/Workers/createWallOutlineGeometry.js +335 -0
- package/Build/Workers/decodeDraco.js +369 -0
- package/Build/Workers/decodeGoogleEarthEnterprisePacket.js +2666 -0
- package/Build/Workers/decodeI3S.js +1339 -0
- package/Build/Workers/gaussianSplatSorter.js +62 -0
- package/Build/Workers/gaussianSplatTextureGenerator.js +68 -0
- package/Build/Workers/incrementallyBuildTerrainPicker.js +121 -0
- package/Build/Workers/transcodeKTX2.js +3463 -0
- package/Build/Workers/transferTypedArrayTest.js +41 -0
- package/Build/Workers/upsampleQuantizedTerrainMesh.js +820 -0
- package/Build/Workers/upsampleVerticesFromCesium3DTilesTerrain.js +95 -0
- package/LICENSE.md +928 -0
- package/README.md +3 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_0.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_1.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_10.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_11.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_12.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_13.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_14.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_15.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_16.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_17.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_18.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_19.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_2.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_20.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_21.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_22.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_23.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_24.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_25.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_26.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_27.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_3.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_4.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_5.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_6.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_7.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_8.json +1 -0
- package/Source/Assets/IAU2006_XYS/IAU2006_XYS_9.json +1 -0
- package/Source/Assets/Images/bing_maps_credit.png +0 -0
- package/Source/Assets/Images/cesium_credit.png +0 -0
- package/Source/Assets/Images/google_earth_credit.png +0 -0
- package/Source/Assets/Images/ion-credit.png +0 -0
- package/Source/Assets/Textures/LensFlare/DirtMask.jpg +0 -0
- package/Source/Assets/Textures/LensFlare/StarBurst.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/0/0/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/0/1/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/0/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/0/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/1/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/1/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/2/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/2/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/3/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/1/3/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/0/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/0/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/0/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/0/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/1/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/1/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/1/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/1/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/2/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/2/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/2/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/2/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/3/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/3/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/3/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/3/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/4/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/4/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/4/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/4/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/5/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/5/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/5/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/5/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/6/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/6/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/6/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/6/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/7/0.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/7/1.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/7/2.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/2/7/3.jpg +0 -0
- package/Source/Assets/Textures/NaturalEarthII/tilemapresource.xml +14 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_mx.jpg +0 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_my.jpg +0 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_mz.jpg +0 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_px.jpg +0 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_py.jpg +0 -0
- package/Source/Assets/Textures/SkyBox/tycho2t3_80_pz.jpg +0 -0
- package/Source/Assets/Textures/maki/airfield.png +0 -0
- package/Source/Assets/Textures/maki/airport.png +0 -0
- package/Source/Assets/Textures/maki/alcohol-shop.png +0 -0
- package/Source/Assets/Textures/maki/america-football.png +0 -0
- package/Source/Assets/Textures/maki/art-gallery.png +0 -0
- package/Source/Assets/Textures/maki/bakery.png +0 -0
- package/Source/Assets/Textures/maki/bank.png +0 -0
- package/Source/Assets/Textures/maki/bar.png +0 -0
- package/Source/Assets/Textures/maki/baseball.png +0 -0
- package/Source/Assets/Textures/maki/basketball.png +0 -0
- package/Source/Assets/Textures/maki/beer.png +0 -0
- package/Source/Assets/Textures/maki/bicycle.png +0 -0
- package/Source/Assets/Textures/maki/building.png +0 -0
- package/Source/Assets/Textures/maki/bus.png +0 -0
- package/Source/Assets/Textures/maki/cafe.png +0 -0
- package/Source/Assets/Textures/maki/camera.png +0 -0
- package/Source/Assets/Textures/maki/campsite.png +0 -0
- package/Source/Assets/Textures/maki/car.png +0 -0
- package/Source/Assets/Textures/maki/cemetery.png +0 -0
- package/Source/Assets/Textures/maki/cesium.png +0 -0
- package/Source/Assets/Textures/maki/chemist.png +0 -0
- package/Source/Assets/Textures/maki/cinema.png +0 -0
- package/Source/Assets/Textures/maki/circle-stroked.png +0 -0
- package/Source/Assets/Textures/maki/circle.png +0 -0
- package/Source/Assets/Textures/maki/city.png +0 -0
- package/Source/Assets/Textures/maki/clothing-store.png +0 -0
- package/Source/Assets/Textures/maki/college.png +0 -0
- package/Source/Assets/Textures/maki/commercial.png +0 -0
- package/Source/Assets/Textures/maki/cricket.png +0 -0
- package/Source/Assets/Textures/maki/cross.png +0 -0
- package/Source/Assets/Textures/maki/dam.png +0 -0
- package/Source/Assets/Textures/maki/danger.png +0 -0
- package/Source/Assets/Textures/maki/disability.png +0 -0
- package/Source/Assets/Textures/maki/dog-park.png +0 -0
- package/Source/Assets/Textures/maki/embassy.png +0 -0
- package/Source/Assets/Textures/maki/emergency-telephone.png +0 -0
- package/Source/Assets/Textures/maki/entrance.png +0 -0
- package/Source/Assets/Textures/maki/farm.png +0 -0
- package/Source/Assets/Textures/maki/fast-food.png +0 -0
- package/Source/Assets/Textures/maki/ferry.png +0 -0
- package/Source/Assets/Textures/maki/fire-station.png +0 -0
- package/Source/Assets/Textures/maki/fuel.png +0 -0
- package/Source/Assets/Textures/maki/garden.png +0 -0
- package/Source/Assets/Textures/maki/gift.png +0 -0
- package/Source/Assets/Textures/maki/golf.png +0 -0
- package/Source/Assets/Textures/maki/grocery.png +0 -0
- package/Source/Assets/Textures/maki/hairdresser.png +0 -0
- package/Source/Assets/Textures/maki/harbor.png +0 -0
- package/Source/Assets/Textures/maki/heart.png +0 -0
- package/Source/Assets/Textures/maki/heliport.png +0 -0
- package/Source/Assets/Textures/maki/hospital.png +0 -0
- package/Source/Assets/Textures/maki/ice-cream.png +0 -0
- package/Source/Assets/Textures/maki/industrial.png +0 -0
- package/Source/Assets/Textures/maki/land-use.png +0 -0
- package/Source/Assets/Textures/maki/laundry.png +0 -0
- package/Source/Assets/Textures/maki/library.png +0 -0
- package/Source/Assets/Textures/maki/lighthouse.png +0 -0
- package/Source/Assets/Textures/maki/lodging.png +0 -0
- package/Source/Assets/Textures/maki/logging.png +0 -0
- package/Source/Assets/Textures/maki/london-underground.png +0 -0
- package/Source/Assets/Textures/maki/marker-stroked.png +0 -0
- package/Source/Assets/Textures/maki/marker.png +0 -0
- package/Source/Assets/Textures/maki/minefield.png +0 -0
- package/Source/Assets/Textures/maki/mobilephone.png +0 -0
- package/Source/Assets/Textures/maki/monument.png +0 -0
- package/Source/Assets/Textures/maki/museum.png +0 -0
- package/Source/Assets/Textures/maki/music.png +0 -0
- package/Source/Assets/Textures/maki/oil-well.png +0 -0
- package/Source/Assets/Textures/maki/park.png +0 -0
- package/Source/Assets/Textures/maki/park2.png +0 -0
- package/Source/Assets/Textures/maki/parking-garage.png +0 -0
- package/Source/Assets/Textures/maki/parking.png +0 -0
- package/Source/Assets/Textures/maki/pharmacy.png +0 -0
- package/Source/Assets/Textures/maki/pitch.png +0 -0
- package/Source/Assets/Textures/maki/place-of-worship.png +0 -0
- package/Source/Assets/Textures/maki/playground.png +0 -0
- package/Source/Assets/Textures/maki/police.png +0 -0
- package/Source/Assets/Textures/maki/polling-place.png +0 -0
- package/Source/Assets/Textures/maki/post.png +0 -0
- package/Source/Assets/Textures/maki/prison.png +0 -0
- package/Source/Assets/Textures/maki/rail-above.png +0 -0
- package/Source/Assets/Textures/maki/rail-light.png +0 -0
- package/Source/Assets/Textures/maki/rail-metro.png +0 -0
- package/Source/Assets/Textures/maki/rail-underground.png +0 -0
- package/Source/Assets/Textures/maki/rail.png +0 -0
- package/Source/Assets/Textures/maki/religious-christian.png +0 -0
- package/Source/Assets/Textures/maki/religious-jewish.png +0 -0
- package/Source/Assets/Textures/maki/religious-muslim.png +0 -0
- package/Source/Assets/Textures/maki/restaurant.png +0 -0
- package/Source/Assets/Textures/maki/roadblock.png +0 -0
- package/Source/Assets/Textures/maki/rocket.png +0 -0
- package/Source/Assets/Textures/maki/school.png +0 -0
- package/Source/Assets/Textures/maki/scooter.png +0 -0
- package/Source/Assets/Textures/maki/shop.png +0 -0
- package/Source/Assets/Textures/maki/skiing.png +0 -0
- package/Source/Assets/Textures/maki/slaughterhouse.png +0 -0
- package/Source/Assets/Textures/maki/soccer.png +0 -0
- package/Source/Assets/Textures/maki/square-stroked.png +0 -0
- package/Source/Assets/Textures/maki/square.png +0 -0
- package/Source/Assets/Textures/maki/star-stroked.png +0 -0
- package/Source/Assets/Textures/maki/star.png +0 -0
- package/Source/Assets/Textures/maki/suitcase.png +0 -0
- package/Source/Assets/Textures/maki/swimming.png +0 -0
- package/Source/Assets/Textures/maki/telephone.png +0 -0
- package/Source/Assets/Textures/maki/tennis.png +0 -0
- package/Source/Assets/Textures/maki/theatre.png +0 -0
- package/Source/Assets/Textures/maki/toilets.png +0 -0
- package/Source/Assets/Textures/maki/town-hall.png +0 -0
- package/Source/Assets/Textures/maki/town.png +0 -0
- package/Source/Assets/Textures/maki/triangle-stroked.png +0 -0
- package/Source/Assets/Textures/maki/triangle.png +0 -0
- package/Source/Assets/Textures/maki/village.png +0 -0
- package/Source/Assets/Textures/maki/warehouse.png +0 -0
- package/Source/Assets/Textures/maki/waste-basket.png +0 -0
- package/Source/Assets/Textures/maki/water.png +0 -0
- package/Source/Assets/Textures/maki/wetland.png +0 -0
- package/Source/Assets/Textures/maki/zoo.png +0 -0
- package/Source/Assets/Textures/moonSmall.jpg +0 -0
- package/Source/Assets/Textures/pin.svg +1 -0
- package/Source/Assets/Textures/waterNormals.jpg +0 -0
- package/Source/Assets/Textures/waterNormalsSmall.jpg +0 -0
- package/Source/Assets/approximateTerrainHeights.json +1 -0
- package/Source/Core/ApproximateTerrainHeights.js +255 -0
- package/Source/Core/ArcGISTiledElevationTerrainProvider.js +755 -0
- package/Source/Core/ArcType.js +31 -0
- package/Source/Core/ArticulationStageType.js +23 -0
- package/Source/Core/AssociativeArray.js +127 -0
- package/Source/Core/AttributeCompression.js +527 -0
- package/Source/Core/AxisAlignedBoundingBox.js +294 -0
- package/Source/Core/BingMapsGeocoderService.js +127 -0
- package/Source/Core/BoundingRectangle.js +374 -0
- package/Source/Core/BoundingSphere.js +1506 -0
- package/Source/Core/BoxGeometry.js +893 -0
- package/Source/Core/BoxOutlineGeometry.js +312 -0
- package/Source/Core/Cartesian2.js +823 -0
- package/Source/Core/Cartesian3.js +1220 -0
- package/Source/Core/Cartesian4.js +979 -0
- package/Source/Core/Cartographic.js +304 -0
- package/Source/Core/CartographicGeocoderService.js +73 -0
- package/Source/Core/CatmullRomSpline.js +324 -0
- package/Source/Core/Cesium3DTilesTerrainData.js +932 -0
- package/Source/Core/Cesium3DTilesTerrainGeometryProcessor.js +1868 -0
- package/Source/Core/Cesium3DTilesTerrainProvider.js +1052 -0
- package/Source/Core/CesiumTerrainProvider.js +1408 -0
- package/Source/Core/Check.d.ts +131 -0
- package/Source/Core/Check.js +212 -0
- package/Source/Core/CircleGeometry.js +207 -0
- package/Source/Core/CircleOutlineGeometry.js +149 -0
- package/Source/Core/Clock.js +316 -0
- package/Source/Core/ClockRange.js +39 -0
- package/Source/Core/ClockStep.js +38 -0
- package/Source/Core/Color.js +2283 -0
- package/Source/Core/ColorGeometryInstanceAttribute.js +181 -0
- package/Source/Core/ComponentDatatype.js +338 -0
- package/Source/Core/CompressedTextureBuffer.js +125 -0
- package/Source/Core/ConstantSpline.js +119 -0
- package/Source/Core/CoplanarPolygonGeometry.js +600 -0
- package/Source/Core/CoplanarPolygonGeometryLibrary.js +132 -0
- package/Source/Core/CoplanarPolygonOutlineGeometry.js +237 -0
- package/Source/Core/CornerType.js +37 -0
- package/Source/Core/CorridorGeometry.js +1411 -0
- package/Source/Core/CorridorGeometryLibrary.js +501 -0
- package/Source/Core/CorridorOutlineGeometry.js +599 -0
- package/Source/Core/Credit.js +172 -0
- package/Source/Core/CubicRealPolynomial.js +238 -0
- package/Source/Core/CullingVolume.js +216 -0
- package/Source/Core/CustomHeightmapTerrainProvider.js +287 -0
- package/Source/Core/CylinderGeometry.js +479 -0
- package/Source/Core/CylinderGeometryLibrary.js +59 -0
- package/Source/Core/CylinderOutlineGeometry.js +269 -0
- package/Source/Core/DefaultProxy.js +26 -0
- package/Source/Core/DeveloperError.js +75 -0
- package/Source/Core/DistanceDisplayCondition.js +171 -0
- package/Source/Core/DistanceDisplayConditionGeometryInstanceAttribute.js +179 -0
- package/Source/Core/DoubleEndedPriorityQueue.js +405 -0
- package/Source/Core/DoublyLinkedList.js +112 -0
- package/Source/Core/EarthOrientationParameters.js +431 -0
- package/Source/Core/EarthOrientationParametersSample.js +52 -0
- package/Source/Core/EasingFunction.js +257 -0
- package/Source/Core/EllipseGeometry.js +1318 -0
- package/Source/Core/EllipseGeometryLibrary.js +365 -0
- package/Source/Core/EllipseOutlineGeometry.js +451 -0
- package/Source/Core/Ellipsoid.js +889 -0
- package/Source/Core/EllipsoidGeodesic.js +523 -0
- package/Source/Core/EllipsoidGeometry.js +650 -0
- package/Source/Core/EllipsoidOutlineGeometry.js +464 -0
- package/Source/Core/EllipsoidRhumbLine.js +751 -0
- package/Source/Core/EllipsoidTangentPlane.js +382 -0
- package/Source/Core/EllipsoidTerrainProvider.js +201 -0
- package/Source/Core/EllipsoidalOccluder.js +538 -0
- package/Source/Core/EncodedCartesian3.js +170 -0
- package/Source/Core/Event.js +205 -0
- package/Source/Core/EventHelper.js +74 -0
- package/Source/Core/ExtrapolationType.js +34 -0
- package/Source/Core/FeatureDetection.js +435 -0
- package/Source/Core/Frozen.js +24 -0
- package/Source/Core/FrustumGeometry.js +583 -0
- package/Source/Core/FrustumOutlineGeometry.js +253 -0
- package/Source/Core/Fullscreen.js +249 -0
- package/Source/Core/GeocodeType.js +24 -0
- package/Source/Core/GeocoderService.js +60 -0
- package/Source/Core/GeographicProjection.js +105 -0
- package/Source/Core/GeographicTilingScheme.js +245 -0
- package/Source/Core/Geometry.js +371 -0
- package/Source/Core/GeometryAttribute.js +133 -0
- package/Source/Core/GeometryAttributes.js +88 -0
- package/Source/Core/GeometryFactory.js +25 -0
- package/Source/Core/GeometryInstance.js +118 -0
- package/Source/Core/GeometryInstanceAttribute.js +133 -0
- package/Source/Core/GeometryOffsetAttribute.js +10 -0
- package/Source/Core/GeometryPipeline.js +3291 -0
- package/Source/Core/GeometryType.js +10 -0
- package/Source/Core/GoogleEarthEnterpriseMetadata.js +584 -0
- package/Source/Core/GoogleEarthEnterpriseTerrainData.js +606 -0
- package/Source/Core/GoogleEarthEnterpriseTerrainProvider.js +574 -0
- package/Source/Core/GoogleEarthEnterpriseTileInformation.js +136 -0
- package/Source/Core/GoogleGeocoderService.js +110 -0
- package/Source/Core/GoogleMaps.js +40 -0
- package/Source/Core/GregorianDate.js +153 -0
- package/Source/Core/GroundPolylineGeometry.js +1659 -0
- package/Source/Core/HeadingPitchRange.js +59 -0
- package/Source/Core/HeadingPitchRoll.js +235 -0
- package/Source/Core/Heap.js +233 -0
- package/Source/Core/HeightmapEncoding.js +25 -0
- package/Source/Core/HeightmapTerrainData.js +903 -0
- package/Source/Core/HeightmapTessellator.js +518 -0
- package/Source/Core/HermitePolynomialApproximation.js +341 -0
- package/Source/Core/HermiteSpline.js +620 -0
- package/Source/Core/HilbertOrder.js +112 -0
- package/Source/Core/ITwinPlatform.js +388 -0
- package/Source/Core/Iau2000Orientation.js +167 -0
- package/Source/Core/Iau2006XysData.js +275 -0
- package/Source/Core/Iau2006XysSample.js +32 -0
- package/Source/Core/IauOrientationAxes.js +105 -0
- package/Source/Core/IauOrientationParameters.js +54 -0
- package/Source/Core/IndexDatatype.js +199 -0
- package/Source/Core/InterpolationAlgorithm.js +65 -0
- package/Source/Core/InterpolationType.js +14 -0
- package/Source/Core/Intersect.js +34 -0
- package/Source/Core/IntersectionTests.js +1087 -0
- package/Source/Core/Intersections2D.js +358 -0
- package/Source/Core/Interval.js +23 -0
- package/Source/Core/Ion.js +56 -0
- package/Source/Core/IonGeocodeProviderType.js +33 -0
- package/Source/Core/IonGeocoderService.js +147 -0
- package/Source/Core/IonResource.js +321 -0
- package/Source/Core/Iso8601.js +54 -0
- package/Source/Core/JulianDate.js +1229 -0
- package/Source/Core/KTX2Transcoder.js +92 -0
- package/Source/Core/KeyboardEventModifier.js +32 -0
- package/Source/Core/LagrangePolynomialApproximation.js +71 -0
- package/Source/Core/LeapSecond.js +24 -0
- package/Source/Core/LinearApproximation.js +83 -0
- package/Source/Core/LinearSpline.js +166 -0
- package/Source/Core/ManagedArray.js +162 -0
- package/Source/Core/MapProjection.js +62 -0
- package/Source/Core/Math.js +1125 -0
- package/Source/Core/Matrix2.js +1092 -0
- package/Source/Core/Matrix3.js +1838 -0
- package/Source/Core/Matrix4.js +3233 -0
- package/Source/Core/MorphWeightSpline.js +161 -0
- package/Source/Core/MortonOrder.js +214 -0
- package/Source/Core/NearFarScalar.js +173 -0
- package/Source/Core/Occluder.js +727 -0
- package/Source/Core/OffsetGeometryInstanceAttribute.js +125 -0
- package/Source/Core/OpenCageGeocoderService.js +134 -0
- package/Source/Core/OrientedBoundingBox.js +1272 -0
- package/Source/Core/OrthographicFrustum.js +351 -0
- package/Source/Core/OrthographicOffCenterFrustum.js +463 -0
- package/Source/Core/Packable.js +40 -0
- package/Source/Core/PackableForInterpolation.js +43 -0
- package/Source/Core/PeliasGeocoderService.js +106 -0
- package/Source/Core/PerspectiveFrustum.js +459 -0
- package/Source/Core/PerspectiveOffCenterFrustum.js +522 -0
- package/Source/Core/PinBuilder.js +234 -0
- package/Source/Core/PixelFormat.js +603 -0
- package/Source/Core/Plane.js +312 -0
- package/Source/Core/PlaneGeometry.js +250 -0
- package/Source/Core/PlaneOutlineGeometry.js +113 -0
- package/Source/Core/PolygonGeometry.js +1580 -0
- package/Source/Core/PolygonGeometryLibrary.js +1301 -0
- package/Source/Core/PolygonHierarchy.js +25 -0
- package/Source/Core/PolygonOutlineGeometry.js +687 -0
- package/Source/Core/PolygonPipeline.js +632 -0
- package/Source/Core/PolylineGeometry.js +573 -0
- package/Source/Core/PolylinePipeline.js +573 -0
- package/Source/Core/PolylineVolumeGeometry.js +412 -0
- package/Source/Core/PolylineVolumeGeometryLibrary.js +701 -0
- package/Source/Core/PolylineVolumeOutlineGeometry.js +294 -0
- package/Source/Core/PrimitiveType.js +107 -0
- package/Source/Core/Proxy.js +24 -0
- package/Source/Core/QuadraticRealPolynomial.js +147 -0
- package/Source/Core/QuantizedMeshTerrainData.js +735 -0
- package/Source/Core/QuarticRealPolynomial.js +342 -0
- package/Source/Core/Quaternion.js +1145 -0
- package/Source/Core/QuaternionSpline.js +155 -0
- package/Source/Core/Queue.js +126 -0
- package/Source/Core/Ray.js +79 -0
- package/Source/Core/Rectangle.js +1071 -0
- package/Source/Core/RectangleCollisionChecker.js +95 -0
- package/Source/Core/RectangleGeometry.js +1480 -0
- package/Source/Core/RectangleGeometryLibrary.js +286 -0
- package/Source/Core/RectangleOutlineGeometry.js +532 -0
- package/Source/Core/ReferenceFrame.js +23 -0
- package/Source/Core/Request.js +193 -0
- package/Source/Core/RequestErrorEvent.js +58 -0
- package/Source/Core/RequestScheduler.js +519 -0
- package/Source/Core/RequestState.js +55 -0
- package/Source/Core/RequestType.js +39 -0
- package/Source/Core/Resource.js +2280 -0
- package/Source/Core/RuntimeError.js +65 -0
- package/Source/Core/S2Cell.js +734 -0
- package/Source/Core/ScreenSpaceEventHandler.js +1140 -0
- package/Source/Core/ScreenSpaceEventType.js +127 -0
- package/Source/Core/ShowGeometryInstanceAttribute.js +122 -0
- package/Source/Core/Simon1994PlanetaryPositions.js +684 -0
- package/Source/Core/SimplePolylineGeometry.js +454 -0
- package/Source/Core/SphereGeometry.js +117 -0
- package/Source/Core/SphereOutlineGeometry.js +119 -0
- package/Source/Core/Spherical.js +183 -0
- package/Source/Core/Spline.js +188 -0
- package/Source/Core/SteppedSpline.js +160 -0
- package/Source/Core/Stereographic.js +247 -0
- package/Source/Core/TaskProcessor.js +403 -0
- package/Source/Core/TerrainData.js +126 -0
- package/Source/Core/TerrainEncoding.js +772 -0
- package/Source/Core/TerrainMesh.js +361 -0
- package/Source/Core/TerrainPicker.js +607 -0
- package/Source/Core/TerrainProvider.js +585 -0
- package/Source/Core/TerrainQuantization.js +25 -0
- package/Source/Core/TexturePacker.js +181 -0
- package/Source/Core/TileAvailability.js +564 -0
- package/Source/Core/TileEdge.js +14 -0
- package/Source/Core/TileProviderError.js +170 -0
- package/Source/Core/TilingScheme.js +132 -0
- package/Source/Core/TimeConstants.js +83 -0
- package/Source/Core/TimeInterval.js +438 -0
- package/Source/Core/TimeIntervalCollection.js +1137 -0
- package/Source/Core/TimeStandard.js +30 -0
- package/Source/Core/Tipsify.js +314 -0
- package/Source/Core/TrackingReferenceFrame.js +45 -0
- package/Source/Core/Transforms.js +1277 -0
- package/Source/Core/TranslationRotationScale.js +57 -0
- package/Source/Core/TridiagonalSystemSolver.js +113 -0
- package/Source/Core/TrustedServers.js +146 -0
- package/Source/Core/VRTheWorldTerrainProvider.js +462 -0
- package/Source/Core/VertexFormat.js +311 -0
- package/Source/Core/VerticalExaggeration.js +70 -0
- package/Source/Core/VideoSynchronizer.js +222 -0
- package/Source/Core/Visibility.js +34 -0
- package/Source/Core/VulkanConstants.js +286 -0
- package/Source/Core/WallGeometry.js +623 -0
- package/Source/Core/WallGeometryLibrary.js +212 -0
- package/Source/Core/WallOutlineGeometry.js +431 -0
- package/Source/Core/WebGLConstants.js +614 -0
- package/Source/Core/WebMercatorProjection.js +152 -0
- package/Source/Core/WebMercatorTilingScheme.js +291 -0
- package/Source/Core/WindingOrder.js +36 -0
- package/Source/Core/WireframeIndexGenerator.js +238 -0
- package/Source/Core/addAllToArray.js +40 -0
- package/Source/Core/appendForwardSlash.js +10 -0
- package/Source/Core/arrayRemoveDuplicates.js +129 -0
- package/Source/Core/barycentricCoordinates.js +109 -0
- package/Source/Core/binarySearch.js +67 -0
- package/Source/Core/buildModuleUrl.js +153 -0
- package/Source/Core/clone.js +30 -0
- package/Source/Core/combine.js +79 -0
- package/Source/Core/createGuid.js +22 -0
- package/Source/Core/createWorldBathymetryAsync.js +45 -0
- package/Source/Core/createWorldTerrainAsync.js +50 -0
- package/Source/Core/decodeGoogleEarthEnterpriseData.js +93 -0
- package/Source/Core/decodeVectorPolylinePositions.js +51 -0
- package/Source/Core/defaultValue.js +29 -0
- package/Source/Core/defer.js +44 -0
- package/Source/Core/defined.d.ts +11 -0
- package/Source/Core/defined.js +17 -0
- package/Source/Core/deprecationWarning.js +53 -0
- package/Source/Core/destroyObject.js +53 -0
- package/Source/Core/formatError.js +30 -0
- package/Source/Core/getAbsoluteUri.js +46 -0
- package/Source/Core/getBaseUri.js +47 -0
- package/Source/Core/getExtensionFromUri.js +38 -0
- package/Source/Core/getFilenameFromUri.js +32 -0
- package/Source/Core/getImageFromTypedArray.js +24 -0
- package/Source/Core/getImagePixels.js +44 -0
- package/Source/Core/getJsonFromTypedArray.js +21 -0
- package/Source/Core/getMagic.js +14 -0
- package/Source/Core/getStringFromTypedArray.js +165 -0
- package/Source/Core/getTimestamp.js +26 -0
- package/Source/Core/isBitSet.js +7 -0
- package/Source/Core/isBlobUri.js +22 -0
- package/Source/Core/isCrossOriginUrl.js +30 -0
- package/Source/Core/isDataUri.js +22 -0
- package/Source/Core/isLeapYear.js +23 -0
- package/Source/Core/loadAndExecuteScript.js +27 -0
- package/Source/Core/loadImageFromTypedArray.js +66 -0
- package/Source/Core/loadKTX2.js +104 -0
- package/Source/Core/mergeSort.js +111 -0
- package/Source/Core/objectToQuery.js +57 -0
- package/Source/Core/oneTimeWarning.js +51 -0
- package/Source/Core/parseResponseHeaders.js +37 -0
- package/Source/Core/pointInsideTriangle.js +39 -0
- package/Source/Core/queryToObject.js +60 -0
- package/Source/Core/resizeImageToNextPowerOfTwo.js +31 -0
- package/Source/Core/sampleTerrain.js +291 -0
- package/Source/Core/sampleTerrainMostDetailed.js +132 -0
- package/Source/Core/scaleToGeodeticSurface.js +147 -0
- package/Source/Core/srgbToLinear.js +32 -0
- package/Source/Core/subdivideArray.js +35 -0
- package/Source/Core/webGLConstantToGlslType.js +25 -0
- package/Source/Core/wrapFunction.js +26 -0
- package/Source/Core/writeTextToCanvas.js +219 -0
- package/Source/DataSources/BillboardGraphics.js +419 -0
- package/Source/DataSources/BillboardVisualizer.js +351 -0
- package/Source/DataSources/BoundingSphereState.js +26 -0
- package/Source/DataSources/BoxGeometryUpdater.js +326 -0
- package/Source/DataSources/BoxGraphics.js +208 -0
- package/Source/DataSources/CallbackPositionProperty.js +172 -0
- package/Source/DataSources/CallbackProperty.js +117 -0
- package/Source/DataSources/Cesium3DTilesetGraphics.js +111 -0
- package/Source/DataSources/Cesium3DTilesetVisualizer.js +261 -0
- package/Source/DataSources/CheckerboardMaterialProperty.js +157 -0
- package/Source/DataSources/ColorMaterialProperty.js +112 -0
- package/Source/DataSources/CompositeEntityCollection.js +591 -0
- package/Source/DataSources/CompositeMaterialProperty.js +128 -0
- package/Source/DataSources/CompositePositionProperty.js +153 -0
- package/Source/DataSources/CompositeProperty.js +154 -0
- package/Source/DataSources/ConstantPositionProperty.js +151 -0
- package/Source/DataSources/ConstantProperty.js +116 -0
- package/Source/DataSources/CorridorGeometryUpdater.js +409 -0
- package/Source/DataSources/CorridorGraphics.js +316 -0
- package/Source/DataSources/CustomDataSource.js +173 -0
- package/Source/DataSources/CylinderGeometryUpdater.js +375 -0
- package/Source/DataSources/CylinderGraphics.js +258 -0
- package/Source/DataSources/CzmlDataSource.js +5142 -0
- package/Source/DataSources/DataSource.js +121 -0
- package/Source/DataSources/DataSourceClock.js +164 -0
- package/Source/DataSources/DataSourceCollection.js +335 -0
- package/Source/DataSources/DataSourceDisplay.js +543 -0
- package/Source/DataSources/DynamicGeometryBatch.js +56 -0
- package/Source/DataSources/DynamicGeometryUpdater.js +270 -0
- package/Source/DataSources/EllipseGeometryUpdater.js +434 -0
- package/Source/DataSources/EllipseGraphics.js +343 -0
- package/Source/DataSources/EllipsoidGeometryUpdater.js +710 -0
- package/Source/DataSources/EllipsoidGraphics.js +312 -0
- package/Source/DataSources/Entity.js +789 -0
- package/Source/DataSources/EntityCluster.js +1022 -0
- package/Source/DataSources/EntityCollection.js +439 -0
- package/Source/DataSources/EntityView.js +476 -0
- package/Source/DataSources/GeoJsonDataSource.js +1064 -0
- package/Source/DataSources/GeometryUpdater.js +538 -0
- package/Source/DataSources/GeometryUpdaterSet.js +114 -0
- package/Source/DataSources/GeometryVisualizer.js +549 -0
- package/Source/DataSources/GpxDataSource.js +1018 -0
- package/Source/DataSources/GridMaterialProperty.js +204 -0
- package/Source/DataSources/GroundGeometryUpdater.js +234 -0
- package/Source/DataSources/ImageMaterialProperty.js +173 -0
- package/Source/DataSources/KmlCamera.js +13 -0
- package/Source/DataSources/KmlDataSource.js +4249 -0
- package/Source/DataSources/KmlLookAt.js +12 -0
- package/Source/DataSources/KmlTour.js +165 -0
- package/Source/DataSources/KmlTourFlyTo.js +109 -0
- package/Source/DataSources/KmlTourWait.js +52 -0
- package/Source/DataSources/LabelGraphics.js +401 -0
- package/Source/DataSources/LabelVisualizer.js +359 -0
- package/Source/DataSources/MaterialProperty.js +111 -0
- package/Source/DataSources/ModelGraphics.js +456 -0
- package/Source/DataSources/ModelVisualizer.js +560 -0
- package/Source/DataSources/NodeTransformationProperty.js +150 -0
- package/Source/DataSources/PathGraphics.js +161 -0
- package/Source/DataSources/PathVisualizer.js +823 -0
- package/Source/DataSources/PlaneGeometryUpdater.js +385 -0
- package/Source/DataSources/PlaneGraphics.js +208 -0
- package/Source/DataSources/PointGraphics.js +223 -0
- package/Source/DataSources/PointVisualizer.js +438 -0
- package/Source/DataSources/PolygonGeometryUpdater.js +591 -0
- package/Source/DataSources/PolygonGraphics.js +383 -0
- package/Source/DataSources/PolylineArrowMaterialProperty.js +110 -0
- package/Source/DataSources/PolylineDashMaterialProperty.js +174 -0
- package/Source/DataSources/PolylineGeometryUpdater.js +878 -0
- package/Source/DataSources/PolylineGlowMaterialProperty.js +152 -0
- package/Source/DataSources/PolylineGraphics.js +241 -0
- package/Source/DataSources/PolylineOutlineMaterialProperty.js +158 -0
- package/Source/DataSources/PolylineVisualizer.js +409 -0
- package/Source/DataSources/PolylineVolumeGeometryUpdater.js +306 -0
- package/Source/DataSources/PolylineVolumeGraphics.js +235 -0
- package/Source/DataSources/PositionProperty.js +131 -0
- package/Source/DataSources/PositionPropertyArray.js +192 -0
- package/Source/DataSources/Property.js +137 -0
- package/Source/DataSources/PropertyArray.js +147 -0
- package/Source/DataSources/PropertyBag.js +275 -0
- package/Source/DataSources/RectangleGeometryUpdater.js +427 -0
- package/Source/DataSources/RectangleGraphics.js +317 -0
- package/Source/DataSources/ReferenceProperty.js +371 -0
- package/Source/DataSources/Rotation.js +155 -0
- package/Source/DataSources/SampledPositionProperty.js +330 -0
- package/Source/DataSources/SampledProperty.js +855 -0
- package/Source/DataSources/ScaledPositionProperty.js +103 -0
- package/Source/DataSources/StaticGeometryColorBatch.js +570 -0
- package/Source/DataSources/StaticGeometryPerMaterialBatch.js +488 -0
- package/Source/DataSources/StaticGroundGeometryColorBatch.js +394 -0
- package/Source/DataSources/StaticGroundGeometryPerMaterialBatch.js +456 -0
- package/Source/DataSources/StaticGroundPolylinePerMaterialBatch.js +434 -0
- package/Source/DataSources/StaticOutlineGeometryBatch.js +465 -0
- package/Source/DataSources/StripeMaterialProperty.js +193 -0
- package/Source/DataSources/StripeOrientation.js +19 -0
- package/Source/DataSources/TerrainOffsetProperty.js +243 -0
- package/Source/DataSources/TimeIntervalCollectionPositionProperty.js +155 -0
- package/Source/DataSources/TimeIntervalCollectionProperty.js +136 -0
- package/Source/DataSources/VelocityOrientationProperty.js +158 -0
- package/Source/DataSources/VelocityVectorProperty.js +213 -0
- package/Source/DataSources/Visualizer.js +61 -0
- package/Source/DataSources/WallGeometryUpdater.js +275 -0
- package/Source/DataSources/WallGraphics.js +236 -0
- package/Source/DataSources/createMaterialPropertyDescriptor.js +35 -0
- package/Source/DataSources/createPropertyDescriptor.js +71 -0
- package/Source/DataSources/createRawPropertyDescriptor.js +13 -0
- package/Source/DataSources/exportKml.js +1517 -0
- package/Source/DataSources/getElement.js +26 -0
- package/Source/DataSources/heightReferenceOnEntityPropertyChanged.js +47 -0
- package/Source/Renderer/AutomaticUniforms.js +1857 -0
- package/Source/Renderer/Buffer.js +452 -0
- package/Source/Renderer/BufferUsage.js +21 -0
- package/Source/Renderer/ClearCommand.js +102 -0
- package/Source/Renderer/ComputeCommand.js +119 -0
- package/Source/Renderer/ComputeEngine.js +135 -0
- package/Source/Renderer/Context.js +1752 -0
- package/Source/Renderer/ContextLimits.js +299 -0
- package/Source/Renderer/CubeMap.js +686 -0
- package/Source/Renderer/CubeMapFace.js +415 -0
- package/Source/Renderer/DrawCommand.js +644 -0
- package/Source/Renderer/Framebuffer.js +447 -0
- package/Source/Renderer/FramebufferManager.js +489 -0
- package/Source/Renderer/MipmapHint.js +19 -0
- package/Source/Renderer/MultisampleFramebuffer.js +136 -0
- package/Source/Renderer/Pass.js +29 -0
- package/Source/Renderer/PassState.js +57 -0
- package/Source/Renderer/PixelDatatype.js +121 -0
- package/Source/Renderer/RenderState.js +967 -0
- package/Source/Renderer/Renderbuffer.js +105 -0
- package/Source/Renderer/RenderbufferFormat.js +42 -0
- package/Source/Renderer/Sampler.js +116 -0
- package/Source/Renderer/ShaderBuilder.js +597 -0
- package/Source/Renderer/ShaderCache.js +287 -0
- package/Source/Renderer/ShaderDestination.js +51 -0
- package/Source/Renderer/ShaderFunction.js +66 -0
- package/Source/Renderer/ShaderProgram.js +619 -0
- package/Source/Renderer/ShaderSource.js +524 -0
- package/Source/Renderer/ShaderStruct.js +55 -0
- package/Source/Renderer/SharedContext.js +186 -0
- package/Source/Renderer/Sync.js +104 -0
- package/Source/Renderer/Texture.js +1126 -0
- package/Source/Renderer/Texture3D.js +578 -0
- package/Source/Renderer/TextureAtlas.js +833 -0
- package/Source/Renderer/TextureCache.js +81 -0
- package/Source/Renderer/TextureMagnificationFilter.js +41 -0
- package/Source/Renderer/TextureMinificationFilter.js +94 -0
- package/Source/Renderer/TextureWrap.js +19 -0
- package/Source/Renderer/UniformState.js +1948 -0
- package/Source/Renderer/VertexArray.js +869 -0
- package/Source/Renderer/VertexArrayFacade.js +509 -0
- package/Source/Renderer/createUniform.js +422 -0
- package/Source/Renderer/createUniformArray.js +638 -0
- package/Source/Renderer/demodernizeShader.js +84 -0
- package/Source/Renderer/freezeRenderState.js +30 -0
- package/Source/Renderer/loadCubeMap.js +88 -0
- package/Source/Scene/AlphaMode.js +33 -0
- package/Source/Scene/Appearance.js +204 -0
- package/Source/Scene/ArcGisBaseMapType.js +12 -0
- package/Source/Scene/ArcGisMapServerImageryProvider.js +875 -0
- package/Source/Scene/ArcGisMapService.js +80 -0
- package/Source/Scene/Atmosphere.js +149 -0
- package/Source/Scene/AttributeType.js +200 -0
- package/Source/Scene/AutoExposure.js +386 -0
- package/Source/Scene/Axis.js +116 -0
- package/Source/Scene/Azure2DImageryProvider.js +393 -0
- package/Source/Scene/B3dmParser.js +173 -0
- package/Source/Scene/BatchTable.js +636 -0
- package/Source/Scene/BatchTableHierarchy.js +504 -0
- package/Source/Scene/BatchTexture.js +574 -0
- package/Source/Scene/Billboard.js +1601 -0
- package/Source/Scene/BillboardCollection.js +2396 -0
- package/Source/Scene/BillboardLoadState.js +44 -0
- package/Source/Scene/BillboardTexture.js +397 -0
- package/Source/Scene/BingMapsImageryProvider.js +769 -0
- package/Source/Scene/BingMapsStyle.js +93 -0
- package/Source/Scene/BlendEquation.js +53 -0
- package/Source/Scene/BlendFunction.js +129 -0
- package/Source/Scene/BlendOption.js +28 -0
- package/Source/Scene/BlendingState.js +73 -0
- package/Source/Scene/BoundingVolumeSemantics.js +169 -0
- package/Source/Scene/BoxEmitter.js +74 -0
- package/Source/Scene/BrdfLutGenerator.js +75 -0
- package/Source/Scene/BufferLoader.js +141 -0
- package/Source/Scene/Camera.js +3978 -0
- package/Source/Scene/CameraEventAggregator.js +619 -0
- package/Source/Scene/CameraEventType.js +47 -0
- package/Source/Scene/CameraFlightPath.js +576 -0
- package/Source/Scene/Cesium3DContentGroup.js +44 -0
- package/Source/Scene/Cesium3DTile.js +2475 -0
- package/Source/Scene/Cesium3DTileBatchTable.js +1132 -0
- package/Source/Scene/Cesium3DTileColorBlendMode.js +52 -0
- package/Source/Scene/Cesium3DTileContent.js +411 -0
- package/Source/Scene/Cesium3DTileContentFactory.js +118 -0
- package/Source/Scene/Cesium3DTileContentState.js +12 -0
- package/Source/Scene/Cesium3DTileContentType.js +179 -0
- package/Source/Scene/Cesium3DTileFeature.js +444 -0
- package/Source/Scene/Cesium3DTileFeatureTable.js +131 -0
- package/Source/Scene/Cesium3DTileOptimizationHint.js +13 -0
- package/Source/Scene/Cesium3DTileOptimizations.js +115 -0
- package/Source/Scene/Cesium3DTilePass.js +79 -0
- package/Source/Scene/Cesium3DTilePassState.js +52 -0
- package/Source/Scene/Cesium3DTilePointFeature.js +856 -0
- package/Source/Scene/Cesium3DTileRefine.js +29 -0
- package/Source/Scene/Cesium3DTileStyle.js +1475 -0
- package/Source/Scene/Cesium3DTileStyleEngine.js +78 -0
- package/Source/Scene/Cesium3DTilesVoxelProvider.js +760 -0
- package/Source/Scene/Cesium3DTileset.js +3932 -0
- package/Source/Scene/Cesium3DTilesetBaseTraversal.js +291 -0
- package/Source/Scene/Cesium3DTilesetCache.js +80 -0
- package/Source/Scene/Cesium3DTilesetHeatmap.js +165 -0
- package/Source/Scene/Cesium3DTilesetMetadata.js +199 -0
- package/Source/Scene/Cesium3DTilesetMostDetailedTraversal.js +131 -0
- package/Source/Scene/Cesium3DTilesetSkipTraversal.js +420 -0
- package/Source/Scene/Cesium3DTilesetStatistics.js +195 -0
- package/Source/Scene/Cesium3DTilesetTraversal.js +323 -0
- package/Source/Scene/CircleEmitter.js +61 -0
- package/Source/Scene/ClassificationPrimitive.js +1387 -0
- package/Source/Scene/ClassificationType.js +35 -0
- package/Source/Scene/ClippingPlane.js +184 -0
- package/Source/Scene/ClippingPlaneCollection.js +764 -0
- package/Source/Scene/ClippingPolygon.js +300 -0
- package/Source/Scene/ClippingPolygonCollection.js +965 -0
- package/Source/Scene/CloudCollection.js +1041 -0
- package/Source/Scene/CloudType.js +33 -0
- package/Source/Scene/ColorBlendMode.js +33 -0
- package/Source/Scene/Composite3DTileContent.js +403 -0
- package/Source/Scene/ConditionsExpression.js +219 -0
- package/Source/Scene/ConeEmitter.js +61 -0
- package/Source/Scene/ContentMetadata.js +184 -0
- package/Source/Scene/CreditDisplay.js +654 -0
- package/Source/Scene/CullFace.js +33 -0
- package/Source/Scene/CumulusCloud.js +347 -0
- package/Source/Scene/DebugAppearance.js +266 -0
- package/Source/Scene/DebugCameraPrimitive.js +257 -0
- package/Source/Scene/DebugInspector.js +151 -0
- package/Source/Scene/DebugModelMatrixPrimitive.js +220 -0
- package/Source/Scene/DepthFunction.js +73 -0
- package/Source/Scene/DepthPlane.js +238 -0
- package/Source/Scene/DerivedCommand.js +708 -0
- package/Source/Scene/DeviceOrientationCameraController.js +120 -0
- package/Source/Scene/DirectionalLight.js +49 -0
- package/Source/Scene/DiscardEmptyTileImagePolicy.js +54 -0
- package/Source/Scene/DiscardMissingTileImagePolicy.js +148 -0
- package/Source/Scene/DracoLoader.js +99 -0
- package/Source/Scene/DynamicAtmosphereLightingType.js +56 -0
- package/Source/Scene/DynamicEnvironmentMapManager.js +1022 -0
- package/Source/Scene/EdgeFramebuffer.js +245 -0
- package/Source/Scene/EllipsoidPrimitive.js +496 -0
- package/Source/Scene/EllipsoidSurfaceAppearance.js +278 -0
- package/Source/Scene/Empty3DTileContent.js +164 -0
- package/Source/Scene/Expression.js +2233 -0
- package/Source/Scene/ExpressionNodeType.js +25 -0
- package/Source/Scene/Fog.js +166 -0
- package/Source/Scene/FrameRateMonitor.js +375 -0
- package/Source/Scene/FrameState.js +477 -0
- package/Source/Scene/FrustumCommands.js +29 -0
- package/Source/Scene/GaussianSplat3DTileContent.js +826 -0
- package/Source/Scene/GaussianSplatPrimitive.js +1065 -0
- package/Source/Scene/GaussianSplatRenderResources.js +81 -0
- package/Source/Scene/GaussianSplatSorter.js +73 -0
- package/Source/Scene/GaussianSplatTextureGenerator.js +64 -0
- package/Source/Scene/Geometry3DTileContent.js +534 -0
- package/Source/Scene/GetFeatureInfoFormat.js +396 -0
- package/Source/Scene/Globe.js +1135 -0
- package/Source/Scene/GlobeDepth.js +407 -0
- package/Source/Scene/GlobeSurfaceShaderSet.js +485 -0
- package/Source/Scene/GlobeSurfaceTile.js +967 -0
- package/Source/Scene/GlobeSurfaceTileProvider.js +2910 -0
- package/Source/Scene/GlobeTranslucency.js +239 -0
- package/Source/Scene/GlobeTranslucencyFramebuffer.js +201 -0
- package/Source/Scene/GlobeTranslucencyState.js +1102 -0
- package/Source/Scene/GltfBufferViewLoader.js +242 -0
- package/Source/Scene/GltfDracoLoader.js +293 -0
- package/Source/Scene/GltfImageLoader.js +320 -0
- package/Source/Scene/GltfIndexBufferLoader.js +421 -0
- package/Source/Scene/GltfJsonLoader.js +314 -0
- package/Source/Scene/GltfLoader.js +2989 -0
- package/Source/Scene/GltfLoaderUtil.js +184 -0
- package/Source/Scene/GltfPipeline/ForEach.js +424 -0
- package/Source/Scene/GltfPipeline/addBuffer.js +30 -0
- package/Source/Scene/GltfPipeline/addDefaults.js +208 -0
- package/Source/Scene/GltfPipeline/addExtensionsRequired.js +24 -0
- package/Source/Scene/GltfPipeline/addExtensionsUsed.js +22 -0
- package/Source/Scene/GltfPipeline/addPipelineExtras.js +36 -0
- package/Source/Scene/GltfPipeline/addToArray.js +25 -0
- package/Source/Scene/GltfPipeline/findAccessorMinMax.js +71 -0
- package/Source/Scene/GltfPipeline/forEachTextureInMaterial.js +155 -0
- package/Source/Scene/GltfPipeline/getAccessorByteStride.js +29 -0
- package/Source/Scene/GltfPipeline/getComponentReader.js +147 -0
- package/Source/Scene/GltfPipeline/moveTechniqueRenderStates.js +135 -0
- package/Source/Scene/GltfPipeline/moveTechniquesToExtension.js +145 -0
- package/Source/Scene/GltfPipeline/numberOfComponentsForType.js +29 -0
- package/Source/Scene/GltfPipeline/parseGlb.js +118 -0
- package/Source/Scene/GltfPipeline/readAccessorPacked.js +54 -0
- package/Source/Scene/GltfPipeline/removeExtension.js +64 -0
- package/Source/Scene/GltfPipeline/removeExtensionsRequired.js +24 -0
- package/Source/Scene/GltfPipeline/removeExtensionsUsed.js +26 -0
- package/Source/Scene/GltfPipeline/removePipelineExtras.js +42 -0
- package/Source/Scene/GltfPipeline/removeUnusedElements.js +906 -0
- package/Source/Scene/GltfPipeline/updateAccessorComponentTypes.js +53 -0
- package/Source/Scene/GltfPipeline/updateVersion.js +1148 -0
- package/Source/Scene/GltfPipeline/usesExtension.js +18 -0
- package/Source/Scene/GltfSpzLoader.js +224 -0
- package/Source/Scene/GltfStructuralMetadataLoader.js +505 -0
- package/Source/Scene/GltfTextureLoader.js +399 -0
- package/Source/Scene/GltfVertexBufferLoader.js +634 -0
- package/Source/Scene/Google2DImageryProvider.js +621 -0
- package/Source/Scene/GoogleEarthEnterpriseImageryProvider.js +548 -0
- package/Source/Scene/GoogleEarthEnterpriseMapsProvider.js +589 -0
- package/Source/Scene/GridImageryProvider.js +322 -0
- package/Source/Scene/GroundPolylinePrimitive.js +890 -0
- package/Source/Scene/GroundPrimitive.js +1000 -0
- package/Source/Scene/GroupMetadata.js +203 -0
- package/Source/Scene/HeightReference.js +85 -0
- package/Source/Scene/HorizontalOrigin.js +41 -0
- package/Source/Scene/I3SDataProvider.js +860 -0
- package/Source/Scene/I3SDecoder.js +133 -0
- package/Source/Scene/I3SFeature.js +61 -0
- package/Source/Scene/I3SField.js +360 -0
- package/Source/Scene/I3SGeometry.js +477 -0
- package/Source/Scene/I3SLayer.js +460 -0
- package/Source/Scene/I3SNode.js +927 -0
- package/Source/Scene/I3SStatistics.js +94 -0
- package/Source/Scene/I3SSublayer.js +175 -0
- package/Source/Scene/I3SSymbology.js +336 -0
- package/Source/Scene/I3dmParser.js +140 -0
- package/Source/Scene/ITwinData.js +283 -0
- package/Source/Scene/ImageBasedLighting.js +463 -0
- package/Source/Scene/Imagery.js +120 -0
- package/Source/Scene/ImageryLayer.js +1747 -0
- package/Source/Scene/ImageryLayerCollection.js +645 -0
- package/Source/Scene/ImageryLayerFeatureInfo.js +111 -0
- package/Source/Scene/ImageryProvider.js +267 -0
- package/Source/Scene/ImageryState.js +14 -0
- package/Source/Scene/Implicit3DTileContent.js +1206 -0
- package/Source/Scene/ImplicitAvailabilityBitstream.js +134 -0
- package/Source/Scene/ImplicitMetadataView.js +178 -0
- package/Source/Scene/ImplicitSubdivisionScheme.js +48 -0
- package/Source/Scene/ImplicitSubtree.js +1161 -0
- package/Source/Scene/ImplicitSubtreeCache.js +127 -0
- package/Source/Scene/ImplicitSubtreeMetadata.js +191 -0
- package/Source/Scene/ImplicitTileCoordinates.js +647 -0
- package/Source/Scene/ImplicitTileset.js +269 -0
- package/Source/Scene/InstanceAttributeSemantic.js +79 -0
- package/Source/Scene/InvertClassification.js +381 -0
- package/Source/Scene/IonImageryProvider.js +346 -0
- package/Source/Scene/IonImageryProviderFactory.js +194 -0
- package/Source/Scene/IonWorldImageryStyle.js +33 -0
- package/Source/Scene/JobScheduler.js +199 -0
- package/Source/Scene/JobType.js +10 -0
- package/Source/Scene/JsonMetadataTable.js +114 -0
- package/Source/Scene/KeyframeNode.js +61 -0
- package/Source/Scene/Label.js +1618 -0
- package/Source/Scene/LabelCollection.js +1032 -0
- package/Source/Scene/LabelStyle.js +33 -0
- package/Source/Scene/Light.js +34 -0
- package/Source/Scene/MapMode2D.js +23 -0
- package/Source/Scene/MapboxImageryProvider.js +332 -0
- package/Source/Scene/MapboxStyleImageryProvider.js +342 -0
- package/Source/Scene/Material.js +1929 -0
- package/Source/Scene/MaterialAppearance.js +328 -0
- package/Source/Scene/Megatexture.js +550 -0
- package/Source/Scene/MetadataClass.js +202 -0
- package/Source/Scene/MetadataClassProperty.js +1191 -0
- package/Source/Scene/MetadataComponentType.js +469 -0
- package/Source/Scene/MetadataEntity.js +425 -0
- package/Source/Scene/MetadataEnum.js +219 -0
- package/Source/Scene/MetadataEnumValue.js +131 -0
- package/Source/Scene/MetadataPicking.js +396 -0
- package/Source/Scene/MetadataSchema.js +202 -0
- package/Source/Scene/MetadataSchemaLoader.js +135 -0
- package/Source/Scene/MetadataSemantic.js +153 -0
- package/Source/Scene/MetadataTable.js +357 -0
- package/Source/Scene/MetadataTableProperty.js +840 -0
- package/Source/Scene/MetadataType.js +220 -0
- package/Source/Scene/Model/AlphaPipelineStage.js +51 -0
- package/Source/Scene/Model/AtmospherePipelineStage.js +64 -0
- package/Source/Scene/Model/B3dmLoader.js +368 -0
- package/Source/Scene/Model/BatchTexturePipelineStage.js +71 -0
- package/Source/Scene/Model/CPUStylingPipelineStage.js +77 -0
- package/Source/Scene/Model/CartesianRectangle.js +108 -0
- package/Source/Scene/Model/ClassificationModelDrawCommand.js +534 -0
- package/Source/Scene/Model/ClassificationPipelineStage.js +132 -0
- package/Source/Scene/Model/CustomShader.js +469 -0
- package/Source/Scene/Model/CustomShaderMode.js +40 -0
- package/Source/Scene/Model/CustomShaderPipelineStage.js +667 -0
- package/Source/Scene/Model/CustomShaderTranslucencyMode.js +35 -0
- package/Source/Scene/Model/DequantizationPipelineStage.js +178 -0
- package/Source/Scene/Model/EdgeDetectionPipelineStage.js +42 -0
- package/Source/Scene/Model/EdgeVisibilityPipelineStage.js +800 -0
- 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 +543 -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 +523 -0
- package/Source/Scene/Model/GeoJsonLoader.js +697 -0
- package/Source/Scene/Model/GeometryPipelineStage.js +529 -0
- package/Source/Scene/Model/I3dmLoader.js +883 -0
- package/Source/Scene/Model/ImageBasedLightingPipelineStage.js +168 -0
- package/Source/Scene/Model/ImageryConfiguration.js +26 -0
- package/Source/Scene/Model/ImageryCoverage.js +488 -0
- package/Source/Scene/Model/ImageryFlags.js +31 -0
- package/Source/Scene/Model/ImageryInput.js +60 -0
- package/Source/Scene/Model/ImageryPipelineStage.js +1046 -0
- package/Source/Scene/Model/InstancingPipelineStage.js +1056 -0
- package/Source/Scene/Model/LightingModel.js +30 -0
- package/Source/Scene/Model/LightingPipelineStage.js +73 -0
- package/Source/Scene/Model/MappedPositions.js +84 -0
- package/Source/Scene/Model/MaterialPipelineStage.js +869 -0
- package/Source/Scene/Model/MetadataPickingPipelineStage.js +96 -0
- package/Source/Scene/Model/MetadataPipelineStage.js +657 -0
- package/Source/Scene/Model/Model.js +3340 -0
- package/Source/Scene/Model/Model3DTileContent.js +551 -0
- package/Source/Scene/Model/ModelAlphaOptions.js +26 -0
- package/Source/Scene/Model/ModelAnimation.js +421 -0
- package/Source/Scene/Model/ModelAnimationChannel.js +294 -0
- package/Source/Scene/Model/ModelAnimationCollection.js +553 -0
- package/Source/Scene/Model/ModelArticulation.js +214 -0
- package/Source/Scene/Model/ModelArticulationStage.js +261 -0
- package/Source/Scene/Model/ModelClippingPlanesPipelineStage.js +126 -0
- package/Source/Scene/Model/ModelClippingPolygonsPipelineStage.js +98 -0
- package/Source/Scene/Model/ModelColorPipelineStage.js +98 -0
- package/Source/Scene/Model/ModelDrawCommand.js +922 -0
- package/Source/Scene/Model/ModelDrawCommands.js +218 -0
- package/Source/Scene/Model/ModelFeature.js +229 -0
- package/Source/Scene/Model/ModelFeatureTable.js +316 -0
- package/Source/Scene/Model/ModelImagery.js +410 -0
- package/Source/Scene/Model/ModelImageryMapping.js +489 -0
- package/Source/Scene/Model/ModelLightingOptions.js +29 -0
- package/Source/Scene/Model/ModelMatrixUpdateStage.js +120 -0
- package/Source/Scene/Model/ModelNode.js +125 -0
- package/Source/Scene/Model/ModelPrimitiveImagery.js +972 -0
- package/Source/Scene/Model/ModelReader.js +810 -0
- package/Source/Scene/Model/ModelRenderResources.js +119 -0
- package/Source/Scene/Model/ModelRuntimeNode.js +648 -0
- package/Source/Scene/Model/ModelRuntimePrimitive.js +380 -0
- package/Source/Scene/Model/ModelSceneGraph.js +1098 -0
- package/Source/Scene/Model/ModelSilhouettePipelineStage.js +109 -0
- package/Source/Scene/Model/ModelSkin.js +180 -0
- package/Source/Scene/Model/ModelSplitterPipelineStage.js +65 -0
- package/Source/Scene/Model/ModelStatistics.js +225 -0
- package/Source/Scene/Model/ModelType.js +94 -0
- package/Source/Scene/Model/ModelUtility.js +395 -0
- package/Source/Scene/Model/MorphTargetsPipelineStage.js +249 -0
- package/Source/Scene/Model/NodeRenderResources.js +170 -0
- package/Source/Scene/Model/NodeStatisticsPipelineStage.js +75 -0
- package/Source/Scene/Model/PickingPipelineStage.js +218 -0
- package/Source/Scene/Model/PntsLoader.js +716 -0
- package/Source/Scene/Model/PointCloudStylingPipelineStage.js +392 -0
- package/Source/Scene/Model/PrimitiveOutlineGenerator.js +689 -0
- package/Source/Scene/Model/PrimitiveOutlinePipelineStage.js +99 -0
- package/Source/Scene/Model/PrimitiveRenderResources.js +297 -0
- package/Source/Scene/Model/PrimitiveStatisticsPipelineStage.js +253 -0
- package/Source/Scene/Model/SceneMode2DPipelineStage.js +301 -0
- package/Source/Scene/Model/SelectedFeatureIdPipelineStage.js +180 -0
- package/Source/Scene/Model/SkinningPipelineStage.js +118 -0
- package/Source/Scene/Model/StyleCommandsNeeded.js +29 -0
- package/Source/Scene/Model/TextureManager.js +244 -0
- package/Source/Scene/Model/TextureUniform.js +71 -0
- package/Source/Scene/Model/TilesetPipelineStage.js +73 -0
- package/Source/Scene/Model/UniformType.js +124 -0
- package/Source/Scene/Model/VaryingType.js +61 -0
- package/Source/Scene/Model/VerticalExaggerationPipelineStage.js +58 -0
- package/Source/Scene/Model/WireframePipelineStage.js +118 -0
- package/Source/Scene/Model/pickModel.js +425 -0
- package/Source/Scene/ModelAnimationLoop.js +33 -0
- package/Source/Scene/ModelAnimationState.js +9 -0
- package/Source/Scene/ModelComponents.js +1662 -0
- package/Source/Scene/Moon.js +175 -0
- package/Source/Scene/Multiple3DTileContent.js +722 -0
- package/Source/Scene/NeverTileDiscardPolicy.js +28 -0
- package/Source/Scene/OIT.js +946 -0
- package/Source/Scene/OpenStreetMapImageryProvider.js +128 -0
- package/Source/Scene/OrderedGroundPrimitiveCollection.js +218 -0
- package/Source/Scene/Particle.js +149 -0
- package/Source/Scene/ParticleBurst.js +51 -0
- package/Source/Scene/ParticleEmitter.js +36 -0
- package/Source/Scene/ParticleSystem.js +885 -0
- package/Source/Scene/PerInstanceColorAppearance.js +296 -0
- package/Source/Scene/PerformanceDisplay.js +120 -0
- package/Source/Scene/PickDepth.js +125 -0
- package/Source/Scene/PickDepthFramebuffer.js +79 -0
- package/Source/Scene/PickFramebuffer.js +255 -0
- package/Source/Scene/PickedMetadataInfo.js +57 -0
- package/Source/Scene/Picking.js +1683 -0
- package/Source/Scene/PntsParser.js +547 -0
- package/Source/Scene/PointCloud.js +1412 -0
- package/Source/Scene/PointCloudEyeDomeLighting.js +284 -0
- package/Source/Scene/PointCloudShading.js +104 -0
- package/Source/Scene/PointPrimitive.js +690 -0
- package/Source/Scene/PointPrimitiveCollection.js +1223 -0
- package/Source/Scene/Polyline.js +431 -0
- package/Source/Scene/PolylineCollection.js +1950 -0
- package/Source/Scene/PolylineColorAppearance.js +220 -0
- package/Source/Scene/PolylineMaterialAppearance.js +231 -0
- package/Source/Scene/PostProcessStage.js +1000 -0
- package/Source/Scene/PostProcessStageCollection.js +900 -0
- package/Source/Scene/PostProcessStageComposite.js +359 -0
- package/Source/Scene/PostProcessStageLibrary.js +826 -0
- package/Source/Scene/PostProcessStageSampleMode.js +22 -0
- package/Source/Scene/PostProcessStageTextureCache.js +454 -0
- package/Source/Scene/Primitive.js +2504 -0
- package/Source/Scene/PrimitiveCollection.js +532 -0
- package/Source/Scene/PrimitiveLoadPlan.js +303 -0
- package/Source/Scene/PrimitivePipeline.js +854 -0
- package/Source/Scene/PrimitiveState.js +136 -0
- package/Source/Scene/PropertyAttribute.js +160 -0
- package/Source/Scene/PropertyAttributeProperty.js +177 -0
- package/Source/Scene/PropertyTable.js +536 -0
- package/Source/Scene/PropertyTexture.js +162 -0
- package/Source/Scene/PropertyTextureProperty.js +304 -0
- package/Source/Scene/QuadtreeOccluders.js +30 -0
- package/Source/Scene/QuadtreePrimitive.js +1575 -0
- package/Source/Scene/QuadtreeTile.js +729 -0
- package/Source/Scene/QuadtreeTileLoadState.js +39 -0
- package/Source/Scene/QuadtreeTileProvider.js +212 -0
- package/Source/Scene/ResourceCache.js +824 -0
- package/Source/Scene/ResourceCacheKey.js +601 -0
- package/Source/Scene/ResourceCacheStatistics.js +149 -0
- package/Source/Scene/ResourceLoader.js +127 -0
- package/Source/Scene/ResourceLoaderState.js +56 -0
- package/Source/Scene/SDFSettings.js +39 -0
- package/Source/Scene/Scene.js +5280 -0
- package/Source/Scene/SceneFramebuffer.js +106 -0
- package/Source/Scene/SceneMode.js +56 -0
- package/Source/Scene/SceneTransforms.js +463 -0
- package/Source/Scene/SceneTransitioner.js +1111 -0
- package/Source/Scene/ScreenSpaceCameraController.js +3098 -0
- package/Source/Scene/SensorVolumePortionToDisplay.js +69 -0
- package/Source/Scene/ShadowMap.js +1957 -0
- package/Source/Scene/ShadowMapShader.js +395 -0
- package/Source/Scene/ShadowMode.js +78 -0
- package/Source/Scene/ShadowVolumeAppearance.js +936 -0
- package/Source/Scene/SingleTileImageryProvider.js +380 -0
- package/Source/Scene/SkyAtmosphere.js +400 -0
- package/Source/Scene/SkyBox.js +289 -0
- package/Source/Scene/SpatialNode.js +377 -0
- package/Source/Scene/SpecularEnvironmentCubeMap.js +240 -0
- package/Source/Scene/SphereEmitter.js +65 -0
- package/Source/Scene/SplitDirection.js +34 -0
- package/Source/Scene/Splitter.js +49 -0
- package/Source/Scene/StencilConstants.js +37 -0
- package/Source/Scene/StencilFunction.js +73 -0
- package/Source/Scene/StencilOperation.js +73 -0
- package/Source/Scene/StructuralMetadata.js +243 -0
- package/Source/Scene/StyleExpression.js +86 -0
- package/Source/Scene/Sun.js +363 -0
- package/Source/Scene/SunLight.js +31 -0
- package/Source/Scene/SunPostProcess.js +288 -0
- package/Source/Scene/SupportedImageFormats.js +18 -0
- package/Source/Scene/Terrain.js +245 -0
- package/Source/Scene/TerrainFillMesh.js +2222 -0
- package/Source/Scene/TerrainState.js +13 -0
- package/Source/Scene/TileBoundingRegion.js +489 -0
- package/Source/Scene/TileBoundingS2Cell.js +699 -0
- package/Source/Scene/TileBoundingSphere.js +167 -0
- package/Source/Scene/TileBoundingVolume.js +68 -0
- package/Source/Scene/TileCoordinatesImageryProvider.js +269 -0
- package/Source/Scene/TileDiscardPolicy.js +34 -0
- package/Source/Scene/TileImagery.js +126 -0
- package/Source/Scene/TileMapServiceImageryProvider.js +442 -0
- package/Source/Scene/TileMetadata.js +184 -0
- package/Source/Scene/TileOrientedBoundingBox.js +219 -0
- package/Source/Scene/TileReplacementQueue.js +119 -0
- package/Source/Scene/TileSelectionResult.js +80 -0
- package/Source/Scene/TileState.js +10 -0
- package/Source/Scene/Tileset3DTileContent.js +182 -0
- package/Source/Scene/TilesetMetadata.js +186 -0
- package/Source/Scene/TimeDynamicImagery.js +308 -0
- package/Source/Scene/TimeDynamicPointCloud.js +802 -0
- package/Source/Scene/Tonemapper.js +64 -0
- package/Source/Scene/TranslucentTileClassification.js +514 -0
- package/Source/Scene/TweenCollection.js +585 -0
- package/Source/Scene/UrlTemplateImageryProvider.js +989 -0
- package/Source/Scene/Vector3DTileBatch.js +37 -0
- package/Source/Scene/Vector3DTileClampedPolylines.js +783 -0
- package/Source/Scene/Vector3DTileContent.js +770 -0
- package/Source/Scene/Vector3DTileGeometry.js +497 -0
- package/Source/Scene/Vector3DTilePoints.js +548 -0
- package/Source/Scene/Vector3DTilePolygons.js +479 -0
- package/Source/Scene/Vector3DTilePolylines.js +679 -0
- package/Source/Scene/Vector3DTilePrimitive.js +1276 -0
- package/Source/Scene/VertexAttributeSemantic.js +305 -0
- package/Source/Scene/VerticalOrigin.js +49 -0
- package/Source/Scene/View.js +465 -0
- package/Source/Scene/ViewportQuad.js +182 -0
- package/Source/Scene/ViewshedShadowMap.js +1953 -0
- package/Source/Scene/VoxelBoundsCollection.js +494 -0
- package/Source/Scene/VoxelBoxShape.js +595 -0
- package/Source/Scene/VoxelCell.js +274 -0
- package/Source/Scene/VoxelContent.js +231 -0
- package/Source/Scene/VoxelCylinderShape.js +868 -0
- package/Source/Scene/VoxelEllipsoidShape.js +1174 -0
- package/Source/Scene/VoxelMetadataOrder.js +24 -0
- package/Source/Scene/VoxelPrimitive.js +2169 -0
- package/Source/Scene/VoxelProvider.js +234 -0
- package/Source/Scene/VoxelRenderResources.js +259 -0
- package/Source/Scene/VoxelShape.js +179 -0
- package/Source/Scene/VoxelShapeType.js +105 -0
- package/Source/Scene/VoxelTraversal.js +1264 -0
- package/Source/Scene/WebMapServiceImageryProvider.js +649 -0
- package/Source/Scene/WebMapTileServiceImageryProvider.js +575 -0
- package/Source/Scene/buildVoxelDrawCommands.js +177 -0
- package/Source/Scene/computeFlyToLocationForRectangle.js +74 -0
- package/Source/Scene/createBillboardPointCallback.js +70 -0
- package/Source/Scene/createElevationBandMaterial.js +580 -0
- package/Source/Scene/createGooglePhotorealistic3DTileset.js +116 -0
- package/Source/Scene/createOsmBuildingsAsync.js +79 -0
- package/Source/Scene/createTangentSpaceDebugPrimitive.js +114 -0
- package/Source/Scene/createWorldImageryAsync.js +39 -0
- package/Source/Scene/findContentMetadata.js +51 -0
- package/Source/Scene/findGroupMetadata.js +39 -0
- package/Source/Scene/findTileMetadata.js +53 -0
- package/Source/Scene/getBinaryAccessor.js +56 -0
- package/Source/Scene/getClipAndStyleCode.js +34 -0
- package/Source/Scene/getClippingFunction.js +154 -0
- package/Source/Scene/getMeshPrimitives.js +72 -0
- package/Source/Scene/getMetadataClassProperty.js +43 -0
- package/Source/Scene/getMetadataProperty.js +48 -0
- package/Source/Scene/hasExtension.js +19 -0
- package/Source/Scene/parseBatchTable.js +448 -0
- package/Source/Scene/parseFeatureMetadataLegacy.js +139 -0
- package/Source/Scene/parseStructuralMetadata.js +102 -0
- package/Source/Scene/preprocess3DTileContent.js +102 -0
- package/Source/Scene/processVoxelProperties.js +398 -0
- package/Source/Shaders/AdjustTranslucentFS.glsl +27 -0
- package/Source/Shaders/AdjustTranslucentFS.js +29 -0
- package/Source/Shaders/Appearances/AllMaterialAppearanceFS.glsl +29 -0
- package/Source/Shaders/Appearances/AllMaterialAppearanceFS.js +31 -0
- package/Source/Shaders/Appearances/AllMaterialAppearanceVS.glsl +26 -0
- package/Source/Shaders/Appearances/AllMaterialAppearanceVS.js +28 -0
- package/Source/Shaders/Appearances/BasicMaterialAppearanceFS.glsl +23 -0
- package/Source/Shaders/Appearances/BasicMaterialAppearanceFS.js +25 -0
- package/Source/Shaders/Appearances/BasicMaterialAppearanceVS.glsl +17 -0
- package/Source/Shaders/Appearances/BasicMaterialAppearanceVS.js +19 -0
- package/Source/Shaders/Appearances/EllipsoidSurfaceAppearanceFS.glsl +33 -0
- package/Source/Shaders/Appearances/EllipsoidSurfaceAppearanceFS.js +35 -0
- package/Source/Shaders/Appearances/EllipsoidSurfaceAppearanceVS.glsl +19 -0
- package/Source/Shaders/Appearances/EllipsoidSurfaceAppearanceVS.js +21 -0
- package/Source/Shaders/Appearances/PerInstanceColorAppearanceFS.glsl +24 -0
- package/Source/Shaders/Appearances/PerInstanceColorAppearanceFS.js +26 -0
- package/Source/Shaders/Appearances/PerInstanceColorAppearanceVS.glsl +20 -0
- package/Source/Shaders/Appearances/PerInstanceColorAppearanceVS.js +22 -0
- package/Source/Shaders/Appearances/PerInstanceFlatColorAppearanceFS.glsl +6 -0
- package/Source/Shaders/Appearances/PerInstanceFlatColorAppearanceFS.js +8 -0
- package/Source/Shaders/Appearances/PerInstanceFlatColorAppearanceVS.glsl +15 -0
- package/Source/Shaders/Appearances/PerInstanceFlatColorAppearanceVS.js +17 -0
- package/Source/Shaders/Appearances/PolylineColorAppearanceVS.glsl +28 -0
- package/Source/Shaders/Appearances/PolylineColorAppearanceVS.js +30 -0
- package/Source/Shaders/Appearances/PolylineMaterialAppearanceVS.glsl +33 -0
- package/Source/Shaders/Appearances/PolylineMaterialAppearanceVS.js +35 -0
- package/Source/Shaders/Appearances/TexturedMaterialAppearanceFS.glsl +25 -0
- package/Source/Shaders/Appearances/TexturedMaterialAppearanceFS.js +27 -0
- package/Source/Shaders/Appearances/TexturedMaterialAppearanceVS.glsl +20 -0
- package/Source/Shaders/Appearances/TexturedMaterialAppearanceVS.js +22 -0
- package/Source/Shaders/AtmosphereCommon.glsl +187 -0
- package/Source/Shaders/AtmosphereCommon.js +189 -0
- package/Source/Shaders/BillboardCollectionFS.glsl +261 -0
- package/Source/Shaders/BillboardCollectionFS.js +262 -0
- package/Source/Shaders/BillboardCollectionVS.glsl +445 -0
- package/Source/Shaders/BillboardCollectionVS.js +447 -0
- package/Source/Shaders/BrdfLutGeneratorFS.glsl +100 -0
- package/Source/Shaders/BrdfLutGeneratorFS.js +102 -0
- package/Source/Shaders/Builtin/Constants/degreesPerRadian.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/degreesPerRadian.js +18 -0
- package/Source/Shaders/Builtin/Constants/depthRange.glsl +14 -0
- package/Source/Shaders/Builtin/Constants/depthRange.js +16 -0
- package/Source/Shaders/Builtin/Constants/epsilon1.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon1.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon2.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon2.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon3.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon3.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon4.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon4.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon5.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon5.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon6.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon6.js +9 -0
- package/Source/Shaders/Builtin/Constants/epsilon7.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/epsilon7.js +9 -0
- package/Source/Shaders/Builtin/Constants/infinity.glsl +7 -0
- package/Source/Shaders/Builtin/Constants/infinity.js +9 -0
- package/Source/Shaders/Builtin/Constants/oneOverPi.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/oneOverPi.js +18 -0
- package/Source/Shaders/Builtin/Constants/oneOverTwoPi.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/oneOverTwoPi.js +18 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTile.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTile.js +11 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileClassification.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileClassification.js +11 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileClassificationIgnoreShow.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileClassificationIgnoreShow.js +11 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileEdges.glsl +10 -0
- package/Source/Shaders/Builtin/Constants/passCesium3DTileEdges.js +12 -0
- package/Source/Shaders/Builtin/Constants/passClassification.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passClassification.js +11 -0
- package/Source/Shaders/Builtin/Constants/passCompute.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passCompute.js +11 -0
- package/Source/Shaders/Builtin/Constants/passEnvironment.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passEnvironment.js +11 -0
- package/Source/Shaders/Builtin/Constants/passGaussianSplats.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passGaussianSplats.js +11 -0
- package/Source/Shaders/Builtin/Constants/passGlobe.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passGlobe.js +11 -0
- package/Source/Shaders/Builtin/Constants/passOpaque.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passOpaque.js +11 -0
- package/Source/Shaders/Builtin/Constants/passOverlay.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passOverlay.js +11 -0
- package/Source/Shaders/Builtin/Constants/passTerrainClassification.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passTerrainClassification.js +11 -0
- package/Source/Shaders/Builtin/Constants/passTranslucent.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passTranslucent.js +11 -0
- package/Source/Shaders/Builtin/Constants/passVoxels.glsl +9 -0
- package/Source/Shaders/Builtin/Constants/passVoxels.js +11 -0
- package/Source/Shaders/Builtin/Constants/pi.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/pi.js +18 -0
- package/Source/Shaders/Builtin/Constants/piOverFour.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/piOverFour.js +18 -0
- package/Source/Shaders/Builtin/Constants/piOverSix.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/piOverSix.js +18 -0
- package/Source/Shaders/Builtin/Constants/piOverThree.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/piOverThree.js +18 -0
- package/Source/Shaders/Builtin/Constants/piOverTwo.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/piOverTwo.js +18 -0
- package/Source/Shaders/Builtin/Constants/radiansPerDegree.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/radiansPerDegree.js +18 -0
- package/Source/Shaders/Builtin/Constants/sceneMode2D.glsl +11 -0
- package/Source/Shaders/Builtin/Constants/sceneMode2D.js +13 -0
- package/Source/Shaders/Builtin/Constants/sceneMode3D.glsl +11 -0
- package/Source/Shaders/Builtin/Constants/sceneMode3D.js +13 -0
- package/Source/Shaders/Builtin/Constants/sceneModeColumbusView.glsl +11 -0
- package/Source/Shaders/Builtin/Constants/sceneModeColumbusView.js +13 -0
- package/Source/Shaders/Builtin/Constants/sceneModeMorphing.glsl +11 -0
- package/Source/Shaders/Builtin/Constants/sceneModeMorphing.js +13 -0
- package/Source/Shaders/Builtin/Constants/solarRadius.glsl +13 -0
- package/Source/Shaders/Builtin/Constants/solarRadius.js +15 -0
- package/Source/Shaders/Builtin/Constants/threePiOver2.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/threePiOver2.js +18 -0
- package/Source/Shaders/Builtin/Constants/twoPi.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/twoPi.js +18 -0
- package/Source/Shaders/Builtin/Constants/webMercatorMaxLatitude.glsl +16 -0
- package/Source/Shaders/Builtin/Constants/webMercatorMaxLatitude.js +18 -0
- package/Source/Shaders/Builtin/CzmBuiltins.js +280 -0
- package/Source/Shaders/Builtin/Functions/HSBToRGB.glsl +24 -0
- package/Source/Shaders/Builtin/Functions/HSBToRGB.js +26 -0
- package/Source/Shaders/Builtin/Functions/HSLToRGB.glsl +31 -0
- package/Source/Shaders/Builtin/Functions/HSLToRGB.js +33 -0
- package/Source/Shaders/Builtin/Functions/RGBToHSB.glsl +27 -0
- package/Source/Shaders/Builtin/Functions/RGBToHSB.js +29 -0
- package/Source/Shaders/Builtin/Functions/RGBToHSL.glsl +34 -0
- package/Source/Shaders/Builtin/Functions/RGBToHSL.js +36 -0
- package/Source/Shaders/Builtin/Functions/RGBToXYZ.glsl +30 -0
- package/Source/Shaders/Builtin/Functions/RGBToXYZ.js +32 -0
- package/Source/Shaders/Builtin/Functions/XYZToRGB.glsl +30 -0
- package/Source/Shaders/Builtin/Functions/XYZToRGB.js +32 -0
- package/Source/Shaders/Builtin/Functions/acesTonemapping.glsl +16 -0
- package/Source/Shaders/Builtin/Functions/acesTonemapping.js +18 -0
- package/Source/Shaders/Builtin/Functions/alphaWeight.glsl +11 -0
- package/Source/Shaders/Builtin/Functions/alphaWeight.js +13 -0
- package/Source/Shaders/Builtin/Functions/antialias.glsl +39 -0
- package/Source/Shaders/Builtin/Functions/antialias.js +41 -0
- package/Source/Shaders/Builtin/Functions/applyHSBShift.glsl +32 -0
- package/Source/Shaders/Builtin/Functions/applyHSBShift.js +34 -0
- package/Source/Shaders/Builtin/Functions/approximateSphericalCoordinates.glsl +18 -0
- package/Source/Shaders/Builtin/Functions/approximateSphericalCoordinates.js +20 -0
- package/Source/Shaders/Builtin/Functions/approximateTanh.glsl +10 -0
- package/Source/Shaders/Builtin/Functions/approximateTanh.js +12 -0
- package/Source/Shaders/Builtin/Functions/backFacing.glsl +13 -0
- package/Source/Shaders/Builtin/Functions/backFacing.js +15 -0
- package/Source/Shaders/Builtin/Functions/branchFreeTernary.glsl +71 -0
- package/Source/Shaders/Builtin/Functions/branchFreeTernary.js +73 -0
- package/Source/Shaders/Builtin/Functions/cascadeColor.glsl +8 -0
- package/Source/Shaders/Builtin/Functions/cascadeColor.js +10 -0
- package/Source/Shaders/Builtin/Functions/cascadeDistance.glsl +7 -0
- package/Source/Shaders/Builtin/Functions/cascadeDistance.js +9 -0
- package/Source/Shaders/Builtin/Functions/cascadeMatrix.glsl +10 -0
- package/Source/Shaders/Builtin/Functions/cascadeMatrix.js +12 -0
- package/Source/Shaders/Builtin/Functions/cascadeWeights.glsl +10 -0
- package/Source/Shaders/Builtin/Functions/cascadeWeights.js +12 -0
- package/Source/Shaders/Builtin/Functions/clipPolygons.glsl +37 -0
- package/Source/Shaders/Builtin/Functions/clipPolygons.js +39 -0
- package/Source/Shaders/Builtin/Functions/columbusViewMorph.glsl +12 -0
- package/Source/Shaders/Builtin/Functions/columbusViewMorph.js +14 -0
- package/Source/Shaders/Builtin/Functions/computeAtmosphereColor.glsl +88 -0
- package/Source/Shaders/Builtin/Functions/computeAtmosphereColor.js +90 -0
- package/Source/Shaders/Builtin/Functions/computeGroundAtmosphereScattering.glsl +30 -0
- package/Source/Shaders/Builtin/Functions/computeGroundAtmosphereScattering.js +32 -0
- package/Source/Shaders/Builtin/Functions/computePosition.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/computePosition.js +24 -0
- package/Source/Shaders/Builtin/Functions/computeScattering.glsl +149 -0
- package/Source/Shaders/Builtin/Functions/computeScattering.js +151 -0
- package/Source/Shaders/Builtin/Functions/cosineAndSine.glsl +211 -0
- package/Source/Shaders/Builtin/Functions/cosineAndSine.js +213 -0
- package/Source/Shaders/Builtin/Functions/decompressTextureCoordinates.glsl +17 -0
- package/Source/Shaders/Builtin/Functions/decompressTextureCoordinates.js +19 -0
- package/Source/Shaders/Builtin/Functions/depthClamp.glsl +47 -0
- package/Source/Shaders/Builtin/Functions/depthClamp.js +49 -0
- package/Source/Shaders/Builtin/Functions/eastNorthUpToEyeCoordinates.glsl +33 -0
- package/Source/Shaders/Builtin/Functions/eastNorthUpToEyeCoordinates.js +35 -0
- package/Source/Shaders/Builtin/Functions/ellipsoidContainsPoint.glsl +12 -0
- package/Source/Shaders/Builtin/Functions/ellipsoidContainsPoint.js +14 -0
- package/Source/Shaders/Builtin/Functions/ellipsoidTextureCoordinates.glsl +10 -0
- package/Source/Shaders/Builtin/Functions/ellipsoidTextureCoordinates.js +12 -0
- package/Source/Shaders/Builtin/Functions/equalsEpsilon.glsl +36 -0
- package/Source/Shaders/Builtin/Functions/equalsEpsilon.js +38 -0
- package/Source/Shaders/Builtin/Functions/eyeOffset.glsl +20 -0
- package/Source/Shaders/Builtin/Functions/eyeOffset.js +22 -0
- package/Source/Shaders/Builtin/Functions/eyeToWindowCoordinates.glsl +32 -0
- package/Source/Shaders/Builtin/Functions/eyeToWindowCoordinates.js +34 -0
- package/Source/Shaders/Builtin/Functions/fastApproximateAtan.glsl +55 -0
- package/Source/Shaders/Builtin/Functions/fastApproximateAtan.js +57 -0
- package/Source/Shaders/Builtin/Functions/fog.glsl +38 -0
- package/Source/Shaders/Builtin/Functions/fog.js +40 -0
- package/Source/Shaders/Builtin/Functions/gammaCorrect.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/gammaCorrect.js +24 -0
- package/Source/Shaders/Builtin/Functions/geodeticSurfaceNormal.glsl +16 -0
- package/Source/Shaders/Builtin/Functions/geodeticSurfaceNormal.js +18 -0
- package/Source/Shaders/Builtin/Functions/getDefaultMaterial.glsl +27 -0
- package/Source/Shaders/Builtin/Functions/getDefaultMaterial.js +29 -0
- package/Source/Shaders/Builtin/Functions/getDynamicAtmosphereLightDirection.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/getDynamicAtmosphereLightDirection.js +24 -0
- package/Source/Shaders/Builtin/Functions/getLambertDiffuse.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/getLambertDiffuse.js +24 -0
- package/Source/Shaders/Builtin/Functions/getSpecular.glsl +29 -0
- package/Source/Shaders/Builtin/Functions/getSpecular.js +31 -0
- package/Source/Shaders/Builtin/Functions/getWaterNoise.glsl +37 -0
- package/Source/Shaders/Builtin/Functions/getWaterNoise.js +39 -0
- package/Source/Shaders/Builtin/Functions/hue.glsl +30 -0
- package/Source/Shaders/Builtin/Functions/hue.js +32 -0
- package/Source/Shaders/Builtin/Functions/inverseGamma.glsl +12 -0
- package/Source/Shaders/Builtin/Functions/inverseGamma.js +14 -0
- package/Source/Shaders/Builtin/Functions/isEmpty.glsl +19 -0
- package/Source/Shaders/Builtin/Functions/isEmpty.js +21 -0
- package/Source/Shaders/Builtin/Functions/isFull.glsl +19 -0
- package/Source/Shaders/Builtin/Functions/isFull.js +21 -0
- package/Source/Shaders/Builtin/Functions/latitudeToWebMercatorFraction.glsl +21 -0
- package/Source/Shaders/Builtin/Functions/latitudeToWebMercatorFraction.js +23 -0
- package/Source/Shaders/Builtin/Functions/lineDistance.glsl +14 -0
- package/Source/Shaders/Builtin/Functions/lineDistance.js +16 -0
- package/Source/Shaders/Builtin/Functions/linearToSrgb.glsl +16 -0
- package/Source/Shaders/Builtin/Functions/linearToSrgb.js +18 -0
- package/Source/Shaders/Builtin/Functions/luminance.glsl +20 -0
- package/Source/Shaders/Builtin/Functions/luminance.js +22 -0
- package/Source/Shaders/Builtin/Functions/maximumComponent.glsl +21 -0
- package/Source/Shaders/Builtin/Functions/maximumComponent.js +23 -0
- package/Source/Shaders/Builtin/Functions/metersPerPixel.glsl +61 -0
- package/Source/Shaders/Builtin/Functions/metersPerPixel.js +63 -0
- package/Source/Shaders/Builtin/Functions/modelToWindowCoordinates.glsl +38 -0
- package/Source/Shaders/Builtin/Functions/modelToWindowCoordinates.js +40 -0
- package/Source/Shaders/Builtin/Functions/multiplyWithColorBalance.glsl +18 -0
- package/Source/Shaders/Builtin/Functions/multiplyWithColorBalance.js +20 -0
- package/Source/Shaders/Builtin/Functions/nearFarScalar.glsl +26 -0
- package/Source/Shaders/Builtin/Functions/nearFarScalar.js +28 -0
- package/Source/Shaders/Builtin/Functions/octDecode.glsl +83 -0
- package/Source/Shaders/Builtin/Functions/octDecode.js +85 -0
- package/Source/Shaders/Builtin/Functions/packDepth.glsl +18 -0
- package/Source/Shaders/Builtin/Functions/packDepth.js +20 -0
- package/Source/Shaders/Builtin/Functions/pbrLighting.glsl +164 -0
- package/Source/Shaders/Builtin/Functions/pbrLighting.js +166 -0
- package/Source/Shaders/Builtin/Functions/pbrNeutralTonemapping.glsl +23 -0
- package/Source/Shaders/Builtin/Functions/pbrNeutralTonemapping.js +25 -0
- package/Source/Shaders/Builtin/Functions/phong.glsl +63 -0
- package/Source/Shaders/Builtin/Functions/phong.js +65 -0
- package/Source/Shaders/Builtin/Functions/planeDistance.glsl +28 -0
- package/Source/Shaders/Builtin/Functions/planeDistance.js +30 -0
- package/Source/Shaders/Builtin/Functions/pointAlongRay.glsl +19 -0
- package/Source/Shaders/Builtin/Functions/pointAlongRay.js +21 -0
- package/Source/Shaders/Builtin/Functions/rayEllipsoidIntersectionInterval.glsl +83 -0
- package/Source/Shaders/Builtin/Functions/rayEllipsoidIntersectionInterval.js +85 -0
- package/Source/Shaders/Builtin/Functions/raySphereIntersectionInterval.glsl +36 -0
- package/Source/Shaders/Builtin/Functions/raySphereIntersectionInterval.js +38 -0
- package/Source/Shaders/Builtin/Functions/readDepth.glsl +4 -0
- package/Source/Shaders/Builtin/Functions/readDepth.js +6 -0
- package/Source/Shaders/Builtin/Functions/readNonPerspective.glsl +31 -0
- package/Source/Shaders/Builtin/Functions/readNonPerspective.js +33 -0
- package/Source/Shaders/Builtin/Functions/reverseLogDepth.glsl +11 -0
- package/Source/Shaders/Builtin/Functions/reverseLogDepth.js +13 -0
- package/Source/Shaders/Builtin/Functions/round.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/round.js +24 -0
- package/Source/Shaders/Builtin/Functions/saturation.glsl +22 -0
- package/Source/Shaders/Builtin/Functions/saturation.js +24 -0
- package/Source/Shaders/Builtin/Functions/shadowDepthCompare.glsl +24 -0
- package/Source/Shaders/Builtin/Functions/shadowDepthCompare.js +26 -0
- package/Source/Shaders/Builtin/Functions/shadowVisibility.glsl +66 -0
- package/Source/Shaders/Builtin/Functions/shadowVisibility.js +68 -0
- package/Source/Shaders/Builtin/Functions/signNotZero.glsl +29 -0
- package/Source/Shaders/Builtin/Functions/signNotZero.js +31 -0
- package/Source/Shaders/Builtin/Functions/sphericalHarmonics.glsl +44 -0
- package/Source/Shaders/Builtin/Functions/sphericalHarmonics.js +46 -0
- package/Source/Shaders/Builtin/Functions/srgbToLinear.glsl +16 -0
- package/Source/Shaders/Builtin/Functions/srgbToLinear.js +18 -0
- package/Source/Shaders/Builtin/Functions/tangentToEyeSpaceMatrix.glsl +25 -0
- package/Source/Shaders/Builtin/Functions/tangentToEyeSpaceMatrix.js +27 -0
- package/Source/Shaders/Builtin/Functions/textureCube.glsl +36 -0
- package/Source/Shaders/Builtin/Functions/textureCube.js +37 -0
- package/Source/Shaders/Builtin/Functions/transformPlane.glsl +15 -0
- package/Source/Shaders/Builtin/Functions/transformPlane.js +17 -0
- package/Source/Shaders/Builtin/Functions/translateRelativeToEye.glsl +45 -0
- package/Source/Shaders/Builtin/Functions/translateRelativeToEye.js +47 -0
- package/Source/Shaders/Builtin/Functions/translucentPhong.glsl +27 -0
- package/Source/Shaders/Builtin/Functions/translucentPhong.js +29 -0
- package/Source/Shaders/Builtin/Functions/transpose.glsl +45 -0
- package/Source/Shaders/Builtin/Functions/transpose.js +47 -0
- package/Source/Shaders/Builtin/Functions/unpackClippingExtents.glsl +14 -0
- package/Source/Shaders/Builtin/Functions/unpackClippingExtents.js +15 -0
- package/Source/Shaders/Builtin/Functions/unpackDepth.glsl +16 -0
- package/Source/Shaders/Builtin/Functions/unpackDepth.js +18 -0
- package/Source/Shaders/Builtin/Functions/unpackFloat.glsl +24 -0
- package/Source/Shaders/Builtin/Functions/unpackFloat.js +26 -0
- package/Source/Shaders/Builtin/Functions/unpackUint.glsl +31 -0
- package/Source/Shaders/Builtin/Functions/unpackUint.js +33 -0
- package/Source/Shaders/Builtin/Functions/valueTransform.glsl +38 -0
- package/Source/Shaders/Builtin/Functions/valueTransform.js +40 -0
- package/Source/Shaders/Builtin/Functions/vertexLogDepth.glsl +64 -0
- package/Source/Shaders/Builtin/Functions/vertexLogDepth.js +66 -0
- package/Source/Shaders/Builtin/Functions/windowToEyeCoordinates.glsl +110 -0
- package/Source/Shaders/Builtin/Functions/windowToEyeCoordinates.js +112 -0
- package/Source/Shaders/Builtin/Functions/writeDepthClamp.glsl +24 -0
- package/Source/Shaders/Builtin/Functions/writeDepthClamp.js +26 -0
- package/Source/Shaders/Builtin/Functions/writeLogDepth.glsl +79 -0
- package/Source/Shaders/Builtin/Functions/writeLogDepth.js +81 -0
- package/Source/Shaders/Builtin/Functions/writeNonPerspective.glsl +32 -0
- package/Source/Shaders/Builtin/Functions/writeNonPerspective.js +34 -0
- package/Source/Shaders/Builtin/Structs/depthRangeStruct.glsl +9 -0
- package/Source/Shaders/Builtin/Structs/depthRangeStruct.js +11 -0
- package/Source/Shaders/Builtin/Structs/material.glsl +22 -0
- package/Source/Shaders/Builtin/Structs/material.js +24 -0
- package/Source/Shaders/Builtin/Structs/materialInput.glsl +30 -0
- package/Source/Shaders/Builtin/Structs/materialInput.js +32 -0
- package/Source/Shaders/Builtin/Structs/modelMaterial.glsl +45 -0
- package/Source/Shaders/Builtin/Structs/modelMaterial.js +47 -0
- package/Source/Shaders/Builtin/Structs/modelVertexOutput.glsl +16 -0
- package/Source/Shaders/Builtin/Structs/modelVertexOutput.js +18 -0
- package/Source/Shaders/Builtin/Structs/ray.glsl +11 -0
- package/Source/Shaders/Builtin/Structs/ray.js +13 -0
- package/Source/Shaders/Builtin/Structs/raySegment.glsl +27 -0
- package/Source/Shaders/Builtin/Structs/raySegment.js +29 -0
- package/Source/Shaders/Builtin/Structs/shadowParameters.glsl +15 -0
- package/Source/Shaders/Builtin/Structs/shadowParameters.js +17 -0
- package/Source/Shaders/CloudCollectionFS.glsl +263 -0
- package/Source/Shaders/CloudCollectionFS.js +265 -0
- package/Source/Shaders/CloudCollectionVS.glsl +48 -0
- package/Source/Shaders/CloudCollectionVS.js +50 -0
- package/Source/Shaders/CloudNoiseFS.glsl +92 -0
- package/Source/Shaders/CloudNoiseFS.js +94 -0
- package/Source/Shaders/CloudNoiseVS.glsl +18 -0
- package/Source/Shaders/CloudNoiseVS.js +20 -0
- package/Source/Shaders/CompareAndPackTranslucentDepth.glsl +12 -0
- package/Source/Shaders/CompareAndPackTranslucentDepth.js +14 -0
- package/Source/Shaders/CompositeOITFS.glsl +31 -0
- package/Source/Shaders/CompositeOITFS.js +33 -0
- package/Source/Shaders/ComputeIrradianceFS.glsl +103 -0
- package/Source/Shaders/ComputeIrradianceFS.js +105 -0
- package/Source/Shaders/ComputeRadianceMapFS.glsl +107 -0
- package/Source/Shaders/ComputeRadianceMapFS.js +109 -0
- package/Source/Shaders/ConvolveSpecularMapFS.glsl +70 -0
- package/Source/Shaders/ConvolveSpecularMapFS.js +72 -0
- package/Source/Shaders/ConvolveSpecularMapVS.glsl +24 -0
- package/Source/Shaders/ConvolveSpecularMapVS.js +26 -0
- package/Source/Shaders/DepthPlaneFS.glsl +36 -0
- package/Source/Shaders/DepthPlaneFS.js +38 -0
- package/Source/Shaders/DepthPlaneVS.glsl +11 -0
- package/Source/Shaders/DepthPlaneVS.js +13 -0
- package/Source/Shaders/EllipsoidFS.glsl +104 -0
- package/Source/Shaders/EllipsoidFS.js +106 -0
- package/Source/Shaders/EllipsoidVS.glsl +28 -0
- package/Source/Shaders/EllipsoidVS.js +30 -0
- package/Source/Shaders/FXAA3_11.glsl +650 -0
- package/Source/Shaders/FXAA3_11.js +680 -0
- package/Source/Shaders/GlobeFS.glsl +692 -0
- package/Source/Shaders/GlobeFS.js +694 -0
- package/Source/Shaders/GlobeVS.glsl +286 -0
- package/Source/Shaders/GlobeVS.js +288 -0
- package/Source/Shaders/GroundAtmosphere.glsl +18 -0
- package/Source/Shaders/GroundAtmosphere.js +20 -0
- package/Source/Shaders/Materials/AspectRampMaterial.glsl +11 -0
- package/Source/Shaders/Materials/AspectRampMaterial.js +13 -0
- package/Source/Shaders/Materials/BumpMapMaterial.glsl +29 -0
- package/Source/Shaders/Materials/BumpMapMaterial.js +31 -0
- package/Source/Shaders/Materials/CheckerboardMaterial.glsl +29 -0
- package/Source/Shaders/Materials/CheckerboardMaterial.js +31 -0
- package/Source/Shaders/Materials/DotMaterial.glsl +18 -0
- package/Source/Shaders/Materials/DotMaterial.js +20 -0
- package/Source/Shaders/Materials/ElevationBandMaterial.glsl +74 -0
- package/Source/Shaders/Materials/ElevationBandMaterial.js +76 -0
- package/Source/Shaders/Materials/ElevationContourMaterial.glsl +26 -0
- package/Source/Shaders/Materials/ElevationContourMaterial.js +28 -0
- package/Source/Shaders/Materials/ElevationRampMaterial.glsl +14 -0
- package/Source/Shaders/Materials/ElevationRampMaterial.js +16 -0
- package/Source/Shaders/Materials/FadeMaterial.glsl +37 -0
- package/Source/Shaders/Materials/FadeMaterial.js +39 -0
- package/Source/Shaders/Materials/GridMaterial.glsl +57 -0
- package/Source/Shaders/Materials/GridMaterial.js +59 -0
- package/Source/Shaders/Materials/NormalMapMaterial.glsl +19 -0
- package/Source/Shaders/Materials/NormalMapMaterial.js +21 -0
- package/Source/Shaders/Materials/PolylineArrowMaterial.glsl +63 -0
- package/Source/Shaders/Materials/PolylineArrowMaterial.js +65 -0
- package/Source/Shaders/Materials/PolylineDashMaterial.glsl +39 -0
- package/Source/Shaders/Materials/PolylineDashMaterial.js +41 -0
- package/Source/Shaders/Materials/PolylineGlowMaterial.glsl +25 -0
- package/Source/Shaders/Materials/PolylineGlowMaterial.js +27 -0
- package/Source/Shaders/Materials/PolylineOutlineMaterial.glsl +29 -0
- package/Source/Shaders/Materials/PolylineOutlineMaterial.js +31 -0
- package/Source/Shaders/Materials/RimLightingMaterial.glsl +21 -0
- package/Source/Shaders/Materials/RimLightingMaterial.js +23 -0
- package/Source/Shaders/Materials/SlopeRampMaterial.glsl +11 -0
- package/Source/Shaders/Materials/SlopeRampMaterial.js +13 -0
- package/Source/Shaders/Materials/StripeMaterial.glsl +24 -0
- package/Source/Shaders/Materials/StripeMaterial.js +26 -0
- package/Source/Shaders/Materials/Water.glsl +58 -0
- package/Source/Shaders/Materials/Water.js +60 -0
- package/Source/Shaders/Materials/WaterMaskMaterial.glsl +15 -0
- package/Source/Shaders/Materials/WaterMaskMaterial.js +17 -0
- package/Source/Shaders/Model/AtmosphereStageFS.glsl +108 -0
- package/Source/Shaders/Model/AtmosphereStageFS.js +110 -0
- package/Source/Shaders/Model/AtmosphereStageVS.glsl +12 -0
- package/Source/Shaders/Model/AtmosphereStageVS.js +14 -0
- package/Source/Shaders/Model/CPUStylingStageFS.glsl +49 -0
- package/Source/Shaders/Model/CPUStylingStageFS.js +51 -0
- package/Source/Shaders/Model/CPUStylingStageVS.glsl +30 -0
- package/Source/Shaders/Model/CPUStylingStageVS.js +32 -0
- package/Source/Shaders/Model/CustomShaderStageFS.glsl +18 -0
- package/Source/Shaders/Model/CustomShaderStageFS.js +20 -0
- package/Source/Shaders/Model/CustomShaderStageVS.glsl +19 -0
- package/Source/Shaders/Model/CustomShaderStageVS.js +21 -0
- package/Source/Shaders/Model/EdgeDetectionStageFS.glsl +58 -0
- package/Source/Shaders/Model/EdgeDetectionStageFS.js +60 -0
- package/Source/Shaders/Model/EdgeVisibilityStageFS.glsl +83 -0
- package/Source/Shaders/Model/EdgeVisibilityStageFS.js +85 -0
- package/Source/Shaders/Model/FeatureIdStageFS.glsl +4 -0
- package/Source/Shaders/Model/FeatureIdStageFS.js +6 -0
- package/Source/Shaders/Model/FeatureIdStageVS.glsl +6 -0
- package/Source/Shaders/Model/FeatureIdStageVS.js +8 -0
- package/Source/Shaders/Model/GeometryStageFS.glsl +25 -0
- package/Source/Shaders/Model/GeometryStageFS.js +27 -0
- package/Source/Shaders/Model/GeometryStageVS.glsl +42 -0
- package/Source/Shaders/Model/GeometryStageVS.js +44 -0
- package/Source/Shaders/Model/ImageBasedLightingStageFS.glsl +101 -0
- package/Source/Shaders/Model/ImageBasedLightingStageFS.js +103 -0
- package/Source/Shaders/Model/InstancingStageCommon.glsl +67 -0
- package/Source/Shaders/Model/InstancingStageCommon.js +69 -0
- package/Source/Shaders/Model/InstancingStageVS.glsl +18 -0
- package/Source/Shaders/Model/InstancingStageVS.js +20 -0
- package/Source/Shaders/Model/LegacyInstancingStageVS.glsl +20 -0
- package/Source/Shaders/Model/LegacyInstancingStageVS.js +22 -0
- package/Source/Shaders/Model/LightingStageFS.glsl +120 -0
- package/Source/Shaders/Model/LightingStageFS.js +122 -0
- package/Source/Shaders/Model/MaterialStageFS.glsl +497 -0
- package/Source/Shaders/Model/MaterialStageFS.js +499 -0
- package/Source/Shaders/Model/MetadataStageFS.glsl +9 -0
- package/Source/Shaders/Model/MetadataStageFS.js +11 -0
- package/Source/Shaders/Model/MetadataStageVS.glsl +10 -0
- package/Source/Shaders/Model/MetadataStageVS.js +12 -0
- package/Source/Shaders/Model/ModelClippingPlanesStageFS.glsl +88 -0
- package/Source/Shaders/Model/ModelClippingPlanesStageFS.js +90 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageFS.glsl +6 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageFS.js +8 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageVS.glsl +27 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageVS.js +29 -0
- package/Source/Shaders/Model/ModelColorStageFS.glsl +7 -0
- package/Source/Shaders/Model/ModelColorStageFS.js +9 -0
- package/Source/Shaders/Model/ModelFS.glsl +133 -0
- package/Source/Shaders/Model/ModelFS.js +135 -0
- package/Source/Shaders/Model/ModelSilhouetteStageFS.glsl +5 -0
- package/Source/Shaders/Model/ModelSilhouetteStageFS.js +6 -0
- package/Source/Shaders/Model/ModelSilhouetteStageVS.glsl +10 -0
- package/Source/Shaders/Model/ModelSilhouetteStageVS.js +12 -0
- package/Source/Shaders/Model/ModelSplitterStageFS.glsl +9 -0
- package/Source/Shaders/Model/ModelSplitterStageFS.js +11 -0
- package/Source/Shaders/Model/ModelVS.glsl +161 -0
- package/Source/Shaders/Model/ModelVS.js +163 -0
- package/Source/Shaders/Model/MorphTargetsStageVS.glsl +15 -0
- package/Source/Shaders/Model/MorphTargetsStageVS.js +16 -0
- package/Source/Shaders/Model/PointCloudStylingStageVS.glsl +45 -0
- package/Source/Shaders/Model/PointCloudStylingStageVS.js +47 -0
- package/Source/Shaders/Model/PrimitiveOutlineStageFS.glsl +15 -0
- package/Source/Shaders/Model/PrimitiveOutlineStageFS.js +17 -0
- package/Source/Shaders/Model/PrimitiveOutlineStageVS.glsl +3 -0
- package/Source/Shaders/Model/PrimitiveOutlineStageVS.js +5 -0
- package/Source/Shaders/Model/SelectedFeatureIdStageCommon.glsl +51 -0
- package/Source/Shaders/Model/SelectedFeatureIdStageCommon.js +53 -0
- package/Source/Shaders/Model/SkinningStageVS.glsl +18 -0
- package/Source/Shaders/Model/SkinningStageVS.js +19 -0
- package/Source/Shaders/Model/VerticalExaggerationStageVS.glsl +39 -0
- package/Source/Shaders/Model/VerticalExaggerationStageVS.js +41 -0
- package/Source/Shaders/PointPrimitiveCollectionFS.glsl +47 -0
- package/Source/Shaders/PointPrimitiveCollectionFS.js +49 -0
- package/Source/Shaders/PointPrimitiveCollectionVS.glsl +185 -0
- package/Source/Shaders/PointPrimitiveCollectionVS.js +187 -0
- package/Source/Shaders/PolygonSignedDistanceFS.glsl +100 -0
- package/Source/Shaders/PolygonSignedDistanceFS.js +101 -0
- package/Source/Shaders/PolylineCommon.glsl +176 -0
- package/Source/Shaders/PolylineCommon.js +178 -0
- package/Source/Shaders/PolylineFS.glsl +25 -0
- package/Source/Shaders/PolylineFS.js +27 -0
- package/Source/Shaders/PolylineShadowVolumeFS.glsl +86 -0
- package/Source/Shaders/PolylineShadowVolumeFS.js +88 -0
- package/Source/Shaders/PolylineShadowVolumeMorphFS.glsl +45 -0
- package/Source/Shaders/PolylineShadowVolumeMorphFS.js +47 -0
- package/Source/Shaders/PolylineShadowVolumeMorphVS.glsl +177 -0
- package/Source/Shaders/PolylineShadowVolumeMorphVS.js +179 -0
- package/Source/Shaders/PolylineShadowVolumeVS.glsl +168 -0
- package/Source/Shaders/PolylineShadowVolumeVS.js +170 -0
- package/Source/Shaders/PolylineVS.glsl +103 -0
- package/Source/Shaders/PolylineVS.js +105 -0
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.glsl +25 -0
- package/Source/Shaders/PostProcessStages/AcesTonemappingStage.js +27 -0
- package/Source/Shaders/PostProcessStages/AdditiveBlend.glsl +17 -0
- package/Source/Shaders/PostProcessStages/AdditiveBlend.js +19 -0
- package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.glsl +144 -0
- package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.js +146 -0
- package/Source/Shaders/PostProcessStages/AmbientOcclusionModulate.glsl +11 -0
- package/Source/Shaders/PostProcessStages/AmbientOcclusionModulate.js +13 -0
- package/Source/Shaders/PostProcessStages/BlackAndWhite.glsl +19 -0
- package/Source/Shaders/PostProcessStages/BlackAndWhite.js +21 -0
- package/Source/Shaders/PostProcessStages/BloomComposite.glsl +20 -0
- package/Source/Shaders/PostProcessStages/BloomComposite.js +22 -0
- package/Source/Shaders/PostProcessStages/BrightPass.glsl +30 -0
- package/Source/Shaders/PostProcessStages/BrightPass.js +32 -0
- package/Source/Shaders/PostProcessStages/Brightness.glsl +11 -0
- package/Source/Shaders/PostProcessStages/Brightness.js +13 -0
- package/Source/Shaders/PostProcessStages/CompositeTranslucentClassification.glsl +31 -0
- package/Source/Shaders/PostProcessStages/CompositeTranslucentClassification.js +33 -0
- package/Source/Shaders/PostProcessStages/ContrastBias.glsl +17 -0
- package/Source/Shaders/PostProcessStages/ContrastBias.js +19 -0
- package/Source/Shaders/PostProcessStages/DepthOfField.glsl +39 -0
- package/Source/Shaders/PostProcessStages/DepthOfField.js +41 -0
- package/Source/Shaders/PostProcessStages/DepthView.glsl +9 -0
- package/Source/Shaders/PostProcessStages/DepthView.js +11 -0
- package/Source/Shaders/PostProcessStages/DepthViewPacked.glsl +14 -0
- package/Source/Shaders/PostProcessStages/DepthViewPacked.js +16 -0
- package/Source/Shaders/PostProcessStages/EdgeDetection.glsl +60 -0
- package/Source/Shaders/PostProcessStages/EdgeDetection.js +62 -0
- package/Source/Shaders/PostProcessStages/FXAA.glsl +21 -0
- package/Source/Shaders/PostProcessStages/FXAA.js +23 -0
- package/Source/Shaders/PostProcessStages/FilmicTonemapping.glsl +40 -0
- package/Source/Shaders/PostProcessStages/FilmicTonemapping.js +42 -0
- package/Source/Shaders/PostProcessStages/GaussianBlur1D.glsl +47 -0
- package/Source/Shaders/PostProcessStages/GaussianBlur1D.js +49 -0
- package/Source/Shaders/PostProcessStages/LensFlare.glsl +153 -0
- package/Source/Shaders/PostProcessStages/LensFlare.js +155 -0
- package/Source/Shaders/PostProcessStages/ModifiedReinhardTonemapping.glsl +28 -0
- package/Source/Shaders/PostProcessStages/ModifiedReinhardTonemapping.js +30 -0
- package/Source/Shaders/PostProcessStages/NightVision.glsl +16 -0
- package/Source/Shaders/PostProcessStages/NightVision.js +18 -0
- package/Source/Shaders/PostProcessStages/PassThrough.glsl +8 -0
- package/Source/Shaders/PostProcessStages/PassThrough.js +10 -0
- package/Source/Shaders/PostProcessStages/PassThroughDepth.glsl +8 -0
- package/Source/Shaders/PostProcessStages/PassThroughDepth.js +10 -0
- package/Source/Shaders/PostProcessStages/PbrNeutralTonemapping.glsl +25 -0
- package/Source/Shaders/PostProcessStages/PbrNeutralTonemapping.js +27 -0
- package/Source/Shaders/PostProcessStages/PointCloudEyeDomeLighting.glsl +61 -0
- package/Source/Shaders/PostProcessStages/PointCloudEyeDomeLighting.js +63 -0
- package/Source/Shaders/PostProcessStages/ReinhardTonemapping.glsl +27 -0
- package/Source/Shaders/PostProcessStages/ReinhardTonemapping.js +29 -0
- package/Source/Shaders/PostProcessStages/Silhouette.glsl +11 -0
- package/Source/Shaders/PostProcessStages/Silhouette.js +13 -0
- package/Source/Shaders/PrimitiveGaussianSplatFS.glsl +18 -0
- package/Source/Shaders/PrimitiveGaussianSplatFS.js +20 -0
- package/Source/Shaders/PrimitiveGaussianSplatVS.glsl +189 -0
- package/Source/Shaders/PrimitiveGaussianSplatVS.js +190 -0
- package/Source/Shaders/ReprojectWebMercatorFS.glsl +8 -0
- package/Source/Shaders/ReprojectWebMercatorFS.js +10 -0
- package/Source/Shaders/ReprojectWebMercatorVS.glsl +12 -0
- package/Source/Shaders/ReprojectWebMercatorVS.js +14 -0
- package/Source/Shaders/ShadowVolumeAppearanceFS.glsl +153 -0
- package/Source/Shaders/ShadowVolumeAppearanceFS.js +155 -0
- package/Source/Shaders/ShadowVolumeAppearanceVS.glsl +101 -0
- package/Source/Shaders/ShadowVolumeAppearanceVS.js +103 -0
- package/Source/Shaders/ShadowVolumeFS.glsl +13 -0
- package/Source/Shaders/ShadowVolumeFS.js +15 -0
- package/Source/Shaders/SkyAtmosphereCommon.glsl +81 -0
- package/Source/Shaders/SkyAtmosphereCommon.js +83 -0
- package/Source/Shaders/SkyAtmosphereFS.glsl +59 -0
- package/Source/Shaders/SkyAtmosphereFS.js +61 -0
- package/Source/Shaders/SkyAtmosphereVS.glsl +32 -0
- package/Source/Shaders/SkyAtmosphereVS.js +34 -0
- package/Source/Shaders/SkyBoxFS.glsl +9 -0
- package/Source/Shaders/SkyBoxFS.js +11 -0
- package/Source/Shaders/SkyBoxVS.glsl +9 -0
- package/Source/Shaders/SkyBoxVS.js +11 -0
- package/Source/Shaders/SunFS.glsl +9 -0
- package/Source/Shaders/SunFS.js +11 -0
- package/Source/Shaders/SunTextureFS.glsl +55 -0
- package/Source/Shaders/SunTextureFS.js +57 -0
- package/Source/Shaders/SunVS.glsl +28 -0
- package/Source/Shaders/SunVS.js +30 -0
- package/Source/Shaders/Vector3DTileClampedPolylinesFS.glsl +48 -0
- package/Source/Shaders/Vector3DTileClampedPolylinesFS.js +50 -0
- package/Source/Shaders/Vector3DTileClampedPolylinesVS.glsl +85 -0
- package/Source/Shaders/Vector3DTileClampedPolylinesVS.js +87 -0
- package/Source/Shaders/Vector3DTilePolylinesVS.glsl +22 -0
- package/Source/Shaders/Vector3DTilePolylinesVS.js +24 -0
- package/Source/Shaders/VectorTileVS.glsl +9 -0
- package/Source/Shaders/VectorTileVS.js +11 -0
- package/Source/Shaders/ViewportQuadFS.glsl +16 -0
- package/Source/Shaders/ViewportQuadFS.js +18 -0
- package/Source/Shaders/ViewportQuadVS.glsl +10 -0
- package/Source/Shaders/ViewportQuadVS.js +12 -0
- package/Source/Shaders/Voxels/IntersectBox.glsl +34 -0
- package/Source/Shaders/Voxels/IntersectBox.js +36 -0
- package/Source/Shaders/Voxels/IntersectCylinder.glsl +142 -0
- package/Source/Shaders/Voxels/IntersectCylinder.js +144 -0
- package/Source/Shaders/Voxels/IntersectDepth.glsl +27 -0
- package/Source/Shaders/Voxels/IntersectDepth.js +29 -0
- package/Source/Shaders/Voxels/IntersectEllipsoid.glsl +330 -0
- package/Source/Shaders/Voxels/IntersectEllipsoid.js +332 -0
- package/Source/Shaders/Voxels/IntersectLongitude.glsl +114 -0
- package/Source/Shaders/Voxels/IntersectLongitude.js +116 -0
- package/Source/Shaders/Voxels/IntersectPlane.glsl +80 -0
- package/Source/Shaders/Voxels/IntersectPlane.js +82 -0
- package/Source/Shaders/Voxels/Intersection.glsl +50 -0
- package/Source/Shaders/Voxels/Intersection.js +52 -0
- package/Source/Shaders/Voxels/IntersectionUtils.glsl +167 -0
- package/Source/Shaders/Voxels/IntersectionUtils.js +169 -0
- package/Source/Shaders/Voxels/Megatexture.glsl +123 -0
- package/Source/Shaders/Voxels/Megatexture.js +125 -0
- package/Source/Shaders/Voxels/Octree.glsl +257 -0
- package/Source/Shaders/Voxels/Octree.js +259 -0
- package/Source/Shaders/Voxels/VoxelFS.glsl +267 -0
- package/Source/Shaders/Voxels/VoxelFS.js +269 -0
- package/Source/Shaders/Voxels/VoxelUtils.glsl +12 -0
- package/Source/Shaders/Voxels/VoxelUtils.js +14 -0
- package/Source/Shaders/Voxels/VoxelVS.glsl +11 -0
- package/Source/Shaders/Voxels/VoxelVS.js +13 -0
- package/Source/Shaders/Voxels/convertLocalToBoxUv.glsl +30 -0
- package/Source/Shaders/Voxels/convertLocalToBoxUv.js +32 -0
- package/Source/Shaders/Voxels/convertLocalToCylinderUv.glsl +97 -0
- package/Source/Shaders/Voxels/convertLocalToCylinderUv.js +99 -0
- package/Source/Shaders/Voxels/convertLocalToEllipsoidUv.glsl +193 -0
- package/Source/Shaders/Voxels/convertLocalToEllipsoidUv.js +195 -0
- package/Source/ThirdParty/Workers/basis_transcoder.js +21 -0
- package/Source/ThirdParty/Workers/package.json +1 -0
- package/Source/ThirdParty/Workers/zip-web-worker.js +1 -0
- package/Source/ThirdParty/basis_transcoder.wasm +0 -0
- package/Source/ThirdParty/draco_decoder.wasm +0 -0
- package/Source/ThirdParty/google-earth-dbroot-parser.js +8337 -0
- package/Source/ThirdParty/wasm_splats_bg.wasm +0 -0
- package/Source/ThirdParty/zip-module.wasm +0 -0
- package/Source/Widget/CesiumWidget.css +119 -0
- package/Source/Widget/CesiumWidget.js +1606 -0
- package/Source/Widget/lighter.css +14 -0
- package/Source/Workers/combineGeometry.js +13 -0
- package/Source/Workers/createBoxGeometry.js +10 -0
- package/Source/Workers/createBoxOutlineGeometry.js +10 -0
- package/Source/Workers/createCircleGeometry.js +18 -0
- package/Source/Workers/createCircleOutlineGeometry.js +18 -0
- package/Source/Workers/createCoplanarPolygonGeometry.js +10 -0
- package/Source/Workers/createCoplanarPolygonOutlineGeometry.js +15 -0
- package/Source/Workers/createCorridorGeometry.js +12 -0
- package/Source/Workers/createCorridorOutlineGeometry.js +17 -0
- package/Source/Workers/createCylinderGeometry.js +10 -0
- package/Source/Workers/createCylinderOutlineGeometry.js +10 -0
- package/Source/Workers/createEllipseGeometry.js +14 -0
- package/Source/Workers/createEllipseOutlineGeometry.js +14 -0
- package/Source/Workers/createEllipsoidGeometry.js +10 -0
- package/Source/Workers/createEllipsoidOutlineGeometry.js +13 -0
- package/Source/Workers/createFrustumGeometry.js +10 -0
- package/Source/Workers/createFrustumOutlineGeometry.js +10 -0
- package/Source/Workers/createGeometry.js +78 -0
- package/Source/Workers/createGroundPolylineGeometry.js +16 -0
- package/Source/Workers/createPlaneGeometry.js +10 -0
- package/Source/Workers/createPlaneOutlineGeometry.js +10 -0
- package/Source/Workers/createPolygonGeometry.js +12 -0
- package/Source/Workers/createPolygonOutlineGeometry.js +12 -0
- package/Source/Workers/createPolylineGeometry.js +12 -0
- package/Source/Workers/createPolylineVolumeGeometry.js +17 -0
- package/Source/Workers/createPolylineVolumeOutlineGeometry.js +22 -0
- package/Source/Workers/createRectangleGeometry.js +14 -0
- package/Source/Workers/createRectangleOutlineGeometry.js +17 -0
- package/Source/Workers/createSimplePolylineGeometry.js +17 -0
- package/Source/Workers/createSphereGeometry.js +10 -0
- package/Source/Workers/createSphereOutlineGeometry.js +10 -0
- package/Source/Workers/createTaskProcessorWorker.js +113 -0
- package/Source/Workers/createVectorTileClampedPolylines.js +541 -0
- package/Source/Workers/createVectorTileGeometries.js +414 -0
- package/Source/Workers/createVectorTilePoints.js +81 -0
- package/Source/Workers/createVectorTilePolygons.js +412 -0
- package/Source/Workers/createVectorTilePolylines.js +210 -0
- package/Source/Workers/createVerticesFromCesium3DTilesTerrain.js +46 -0
- package/Source/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +651 -0
- package/Source/Workers/createVerticesFromHeightmap.js +53 -0
- package/Source/Workers/createVerticesFromQuantizedTerrainMesh.js +549 -0
- package/Source/Workers/createWallGeometry.js +12 -0
- package/Source/Workers/createWallOutlineGeometry.js +12 -0
- package/Source/Workers/decodeDraco.js +383 -0
- package/Source/Workers/decodeGoogleEarthEnterprisePacket.js +268 -0
- package/Source/Workers/decodeI3S.js +1652 -0
- package/Source/Workers/gaussianSplatSorter.js +34 -0
- package/Source/Workers/gaussianSplatTextureGenerator.js +39 -0
- package/Source/Workers/incrementallyBuildTerrainPicker.js +108 -0
- package/Source/Workers/transcodeKTX2.js +308 -0
- package/Source/Workers/transferTypedArrayTest.js +16 -0
- package/Source/Workers/upsampleQuantizedTerrainMesh.js +681 -0
- package/Source/Workers/upsampleVerticesFromCesium3DTilesTerrain.js +55 -0
- package/index.d.ts +46026 -0
- package/index.js +1227 -0
- package/package.json +79 -0
|
@@ -0,0 +1,2910 @@
|
|
|
1
|
+
import BoundingSphere from "../Core/BoundingSphere.js";
|
|
2
|
+
import BoxOutlineGeometry from "../Core/BoxOutlineGeometry.js";
|
|
3
|
+
import Cartesian2 from "../Core/Cartesian2.js";
|
|
4
|
+
import Cartesian3 from "../Core/Cartesian3.js";
|
|
5
|
+
import Cartesian4 from "../Core/Cartesian4.js";
|
|
6
|
+
import Cartographic from "../Core/Cartographic.js";
|
|
7
|
+
import clone from "../Core/clone.js";
|
|
8
|
+
import Color from "../Core/Color.js";
|
|
9
|
+
import ColorGeometryInstanceAttribute from "../Core/ColorGeometryInstanceAttribute.js";
|
|
10
|
+
import combine from "../Core/combine.js";
|
|
11
|
+
import defined from "../Core/defined.js";
|
|
12
|
+
import destroyObject from "../Core/destroyObject.js";
|
|
13
|
+
import DeveloperError from "../Core/DeveloperError.js";
|
|
14
|
+
import Event from "../Core/Event.js";
|
|
15
|
+
import GeometryInstance from "../Core/GeometryInstance.js";
|
|
16
|
+
import GeometryPipeline from "../Core/GeometryPipeline.js";
|
|
17
|
+
import IndexDatatype from "../Core/IndexDatatype.js";
|
|
18
|
+
import Intersect from "../Core/Intersect.js";
|
|
19
|
+
import CesiumMath from "../Core/Math.js";
|
|
20
|
+
import Matrix4 from "../Core/Matrix4.js";
|
|
21
|
+
import NearFarScalar from "../Core/NearFarScalar.js";
|
|
22
|
+
import OrientedBoundingBox from "../Core/OrientedBoundingBox.js";
|
|
23
|
+
import OrthographicFrustum from "../Core/OrthographicFrustum.js";
|
|
24
|
+
import PrimitiveType from "../Core/PrimitiveType.js";
|
|
25
|
+
import Rectangle from "../Core/Rectangle.js";
|
|
26
|
+
import SphereOutlineGeometry from "../Core/SphereOutlineGeometry.js";
|
|
27
|
+
import VerticalExaggeration from "../Core/VerticalExaggeration.js";
|
|
28
|
+
import TerrainQuantization from "../Core/TerrainQuantization.js";
|
|
29
|
+
import Visibility from "../Core/Visibility.js";
|
|
30
|
+
import WebMercatorProjection from "../Core/WebMercatorProjection.js";
|
|
31
|
+
import Buffer from "../Renderer/Buffer.js";
|
|
32
|
+
import BufferUsage from "../Renderer/BufferUsage.js";
|
|
33
|
+
import ContextLimits from "../Renderer/ContextLimits.js";
|
|
34
|
+
import DrawCommand from "../Renderer/DrawCommand.js";
|
|
35
|
+
import Pass from "../Renderer/Pass.js";
|
|
36
|
+
import RenderState from "../Renderer/RenderState.js";
|
|
37
|
+
import VertexArray from "../Renderer/VertexArray.js";
|
|
38
|
+
import BlendingState from "./BlendingState.js";
|
|
39
|
+
import ClippingPlaneCollection from "./ClippingPlaneCollection.js";
|
|
40
|
+
import ClippingPolygonCollection from "./ClippingPolygonCollection.js";
|
|
41
|
+
import DepthFunction from "./DepthFunction.js";
|
|
42
|
+
import GlobeSurfaceTile from "./GlobeSurfaceTile.js";
|
|
43
|
+
import ImageryLayer from "./ImageryLayer.js";
|
|
44
|
+
import ImageryState from "./ImageryState.js";
|
|
45
|
+
import PerInstanceColorAppearance from "./PerInstanceColorAppearance.js";
|
|
46
|
+
import Primitive from "./Primitive.js";
|
|
47
|
+
import QuadtreeTileLoadState from "./QuadtreeTileLoadState.js";
|
|
48
|
+
import SceneMode from "./SceneMode.js";
|
|
49
|
+
import ShadowMode from "./ShadowMode.js";
|
|
50
|
+
import TerrainFillMesh from "./TerrainFillMesh.js";
|
|
51
|
+
import TerrainState from "./TerrainState.js";
|
|
52
|
+
import TileBoundingRegion from "./TileBoundingRegion.js";
|
|
53
|
+
import TileSelectionResult from "./TileSelectionResult.js";
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Provides quadtree tiles representing the surface of the globe. This type is intended to be used
|
|
57
|
+
* with {@link QuadtreePrimitive}.
|
|
58
|
+
*
|
|
59
|
+
* @alias GlobeSurfaceTileProvider
|
|
60
|
+
* @constructor
|
|
61
|
+
*
|
|
62
|
+
* @param {TerrainProvider} options.terrainProvider The terrain provider that describes the surface geometry.
|
|
63
|
+
* @param {ImageryLayerCollection} option.imageryLayers The collection of imagery layers describing the shading of the surface.
|
|
64
|
+
* @param {GlobeSurfaceShaderSet} options.surfaceShaderSet The set of shaders used to render the surface.
|
|
65
|
+
*
|
|
66
|
+
* @private
|
|
67
|
+
*/
|
|
68
|
+
function GlobeSurfaceTileProvider(options) {
|
|
69
|
+
//>>includeStart('debug', pragmas.debug);
|
|
70
|
+
if (!defined(options)) {
|
|
71
|
+
throw new DeveloperError("options is required.");
|
|
72
|
+
}
|
|
73
|
+
if (!defined(options.terrainProvider)) {
|
|
74
|
+
throw new DeveloperError("options.terrainProvider is required.");
|
|
75
|
+
} else if (!defined(options.imageryLayers)) {
|
|
76
|
+
throw new DeveloperError("options.imageryLayers is required.");
|
|
77
|
+
} else if (!defined(options.surfaceShaderSet)) {
|
|
78
|
+
throw new DeveloperError("options.surfaceShaderSet is required.");
|
|
79
|
+
}
|
|
80
|
+
//>>includeEnd('debug');
|
|
81
|
+
|
|
82
|
+
this.lightingFadeOutDistance = 6500000.0;
|
|
83
|
+
this.lightingFadeInDistance = 9000000.0;
|
|
84
|
+
this.hasWaterMask = false;
|
|
85
|
+
this.showWaterEffect = false;
|
|
86
|
+
this.oceanNormalMap = undefined;
|
|
87
|
+
this.zoomedOutOceanSpecularIntensity = 0.5;
|
|
88
|
+
this.enableLighting = false;
|
|
89
|
+
this.dynamicAtmosphereLighting = false;
|
|
90
|
+
this.dynamicAtmosphereLightingFromSun = false;
|
|
91
|
+
this.showGroundAtmosphere = false;
|
|
92
|
+
this.shadows = ShadowMode.RECEIVE_ONLY;
|
|
93
|
+
this.vertexShadowDarkness = 0.3;
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* The color to use to highlight terrain fill tiles. If undefined, fill tiles are not
|
|
97
|
+
* highlighted at all. The alpha value is used to alpha blend with the tile's
|
|
98
|
+
* actual color. Because terrain fill tiles do not represent the actual terrain surface,
|
|
99
|
+
* it may be useful in some applications to indicate visually that they are not to be trusted.
|
|
100
|
+
* @type {Color}
|
|
101
|
+
* @default undefined
|
|
102
|
+
*/
|
|
103
|
+
this.fillHighlightColor = undefined;
|
|
104
|
+
|
|
105
|
+
this.hueShift = 0.0;
|
|
106
|
+
this.saturationShift = 0.0;
|
|
107
|
+
this.brightnessShift = 0.0;
|
|
108
|
+
|
|
109
|
+
this.showSkirts = true;
|
|
110
|
+
this.backFaceCulling = true;
|
|
111
|
+
this.undergroundColor = undefined;
|
|
112
|
+
this.undergroundColorAlphaByDistance = undefined;
|
|
113
|
+
|
|
114
|
+
this.lambertDiffuseMultiplier = 0.0;
|
|
115
|
+
|
|
116
|
+
this.materialUniformMap = undefined;
|
|
117
|
+
this._materialUniformMap = undefined;
|
|
118
|
+
|
|
119
|
+
this._quadtree = undefined;
|
|
120
|
+
this._terrainProvider = options.terrainProvider;
|
|
121
|
+
this._imageryLayers = options.imageryLayers;
|
|
122
|
+
this._surfaceShaderSet = options.surfaceShaderSet;
|
|
123
|
+
|
|
124
|
+
this._renderState = undefined;
|
|
125
|
+
this._blendRenderState = undefined;
|
|
126
|
+
this._disableCullingRenderState = undefined;
|
|
127
|
+
this._disableCullingBlendRenderState = undefined;
|
|
128
|
+
|
|
129
|
+
this._errorEvent = new Event();
|
|
130
|
+
|
|
131
|
+
this._removeLayerAddedListener =
|
|
132
|
+
this._imageryLayers.layerAdded.addEventListener(
|
|
133
|
+
GlobeSurfaceTileProvider.prototype._onLayerAdded,
|
|
134
|
+
this,
|
|
135
|
+
);
|
|
136
|
+
this._removeLayerRemovedListener =
|
|
137
|
+
this._imageryLayers.layerRemoved.addEventListener(
|
|
138
|
+
GlobeSurfaceTileProvider.prototype._onLayerRemoved,
|
|
139
|
+
this,
|
|
140
|
+
);
|
|
141
|
+
this._removeLayerMovedListener =
|
|
142
|
+
this._imageryLayers.layerMoved.addEventListener(
|
|
143
|
+
GlobeSurfaceTileProvider.prototype._onLayerMoved,
|
|
144
|
+
this,
|
|
145
|
+
);
|
|
146
|
+
this._removeLayerShownListener =
|
|
147
|
+
this._imageryLayers.layerShownOrHidden.addEventListener(
|
|
148
|
+
GlobeSurfaceTileProvider.prototype._onLayerShownOrHidden,
|
|
149
|
+
this,
|
|
150
|
+
);
|
|
151
|
+
this._imageryLayersUpdatedEvent = new Event();
|
|
152
|
+
|
|
153
|
+
this._layerOrderChanged = false;
|
|
154
|
+
|
|
155
|
+
this._tilesToRenderByTextureCount = [];
|
|
156
|
+
this._drawCommands = [];
|
|
157
|
+
this._uniformMaps = [];
|
|
158
|
+
this._usedDrawCommands = 0;
|
|
159
|
+
|
|
160
|
+
this._vertexArraysToDestroy = [];
|
|
161
|
+
|
|
162
|
+
this._debug = {
|
|
163
|
+
wireframe: false,
|
|
164
|
+
boundingSphereTile: undefined,
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
this._baseColor = undefined;
|
|
168
|
+
this._firstPassInitialColor = undefined;
|
|
169
|
+
this.baseColor = new Color(0.0, 0.0, 0.5, 1.0);
|
|
170
|
+
|
|
171
|
+
/**
|
|
172
|
+
* A property specifying a {@link ClippingPlaneCollection} used to selectively disable rendering on the outside of each plane.
|
|
173
|
+
* @type {ClippingPlaneCollection}
|
|
174
|
+
* @private
|
|
175
|
+
*/
|
|
176
|
+
this._clippingPlanes = undefined;
|
|
177
|
+
|
|
178
|
+
/**
|
|
179
|
+
* A property specifying a {@link ClippingPolygonCollection} used to selectively disable rendering inside or outside a list of polygons.
|
|
180
|
+
* @type {ClippingPolygonCollection}
|
|
181
|
+
* @private
|
|
182
|
+
*/
|
|
183
|
+
this._clippingPolygons = undefined;
|
|
184
|
+
|
|
185
|
+
/**
|
|
186
|
+
* A property specifying a {@link Rectangle} used to selectively limit terrain and imagery rendering.
|
|
187
|
+
* @type {Rectangle}
|
|
188
|
+
*/
|
|
189
|
+
this.cartographicLimitRectangle = Rectangle.clone(Rectangle.MAX_VALUE);
|
|
190
|
+
|
|
191
|
+
this._hasLoadedTilesThisFrame = false;
|
|
192
|
+
this._hasFillTilesThisFrame = false;
|
|
193
|
+
|
|
194
|
+
this._oldVerticalExaggeration = undefined;
|
|
195
|
+
this._oldVerticalExaggerationRelativeHeight = undefined;
|
|
196
|
+
this._oldSceneMode = SceneMode.SCENE3D;
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
Object.defineProperties(GlobeSurfaceTileProvider.prototype, {
|
|
200
|
+
/**
|
|
201
|
+
* Gets or sets the color of the globe when no imagery is available.
|
|
202
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
203
|
+
* @type {Color}
|
|
204
|
+
*/
|
|
205
|
+
baseColor: {
|
|
206
|
+
get: function () {
|
|
207
|
+
return this._baseColor;
|
|
208
|
+
},
|
|
209
|
+
set: function (value) {
|
|
210
|
+
//>>includeStart('debug', pragmas.debug);
|
|
211
|
+
if (!defined(value)) {
|
|
212
|
+
throw new DeveloperError("value is required.");
|
|
213
|
+
}
|
|
214
|
+
//>>includeEnd('debug');
|
|
215
|
+
|
|
216
|
+
this._baseColor = value;
|
|
217
|
+
this._firstPassInitialColor = Cartesian4.fromColor(
|
|
218
|
+
value,
|
|
219
|
+
this._firstPassInitialColor,
|
|
220
|
+
);
|
|
221
|
+
},
|
|
222
|
+
},
|
|
223
|
+
/**
|
|
224
|
+
* Gets or sets the {@link QuadtreePrimitive} for which this provider is
|
|
225
|
+
* providing tiles. This property may be undefined if the provider is not yet associated
|
|
226
|
+
* with a {@link QuadtreePrimitive}.
|
|
227
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
228
|
+
* @type {QuadtreePrimitive}
|
|
229
|
+
*/
|
|
230
|
+
quadtree: {
|
|
231
|
+
get: function () {
|
|
232
|
+
return this._quadtree;
|
|
233
|
+
},
|
|
234
|
+
set: function (value) {
|
|
235
|
+
//>>includeStart('debug', pragmas.debug);
|
|
236
|
+
if (!defined(value)) {
|
|
237
|
+
throw new DeveloperError("value is required.");
|
|
238
|
+
}
|
|
239
|
+
//>>includeEnd('debug');
|
|
240
|
+
|
|
241
|
+
this._quadtree = value;
|
|
242
|
+
},
|
|
243
|
+
},
|
|
244
|
+
|
|
245
|
+
/**
|
|
246
|
+
* Gets the tiling scheme used by the provider.
|
|
247
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
248
|
+
* @type {TilingScheme}
|
|
249
|
+
*/
|
|
250
|
+
tilingScheme: {
|
|
251
|
+
get: function () {
|
|
252
|
+
if (!defined(this._terrainProvider)) {
|
|
253
|
+
return undefined;
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
return this._terrainProvider.tilingScheme;
|
|
257
|
+
},
|
|
258
|
+
},
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* Gets an event that is raised when the geometry provider encounters an asynchronous error. By subscribing
|
|
262
|
+
* to the event, you will be notified of the error and can potentially recover from it. Event listeners
|
|
263
|
+
* are passed an instance of {@link TileProviderError}.
|
|
264
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
265
|
+
* @type {Event}
|
|
266
|
+
*/
|
|
267
|
+
errorEvent: {
|
|
268
|
+
get: function () {
|
|
269
|
+
return this._errorEvent;
|
|
270
|
+
},
|
|
271
|
+
},
|
|
272
|
+
|
|
273
|
+
/**
|
|
274
|
+
* Gets an event that is raised when an imagery layer is added, shown, hidden, moved, or removed.
|
|
275
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
276
|
+
* @type {Event}
|
|
277
|
+
*/
|
|
278
|
+
imageryLayersUpdatedEvent: {
|
|
279
|
+
get: function () {
|
|
280
|
+
return this._imageryLayersUpdatedEvent;
|
|
281
|
+
},
|
|
282
|
+
},
|
|
283
|
+
|
|
284
|
+
/**
|
|
285
|
+
* Gets or sets the terrain provider that describes the surface geometry.
|
|
286
|
+
* @memberof GlobeSurfaceTileProvider.prototype
|
|
287
|
+
* @type {TerrainProvider}
|
|
288
|
+
*/
|
|
289
|
+
terrainProvider: {
|
|
290
|
+
get: function () {
|
|
291
|
+
return this._terrainProvider;
|
|
292
|
+
},
|
|
293
|
+
set: function (terrainProvider) {
|
|
294
|
+
if (this._terrainProvider === terrainProvider) {
|
|
295
|
+
return;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
this._terrainProvider = terrainProvider;
|
|
299
|
+
|
|
300
|
+
if (defined(this._quadtree)) {
|
|
301
|
+
this._quadtree.invalidateAllTiles();
|
|
302
|
+
}
|
|
303
|
+
},
|
|
304
|
+
},
|
|
305
|
+
/**
|
|
306
|
+
* The {@link ClippingPlaneCollection} used to selectively disable rendering.
|
|
307
|
+
*
|
|
308
|
+
* @type {ClippingPlaneCollection}
|
|
309
|
+
*
|
|
310
|
+
* @private
|
|
311
|
+
*/
|
|
312
|
+
clippingPlanes: {
|
|
313
|
+
get: function () {
|
|
314
|
+
return this._clippingPlanes;
|
|
315
|
+
},
|
|
316
|
+
set: function (value) {
|
|
317
|
+
ClippingPlaneCollection.setOwner(value, this, "_clippingPlanes");
|
|
318
|
+
},
|
|
319
|
+
},
|
|
320
|
+
|
|
321
|
+
/**
|
|
322
|
+
* The {@link ClippingPolygonCollection} used to selectively disable rendering inside or outside a list of polygons.
|
|
323
|
+
*
|
|
324
|
+
* @type {ClippingPolygonCollection}
|
|
325
|
+
*
|
|
326
|
+
* @private
|
|
327
|
+
*/
|
|
328
|
+
clippingPolygons: {
|
|
329
|
+
get: function () {
|
|
330
|
+
return this._clippingPolygons;
|
|
331
|
+
},
|
|
332
|
+
set: function (value) {
|
|
333
|
+
ClippingPolygonCollection.setOwner(value, this, "_clippingPolygons");
|
|
334
|
+
},
|
|
335
|
+
},
|
|
336
|
+
});
|
|
337
|
+
|
|
338
|
+
function sortTileImageryByLayerIndex(a, b) {
|
|
339
|
+
let aImagery = a.loadingImagery;
|
|
340
|
+
if (!defined(aImagery)) {
|
|
341
|
+
aImagery = a.readyImagery;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
let bImagery = b.loadingImagery;
|
|
345
|
+
if (!defined(bImagery)) {
|
|
346
|
+
bImagery = b.readyImagery;
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
return aImagery.imageryLayer._layerIndex - bImagery.imageryLayer._layerIndex;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
/**
|
|
353
|
+
* Make updates to the tile provider that are not involved in rendering. Called before the render update cycle.
|
|
354
|
+
*/
|
|
355
|
+
GlobeSurfaceTileProvider.prototype.update = function (frameState) {
|
|
356
|
+
// update collection: imagery indices, base layers, raise layer show/hide event
|
|
357
|
+
this._imageryLayers._update();
|
|
358
|
+
};
|
|
359
|
+
|
|
360
|
+
function updateCredits(surface, frameState) {
|
|
361
|
+
const creditDisplay = frameState.creditDisplay;
|
|
362
|
+
const terrainProvider = surface._terrainProvider;
|
|
363
|
+
if (defined(terrainProvider) && defined(terrainProvider.credit)) {
|
|
364
|
+
creditDisplay.addCreditToNextFrame(terrainProvider.credit);
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
const imageryLayers = surface._imageryLayers;
|
|
368
|
+
for (let i = 0, len = imageryLayers.length; i < len; ++i) {
|
|
369
|
+
const layer = imageryLayers.get(i);
|
|
370
|
+
if (layer.ready && layer.show && defined(layer.imageryProvider.credit)) {
|
|
371
|
+
creditDisplay.addCreditToNextFrame(layer.imageryProvider.credit);
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* Called at the beginning of each render frame, before {@link QuadtreeTileProvider#showTileThisFrame}
|
|
378
|
+
* @param {FrameState} frameState The frame state.
|
|
379
|
+
*/
|
|
380
|
+
GlobeSurfaceTileProvider.prototype.initialize = function (frameState) {
|
|
381
|
+
// update each layer for texture reprojection.
|
|
382
|
+
this._imageryLayers.queueReprojectionCommands(frameState);
|
|
383
|
+
|
|
384
|
+
if (this._layerOrderChanged) {
|
|
385
|
+
this._layerOrderChanged = false;
|
|
386
|
+
|
|
387
|
+
// Sort the TileImagery instances in each tile by the layer index.
|
|
388
|
+
this._quadtree.forEachLoadedTile(function (tile) {
|
|
389
|
+
tile.data.imagery.sort(sortTileImageryByLayerIndex);
|
|
390
|
+
});
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
// Add credits for terrain and imagery providers.
|
|
394
|
+
updateCredits(this, frameState);
|
|
395
|
+
|
|
396
|
+
const vertexArraysToDestroy = this._vertexArraysToDestroy;
|
|
397
|
+
const length = vertexArraysToDestroy.length;
|
|
398
|
+
for (let j = 0; j < length; ++j) {
|
|
399
|
+
GlobeSurfaceTile._freeVertexArray(vertexArraysToDestroy[j]);
|
|
400
|
+
}
|
|
401
|
+
vertexArraysToDestroy.length = 0;
|
|
402
|
+
};
|
|
403
|
+
|
|
404
|
+
/**
|
|
405
|
+
* Called at the beginning of the update cycle for each render frame, before {@link QuadtreeTileProvider#showTileThisFrame}
|
|
406
|
+
* or any other functions.
|
|
407
|
+
*
|
|
408
|
+
* @param {FrameState} frameState The frame state.
|
|
409
|
+
*/
|
|
410
|
+
GlobeSurfaceTileProvider.prototype.beginUpdate = function (frameState) {
|
|
411
|
+
const tilesToRenderByTextureCount = this._tilesToRenderByTextureCount;
|
|
412
|
+
for (let i = 0, len = tilesToRenderByTextureCount.length; i < len; ++i) {
|
|
413
|
+
const tiles = tilesToRenderByTextureCount[i];
|
|
414
|
+
if (defined(tiles)) {
|
|
415
|
+
tiles.length = 0;
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
// update clipping planes
|
|
419
|
+
const clippingPlanes = this._clippingPlanes;
|
|
420
|
+
if (defined(clippingPlanes) && clippingPlanes.enabled) {
|
|
421
|
+
clippingPlanes.update(frameState);
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
// update clipping polygons
|
|
425
|
+
const clippingPolygons = this._clippingPolygons;
|
|
426
|
+
if (defined(clippingPolygons) && clippingPolygons.enabled) {
|
|
427
|
+
clippingPolygons.update(frameState);
|
|
428
|
+
clippingPolygons.queueCommands(frameState);
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
this._usedDrawCommands = 0;
|
|
432
|
+
|
|
433
|
+
this._hasLoadedTilesThisFrame = false;
|
|
434
|
+
this._hasFillTilesThisFrame = false;
|
|
435
|
+
};
|
|
436
|
+
|
|
437
|
+
/**
|
|
438
|
+
* Called at the end of the update cycle for each render frame, after {@link QuadtreeTileProvider#showTileThisFrame}
|
|
439
|
+
* and any other functions.
|
|
440
|
+
*
|
|
441
|
+
* @param {FrameState} frameState The frame state.
|
|
442
|
+
*/
|
|
443
|
+
GlobeSurfaceTileProvider.prototype.endUpdate = function (frameState) {
|
|
444
|
+
if (!defined(this._renderState)) {
|
|
445
|
+
this._renderState = RenderState.fromCache({
|
|
446
|
+
// Write color and depth
|
|
447
|
+
cull: {
|
|
448
|
+
enabled: true,
|
|
449
|
+
},
|
|
450
|
+
depthTest: {
|
|
451
|
+
enabled: true,
|
|
452
|
+
func: DepthFunction.LESS,
|
|
453
|
+
},
|
|
454
|
+
});
|
|
455
|
+
|
|
456
|
+
this._blendRenderState = RenderState.fromCache({
|
|
457
|
+
// Write color and depth
|
|
458
|
+
cull: {
|
|
459
|
+
enabled: true,
|
|
460
|
+
},
|
|
461
|
+
depthTest: {
|
|
462
|
+
enabled: true,
|
|
463
|
+
func: DepthFunction.LESS_OR_EQUAL,
|
|
464
|
+
},
|
|
465
|
+
blending: BlendingState.ALPHA_BLEND,
|
|
466
|
+
});
|
|
467
|
+
|
|
468
|
+
let rs = clone(this._renderState, true);
|
|
469
|
+
rs.cull.enabled = false;
|
|
470
|
+
this._disableCullingRenderState = RenderState.fromCache(rs);
|
|
471
|
+
|
|
472
|
+
rs = clone(this._blendRenderState, true);
|
|
473
|
+
rs.cull.enabled = false;
|
|
474
|
+
this._disableCullingBlendRenderState = RenderState.fromCache(rs);
|
|
475
|
+
}
|
|
476
|
+
|
|
477
|
+
// If this frame has a mix of loaded and fill tiles, we need to propagate
|
|
478
|
+
// loaded heights to the fill tiles.
|
|
479
|
+
if (this._hasFillTilesThisFrame && this._hasLoadedTilesThisFrame) {
|
|
480
|
+
TerrainFillMesh.updateFillTiles(
|
|
481
|
+
this,
|
|
482
|
+
this._quadtree._tilesToRender,
|
|
483
|
+
frameState,
|
|
484
|
+
this._vertexArraysToDestroy,
|
|
485
|
+
);
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
// When vertical exaggeration changes, all of the loaded tiles need to generate
|
|
489
|
+
// geodetic surface normals so they can scale properly when rendered.
|
|
490
|
+
// When exaggeration is reset, geodetic surface normals are removed to decrease
|
|
491
|
+
// memory usage. Some tiles might have been constructed with the correct
|
|
492
|
+
// exaggeration already, so skip over them.
|
|
493
|
+
|
|
494
|
+
// If the geodetic surface normals can't be created because the tile doesn't
|
|
495
|
+
// have a mesh, keep checking until the tile does have a mesh. This can happen
|
|
496
|
+
// if the tile's mesh starts construction in a worker thread right before the
|
|
497
|
+
// exaggeration changes.
|
|
498
|
+
|
|
499
|
+
const quadtree = this.quadtree;
|
|
500
|
+
const exaggeration = frameState.verticalExaggeration;
|
|
501
|
+
const exaggerationRelativeHeight =
|
|
502
|
+
frameState.verticalExaggerationRelativeHeight;
|
|
503
|
+
const exaggerationChanged =
|
|
504
|
+
this._oldVerticalExaggeration !== exaggeration ||
|
|
505
|
+
this._oldVerticalExaggerationRelativeHeight !== exaggerationRelativeHeight;
|
|
506
|
+
|
|
507
|
+
// Keep track of the next time there is a change in exaggeration
|
|
508
|
+
this._oldVerticalExaggeration = exaggeration;
|
|
509
|
+
this._oldVerticalExaggerationRelativeHeight = exaggerationRelativeHeight;
|
|
510
|
+
|
|
511
|
+
if (exaggerationChanged) {
|
|
512
|
+
quadtree.forEachLoadedTile(function (tile) {
|
|
513
|
+
const surfaceTile = tile.data;
|
|
514
|
+
surfaceTile.updateExaggeration(tile, frameState, quadtree);
|
|
515
|
+
});
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
const sceneModeChanged = this._oldSceneMode !== frameState.mode;
|
|
519
|
+
this._oldSceneMode = frameState.mode;
|
|
520
|
+
|
|
521
|
+
if (sceneModeChanged) {
|
|
522
|
+
quadtree.forEachLoadedTile(function (tile) {
|
|
523
|
+
const surfaceTile = tile.data;
|
|
524
|
+
surfaceTile.updateSceneMode(frameState.mode);
|
|
525
|
+
});
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
// Add the tile render commands to the command list, sorted by texture count.
|
|
529
|
+
const tilesToRenderByTextureCount = this._tilesToRenderByTextureCount;
|
|
530
|
+
for (
|
|
531
|
+
let textureCountIndex = 0,
|
|
532
|
+
textureCountLength = tilesToRenderByTextureCount.length;
|
|
533
|
+
textureCountIndex < textureCountLength;
|
|
534
|
+
++textureCountIndex
|
|
535
|
+
) {
|
|
536
|
+
const tilesToRender = tilesToRenderByTextureCount[textureCountIndex];
|
|
537
|
+
if (!defined(tilesToRender)) {
|
|
538
|
+
continue;
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
for (
|
|
542
|
+
let tileIndex = 0, tileLength = tilesToRender.length;
|
|
543
|
+
tileIndex < tileLength;
|
|
544
|
+
++tileIndex
|
|
545
|
+
) {
|
|
546
|
+
const tile = tilesToRender[tileIndex];
|
|
547
|
+
const tileBoundingRegion = tile.data.tileBoundingRegion;
|
|
548
|
+
addDrawCommandsForTile(this, tile, frameState);
|
|
549
|
+
frameState.minimumTerrainHeight = Math.min(
|
|
550
|
+
frameState.minimumTerrainHeight,
|
|
551
|
+
tileBoundingRegion.minimumHeight,
|
|
552
|
+
);
|
|
553
|
+
}
|
|
554
|
+
}
|
|
555
|
+
};
|
|
556
|
+
|
|
557
|
+
function pushCommand(command, frameState) {
|
|
558
|
+
const globeTranslucencyState = frameState.globeTranslucencyState;
|
|
559
|
+
if (globeTranslucencyState.translucent) {
|
|
560
|
+
const isBlendCommand = command.renderState.blending.enabled;
|
|
561
|
+
globeTranslucencyState.pushDerivedCommands(
|
|
562
|
+
command,
|
|
563
|
+
isBlendCommand,
|
|
564
|
+
frameState,
|
|
565
|
+
);
|
|
566
|
+
} else {
|
|
567
|
+
frameState.commandList.push(command);
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
|
|
571
|
+
/**
|
|
572
|
+
* Adds draw commands for tiles rendered in the previous frame for a pick pass.
|
|
573
|
+
*
|
|
574
|
+
* @param {FrameState} frameState The frame state.
|
|
575
|
+
*/
|
|
576
|
+
GlobeSurfaceTileProvider.prototype.updateForPick = function (frameState) {
|
|
577
|
+
// Add the tile pick commands from the tiles drawn last frame.
|
|
578
|
+
const drawCommands = this._drawCommands;
|
|
579
|
+
for (let i = 0, length = this._usedDrawCommands; i < length; ++i) {
|
|
580
|
+
pushCommand(drawCommands[i], frameState);
|
|
581
|
+
}
|
|
582
|
+
};
|
|
583
|
+
|
|
584
|
+
/**
|
|
585
|
+
* Cancels any imagery re-projections in the queue.
|
|
586
|
+
*/
|
|
587
|
+
GlobeSurfaceTileProvider.prototype.cancelReprojections = function () {
|
|
588
|
+
this._imageryLayers.cancelReprojections();
|
|
589
|
+
};
|
|
590
|
+
|
|
591
|
+
/**
|
|
592
|
+
* Gets the maximum geometric error allowed in a tile at a given level, in meters.
|
|
593
|
+
*
|
|
594
|
+
* @param {number} level The tile level for which to get the maximum geometric error.
|
|
595
|
+
* @returns {number} The maximum geometric error in meters.
|
|
596
|
+
*/
|
|
597
|
+
GlobeSurfaceTileProvider.prototype.getLevelMaximumGeometricError = function (
|
|
598
|
+
level,
|
|
599
|
+
) {
|
|
600
|
+
if (!defined(this._terrainProvider)) {
|
|
601
|
+
return 0;
|
|
602
|
+
}
|
|
603
|
+
|
|
604
|
+
return this._terrainProvider.getLevelMaximumGeometricError(level);
|
|
605
|
+
};
|
|
606
|
+
|
|
607
|
+
/**
|
|
608
|
+
* Loads, or continues loading, a given tile. This function will continue to be called
|
|
609
|
+
* until {@link QuadtreeTile#state} is no longer {@link QuadtreeTileLoadState#LOADING}.
|
|
610
|
+
*
|
|
611
|
+
* @param {FrameState} frameState The frame state.
|
|
612
|
+
* @param {QuadtreeTile} tile The tile to load.
|
|
613
|
+
*/
|
|
614
|
+
GlobeSurfaceTileProvider.prototype.loadTile = function (frameState, tile) {
|
|
615
|
+
// We don't want to load imagery until we're certain that the terrain tiles are actually visible.
|
|
616
|
+
// So if our bounding volume isn't accurate because it came from another tile, load terrain only
|
|
617
|
+
// initially. If we load some terrain and suddenly have a more accurate bounding volume and the
|
|
618
|
+
// tile is _still_ visible, give the tile a chance to load imagery immediately rather than
|
|
619
|
+
// waiting for next frame.
|
|
620
|
+
|
|
621
|
+
let surfaceTile = tile.data;
|
|
622
|
+
let terrainOnly = true;
|
|
623
|
+
let terrainStateBefore;
|
|
624
|
+
if (defined(surfaceTile)) {
|
|
625
|
+
terrainOnly =
|
|
626
|
+
surfaceTile.boundingVolumeSourceTile !== tile ||
|
|
627
|
+
tile._lastSelectionResult === TileSelectionResult.CULLED_BUT_NEEDED;
|
|
628
|
+
terrainStateBefore = surfaceTile.terrainState;
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
GlobeSurfaceTile.processStateMachine(
|
|
632
|
+
tile,
|
|
633
|
+
frameState,
|
|
634
|
+
this.terrainProvider,
|
|
635
|
+
this._imageryLayers,
|
|
636
|
+
this.quadtree,
|
|
637
|
+
this._vertexArraysToDestroy,
|
|
638
|
+
terrainOnly,
|
|
639
|
+
);
|
|
640
|
+
|
|
641
|
+
surfaceTile = tile.data;
|
|
642
|
+
if (terrainOnly && terrainStateBefore !== tile.data.terrainState) {
|
|
643
|
+
// Terrain state changed. If:
|
|
644
|
+
// a) The tile is visible, and
|
|
645
|
+
// b) The bounding volume is accurate (updated as a side effect of computing visibility)
|
|
646
|
+
// Then we'll load imagery, too.
|
|
647
|
+
if (
|
|
648
|
+
this.computeTileVisibility(tile, frameState, this.quadtree.occluders) !==
|
|
649
|
+
Visibility.NONE &&
|
|
650
|
+
surfaceTile.boundingVolumeSourceTile === tile
|
|
651
|
+
) {
|
|
652
|
+
terrainOnly = false;
|
|
653
|
+
GlobeSurfaceTile.processStateMachine(
|
|
654
|
+
tile,
|
|
655
|
+
frameState,
|
|
656
|
+
this.terrainProvider,
|
|
657
|
+
this._imageryLayers,
|
|
658
|
+
this.quadtree,
|
|
659
|
+
this._vertexArraysToDestroy,
|
|
660
|
+
terrainOnly,
|
|
661
|
+
);
|
|
662
|
+
}
|
|
663
|
+
}
|
|
664
|
+
};
|
|
665
|
+
|
|
666
|
+
const boundingSphereScratch = new BoundingSphere();
|
|
667
|
+
const rectangleIntersectionScratch = new Rectangle();
|
|
668
|
+
const splitCartographicLimitRectangleScratch = new Rectangle();
|
|
669
|
+
const rectangleCenterScratch = new Cartographic();
|
|
670
|
+
|
|
671
|
+
// cartographicLimitRectangle may span the IDL, but tiles never will.
|
|
672
|
+
function clipRectangleAntimeridian(tileRectangle, cartographicLimitRectangle) {
|
|
673
|
+
if (cartographicLimitRectangle.west < cartographicLimitRectangle.east) {
|
|
674
|
+
return cartographicLimitRectangle;
|
|
675
|
+
}
|
|
676
|
+
const splitRectangle = Rectangle.clone(
|
|
677
|
+
cartographicLimitRectangle,
|
|
678
|
+
splitCartographicLimitRectangleScratch,
|
|
679
|
+
);
|
|
680
|
+
const tileCenter = Rectangle.center(tileRectangle, rectangleCenterScratch);
|
|
681
|
+
if (tileCenter.longitude > 0.0) {
|
|
682
|
+
splitRectangle.east = CesiumMath.PI;
|
|
683
|
+
} else {
|
|
684
|
+
splitRectangle.west = -CesiumMath.PI;
|
|
685
|
+
}
|
|
686
|
+
return splitRectangle;
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
function isUndergroundVisible(tileProvider, frameState) {
|
|
690
|
+
if (frameState.cameraUnderground) {
|
|
691
|
+
return true;
|
|
692
|
+
}
|
|
693
|
+
|
|
694
|
+
if (frameState.globeTranslucencyState.translucent) {
|
|
695
|
+
return true;
|
|
696
|
+
}
|
|
697
|
+
|
|
698
|
+
if (tileProvider.backFaceCulling) {
|
|
699
|
+
return false;
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
const clippingPlanes = tileProvider._clippingPlanes;
|
|
703
|
+
if (defined(clippingPlanes) && clippingPlanes.enabled) {
|
|
704
|
+
return true;
|
|
705
|
+
}
|
|
706
|
+
|
|
707
|
+
const clippingPolygons = tileProvider._clippingPolygons;
|
|
708
|
+
if (defined(clippingPolygons) && clippingPolygons.enabled) {
|
|
709
|
+
return true;
|
|
710
|
+
}
|
|
711
|
+
|
|
712
|
+
if (
|
|
713
|
+
!Rectangle.equals(
|
|
714
|
+
tileProvider.cartographicLimitRectangle,
|
|
715
|
+
Rectangle.MAX_VALUE,
|
|
716
|
+
)
|
|
717
|
+
) {
|
|
718
|
+
return true;
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
return false;
|
|
722
|
+
}
|
|
723
|
+
|
|
724
|
+
/**
|
|
725
|
+
* Determines the visibility of a given tile. The tile may be fully visible, partially visible, or not
|
|
726
|
+
* visible at all. Tiles that are renderable and are at least partially visible will be shown by a call
|
|
727
|
+
* to {@link GlobeSurfaceTileProvider#showTileThisFrame}.
|
|
728
|
+
*
|
|
729
|
+
* @param {QuadtreeTile} tile The tile instance.
|
|
730
|
+
* @param {FrameState} frameState The state information about the current frame.
|
|
731
|
+
* @param {QuadtreeOccluders} occluders The objects that may occlude this tile.
|
|
732
|
+
*
|
|
733
|
+
* @returns {Visibility} Visibility.NONE if the tile is not visible,
|
|
734
|
+
* Visibility.PARTIAL if the tile is partially visible, or
|
|
735
|
+
* Visibility.FULL if the tile is fully visible.
|
|
736
|
+
*/
|
|
737
|
+
GlobeSurfaceTileProvider.prototype.computeTileVisibility = function (
|
|
738
|
+
tile,
|
|
739
|
+
frameState,
|
|
740
|
+
occluders,
|
|
741
|
+
) {
|
|
742
|
+
const distance = this.computeDistanceToTile(tile, frameState);
|
|
743
|
+
tile._distance = distance;
|
|
744
|
+
|
|
745
|
+
const undergroundVisible = isUndergroundVisible(this, frameState);
|
|
746
|
+
|
|
747
|
+
if (frameState.fog.enabled && !undergroundVisible) {
|
|
748
|
+
if (CesiumMath.fog(distance, frameState.fog.density) >= 1.0) {
|
|
749
|
+
// Tile is completely in fog so return that it is not visible.
|
|
750
|
+
return Visibility.NONE;
|
|
751
|
+
}
|
|
752
|
+
}
|
|
753
|
+
|
|
754
|
+
const surfaceTile = tile.data;
|
|
755
|
+
const tileBoundingRegion = surfaceTile.tileBoundingRegion;
|
|
756
|
+
|
|
757
|
+
if (surfaceTile.boundingVolumeSourceTile === undefined) {
|
|
758
|
+
// We have no idea where this tile is, so let's just call it partially visible.
|
|
759
|
+
return Visibility.PARTIAL;
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
const cullingVolume = frameState.cullingVolume;
|
|
763
|
+
let boundingVolume = tileBoundingRegion.boundingVolume;
|
|
764
|
+
|
|
765
|
+
if (!defined(boundingVolume)) {
|
|
766
|
+
boundingVolume = tileBoundingRegion.boundingSphere;
|
|
767
|
+
}
|
|
768
|
+
|
|
769
|
+
// Check if the tile is outside the limit area in cartographic space
|
|
770
|
+
surfaceTile.clippedByBoundaries = false;
|
|
771
|
+
const clippedCartographicLimitRectangle = clipRectangleAntimeridian(
|
|
772
|
+
tile.rectangle,
|
|
773
|
+
this.cartographicLimitRectangle,
|
|
774
|
+
);
|
|
775
|
+
const areaLimitIntersection = Rectangle.simpleIntersection(
|
|
776
|
+
clippedCartographicLimitRectangle,
|
|
777
|
+
tile.rectangle,
|
|
778
|
+
rectangleIntersectionScratch,
|
|
779
|
+
);
|
|
780
|
+
if (!defined(areaLimitIntersection)) {
|
|
781
|
+
return Visibility.NONE;
|
|
782
|
+
}
|
|
783
|
+
if (!Rectangle.equals(areaLimitIntersection, tile.rectangle)) {
|
|
784
|
+
surfaceTile.clippedByBoundaries = true;
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
if (frameState.mode !== SceneMode.SCENE3D) {
|
|
788
|
+
boundingVolume = boundingSphereScratch;
|
|
789
|
+
BoundingSphere.fromRectangleWithHeights2D(
|
|
790
|
+
tile.rectangle,
|
|
791
|
+
frameState.mapProjection,
|
|
792
|
+
tileBoundingRegion.minimumHeight,
|
|
793
|
+
tileBoundingRegion.maximumHeight,
|
|
794
|
+
boundingVolume,
|
|
795
|
+
);
|
|
796
|
+
Cartesian3.fromElements(
|
|
797
|
+
boundingVolume.center.z,
|
|
798
|
+
boundingVolume.center.x,
|
|
799
|
+
boundingVolume.center.y,
|
|
800
|
+
boundingVolume.center,
|
|
801
|
+
);
|
|
802
|
+
|
|
803
|
+
if (
|
|
804
|
+
frameState.mode === SceneMode.MORPHING &&
|
|
805
|
+
defined(surfaceTile.renderedMesh)
|
|
806
|
+
) {
|
|
807
|
+
boundingVolume = BoundingSphere.union(
|
|
808
|
+
tileBoundingRegion.boundingSphere,
|
|
809
|
+
boundingVolume,
|
|
810
|
+
boundingVolume,
|
|
811
|
+
);
|
|
812
|
+
}
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
if (!defined(boundingVolume)) {
|
|
816
|
+
return Visibility.PARTIAL;
|
|
817
|
+
}
|
|
818
|
+
|
|
819
|
+
const clippingPlanes = this._clippingPlanes;
|
|
820
|
+
if (defined(clippingPlanes) && clippingPlanes.enabled) {
|
|
821
|
+
const planeIntersection =
|
|
822
|
+
clippingPlanes.computeIntersectionWithBoundingVolume(boundingVolume);
|
|
823
|
+
tile.isClipped = planeIntersection !== Intersect.INSIDE;
|
|
824
|
+
if (planeIntersection === Intersect.OUTSIDE) {
|
|
825
|
+
return Visibility.NONE;
|
|
826
|
+
}
|
|
827
|
+
}
|
|
828
|
+
|
|
829
|
+
const clippingPolygons = this._clippingPolygons;
|
|
830
|
+
if (defined(clippingPolygons) && clippingPolygons.enabled) {
|
|
831
|
+
const polygonIntersection =
|
|
832
|
+
clippingPolygons.computeIntersectionWithBoundingVolume(
|
|
833
|
+
tileBoundingRegion,
|
|
834
|
+
);
|
|
835
|
+
tile.isClipped = polygonIntersection !== Intersect.OUTSIDE;
|
|
836
|
+
// Polygon clipping intersections are determined by outer rectangles, therefore we cannot
|
|
837
|
+
// preemptively determine if a tile is completely clipped or not here.
|
|
838
|
+
}
|
|
839
|
+
|
|
840
|
+
let visibility;
|
|
841
|
+
const intersection = cullingVolume.computeVisibility(boundingVolume);
|
|
842
|
+
|
|
843
|
+
if (intersection === Intersect.OUTSIDE) {
|
|
844
|
+
visibility = Visibility.NONE;
|
|
845
|
+
} else if (intersection === Intersect.INTERSECTING) {
|
|
846
|
+
visibility = Visibility.PARTIAL;
|
|
847
|
+
} else if (intersection === Intersect.INSIDE) {
|
|
848
|
+
visibility = Visibility.FULL;
|
|
849
|
+
}
|
|
850
|
+
|
|
851
|
+
if (visibility === Visibility.NONE) {
|
|
852
|
+
return visibility;
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
const ortho3D =
|
|
856
|
+
frameState.mode === SceneMode.SCENE3D &&
|
|
857
|
+
frameState.camera.frustum instanceof OrthographicFrustum;
|
|
858
|
+
if (
|
|
859
|
+
frameState.mode === SceneMode.SCENE3D &&
|
|
860
|
+
!ortho3D &&
|
|
861
|
+
defined(occluders) &&
|
|
862
|
+
!undergroundVisible
|
|
863
|
+
) {
|
|
864
|
+
const occludeePointInScaledSpace = surfaceTile.occludeePointInScaledSpace;
|
|
865
|
+
if (!defined(occludeePointInScaledSpace)) {
|
|
866
|
+
return visibility;
|
|
867
|
+
}
|
|
868
|
+
|
|
869
|
+
if (
|
|
870
|
+
occluders.ellipsoid.isScaledSpacePointVisiblePossiblyUnderEllipsoid(
|
|
871
|
+
occludeePointInScaledSpace,
|
|
872
|
+
tileBoundingRegion.minimumHeight,
|
|
873
|
+
)
|
|
874
|
+
) {
|
|
875
|
+
return visibility;
|
|
876
|
+
}
|
|
877
|
+
|
|
878
|
+
return Visibility.NONE;
|
|
879
|
+
}
|
|
880
|
+
|
|
881
|
+
return visibility;
|
|
882
|
+
};
|
|
883
|
+
|
|
884
|
+
/**
|
|
885
|
+
* Determines if the given tile can be refined
|
|
886
|
+
* @param {QuadtreeTile} tile The tile to check.
|
|
887
|
+
* @returns {boolean} True if the tile can be refined, false if it cannot.
|
|
888
|
+
*/
|
|
889
|
+
GlobeSurfaceTileProvider.prototype.canRefine = function (tile) {
|
|
890
|
+
// Only allow refinement it we know whether or not the children of this tile exist.
|
|
891
|
+
// For a tileset with `availability`, we'll always be able to refine.
|
|
892
|
+
// We can ask for availability of _any_ child tile because we only need to confirm
|
|
893
|
+
// that we get a yes or no answer, it doesn't matter what the answer is.
|
|
894
|
+
if (defined(tile.data.terrainData)) {
|
|
895
|
+
return true;
|
|
896
|
+
}
|
|
897
|
+
const childAvailable = this.terrainProvider.getTileDataAvailable(
|
|
898
|
+
tile.x * 2,
|
|
899
|
+
tile.y * 2,
|
|
900
|
+
tile.level + 1,
|
|
901
|
+
);
|
|
902
|
+
return childAvailable !== undefined;
|
|
903
|
+
};
|
|
904
|
+
|
|
905
|
+
const readyImageryScratch = [];
|
|
906
|
+
const canRenderTraversalStack = [];
|
|
907
|
+
|
|
908
|
+
/**
|
|
909
|
+
* Determines if the given not-fully-loaded tile can be rendered without losing detail that
|
|
910
|
+
* was present last frame as a result of rendering descendant tiles. This method will only be
|
|
911
|
+
* called if this tile's descendants were rendered last frame. If the tile is fully loaded,
|
|
912
|
+
* it is assumed that this method will return true and it will not be called.
|
|
913
|
+
* @param {QuadtreeTile} tile The tile to check.
|
|
914
|
+
* @returns {boolean} True if the tile can be rendered without losing detail.
|
|
915
|
+
*/
|
|
916
|
+
GlobeSurfaceTileProvider.prototype.canRenderWithoutLosingDetail = function (
|
|
917
|
+
tile,
|
|
918
|
+
frameState,
|
|
919
|
+
) {
|
|
920
|
+
const surfaceTile = tile.data;
|
|
921
|
+
|
|
922
|
+
const readyImagery = readyImageryScratch;
|
|
923
|
+
readyImagery.length = this._imageryLayers.length;
|
|
924
|
+
|
|
925
|
+
let terrainReady = false;
|
|
926
|
+
let initialImageryState = false;
|
|
927
|
+
let imagery;
|
|
928
|
+
|
|
929
|
+
if (defined(surfaceTile)) {
|
|
930
|
+
// We can render even with non-ready terrain as long as all our rendered descendants
|
|
931
|
+
// are missing terrain geometry too. i.e. if we rendered fills for more detailed tiles
|
|
932
|
+
// last frame, it's ok to render a fill for this tile this frame.
|
|
933
|
+
terrainReady = surfaceTile.terrainState === TerrainState.READY;
|
|
934
|
+
|
|
935
|
+
// Initially assume all imagery layers are ready, unless imagery hasn't been initialized at all.
|
|
936
|
+
initialImageryState = true;
|
|
937
|
+
|
|
938
|
+
imagery = surfaceTile.imagery;
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
let i;
|
|
942
|
+
let len;
|
|
943
|
+
|
|
944
|
+
for (i = 0, len = readyImagery.length; i < len; ++i) {
|
|
945
|
+
readyImagery[i] = initialImageryState;
|
|
946
|
+
}
|
|
947
|
+
|
|
948
|
+
if (defined(imagery)) {
|
|
949
|
+
for (i = 0, len = imagery.length; i < len; ++i) {
|
|
950
|
+
const tileImagery = imagery[i];
|
|
951
|
+
const loadingImagery = tileImagery.loadingImagery;
|
|
952
|
+
const isReady =
|
|
953
|
+
!defined(loadingImagery) ||
|
|
954
|
+
loadingImagery.state === ImageryState.FAILED ||
|
|
955
|
+
loadingImagery.state === ImageryState.INVALID;
|
|
956
|
+
const layerIndex = (
|
|
957
|
+
tileImagery.loadingImagery || tileImagery.readyImagery
|
|
958
|
+
).imageryLayer._layerIndex;
|
|
959
|
+
|
|
960
|
+
// For a layer to be ready, all tiles belonging to that layer must be ready.
|
|
961
|
+
readyImagery[layerIndex] = isReady && readyImagery[layerIndex];
|
|
962
|
+
}
|
|
963
|
+
}
|
|
964
|
+
|
|
965
|
+
const lastFrame = this.quadtree._lastSelectionFrameNumber;
|
|
966
|
+
|
|
967
|
+
// Traverse the descendants looking for one with terrain or imagery that is not loaded on this tile.
|
|
968
|
+
const stack = canRenderTraversalStack;
|
|
969
|
+
stack.length = 0;
|
|
970
|
+
stack.push(
|
|
971
|
+
tile.southwestChild,
|
|
972
|
+
tile.southeastChild,
|
|
973
|
+
tile.northwestChild,
|
|
974
|
+
tile.northeastChild,
|
|
975
|
+
);
|
|
976
|
+
|
|
977
|
+
while (stack.length > 0) {
|
|
978
|
+
const descendant = stack.pop();
|
|
979
|
+
const lastFrameSelectionResult =
|
|
980
|
+
descendant._lastSelectionResultFrame === lastFrame
|
|
981
|
+
? descendant._lastSelectionResult
|
|
982
|
+
: TileSelectionResult.NONE;
|
|
983
|
+
|
|
984
|
+
if (lastFrameSelectionResult === TileSelectionResult.RENDERED) {
|
|
985
|
+
const descendantSurface = descendant.data;
|
|
986
|
+
|
|
987
|
+
if (!defined(descendantSurface)) {
|
|
988
|
+
// Descendant has no data, so it can't block rendering.
|
|
989
|
+
continue;
|
|
990
|
+
}
|
|
991
|
+
|
|
992
|
+
if (
|
|
993
|
+
!terrainReady &&
|
|
994
|
+
descendant.data.terrainState === TerrainState.READY
|
|
995
|
+
) {
|
|
996
|
+
// Rendered descendant has real terrain, but we don't. Rendering is blocked.
|
|
997
|
+
return false;
|
|
998
|
+
}
|
|
999
|
+
|
|
1000
|
+
const descendantImagery = descendant.data.imagery;
|
|
1001
|
+
for (i = 0, len = descendantImagery.length; i < len; ++i) {
|
|
1002
|
+
const descendantTileImagery = descendantImagery[i];
|
|
1003
|
+
const descendantLoadingImagery = descendantTileImagery.loadingImagery;
|
|
1004
|
+
const descendantIsReady =
|
|
1005
|
+
!defined(descendantLoadingImagery) ||
|
|
1006
|
+
descendantLoadingImagery.state === ImageryState.FAILED ||
|
|
1007
|
+
descendantLoadingImagery.state === ImageryState.INVALID;
|
|
1008
|
+
const descendantLayerIndex = (
|
|
1009
|
+
descendantTileImagery.loadingImagery ||
|
|
1010
|
+
descendantTileImagery.readyImagery
|
|
1011
|
+
).imageryLayer._layerIndex;
|
|
1012
|
+
|
|
1013
|
+
// If this imagery tile of a descendant is ready but the layer isn't ready in this tile,
|
|
1014
|
+
// then rendering is blocked.
|
|
1015
|
+
if (descendantIsReady && !readyImagery[descendantLayerIndex]) {
|
|
1016
|
+
return false;
|
|
1017
|
+
}
|
|
1018
|
+
}
|
|
1019
|
+
} else if (lastFrameSelectionResult === TileSelectionResult.REFINED) {
|
|
1020
|
+
stack.push(
|
|
1021
|
+
descendant.southwestChild,
|
|
1022
|
+
descendant.southeastChild,
|
|
1023
|
+
descendant.northwestChild,
|
|
1024
|
+
descendant.northeastChild,
|
|
1025
|
+
);
|
|
1026
|
+
}
|
|
1027
|
+
}
|
|
1028
|
+
|
|
1029
|
+
return true;
|
|
1030
|
+
};
|
|
1031
|
+
|
|
1032
|
+
const tileDirectionScratch = new Cartesian3();
|
|
1033
|
+
|
|
1034
|
+
/**
|
|
1035
|
+
* Determines the priority for loading this tile. Lower priority values load sooner.
|
|
1036
|
+
* @param {QuadtreeTile} tile The tile.
|
|
1037
|
+
* @param {FrameState} frameState The frame state.
|
|
1038
|
+
* @returns {number} The load priority value.
|
|
1039
|
+
*/
|
|
1040
|
+
GlobeSurfaceTileProvider.prototype.computeTileLoadPriority = function (
|
|
1041
|
+
tile,
|
|
1042
|
+
frameState,
|
|
1043
|
+
) {
|
|
1044
|
+
const surfaceTile = tile.data;
|
|
1045
|
+
if (surfaceTile === undefined) {
|
|
1046
|
+
return 0.0;
|
|
1047
|
+
}
|
|
1048
|
+
|
|
1049
|
+
const obb = surfaceTile.tileBoundingRegion.boundingVolume;
|
|
1050
|
+
if (obb === undefined) {
|
|
1051
|
+
return 0.0;
|
|
1052
|
+
}
|
|
1053
|
+
|
|
1054
|
+
const cameraPosition = frameState.camera.positionWC;
|
|
1055
|
+
const cameraDirection = frameState.camera.directionWC;
|
|
1056
|
+
const tileDirection = Cartesian3.subtract(
|
|
1057
|
+
obb.center,
|
|
1058
|
+
cameraPosition,
|
|
1059
|
+
tileDirectionScratch,
|
|
1060
|
+
);
|
|
1061
|
+
const magnitude = Cartesian3.magnitude(tileDirection);
|
|
1062
|
+
if (magnitude < CesiumMath.EPSILON5) {
|
|
1063
|
+
return 0.0;
|
|
1064
|
+
}
|
|
1065
|
+
Cartesian3.divideByScalar(tileDirection, magnitude, tileDirection);
|
|
1066
|
+
return (
|
|
1067
|
+
(1.0 - Cartesian3.dot(tileDirection, cameraDirection)) * tile._distance
|
|
1068
|
+
);
|
|
1069
|
+
};
|
|
1070
|
+
|
|
1071
|
+
const modifiedModelViewScratch = new Matrix4();
|
|
1072
|
+
const modifiedModelViewProjectionScratch = new Matrix4();
|
|
1073
|
+
const tileRectangleScratch = new Cartesian4();
|
|
1074
|
+
const localizedCartographicLimitRectangleScratch = new Cartesian4();
|
|
1075
|
+
const localizedTranslucencyRectangleScratch = new Cartesian4();
|
|
1076
|
+
const rtcScratch = new Cartesian3();
|
|
1077
|
+
const centerEyeScratch = new Cartesian3();
|
|
1078
|
+
const southwestScratch = new Cartesian3();
|
|
1079
|
+
const northeastScratch = new Cartesian3();
|
|
1080
|
+
|
|
1081
|
+
/**
|
|
1082
|
+
* Shows a specified tile in this frame. The provider can cause the tile to be shown by adding
|
|
1083
|
+
* render commands to the commandList, or use any other method as appropriate. The tile is not
|
|
1084
|
+
* expected to be visible next frame as well, unless this method is called next frame, too.
|
|
1085
|
+
*
|
|
1086
|
+
* @param {QuadtreeTile} tile The tile instance.
|
|
1087
|
+
* @param {FrameState} frameState The state information of the current rendering frame.
|
|
1088
|
+
*/
|
|
1089
|
+
GlobeSurfaceTileProvider.prototype.showTileThisFrame = function (
|
|
1090
|
+
tile,
|
|
1091
|
+
frameState,
|
|
1092
|
+
) {
|
|
1093
|
+
let readyTextureCount = 0;
|
|
1094
|
+
const tileImageryCollection = tile.data.imagery;
|
|
1095
|
+
for (let i = 0, len = tileImageryCollection.length; i < len; ++i) {
|
|
1096
|
+
const tileImagery = tileImageryCollection[i];
|
|
1097
|
+
if (
|
|
1098
|
+
defined(tileImagery.readyImagery) &&
|
|
1099
|
+
tileImagery.readyImagery.imageryLayer.alpha !== 0.0
|
|
1100
|
+
) {
|
|
1101
|
+
++readyTextureCount;
|
|
1102
|
+
}
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
let tileSet = this._tilesToRenderByTextureCount[readyTextureCount];
|
|
1106
|
+
if (!defined(tileSet)) {
|
|
1107
|
+
tileSet = [];
|
|
1108
|
+
this._tilesToRenderByTextureCount[readyTextureCount] = tileSet;
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1111
|
+
tileSet.push(tile);
|
|
1112
|
+
|
|
1113
|
+
const surfaceTile = tile.data;
|
|
1114
|
+
if (!defined(surfaceTile.vertexArray)) {
|
|
1115
|
+
this._hasFillTilesThisFrame = true;
|
|
1116
|
+
} else {
|
|
1117
|
+
this._hasLoadedTilesThisFrame = true;
|
|
1118
|
+
}
|
|
1119
|
+
|
|
1120
|
+
const debug = this._debug;
|
|
1121
|
+
++debug.tilesRendered;
|
|
1122
|
+
debug.texturesRendered += readyTextureCount;
|
|
1123
|
+
};
|
|
1124
|
+
|
|
1125
|
+
const cornerPositionsScratch = [
|
|
1126
|
+
new Cartesian3(),
|
|
1127
|
+
new Cartesian3(),
|
|
1128
|
+
new Cartesian3(),
|
|
1129
|
+
new Cartesian3(),
|
|
1130
|
+
];
|
|
1131
|
+
|
|
1132
|
+
function computeOccludeePoint(
|
|
1133
|
+
tileProvider,
|
|
1134
|
+
center,
|
|
1135
|
+
rectangle,
|
|
1136
|
+
minimumHeight,
|
|
1137
|
+
maximumHeight,
|
|
1138
|
+
result,
|
|
1139
|
+
) {
|
|
1140
|
+
const ellipsoidalOccluder = tileProvider.quadtree._occluders.ellipsoid;
|
|
1141
|
+
const ellipsoid = ellipsoidalOccluder.ellipsoid;
|
|
1142
|
+
|
|
1143
|
+
const cornerPositions = cornerPositionsScratch;
|
|
1144
|
+
Cartesian3.fromRadians(
|
|
1145
|
+
rectangle.west,
|
|
1146
|
+
rectangle.south,
|
|
1147
|
+
maximumHeight,
|
|
1148
|
+
ellipsoid,
|
|
1149
|
+
cornerPositions[0],
|
|
1150
|
+
);
|
|
1151
|
+
Cartesian3.fromRadians(
|
|
1152
|
+
rectangle.east,
|
|
1153
|
+
rectangle.south,
|
|
1154
|
+
maximumHeight,
|
|
1155
|
+
ellipsoid,
|
|
1156
|
+
cornerPositions[1],
|
|
1157
|
+
);
|
|
1158
|
+
Cartesian3.fromRadians(
|
|
1159
|
+
rectangle.west,
|
|
1160
|
+
rectangle.north,
|
|
1161
|
+
maximumHeight,
|
|
1162
|
+
ellipsoid,
|
|
1163
|
+
cornerPositions[2],
|
|
1164
|
+
);
|
|
1165
|
+
Cartesian3.fromRadians(
|
|
1166
|
+
rectangle.east,
|
|
1167
|
+
rectangle.north,
|
|
1168
|
+
maximumHeight,
|
|
1169
|
+
ellipsoid,
|
|
1170
|
+
cornerPositions[3],
|
|
1171
|
+
);
|
|
1172
|
+
|
|
1173
|
+
return ellipsoidalOccluder.computeHorizonCullingPointPossiblyUnderEllipsoid(
|
|
1174
|
+
center,
|
|
1175
|
+
cornerPositions,
|
|
1176
|
+
minimumHeight,
|
|
1177
|
+
result,
|
|
1178
|
+
);
|
|
1179
|
+
}
|
|
1180
|
+
|
|
1181
|
+
/**
|
|
1182
|
+
* Gets the distance from the camera to the closest point on the tile. This is used for level-of-detail selection.
|
|
1183
|
+
*
|
|
1184
|
+
* @param {QuadtreeTile} tile The tile instance.
|
|
1185
|
+
* @param {FrameState} frameState The state information of the current rendering frame.
|
|
1186
|
+
*
|
|
1187
|
+
* @returns {number} The distance from the camera to the closest point on the tile, in meters.
|
|
1188
|
+
*/
|
|
1189
|
+
GlobeSurfaceTileProvider.prototype.computeDistanceToTile = function (
|
|
1190
|
+
tile,
|
|
1191
|
+
frameState,
|
|
1192
|
+
) {
|
|
1193
|
+
// The distance should be:
|
|
1194
|
+
// 1. the actual distance to the tight-fitting bounding volume, or
|
|
1195
|
+
// 2. a distance that is equal to or greater than the actual distance to the tight-fitting bounding volume.
|
|
1196
|
+
//
|
|
1197
|
+
// When we don't know the min/max heights for a tile, but we do know the min/max of an ancestor tile, we can
|
|
1198
|
+
// build a tight-fitting bounding volume horizontally, but not vertically. The min/max heights from the
|
|
1199
|
+
// ancestor will likely form a volume that is much bigger than it needs to be. This means that the volume may
|
|
1200
|
+
// be deemed to be much closer to the camera than it really is, causing us to select tiles that are too detailed.
|
|
1201
|
+
// Loading too-detailed tiles is super expensive, so we don't want to do that. We don't know where the child
|
|
1202
|
+
// tile really lies within the parent range of heights, but we _do_ know the child tile can't be any closer than
|
|
1203
|
+
// the ancestor height surface (min or max) that is _farthest away_ from the camera. So if we compute distance
|
|
1204
|
+
// based on that conservative metric, we may end up loading tiles that are not detailed enough, but that's much
|
|
1205
|
+
// better (faster) than loading tiles that are too detailed.
|
|
1206
|
+
|
|
1207
|
+
updateTileBoundingRegion(tile, this, frameState);
|
|
1208
|
+
|
|
1209
|
+
const surfaceTile = tile.data;
|
|
1210
|
+
const boundingVolumeSourceTile = surfaceTile.boundingVolumeSourceTile;
|
|
1211
|
+
if (boundingVolumeSourceTile === undefined) {
|
|
1212
|
+
// Can't find any min/max heights anywhere? Ok, let's just say the
|
|
1213
|
+
// tile is really far away so we'll load and render it rather than
|
|
1214
|
+
// refining.
|
|
1215
|
+
return 9999999999.0;
|
|
1216
|
+
}
|
|
1217
|
+
|
|
1218
|
+
const tileBoundingRegion = surfaceTile.tileBoundingRegion;
|
|
1219
|
+
const min = tileBoundingRegion.minimumHeight;
|
|
1220
|
+
const max = tileBoundingRegion.maximumHeight;
|
|
1221
|
+
|
|
1222
|
+
if (surfaceTile.boundingVolumeSourceTile !== tile) {
|
|
1223
|
+
const cameraHeight = frameState.camera.positionCartographic.height;
|
|
1224
|
+
const distanceToMin = Math.abs(cameraHeight - min);
|
|
1225
|
+
const distanceToMax = Math.abs(cameraHeight - max);
|
|
1226
|
+
if (distanceToMin > distanceToMax) {
|
|
1227
|
+
tileBoundingRegion.minimumHeight = min;
|
|
1228
|
+
tileBoundingRegion.maximumHeight = min;
|
|
1229
|
+
} else {
|
|
1230
|
+
tileBoundingRegion.minimumHeight = max;
|
|
1231
|
+
tileBoundingRegion.maximumHeight = max;
|
|
1232
|
+
}
|
|
1233
|
+
}
|
|
1234
|
+
|
|
1235
|
+
const result = tileBoundingRegion.distanceToCamera(frameState);
|
|
1236
|
+
|
|
1237
|
+
tileBoundingRegion.minimumHeight = min;
|
|
1238
|
+
tileBoundingRegion.maximumHeight = max;
|
|
1239
|
+
|
|
1240
|
+
return result;
|
|
1241
|
+
};
|
|
1242
|
+
|
|
1243
|
+
function updateTileBoundingRegion(tile, tileProvider, frameState) {
|
|
1244
|
+
let surfaceTile = tile.data;
|
|
1245
|
+
if (surfaceTile === undefined) {
|
|
1246
|
+
surfaceTile = tile.data = new GlobeSurfaceTile();
|
|
1247
|
+
}
|
|
1248
|
+
|
|
1249
|
+
const ellipsoid = tile.tilingScheme.ellipsoid;
|
|
1250
|
+
if (surfaceTile.tileBoundingRegion === undefined) {
|
|
1251
|
+
surfaceTile.tileBoundingRegion = new TileBoundingRegion({
|
|
1252
|
+
computeBoundingVolumes: false,
|
|
1253
|
+
rectangle: tile.rectangle,
|
|
1254
|
+
ellipsoid: ellipsoid,
|
|
1255
|
+
minimumHeight: 0.0,
|
|
1256
|
+
maximumHeight: 0.0,
|
|
1257
|
+
});
|
|
1258
|
+
}
|
|
1259
|
+
|
|
1260
|
+
const tileBoundingRegion = surfaceTile.tileBoundingRegion;
|
|
1261
|
+
const oldMinimumHeight = tileBoundingRegion.minimumHeight;
|
|
1262
|
+
const oldMaximumHeight = tileBoundingRegion.maximumHeight;
|
|
1263
|
+
let hasBoundingVolumesFromMesh = false;
|
|
1264
|
+
let sourceTile = tile;
|
|
1265
|
+
|
|
1266
|
+
// Get min and max heights from the mesh.
|
|
1267
|
+
// If the mesh is not available, get them from the terrain data.
|
|
1268
|
+
// If the terrain data is not available either, get them from an ancestor.
|
|
1269
|
+
// If none of the ancestors are available, then there are no min and max heights for this tile at this time.
|
|
1270
|
+
const mesh = surfaceTile.mesh;
|
|
1271
|
+
const terrainData = surfaceTile.terrainData;
|
|
1272
|
+
if (
|
|
1273
|
+
mesh !== undefined &&
|
|
1274
|
+
mesh.minimumHeight !== undefined &&
|
|
1275
|
+
mesh.maximumHeight !== undefined
|
|
1276
|
+
) {
|
|
1277
|
+
tileBoundingRegion.minimumHeight = mesh.minimumHeight;
|
|
1278
|
+
tileBoundingRegion.maximumHeight = mesh.maximumHeight;
|
|
1279
|
+
hasBoundingVolumesFromMesh = true;
|
|
1280
|
+
} else if (
|
|
1281
|
+
terrainData !== undefined &&
|
|
1282
|
+
terrainData._minimumHeight !== undefined &&
|
|
1283
|
+
terrainData._maximumHeight !== undefined
|
|
1284
|
+
) {
|
|
1285
|
+
tileBoundingRegion.minimumHeight = terrainData._minimumHeight;
|
|
1286
|
+
tileBoundingRegion.maximumHeight = terrainData._maximumHeight;
|
|
1287
|
+
} else {
|
|
1288
|
+
// No accurate min/max heights available, so we're stuck with min/max heights from an ancestor tile.
|
|
1289
|
+
tileBoundingRegion.minimumHeight = Number.NaN;
|
|
1290
|
+
tileBoundingRegion.maximumHeight = Number.NaN;
|
|
1291
|
+
|
|
1292
|
+
let ancestorTile = tile.parent;
|
|
1293
|
+
while (ancestorTile !== undefined) {
|
|
1294
|
+
const ancestorSurfaceTile = ancestorTile.data;
|
|
1295
|
+
if (ancestorSurfaceTile !== undefined) {
|
|
1296
|
+
const ancestorMesh = ancestorSurfaceTile.mesh;
|
|
1297
|
+
const ancestorTerrainData = ancestorSurfaceTile.terrainData;
|
|
1298
|
+
if (
|
|
1299
|
+
ancestorMesh !== undefined &&
|
|
1300
|
+
ancestorMesh.minimumHeight !== undefined &&
|
|
1301
|
+
ancestorMesh.maximumHeight !== undefined
|
|
1302
|
+
) {
|
|
1303
|
+
tileBoundingRegion.minimumHeight = ancestorMesh.minimumHeight;
|
|
1304
|
+
tileBoundingRegion.maximumHeight = ancestorMesh.maximumHeight;
|
|
1305
|
+
break;
|
|
1306
|
+
} else if (
|
|
1307
|
+
ancestorTerrainData !== undefined &&
|
|
1308
|
+
ancestorTerrainData._minimumHeight !== undefined &&
|
|
1309
|
+
ancestorTerrainData._maximumHeight !== undefined
|
|
1310
|
+
) {
|
|
1311
|
+
tileBoundingRegion.minimumHeight = ancestorTerrainData._minimumHeight;
|
|
1312
|
+
tileBoundingRegion.maximumHeight = ancestorTerrainData._maximumHeight;
|
|
1313
|
+
break;
|
|
1314
|
+
}
|
|
1315
|
+
}
|
|
1316
|
+
ancestorTile = ancestorTile.parent;
|
|
1317
|
+
}
|
|
1318
|
+
sourceTile = ancestorTile;
|
|
1319
|
+
}
|
|
1320
|
+
|
|
1321
|
+
// Update bounding regions from the min and max heights
|
|
1322
|
+
if (sourceTile !== undefined) {
|
|
1323
|
+
const exaggeration = frameState.verticalExaggeration;
|
|
1324
|
+
const exaggerationRelativeHeight =
|
|
1325
|
+
frameState.verticalExaggerationRelativeHeight;
|
|
1326
|
+
const hasExaggeration = exaggeration !== 1.0;
|
|
1327
|
+
if (hasExaggeration) {
|
|
1328
|
+
hasBoundingVolumesFromMesh = false;
|
|
1329
|
+
tileBoundingRegion.minimumHeight = VerticalExaggeration.getHeight(
|
|
1330
|
+
tileBoundingRegion.minimumHeight,
|
|
1331
|
+
exaggeration,
|
|
1332
|
+
exaggerationRelativeHeight,
|
|
1333
|
+
);
|
|
1334
|
+
tileBoundingRegion.maximumHeight = VerticalExaggeration.getHeight(
|
|
1335
|
+
tileBoundingRegion.maximumHeight,
|
|
1336
|
+
exaggeration,
|
|
1337
|
+
exaggerationRelativeHeight,
|
|
1338
|
+
);
|
|
1339
|
+
}
|
|
1340
|
+
|
|
1341
|
+
if (hasBoundingVolumesFromMesh) {
|
|
1342
|
+
if (!surfaceTile.boundingVolumeIsFromMesh) {
|
|
1343
|
+
tileBoundingRegion._orientedBoundingBox = OrientedBoundingBox.clone(
|
|
1344
|
+
mesh.orientedBoundingBox,
|
|
1345
|
+
tileBoundingRegion._orientedBoundingBox,
|
|
1346
|
+
);
|
|
1347
|
+
tileBoundingRegion._boundingSphere = BoundingSphere.clone(
|
|
1348
|
+
mesh.boundingSphere3D,
|
|
1349
|
+
tileBoundingRegion._boundingSphere,
|
|
1350
|
+
);
|
|
1351
|
+
surfaceTile.occludeePointInScaledSpace = Cartesian3.clone(
|
|
1352
|
+
mesh.occludeePointInScaledSpace,
|
|
1353
|
+
surfaceTile.occludeePointInScaledSpace,
|
|
1354
|
+
);
|
|
1355
|
+
|
|
1356
|
+
// If the occludee point is not defined, fallback to calculating it from the OBB
|
|
1357
|
+
if (!defined(surfaceTile.occludeePointInScaledSpace)) {
|
|
1358
|
+
surfaceTile.occludeePointInScaledSpace = computeOccludeePoint(
|
|
1359
|
+
tileProvider,
|
|
1360
|
+
tileBoundingRegion._orientedBoundingBox.center,
|
|
1361
|
+
tile.rectangle,
|
|
1362
|
+
tileBoundingRegion.minimumHeight,
|
|
1363
|
+
tileBoundingRegion.maximumHeight,
|
|
1364
|
+
surfaceTile.occludeePointInScaledSpace,
|
|
1365
|
+
);
|
|
1366
|
+
}
|
|
1367
|
+
}
|
|
1368
|
+
} else {
|
|
1369
|
+
const needsBounds =
|
|
1370
|
+
tileBoundingRegion._orientedBoundingBox === undefined ||
|
|
1371
|
+
tileBoundingRegion._boundingSphere === undefined;
|
|
1372
|
+
const heightChanged =
|
|
1373
|
+
tileBoundingRegion.minimumHeight !== oldMinimumHeight ||
|
|
1374
|
+
tileBoundingRegion.maximumHeight !== oldMaximumHeight;
|
|
1375
|
+
if (heightChanged || needsBounds) {
|
|
1376
|
+
// Bounding volumes need to be recomputed in some circumstances
|
|
1377
|
+
tileBoundingRegion.computeBoundingVolumes(ellipsoid);
|
|
1378
|
+
surfaceTile.occludeePointInScaledSpace = computeOccludeePoint(
|
|
1379
|
+
tileProvider,
|
|
1380
|
+
tileBoundingRegion._orientedBoundingBox.center,
|
|
1381
|
+
tile.rectangle,
|
|
1382
|
+
tileBoundingRegion.minimumHeight,
|
|
1383
|
+
tileBoundingRegion.maximumHeight,
|
|
1384
|
+
surfaceTile.occludeePointInScaledSpace,
|
|
1385
|
+
);
|
|
1386
|
+
}
|
|
1387
|
+
}
|
|
1388
|
+
surfaceTile.boundingVolumeSourceTile = sourceTile;
|
|
1389
|
+
surfaceTile.boundingVolumeIsFromMesh = hasBoundingVolumesFromMesh;
|
|
1390
|
+
} else {
|
|
1391
|
+
surfaceTile.boundingVolumeSourceTile = undefined;
|
|
1392
|
+
surfaceTile.boundingVolumeIsFromMesh = false;
|
|
1393
|
+
}
|
|
1394
|
+
}
|
|
1395
|
+
|
|
1396
|
+
/**
|
|
1397
|
+
* Returns true if this object was destroyed; otherwise, false.
|
|
1398
|
+
* <br /><br />
|
|
1399
|
+
* If this object was destroyed, it should not be used; calling any function other than
|
|
1400
|
+
* <code>isDestroyed</code> will result in a {@link DeveloperError} exception.
|
|
1401
|
+
*
|
|
1402
|
+
* @returns {boolean} True if this object was destroyed; otherwise, false.
|
|
1403
|
+
*
|
|
1404
|
+
* @see GlobeSurfaceTileProvider#destroy
|
|
1405
|
+
*/
|
|
1406
|
+
GlobeSurfaceTileProvider.prototype.isDestroyed = function () {
|
|
1407
|
+
return false;
|
|
1408
|
+
};
|
|
1409
|
+
|
|
1410
|
+
/**
|
|
1411
|
+
* Destroys the WebGL resources held by this object. Destroying an object allows for deterministic
|
|
1412
|
+
* release of WebGL resources, instead of relying on the garbage collector to destroy this object.
|
|
1413
|
+
* <br /><br />
|
|
1414
|
+
* Once an object is destroyed, it should not be used; calling any function other than
|
|
1415
|
+
* <code>isDestroyed</code> will result in a {@link DeveloperError} exception. Therefore,
|
|
1416
|
+
* assign the return value (<code>undefined</code>) to the object as done in the example.
|
|
1417
|
+
*
|
|
1418
|
+
* @exception {DeveloperError} This object was destroyed, i.e., destroy() was called.
|
|
1419
|
+
*
|
|
1420
|
+
*
|
|
1421
|
+
* @example
|
|
1422
|
+
* provider = provider && provider();
|
|
1423
|
+
*
|
|
1424
|
+
* @see GlobeSurfaceTileProvider#isDestroyed
|
|
1425
|
+
*/
|
|
1426
|
+
GlobeSurfaceTileProvider.prototype.destroy = function () {
|
|
1427
|
+
this._tileProvider = this._tileProvider && this._tileProvider.destroy();
|
|
1428
|
+
this._clippingPlanes = this._clippingPlanes && this._clippingPlanes.destroy();
|
|
1429
|
+
this._clippingPolygons =
|
|
1430
|
+
this._clippingPolygons && this._clippingPolygons.destroy();
|
|
1431
|
+
this._removeLayerAddedListener =
|
|
1432
|
+
this._removeLayerAddedListener && this._removeLayerAddedListener();
|
|
1433
|
+
this._removeLayerRemovedListener =
|
|
1434
|
+
this._removeLayerRemovedListener && this._removeLayerRemovedListener();
|
|
1435
|
+
this._removeLayerMovedListener =
|
|
1436
|
+
this._removeLayerMovedListener && this._removeLayerMovedListener();
|
|
1437
|
+
this._removeLayerShownListener =
|
|
1438
|
+
this._removeLayerShownListener && this._removeLayerShownListener();
|
|
1439
|
+
|
|
1440
|
+
return destroyObject(this);
|
|
1441
|
+
};
|
|
1442
|
+
|
|
1443
|
+
function getTileReadyCallback(tileImageriesToFree, layer, terrainProvider) {
|
|
1444
|
+
return function (tile) {
|
|
1445
|
+
let tileImagery;
|
|
1446
|
+
let imagery;
|
|
1447
|
+
let startIndex = -1;
|
|
1448
|
+
const tileImageryCollection = tile.data.imagery;
|
|
1449
|
+
const length = tileImageryCollection.length;
|
|
1450
|
+
let i;
|
|
1451
|
+
for (i = 0; i < length; ++i) {
|
|
1452
|
+
tileImagery = tileImageryCollection[i];
|
|
1453
|
+
imagery = tileImagery.readyImagery ?? tileImagery.loadingImagery;
|
|
1454
|
+
if (imagery.imageryLayer === layer) {
|
|
1455
|
+
startIndex = i;
|
|
1456
|
+
break;
|
|
1457
|
+
}
|
|
1458
|
+
}
|
|
1459
|
+
|
|
1460
|
+
if (startIndex !== -1) {
|
|
1461
|
+
const endIndex = startIndex + tileImageriesToFree;
|
|
1462
|
+
tileImagery = tileImageryCollection[endIndex];
|
|
1463
|
+
imagery = defined(tileImagery)
|
|
1464
|
+
? (tileImagery.readyImagery ?? tileImagery.loadingImagery)
|
|
1465
|
+
: undefined;
|
|
1466
|
+
if (!defined(imagery) || imagery.imageryLayer !== layer) {
|
|
1467
|
+
// Return false to keep the callback if we have to wait on the skeletons
|
|
1468
|
+
// Return true to remove the callback if something went wrong
|
|
1469
|
+
return !layer._createTileImagerySkeletons(
|
|
1470
|
+
tile,
|
|
1471
|
+
terrainProvider,
|
|
1472
|
+
endIndex,
|
|
1473
|
+
);
|
|
1474
|
+
}
|
|
1475
|
+
|
|
1476
|
+
for (i = startIndex; i < endIndex; ++i) {
|
|
1477
|
+
tileImageryCollection[i].freeResources();
|
|
1478
|
+
}
|
|
1479
|
+
|
|
1480
|
+
tileImageryCollection.splice(startIndex, tileImageriesToFree);
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1483
|
+
return true; // Everything is done, so remove the callback
|
|
1484
|
+
};
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
GlobeSurfaceTileProvider.prototype._onLayerAdded = function (layer, index) {
|
|
1488
|
+
if (this.isDestroyed()) {
|
|
1489
|
+
return;
|
|
1490
|
+
}
|
|
1491
|
+
|
|
1492
|
+
if (layer.show) {
|
|
1493
|
+
const terrainProvider = this._terrainProvider;
|
|
1494
|
+
|
|
1495
|
+
const that = this;
|
|
1496
|
+
const tileImageryUpdatedEvent = this._imageryLayersUpdatedEvent;
|
|
1497
|
+
const reloadFunction = function () {
|
|
1498
|
+
// Clear the layer's cache
|
|
1499
|
+
layer._imageryCache = {};
|
|
1500
|
+
|
|
1501
|
+
that._quadtree.forEachLoadedTile(function (tile) {
|
|
1502
|
+
// If this layer is still waiting to for the loaded callback, just return
|
|
1503
|
+
if (defined(tile._loadedCallbacks[layer._layerIndex])) {
|
|
1504
|
+
return;
|
|
1505
|
+
}
|
|
1506
|
+
|
|
1507
|
+
let i;
|
|
1508
|
+
|
|
1509
|
+
// Figure out how many TileImageries we will need to remove and where to insert new ones
|
|
1510
|
+
const tileImageryCollection = tile.data.imagery;
|
|
1511
|
+
const length = tileImageryCollection.length;
|
|
1512
|
+
let startIndex = -1;
|
|
1513
|
+
let tileImageriesToFree = 0;
|
|
1514
|
+
for (i = 0; i < length; ++i) {
|
|
1515
|
+
const tileImagery = tileImageryCollection[i];
|
|
1516
|
+
const imagery =
|
|
1517
|
+
tileImagery.readyImagery ?? tileImagery.loadingImagery;
|
|
1518
|
+
if (imagery.imageryLayer === layer) {
|
|
1519
|
+
if (startIndex === -1) {
|
|
1520
|
+
startIndex = i;
|
|
1521
|
+
}
|
|
1522
|
+
|
|
1523
|
+
++tileImageriesToFree;
|
|
1524
|
+
} else if (startIndex !== -1) {
|
|
1525
|
+
// iterated past the section of TileImageries belonging to this layer, no need to continue.
|
|
1526
|
+
break;
|
|
1527
|
+
}
|
|
1528
|
+
}
|
|
1529
|
+
|
|
1530
|
+
if (startIndex === -1) {
|
|
1531
|
+
return;
|
|
1532
|
+
}
|
|
1533
|
+
|
|
1534
|
+
// Insert immediately after existing TileImageries
|
|
1535
|
+
const insertionPoint = startIndex + tileImageriesToFree;
|
|
1536
|
+
|
|
1537
|
+
// Create new TileImageries for all loaded tiles
|
|
1538
|
+
if (
|
|
1539
|
+
layer._createTileImagerySkeletons(
|
|
1540
|
+
tile,
|
|
1541
|
+
terrainProvider,
|
|
1542
|
+
insertionPoint,
|
|
1543
|
+
)
|
|
1544
|
+
) {
|
|
1545
|
+
// Add callback to remove old TileImageries when the new TileImageries are ready
|
|
1546
|
+
tile._loadedCallbacks[layer._layerIndex] = getTileReadyCallback(
|
|
1547
|
+
tileImageriesToFree,
|
|
1548
|
+
layer,
|
|
1549
|
+
terrainProvider,
|
|
1550
|
+
);
|
|
1551
|
+
|
|
1552
|
+
tile.state = QuadtreeTileLoadState.LOADING;
|
|
1553
|
+
}
|
|
1554
|
+
});
|
|
1555
|
+
};
|
|
1556
|
+
|
|
1557
|
+
if (layer.ready) {
|
|
1558
|
+
const imageryProvider = layer.imageryProvider;
|
|
1559
|
+
imageryProvider._reload = reloadFunction;
|
|
1560
|
+
}
|
|
1561
|
+
|
|
1562
|
+
// create TileImageries for this layer for all previously loaded tiles
|
|
1563
|
+
this._quadtree.forEachLoadedTile(function (tile) {
|
|
1564
|
+
if (layer._createTileImagerySkeletons(tile, terrainProvider)) {
|
|
1565
|
+
tile.state = QuadtreeTileLoadState.LOADING;
|
|
1566
|
+
|
|
1567
|
+
// Tiles that are not currently being rendered need to load the new layer before they're renderable.
|
|
1568
|
+
// We don't mark the rendered tiles non-renderable, though, because that would make the globe disappear.
|
|
1569
|
+
if (
|
|
1570
|
+
tile.level !== 0 &&
|
|
1571
|
+
(tile._lastSelectionResultFrame !==
|
|
1572
|
+
that.quadtree._lastSelectionFrameNumber ||
|
|
1573
|
+
tile._lastSelectionResult !== TileSelectionResult.RENDERED)
|
|
1574
|
+
) {
|
|
1575
|
+
tile.renderable = false;
|
|
1576
|
+
}
|
|
1577
|
+
}
|
|
1578
|
+
});
|
|
1579
|
+
|
|
1580
|
+
this._layerOrderChanged = true;
|
|
1581
|
+
tileImageryUpdatedEvent.raiseEvent();
|
|
1582
|
+
}
|
|
1583
|
+
};
|
|
1584
|
+
|
|
1585
|
+
GlobeSurfaceTileProvider.prototype._onLayerRemoved = function (layer, index) {
|
|
1586
|
+
// destroy TileImagerys for this layer for all previously loaded tiles
|
|
1587
|
+
this._quadtree.forEachLoadedTile(function (tile) {
|
|
1588
|
+
const tileImageryCollection = tile.data.imagery;
|
|
1589
|
+
|
|
1590
|
+
let startIndex = -1;
|
|
1591
|
+
let numDestroyed = 0;
|
|
1592
|
+
for (let i = 0, len = tileImageryCollection.length; i < len; ++i) {
|
|
1593
|
+
const tileImagery = tileImageryCollection[i];
|
|
1594
|
+
let imagery = tileImagery.loadingImagery;
|
|
1595
|
+
if (!defined(imagery)) {
|
|
1596
|
+
imagery = tileImagery.readyImagery;
|
|
1597
|
+
}
|
|
1598
|
+
if (imagery.imageryLayer === layer) {
|
|
1599
|
+
if (startIndex === -1) {
|
|
1600
|
+
startIndex = i;
|
|
1601
|
+
}
|
|
1602
|
+
|
|
1603
|
+
tileImagery.freeResources();
|
|
1604
|
+
++numDestroyed;
|
|
1605
|
+
} else if (startIndex !== -1) {
|
|
1606
|
+
// iterated past the section of TileImagerys belonging to this layer, no need to continue.
|
|
1607
|
+
break;
|
|
1608
|
+
}
|
|
1609
|
+
}
|
|
1610
|
+
|
|
1611
|
+
if (startIndex !== -1) {
|
|
1612
|
+
tileImageryCollection.splice(startIndex, numDestroyed);
|
|
1613
|
+
}
|
|
1614
|
+
});
|
|
1615
|
+
|
|
1616
|
+
if (defined(layer.imageryProvider)) {
|
|
1617
|
+
layer.imageryProvider._reload = undefined;
|
|
1618
|
+
}
|
|
1619
|
+
|
|
1620
|
+
this._imageryLayersUpdatedEvent.raiseEvent();
|
|
1621
|
+
};
|
|
1622
|
+
|
|
1623
|
+
GlobeSurfaceTileProvider.prototype._onLayerMoved = function (
|
|
1624
|
+
layer,
|
|
1625
|
+
newIndex,
|
|
1626
|
+
oldIndex,
|
|
1627
|
+
) {
|
|
1628
|
+
this._layerOrderChanged = true;
|
|
1629
|
+
this._imageryLayersUpdatedEvent.raiseEvent();
|
|
1630
|
+
};
|
|
1631
|
+
|
|
1632
|
+
GlobeSurfaceTileProvider.prototype._onLayerShownOrHidden = function (
|
|
1633
|
+
layer,
|
|
1634
|
+
index,
|
|
1635
|
+
show,
|
|
1636
|
+
) {
|
|
1637
|
+
if (show) {
|
|
1638
|
+
this._onLayerAdded(layer, index);
|
|
1639
|
+
} else {
|
|
1640
|
+
this._onLayerRemoved(layer, index);
|
|
1641
|
+
}
|
|
1642
|
+
};
|
|
1643
|
+
|
|
1644
|
+
const scratchClippingPlanesMatrix = new Matrix4();
|
|
1645
|
+
const scratchInverseTransposeClippingPlanesMatrix = new Matrix4();
|
|
1646
|
+
function createTileUniformMap(frameState, globeSurfaceTileProvider) {
|
|
1647
|
+
const uniformMap = {
|
|
1648
|
+
u_initialColor: function () {
|
|
1649
|
+
return this.properties.initialColor;
|
|
1650
|
+
},
|
|
1651
|
+
u_fillHighlightColor: function () {
|
|
1652
|
+
return this.properties.fillHighlightColor;
|
|
1653
|
+
},
|
|
1654
|
+
u_zoomedOutOceanSpecularIntensity: function () {
|
|
1655
|
+
return this.properties.zoomedOutOceanSpecularIntensity;
|
|
1656
|
+
},
|
|
1657
|
+
u_oceanNormalMap: function () {
|
|
1658
|
+
return this.properties.oceanNormalMap;
|
|
1659
|
+
},
|
|
1660
|
+
u_atmosphereLightIntensity: function () {
|
|
1661
|
+
return this.properties.atmosphereLightIntensity;
|
|
1662
|
+
},
|
|
1663
|
+
u_atmosphereRayleighCoefficient: function () {
|
|
1664
|
+
return this.properties.atmosphereRayleighCoefficient;
|
|
1665
|
+
},
|
|
1666
|
+
u_atmosphereMieCoefficient: function () {
|
|
1667
|
+
return this.properties.atmosphereMieCoefficient;
|
|
1668
|
+
},
|
|
1669
|
+
u_atmosphereRayleighScaleHeight: function () {
|
|
1670
|
+
return this.properties.atmosphereRayleighScaleHeight;
|
|
1671
|
+
},
|
|
1672
|
+
u_atmosphereMieScaleHeight: function () {
|
|
1673
|
+
return this.properties.atmosphereMieScaleHeight;
|
|
1674
|
+
},
|
|
1675
|
+
u_atmosphereMieAnisotropy: function () {
|
|
1676
|
+
return this.properties.atmosphereMieAnisotropy;
|
|
1677
|
+
},
|
|
1678
|
+
u_lightingFadeDistance: function () {
|
|
1679
|
+
return this.properties.lightingFadeDistance;
|
|
1680
|
+
},
|
|
1681
|
+
u_nightFadeDistance: function () {
|
|
1682
|
+
return this.properties.nightFadeDistance;
|
|
1683
|
+
},
|
|
1684
|
+
u_center3D: function () {
|
|
1685
|
+
return this.properties.center3D;
|
|
1686
|
+
},
|
|
1687
|
+
u_verticalExaggerationAndRelativeHeight: function () {
|
|
1688
|
+
return this.properties.verticalExaggerationAndRelativeHeight;
|
|
1689
|
+
},
|
|
1690
|
+
u_tileRectangle: function () {
|
|
1691
|
+
return this.properties.tileRectangle;
|
|
1692
|
+
},
|
|
1693
|
+
u_modifiedModelView: function () {
|
|
1694
|
+
const viewMatrix = frameState.context.uniformState.view;
|
|
1695
|
+
const centerEye = Matrix4.multiplyByPoint(
|
|
1696
|
+
viewMatrix,
|
|
1697
|
+
this.properties.rtc,
|
|
1698
|
+
centerEyeScratch,
|
|
1699
|
+
);
|
|
1700
|
+
Matrix4.setTranslation(viewMatrix, centerEye, modifiedModelViewScratch);
|
|
1701
|
+
return modifiedModelViewScratch;
|
|
1702
|
+
},
|
|
1703
|
+
u_modifiedModelViewProjection: function () {
|
|
1704
|
+
const viewMatrix = frameState.context.uniformState.view;
|
|
1705
|
+
const projectionMatrix = frameState.context.uniformState.projection;
|
|
1706
|
+
const centerEye = Matrix4.multiplyByPoint(
|
|
1707
|
+
viewMatrix,
|
|
1708
|
+
this.properties.rtc,
|
|
1709
|
+
centerEyeScratch,
|
|
1710
|
+
);
|
|
1711
|
+
Matrix4.setTranslation(
|
|
1712
|
+
viewMatrix,
|
|
1713
|
+
centerEye,
|
|
1714
|
+
modifiedModelViewProjectionScratch,
|
|
1715
|
+
);
|
|
1716
|
+
Matrix4.multiply(
|
|
1717
|
+
projectionMatrix,
|
|
1718
|
+
modifiedModelViewProjectionScratch,
|
|
1719
|
+
modifiedModelViewProjectionScratch,
|
|
1720
|
+
);
|
|
1721
|
+
return modifiedModelViewProjectionScratch;
|
|
1722
|
+
},
|
|
1723
|
+
u_dayTextures: function () {
|
|
1724
|
+
return this.properties.dayTextures;
|
|
1725
|
+
},
|
|
1726
|
+
u_dayTextureTranslationAndScale: function () {
|
|
1727
|
+
return this.properties.dayTextureTranslationAndScale;
|
|
1728
|
+
},
|
|
1729
|
+
u_dayTextureTexCoordsRectangle: function () {
|
|
1730
|
+
return this.properties.dayTextureTexCoordsRectangle;
|
|
1731
|
+
},
|
|
1732
|
+
u_dayTextureUseWebMercatorT: function () {
|
|
1733
|
+
return this.properties.dayTextureUseWebMercatorT;
|
|
1734
|
+
},
|
|
1735
|
+
u_dayTextureAlpha: function () {
|
|
1736
|
+
return this.properties.dayTextureAlpha;
|
|
1737
|
+
},
|
|
1738
|
+
u_dayTextureNightAlpha: function () {
|
|
1739
|
+
return this.properties.dayTextureNightAlpha;
|
|
1740
|
+
},
|
|
1741
|
+
u_dayTextureDayAlpha: function () {
|
|
1742
|
+
return this.properties.dayTextureDayAlpha;
|
|
1743
|
+
},
|
|
1744
|
+
u_dayTextureBrightness: function () {
|
|
1745
|
+
return this.properties.dayTextureBrightness;
|
|
1746
|
+
},
|
|
1747
|
+
u_dayTextureContrast: function () {
|
|
1748
|
+
return this.properties.dayTextureContrast;
|
|
1749
|
+
},
|
|
1750
|
+
u_dayTextureHue: function () {
|
|
1751
|
+
return this.properties.dayTextureHue;
|
|
1752
|
+
},
|
|
1753
|
+
u_dayTextureSaturation: function () {
|
|
1754
|
+
return this.properties.dayTextureSaturation;
|
|
1755
|
+
},
|
|
1756
|
+
u_dayTextureOneOverGamma: function () {
|
|
1757
|
+
return this.properties.dayTextureOneOverGamma;
|
|
1758
|
+
},
|
|
1759
|
+
u_dayIntensity: function () {
|
|
1760
|
+
return this.properties.dayIntensity;
|
|
1761
|
+
},
|
|
1762
|
+
u_southAndNorthLatitude: function () {
|
|
1763
|
+
return this.properties.southAndNorthLatitude;
|
|
1764
|
+
},
|
|
1765
|
+
u_southMercatorYAndOneOverHeight: function () {
|
|
1766
|
+
return this.properties.southMercatorYAndOneOverHeight;
|
|
1767
|
+
},
|
|
1768
|
+
u_waterMask: function () {
|
|
1769
|
+
return this.properties.waterMask;
|
|
1770
|
+
},
|
|
1771
|
+
u_waterMaskTranslationAndScale: function () {
|
|
1772
|
+
return this.properties.waterMaskTranslationAndScale;
|
|
1773
|
+
},
|
|
1774
|
+
u_minMaxHeight: function () {
|
|
1775
|
+
return this.properties.minMaxHeight;
|
|
1776
|
+
},
|
|
1777
|
+
u_scaleAndBias: function () {
|
|
1778
|
+
return this.properties.scaleAndBias;
|
|
1779
|
+
},
|
|
1780
|
+
u_dayTextureSplit: function () {
|
|
1781
|
+
return this.properties.dayTextureSplit;
|
|
1782
|
+
},
|
|
1783
|
+
u_dayTextureCutoutRectangles: function () {
|
|
1784
|
+
return this.properties.dayTextureCutoutRectangles;
|
|
1785
|
+
},
|
|
1786
|
+
u_clippingPlanes: function () {
|
|
1787
|
+
const clippingPlanes = globeSurfaceTileProvider._clippingPlanes;
|
|
1788
|
+
if (defined(clippingPlanes) && defined(clippingPlanes.texture)) {
|
|
1789
|
+
// Check in case clippingPlanes hasn't been updated yet.
|
|
1790
|
+
return clippingPlanes.texture;
|
|
1791
|
+
}
|
|
1792
|
+
return frameState.context.defaultTexture;
|
|
1793
|
+
},
|
|
1794
|
+
u_cartographicLimitRectangle: function () {
|
|
1795
|
+
return this.properties.localizedCartographicLimitRectangle;
|
|
1796
|
+
},
|
|
1797
|
+
u_clippingPlanesMatrix: function () {
|
|
1798
|
+
const clippingPlanes = globeSurfaceTileProvider._clippingPlanes;
|
|
1799
|
+
const transform = defined(clippingPlanes)
|
|
1800
|
+
? Matrix4.multiply(
|
|
1801
|
+
frameState.context.uniformState.view,
|
|
1802
|
+
clippingPlanes.modelMatrix,
|
|
1803
|
+
scratchClippingPlanesMatrix,
|
|
1804
|
+
)
|
|
1805
|
+
: Matrix4.IDENTITY;
|
|
1806
|
+
|
|
1807
|
+
return Matrix4.inverseTranspose(
|
|
1808
|
+
transform,
|
|
1809
|
+
scratchInverseTransposeClippingPlanesMatrix,
|
|
1810
|
+
);
|
|
1811
|
+
},
|
|
1812
|
+
u_clippingPlanesEdgeStyle: function () {
|
|
1813
|
+
const style = this.properties.clippingPlanesEdgeColor;
|
|
1814
|
+
style.alpha = this.properties.clippingPlanesEdgeWidth;
|
|
1815
|
+
return style;
|
|
1816
|
+
},
|
|
1817
|
+
u_clippingDistance: function () {
|
|
1818
|
+
const texture =
|
|
1819
|
+
globeSurfaceTileProvider._clippingPolygons.clippingTexture;
|
|
1820
|
+
if (defined(texture)) {
|
|
1821
|
+
return texture;
|
|
1822
|
+
}
|
|
1823
|
+
return frameState.context.defaultTexture;
|
|
1824
|
+
},
|
|
1825
|
+
u_clippingExtents: function () {
|
|
1826
|
+
const texture = globeSurfaceTileProvider._clippingPolygons.extentsTexture;
|
|
1827
|
+
if (defined(texture)) {
|
|
1828
|
+
return texture;
|
|
1829
|
+
}
|
|
1830
|
+
return frameState.context.defaultTexture;
|
|
1831
|
+
},
|
|
1832
|
+
u_minimumBrightness: function () {
|
|
1833
|
+
return frameState.fog.minimumBrightness;
|
|
1834
|
+
},
|
|
1835
|
+
u_hsbShift: function () {
|
|
1836
|
+
return this.properties.hsbShift;
|
|
1837
|
+
},
|
|
1838
|
+
u_colorsToAlpha: function () {
|
|
1839
|
+
return this.properties.colorsToAlpha;
|
|
1840
|
+
},
|
|
1841
|
+
u_frontFaceAlphaByDistance: function () {
|
|
1842
|
+
return this.properties.frontFaceAlphaByDistance;
|
|
1843
|
+
},
|
|
1844
|
+
u_backFaceAlphaByDistance: function () {
|
|
1845
|
+
return this.properties.backFaceAlphaByDistance;
|
|
1846
|
+
},
|
|
1847
|
+
u_translucencyRectangle: function () {
|
|
1848
|
+
return this.properties.localizedTranslucencyRectangle;
|
|
1849
|
+
},
|
|
1850
|
+
u_undergroundColor: function () {
|
|
1851
|
+
return this.properties.undergroundColor;
|
|
1852
|
+
},
|
|
1853
|
+
u_undergroundColorAlphaByDistance: function () {
|
|
1854
|
+
return this.properties.undergroundColorAlphaByDistance;
|
|
1855
|
+
},
|
|
1856
|
+
u_lambertDiffuseMultiplier: function () {
|
|
1857
|
+
return this.properties.lambertDiffuseMultiplier;
|
|
1858
|
+
},
|
|
1859
|
+
u_vertexShadowDarkness: function () {
|
|
1860
|
+
return this.properties.vertexShadowDarkness;
|
|
1861
|
+
},
|
|
1862
|
+
|
|
1863
|
+
// make a separate object so that changes to the properties are seen on
|
|
1864
|
+
// derived commands that combine another uniform map with this one.
|
|
1865
|
+
properties: {
|
|
1866
|
+
initialColor: new Cartesian4(0.0, 0.0, 0.5, 1.0),
|
|
1867
|
+
fillHighlightColor: new Color(0.0, 0.0, 0.0, 0.0),
|
|
1868
|
+
zoomedOutOceanSpecularIntensity: 0.5,
|
|
1869
|
+
oceanNormalMap: undefined,
|
|
1870
|
+
lightingFadeDistance: new Cartesian2(6500000.0, 9000000.0),
|
|
1871
|
+
nightFadeDistance: new Cartesian2(10000000.0, 40000000.0),
|
|
1872
|
+
atmosphereLightIntensity: 10.0,
|
|
1873
|
+
atmosphereRayleighCoefficient: new Cartesian3(5.5e-6, 13.0e-6, 28.4e-6),
|
|
1874
|
+
atmosphereMieCoefficient: new Cartesian3(21e-6, 21e-6, 21e-6),
|
|
1875
|
+
atmosphereRayleighScaleHeight: 10000.0,
|
|
1876
|
+
atmosphereMieScaleHeight: 3200.0,
|
|
1877
|
+
atmosphereMieAnisotropy: 0.9,
|
|
1878
|
+
hsbShift: new Cartesian3(),
|
|
1879
|
+
|
|
1880
|
+
center3D: undefined,
|
|
1881
|
+
rtc: new Cartesian3(),
|
|
1882
|
+
modifiedModelView: new Matrix4(),
|
|
1883
|
+
tileRectangle: new Cartesian4(),
|
|
1884
|
+
|
|
1885
|
+
verticalExaggerationAndRelativeHeight: new Cartesian2(1.0, 0.0),
|
|
1886
|
+
|
|
1887
|
+
dayTextures: [],
|
|
1888
|
+
dayTextureTranslationAndScale: [],
|
|
1889
|
+
dayTextureTexCoordsRectangle: [],
|
|
1890
|
+
dayTextureUseWebMercatorT: [],
|
|
1891
|
+
dayTextureAlpha: [],
|
|
1892
|
+
dayTextureNightAlpha: [],
|
|
1893
|
+
dayTextureDayAlpha: [],
|
|
1894
|
+
dayTextureBrightness: [],
|
|
1895
|
+
dayTextureContrast: [],
|
|
1896
|
+
dayTextureHue: [],
|
|
1897
|
+
dayTextureSaturation: [],
|
|
1898
|
+
dayTextureOneOverGamma: [],
|
|
1899
|
+
dayTextureSplit: [],
|
|
1900
|
+
dayTextureCutoutRectangles: [],
|
|
1901
|
+
dayIntensity: 0.0,
|
|
1902
|
+
colorsToAlpha: [],
|
|
1903
|
+
|
|
1904
|
+
southAndNorthLatitude: new Cartesian2(),
|
|
1905
|
+
southMercatorYAndOneOverHeight: new Cartesian2(),
|
|
1906
|
+
|
|
1907
|
+
waterMask: undefined,
|
|
1908
|
+
waterMaskTranslationAndScale: new Cartesian4(),
|
|
1909
|
+
|
|
1910
|
+
minMaxHeight: new Cartesian2(),
|
|
1911
|
+
scaleAndBias: new Matrix4(),
|
|
1912
|
+
clippingPlanesEdgeColor: Color.clone(Color.WHITE),
|
|
1913
|
+
clippingPlanesEdgeWidth: 0.0,
|
|
1914
|
+
|
|
1915
|
+
localizedCartographicLimitRectangle: new Cartesian4(),
|
|
1916
|
+
|
|
1917
|
+
frontFaceAlphaByDistance: new Cartesian4(),
|
|
1918
|
+
backFaceAlphaByDistance: new Cartesian4(),
|
|
1919
|
+
localizedTranslucencyRectangle: new Cartesian4(),
|
|
1920
|
+
undergroundColor: Color.clone(Color.TRANSPARENT),
|
|
1921
|
+
undergroundColorAlphaByDistance: new Cartesian4(),
|
|
1922
|
+
lambertDiffuseMultiplier: 0.0,
|
|
1923
|
+
vertexShadowDarkness: 0.0,
|
|
1924
|
+
},
|
|
1925
|
+
};
|
|
1926
|
+
|
|
1927
|
+
if (defined(globeSurfaceTileProvider.materialUniformMap)) {
|
|
1928
|
+
return combine(uniformMap, globeSurfaceTileProvider.materialUniformMap);
|
|
1929
|
+
}
|
|
1930
|
+
|
|
1931
|
+
return uniformMap;
|
|
1932
|
+
}
|
|
1933
|
+
|
|
1934
|
+
function createWireframeVertexArrayIfNecessary(context, provider, tile) {
|
|
1935
|
+
const surfaceTile = tile.data;
|
|
1936
|
+
|
|
1937
|
+
let mesh;
|
|
1938
|
+
let vertexArray;
|
|
1939
|
+
|
|
1940
|
+
if (defined(surfaceTile.vertexArray)) {
|
|
1941
|
+
mesh = surfaceTile.mesh;
|
|
1942
|
+
vertexArray = surfaceTile.vertexArray;
|
|
1943
|
+
} else if (
|
|
1944
|
+
defined(surfaceTile.fill) &&
|
|
1945
|
+
defined(surfaceTile.fill.vertexArray)
|
|
1946
|
+
) {
|
|
1947
|
+
mesh = surfaceTile.fill.mesh;
|
|
1948
|
+
vertexArray = surfaceTile.fill.vertexArray;
|
|
1949
|
+
}
|
|
1950
|
+
|
|
1951
|
+
if (!defined(mesh) || !defined(vertexArray)) {
|
|
1952
|
+
return;
|
|
1953
|
+
}
|
|
1954
|
+
|
|
1955
|
+
if (defined(surfaceTile.wireframeVertexArray)) {
|
|
1956
|
+
if (surfaceTile.wireframeVertexArray.mesh === mesh) {
|
|
1957
|
+
return;
|
|
1958
|
+
}
|
|
1959
|
+
|
|
1960
|
+
surfaceTile.wireframeVertexArray.destroy();
|
|
1961
|
+
surfaceTile.wireframeVertexArray = undefined;
|
|
1962
|
+
}
|
|
1963
|
+
|
|
1964
|
+
surfaceTile.wireframeVertexArray = createWireframeVertexArray(
|
|
1965
|
+
context,
|
|
1966
|
+
vertexArray,
|
|
1967
|
+
mesh,
|
|
1968
|
+
);
|
|
1969
|
+
surfaceTile.wireframeVertexArray.mesh = mesh;
|
|
1970
|
+
}
|
|
1971
|
+
|
|
1972
|
+
/**
|
|
1973
|
+
* Creates a vertex array for wireframe rendering of a terrain tile.
|
|
1974
|
+
*
|
|
1975
|
+
* @private
|
|
1976
|
+
*
|
|
1977
|
+
* @param {Context} context The context in which to create the vertex array.
|
|
1978
|
+
* @param {VertexArray} vertexArray The existing, non-wireframe vertex array. The new vertex array
|
|
1979
|
+
* will share vertex buffers with this existing one.
|
|
1980
|
+
* @param {TerrainMesh} terrainMesh The terrain mesh containing non-wireframe indices.
|
|
1981
|
+
* @returns {VertexArray} The vertex array for wireframe rendering.
|
|
1982
|
+
*/
|
|
1983
|
+
function createWireframeVertexArray(context, vertexArray, terrainMesh) {
|
|
1984
|
+
const indices = terrainMesh.indices;
|
|
1985
|
+
|
|
1986
|
+
const geometry = {
|
|
1987
|
+
indices: indices,
|
|
1988
|
+
primitiveType: PrimitiveType.TRIANGLES,
|
|
1989
|
+
};
|
|
1990
|
+
|
|
1991
|
+
GeometryPipeline.toWireframe(geometry);
|
|
1992
|
+
|
|
1993
|
+
const wireframeIndices = geometry.indices;
|
|
1994
|
+
const wireframeIndexBuffer = Buffer.createIndexBuffer({
|
|
1995
|
+
context: context,
|
|
1996
|
+
typedArray: wireframeIndices,
|
|
1997
|
+
usage: BufferUsage.STATIC_DRAW,
|
|
1998
|
+
indexDatatype: IndexDatatype.fromSizeInBytes(
|
|
1999
|
+
wireframeIndices.BYTES_PER_ELEMENT,
|
|
2000
|
+
),
|
|
2001
|
+
});
|
|
2002
|
+
return new VertexArray({
|
|
2003
|
+
context: context,
|
|
2004
|
+
attributes: vertexArray._attributes,
|
|
2005
|
+
indexBuffer: wireframeIndexBuffer,
|
|
2006
|
+
});
|
|
2007
|
+
}
|
|
2008
|
+
|
|
2009
|
+
let getDebugOrientedBoundingBox;
|
|
2010
|
+
let getDebugBoundingSphere;
|
|
2011
|
+
let debugDestroyPrimitive;
|
|
2012
|
+
|
|
2013
|
+
(function () {
|
|
2014
|
+
const instanceOBB = new GeometryInstance({
|
|
2015
|
+
geometry: BoxOutlineGeometry.fromDimensions({
|
|
2016
|
+
dimensions: new Cartesian3(2.0, 2.0, 2.0),
|
|
2017
|
+
}),
|
|
2018
|
+
});
|
|
2019
|
+
const instanceSphere = new GeometryInstance({
|
|
2020
|
+
geometry: new SphereOutlineGeometry({ radius: 1.0 }),
|
|
2021
|
+
});
|
|
2022
|
+
let modelMatrix = new Matrix4();
|
|
2023
|
+
let previousVolume;
|
|
2024
|
+
let primitive;
|
|
2025
|
+
|
|
2026
|
+
function createDebugPrimitive(instance) {
|
|
2027
|
+
return new Primitive({
|
|
2028
|
+
geometryInstances: instance,
|
|
2029
|
+
appearance: new PerInstanceColorAppearance({
|
|
2030
|
+
translucent: false,
|
|
2031
|
+
flat: true,
|
|
2032
|
+
}),
|
|
2033
|
+
asynchronous: false,
|
|
2034
|
+
});
|
|
2035
|
+
}
|
|
2036
|
+
|
|
2037
|
+
getDebugOrientedBoundingBox = function (obb, color) {
|
|
2038
|
+
if (obb === previousVolume) {
|
|
2039
|
+
return primitive;
|
|
2040
|
+
}
|
|
2041
|
+
debugDestroyPrimitive();
|
|
2042
|
+
|
|
2043
|
+
previousVolume = obb;
|
|
2044
|
+
modelMatrix = Matrix4.fromRotationTranslation(
|
|
2045
|
+
obb.halfAxes,
|
|
2046
|
+
obb.center,
|
|
2047
|
+
modelMatrix,
|
|
2048
|
+
);
|
|
2049
|
+
|
|
2050
|
+
instanceOBB.modelMatrix = modelMatrix;
|
|
2051
|
+
instanceOBB.attributes.color =
|
|
2052
|
+
ColorGeometryInstanceAttribute.fromColor(color);
|
|
2053
|
+
|
|
2054
|
+
primitive = createDebugPrimitive(instanceOBB);
|
|
2055
|
+
return primitive;
|
|
2056
|
+
};
|
|
2057
|
+
|
|
2058
|
+
getDebugBoundingSphere = function (sphere, color) {
|
|
2059
|
+
if (sphere === previousVolume) {
|
|
2060
|
+
return primitive;
|
|
2061
|
+
}
|
|
2062
|
+
debugDestroyPrimitive();
|
|
2063
|
+
|
|
2064
|
+
previousVolume = sphere;
|
|
2065
|
+
modelMatrix = Matrix4.fromTranslation(sphere.center, modelMatrix);
|
|
2066
|
+
modelMatrix = Matrix4.multiplyByUniformScale(
|
|
2067
|
+
modelMatrix,
|
|
2068
|
+
sphere.radius,
|
|
2069
|
+
modelMatrix,
|
|
2070
|
+
);
|
|
2071
|
+
|
|
2072
|
+
instanceSphere.modelMatrix = modelMatrix;
|
|
2073
|
+
instanceSphere.attributes.color =
|
|
2074
|
+
ColorGeometryInstanceAttribute.fromColor(color);
|
|
2075
|
+
|
|
2076
|
+
primitive = createDebugPrimitive(instanceSphere);
|
|
2077
|
+
return primitive;
|
|
2078
|
+
};
|
|
2079
|
+
|
|
2080
|
+
debugDestroyPrimitive = function () {
|
|
2081
|
+
if (defined(primitive)) {
|
|
2082
|
+
primitive.destroy();
|
|
2083
|
+
primitive = undefined;
|
|
2084
|
+
previousVolume = undefined;
|
|
2085
|
+
}
|
|
2086
|
+
};
|
|
2087
|
+
})();
|
|
2088
|
+
|
|
2089
|
+
const otherPassesInitialColor = new Cartesian4(0.0, 0.0, 0.0, 0.0);
|
|
2090
|
+
const surfaceShaderSetOptionsScratch = {
|
|
2091
|
+
frameState: undefined,
|
|
2092
|
+
surfaceTile: undefined,
|
|
2093
|
+
numberOfDayTextures: undefined,
|
|
2094
|
+
applyBrightness: undefined,
|
|
2095
|
+
applyContrast: undefined,
|
|
2096
|
+
applyHue: undefined,
|
|
2097
|
+
applySaturation: undefined,
|
|
2098
|
+
applyGamma: undefined,
|
|
2099
|
+
applyAlpha: undefined,
|
|
2100
|
+
applyDayNightAlpha: undefined,
|
|
2101
|
+
applySplit: undefined,
|
|
2102
|
+
showReflectiveOcean: undefined,
|
|
2103
|
+
showOceanWaves: undefined,
|
|
2104
|
+
enableLighting: undefined,
|
|
2105
|
+
dynamicAtmosphereLighting: undefined,
|
|
2106
|
+
dynamicAtmosphereLightingFromSun: undefined,
|
|
2107
|
+
showGroundAtmosphere: undefined,
|
|
2108
|
+
perFragmentGroundAtmosphere: undefined,
|
|
2109
|
+
hasVertexNormals: undefined,
|
|
2110
|
+
useWebMercatorProjection: undefined,
|
|
2111
|
+
enableFog: undefined,
|
|
2112
|
+
enableClippingPlanes: undefined,
|
|
2113
|
+
clippingPlanes: undefined,
|
|
2114
|
+
enableClippingPolygons: undefined,
|
|
2115
|
+
clippingPolygons: undefined,
|
|
2116
|
+
clippedByBoundaries: undefined,
|
|
2117
|
+
hasImageryLayerCutout: undefined,
|
|
2118
|
+
colorCorrect: undefined,
|
|
2119
|
+
colorToAlpha: undefined,
|
|
2120
|
+
hasGeodeticSurfaceNormals: undefined,
|
|
2121
|
+
hasExaggeration: undefined,
|
|
2122
|
+
};
|
|
2123
|
+
|
|
2124
|
+
const defaultUndergroundColor = Color.TRANSPARENT;
|
|
2125
|
+
const defaultUndergroundColorAlphaByDistance = new NearFarScalar();
|
|
2126
|
+
|
|
2127
|
+
function addDrawCommandsForTile(tileProvider, tile, frameState) {
|
|
2128
|
+
const surfaceTile = tile.data;
|
|
2129
|
+
|
|
2130
|
+
if (!defined(surfaceTile.vertexArray)) {
|
|
2131
|
+
if (surfaceTile.fill === undefined) {
|
|
2132
|
+
// No fill was created for this tile, probably because this tile is not connected to
|
|
2133
|
+
// any renderable tiles. So create a simple tile in the middle of the tile's possible
|
|
2134
|
+
// height range.
|
|
2135
|
+
surfaceTile.fill = new TerrainFillMesh(tile);
|
|
2136
|
+
}
|
|
2137
|
+
surfaceTile.fill.update(tileProvider, frameState);
|
|
2138
|
+
}
|
|
2139
|
+
|
|
2140
|
+
const creditDisplay = frameState.creditDisplay;
|
|
2141
|
+
|
|
2142
|
+
const terrainData = surfaceTile.terrainData;
|
|
2143
|
+
if (defined(terrainData) && defined(terrainData.credits)) {
|
|
2144
|
+
const tileCredits = terrainData.credits;
|
|
2145
|
+
for (
|
|
2146
|
+
let tileCreditIndex = 0, tileCreditLength = tileCredits.length;
|
|
2147
|
+
tileCreditIndex < tileCreditLength;
|
|
2148
|
+
++tileCreditIndex
|
|
2149
|
+
) {
|
|
2150
|
+
creditDisplay.addCreditToNextFrame(tileCredits[tileCreditIndex]);
|
|
2151
|
+
}
|
|
2152
|
+
}
|
|
2153
|
+
|
|
2154
|
+
let maxTextures = ContextLimits.maximumTextureImageUnits;
|
|
2155
|
+
|
|
2156
|
+
let waterMaskTexture = surfaceTile.waterMaskTexture;
|
|
2157
|
+
let waterMaskTranslationAndScale = surfaceTile.waterMaskTranslationAndScale;
|
|
2158
|
+
if (!defined(waterMaskTexture) && defined(surfaceTile.fill)) {
|
|
2159
|
+
waterMaskTexture = surfaceTile.fill.waterMaskTexture;
|
|
2160
|
+
waterMaskTranslationAndScale =
|
|
2161
|
+
surfaceTile.fill.waterMaskTranslationAndScale;
|
|
2162
|
+
}
|
|
2163
|
+
|
|
2164
|
+
const cameraUnderground = frameState.cameraUnderground;
|
|
2165
|
+
|
|
2166
|
+
const globeTranslucencyState = frameState.globeTranslucencyState;
|
|
2167
|
+
const translucent = globeTranslucencyState.translucent;
|
|
2168
|
+
const frontFaceAlphaByDistance =
|
|
2169
|
+
globeTranslucencyState.frontFaceAlphaByDistance;
|
|
2170
|
+
const backFaceAlphaByDistance =
|
|
2171
|
+
globeTranslucencyState.backFaceAlphaByDistance;
|
|
2172
|
+
const translucencyRectangle = globeTranslucencyState.rectangle;
|
|
2173
|
+
|
|
2174
|
+
const undergroundColor =
|
|
2175
|
+
tileProvider.undergroundColor ?? defaultUndergroundColor;
|
|
2176
|
+
const undergroundColorAlphaByDistance =
|
|
2177
|
+
tileProvider.undergroundColorAlphaByDistance ??
|
|
2178
|
+
defaultUndergroundColorAlphaByDistance;
|
|
2179
|
+
const showUndergroundColor =
|
|
2180
|
+
isUndergroundVisible(tileProvider, frameState) &&
|
|
2181
|
+
frameState.mode === SceneMode.SCENE3D &&
|
|
2182
|
+
undergroundColor.alpha > 0.0 &&
|
|
2183
|
+
(undergroundColorAlphaByDistance.nearValue > 0.0 ||
|
|
2184
|
+
undergroundColorAlphaByDistance.farValue > 0.0);
|
|
2185
|
+
|
|
2186
|
+
const lambertDiffuseMultiplier = tileProvider.lambertDiffuseMultiplier;
|
|
2187
|
+
const vertexShadowDarkness = tileProvider.vertexShadowDarkness;
|
|
2188
|
+
|
|
2189
|
+
const hasWaterMask = tileProvider.hasWaterMask && defined(waterMaskTexture);
|
|
2190
|
+
const showReflectiveOcean = hasWaterMask && tileProvider.showWaterEffect;
|
|
2191
|
+
const oceanNormalMap = tileProvider.oceanNormalMap;
|
|
2192
|
+
const showOceanWaves = showReflectiveOcean && defined(oceanNormalMap);
|
|
2193
|
+
const terrainProvider = tileProvider.terrainProvider;
|
|
2194
|
+
const hasVertexNormals =
|
|
2195
|
+
defined(terrainProvider) && tileProvider.terrainProvider.hasVertexNormals;
|
|
2196
|
+
const enableFog =
|
|
2197
|
+
frameState.fog.enabled && frameState.fog.renderable && !cameraUnderground;
|
|
2198
|
+
const showGroundAtmosphere =
|
|
2199
|
+
tileProvider.showGroundAtmosphere && frameState.mode === SceneMode.SCENE3D;
|
|
2200
|
+
const castShadows =
|
|
2201
|
+
ShadowMode.castShadows(tileProvider.shadows) && !translucent;
|
|
2202
|
+
const receiveShadows =
|
|
2203
|
+
ShadowMode.receiveShadows(tileProvider.shadows) && !translucent;
|
|
2204
|
+
|
|
2205
|
+
const hueShift = tileProvider.hueShift;
|
|
2206
|
+
const saturationShift = tileProvider.saturationShift;
|
|
2207
|
+
const brightnessShift = tileProvider.brightnessShift;
|
|
2208
|
+
|
|
2209
|
+
let colorCorrect = !(
|
|
2210
|
+
CesiumMath.equalsEpsilon(hueShift, 0.0, CesiumMath.EPSILON7) &&
|
|
2211
|
+
CesiumMath.equalsEpsilon(saturationShift, 0.0, CesiumMath.EPSILON7) &&
|
|
2212
|
+
CesiumMath.equalsEpsilon(brightnessShift, 0.0, CesiumMath.EPSILON7)
|
|
2213
|
+
);
|
|
2214
|
+
|
|
2215
|
+
let perFragmentGroundAtmosphere = false;
|
|
2216
|
+
if (showGroundAtmosphere) {
|
|
2217
|
+
const cameraDistance = Cartesian3.magnitude(frameState.camera.positionWC);
|
|
2218
|
+
const fadeOutDistance = tileProvider.nightFadeOutDistance;
|
|
2219
|
+
perFragmentGroundAtmosphere = cameraDistance > fadeOutDistance;
|
|
2220
|
+
}
|
|
2221
|
+
|
|
2222
|
+
if (hasWaterMask) {
|
|
2223
|
+
--maxTextures;
|
|
2224
|
+
}
|
|
2225
|
+
if (showOceanWaves) {
|
|
2226
|
+
--maxTextures;
|
|
2227
|
+
}
|
|
2228
|
+
if (
|
|
2229
|
+
defined(frameState.shadowState) &&
|
|
2230
|
+
frameState.shadowState.shadowsEnabled
|
|
2231
|
+
) {
|
|
2232
|
+
--maxTextures;
|
|
2233
|
+
}
|
|
2234
|
+
if (
|
|
2235
|
+
defined(tileProvider.clippingPlanes) &&
|
|
2236
|
+
tileProvider.clippingPlanes.enabled
|
|
2237
|
+
) {
|
|
2238
|
+
--maxTextures;
|
|
2239
|
+
}
|
|
2240
|
+
if (
|
|
2241
|
+
defined(tileProvider.clippingPolygons) &&
|
|
2242
|
+
tileProvider.clippingPolygons.enabled
|
|
2243
|
+
) {
|
|
2244
|
+
--maxTextures;
|
|
2245
|
+
--maxTextures;
|
|
2246
|
+
}
|
|
2247
|
+
|
|
2248
|
+
maxTextures -= globeTranslucencyState.numberOfTextureUniforms;
|
|
2249
|
+
|
|
2250
|
+
const mesh = surfaceTile.renderedMesh;
|
|
2251
|
+
let rtc = mesh.center;
|
|
2252
|
+
const encoding = mesh.encoding;
|
|
2253
|
+
const tileBoundingRegion = surfaceTile.tileBoundingRegion;
|
|
2254
|
+
|
|
2255
|
+
const exaggeration = frameState.verticalExaggeration;
|
|
2256
|
+
const exaggerationRelativeHeight =
|
|
2257
|
+
frameState.verticalExaggerationRelativeHeight;
|
|
2258
|
+
const hasExaggeration = exaggeration !== 1.0;
|
|
2259
|
+
const hasGeodeticSurfaceNormals = encoding.hasGeodeticSurfaceNormals;
|
|
2260
|
+
|
|
2261
|
+
// Not used in 3D.
|
|
2262
|
+
const tileRectangle = tileRectangleScratch;
|
|
2263
|
+
|
|
2264
|
+
// Only used for Mercator projections.
|
|
2265
|
+
let southLatitude = 0.0;
|
|
2266
|
+
let northLatitude = 0.0;
|
|
2267
|
+
let southMercatorY = 0.0;
|
|
2268
|
+
let oneOverMercatorHeight = 0.0;
|
|
2269
|
+
|
|
2270
|
+
let useWebMercatorProjection = false;
|
|
2271
|
+
|
|
2272
|
+
if (frameState.mode !== SceneMode.SCENE3D) {
|
|
2273
|
+
const projection = frameState.mapProjection;
|
|
2274
|
+
const southwest = projection.project(
|
|
2275
|
+
Rectangle.southwest(tile.rectangle),
|
|
2276
|
+
southwestScratch,
|
|
2277
|
+
);
|
|
2278
|
+
const northeast = projection.project(
|
|
2279
|
+
Rectangle.northeast(tile.rectangle),
|
|
2280
|
+
northeastScratch,
|
|
2281
|
+
);
|
|
2282
|
+
|
|
2283
|
+
tileRectangle.x = southwest.x;
|
|
2284
|
+
tileRectangle.y = southwest.y;
|
|
2285
|
+
tileRectangle.z = northeast.x;
|
|
2286
|
+
tileRectangle.w = northeast.y;
|
|
2287
|
+
|
|
2288
|
+
// In 2D and Columbus View, use the center of the tile for RTC rendering.
|
|
2289
|
+
if (frameState.mode !== SceneMode.MORPHING) {
|
|
2290
|
+
rtc = rtcScratch;
|
|
2291
|
+
rtc.x = 0.0;
|
|
2292
|
+
rtc.y = (tileRectangle.z + tileRectangle.x) * 0.5;
|
|
2293
|
+
rtc.z = (tileRectangle.w + tileRectangle.y) * 0.5;
|
|
2294
|
+
tileRectangle.x -= rtc.y;
|
|
2295
|
+
tileRectangle.y -= rtc.z;
|
|
2296
|
+
tileRectangle.z -= rtc.y;
|
|
2297
|
+
tileRectangle.w -= rtc.z;
|
|
2298
|
+
}
|
|
2299
|
+
|
|
2300
|
+
if (
|
|
2301
|
+
frameState.mode === SceneMode.SCENE2D &&
|
|
2302
|
+
encoding.quantization === TerrainQuantization.BITS12
|
|
2303
|
+
) {
|
|
2304
|
+
// In 2D, the texture coordinates of the tile are interpolated over the rectangle to get the position in the vertex shader.
|
|
2305
|
+
// When the texture coordinates are quantized, error is introduced. This can be seen through the 1px wide cracking
|
|
2306
|
+
// between the quantized tiles in 2D. To compensate for the error, move the expand the rectangle in each direction by
|
|
2307
|
+
// half the error amount.
|
|
2308
|
+
const epsilon = (1.0 / (Math.pow(2.0, 12.0) - 1.0)) * 0.5;
|
|
2309
|
+
const widthEpsilon = (tileRectangle.z - tileRectangle.x) * epsilon;
|
|
2310
|
+
const heightEpsilon = (tileRectangle.w - tileRectangle.y) * epsilon;
|
|
2311
|
+
tileRectangle.x -= widthEpsilon;
|
|
2312
|
+
tileRectangle.y -= heightEpsilon;
|
|
2313
|
+
tileRectangle.z += widthEpsilon;
|
|
2314
|
+
tileRectangle.w += heightEpsilon;
|
|
2315
|
+
}
|
|
2316
|
+
|
|
2317
|
+
if (projection instanceof WebMercatorProjection) {
|
|
2318
|
+
southLatitude = tile.rectangle.south;
|
|
2319
|
+
northLatitude = tile.rectangle.north;
|
|
2320
|
+
|
|
2321
|
+
southMercatorY =
|
|
2322
|
+
WebMercatorProjection.geodeticLatitudeToMercatorAngle(southLatitude);
|
|
2323
|
+
|
|
2324
|
+
oneOverMercatorHeight =
|
|
2325
|
+
1.0 /
|
|
2326
|
+
(WebMercatorProjection.geodeticLatitudeToMercatorAngle(northLatitude) -
|
|
2327
|
+
southMercatorY);
|
|
2328
|
+
|
|
2329
|
+
useWebMercatorProjection = true;
|
|
2330
|
+
}
|
|
2331
|
+
}
|
|
2332
|
+
|
|
2333
|
+
const surfaceShaderSetOptions = surfaceShaderSetOptionsScratch;
|
|
2334
|
+
surfaceShaderSetOptions.frameState = frameState;
|
|
2335
|
+
surfaceShaderSetOptions.surfaceTile = surfaceTile;
|
|
2336
|
+
surfaceShaderSetOptions.hasWaterMask = hasWaterMask;
|
|
2337
|
+
surfaceShaderSetOptions.showReflectiveOcean = showReflectiveOcean;
|
|
2338
|
+
surfaceShaderSetOptions.showOceanWaves = showOceanWaves;
|
|
2339
|
+
surfaceShaderSetOptions.enableLighting = tileProvider.enableLighting;
|
|
2340
|
+
surfaceShaderSetOptions.dynamicAtmosphereLighting =
|
|
2341
|
+
tileProvider.dynamicAtmosphereLighting;
|
|
2342
|
+
surfaceShaderSetOptions.dynamicAtmosphereLightingFromSun =
|
|
2343
|
+
tileProvider.dynamicAtmosphereLightingFromSun;
|
|
2344
|
+
surfaceShaderSetOptions.showGroundAtmosphere = showGroundAtmosphere;
|
|
2345
|
+
surfaceShaderSetOptions.atmosphereLightIntensity =
|
|
2346
|
+
tileProvider.atmosphereLightIntensity;
|
|
2347
|
+
surfaceShaderSetOptions.atmosphereRayleighCoefficient =
|
|
2348
|
+
tileProvider.atmosphereRayleighCoefficient;
|
|
2349
|
+
surfaceShaderSetOptions.atmosphereMieCoefficient =
|
|
2350
|
+
tileProvider.atmosphereMieCoefficient;
|
|
2351
|
+
surfaceShaderSetOptions.atmosphereRayleighScaleHeight =
|
|
2352
|
+
tileProvider.atmosphereRayleighScaleHeight;
|
|
2353
|
+
surfaceShaderSetOptions.atmosphereMieScaleHeight =
|
|
2354
|
+
tileProvider.atmosphereMieScaleHeight;
|
|
2355
|
+
surfaceShaderSetOptions.atmosphereMieAnisotropy =
|
|
2356
|
+
tileProvider.atmosphereMieAnisotropy;
|
|
2357
|
+
surfaceShaderSetOptions.perFragmentGroundAtmosphere =
|
|
2358
|
+
perFragmentGroundAtmosphere;
|
|
2359
|
+
surfaceShaderSetOptions.hasVertexNormals = hasVertexNormals;
|
|
2360
|
+
surfaceShaderSetOptions.useWebMercatorProjection = useWebMercatorProjection;
|
|
2361
|
+
surfaceShaderSetOptions.clippedByBoundaries = surfaceTile.clippedByBoundaries;
|
|
2362
|
+
surfaceShaderSetOptions.hasGeodeticSurfaceNormals = hasGeodeticSurfaceNormals;
|
|
2363
|
+
surfaceShaderSetOptions.hasExaggeration = hasExaggeration;
|
|
2364
|
+
|
|
2365
|
+
const tileImageryCollection = surfaceTile.imagery;
|
|
2366
|
+
let imageryIndex = 0;
|
|
2367
|
+
const imageryLen = tileImageryCollection.length;
|
|
2368
|
+
|
|
2369
|
+
const showSkirts =
|
|
2370
|
+
tileProvider.showSkirts && !cameraUnderground && !translucent;
|
|
2371
|
+
const backFaceCulling =
|
|
2372
|
+
tileProvider.backFaceCulling && !cameraUnderground && !translucent;
|
|
2373
|
+
const firstPassRenderState = backFaceCulling
|
|
2374
|
+
? tileProvider._renderState
|
|
2375
|
+
: tileProvider._disableCullingRenderState;
|
|
2376
|
+
const otherPassesRenderState = backFaceCulling
|
|
2377
|
+
? tileProvider._blendRenderState
|
|
2378
|
+
: tileProvider._disableCullingBlendRenderState;
|
|
2379
|
+
let renderState = firstPassRenderState;
|
|
2380
|
+
|
|
2381
|
+
let initialColor = tileProvider._firstPassInitialColor;
|
|
2382
|
+
|
|
2383
|
+
const context = frameState.context;
|
|
2384
|
+
|
|
2385
|
+
if (!defined(tileProvider._debug.boundingSphereTile)) {
|
|
2386
|
+
debugDestroyPrimitive();
|
|
2387
|
+
}
|
|
2388
|
+
|
|
2389
|
+
const materialUniformMapChanged =
|
|
2390
|
+
tileProvider._materialUniformMap !== tileProvider.materialUniformMap;
|
|
2391
|
+
if (materialUniformMapChanged) {
|
|
2392
|
+
tileProvider._materialUniformMap = tileProvider.materialUniformMap;
|
|
2393
|
+
const drawCommandsLength = tileProvider._drawCommands.length;
|
|
2394
|
+
for (let i = 0; i < drawCommandsLength; ++i) {
|
|
2395
|
+
tileProvider._uniformMaps[i] = createTileUniformMap(
|
|
2396
|
+
frameState,
|
|
2397
|
+
tileProvider,
|
|
2398
|
+
);
|
|
2399
|
+
}
|
|
2400
|
+
}
|
|
2401
|
+
|
|
2402
|
+
do {
|
|
2403
|
+
let numberOfDayTextures = 0;
|
|
2404
|
+
|
|
2405
|
+
let command;
|
|
2406
|
+
let uniformMap;
|
|
2407
|
+
|
|
2408
|
+
if (tileProvider._drawCommands.length <= tileProvider._usedDrawCommands) {
|
|
2409
|
+
command = new DrawCommand();
|
|
2410
|
+
command.owner = tile;
|
|
2411
|
+
command.cull = false;
|
|
2412
|
+
command.boundingVolume = new BoundingSphere();
|
|
2413
|
+
command.orientedBoundingBox = undefined;
|
|
2414
|
+
|
|
2415
|
+
uniformMap = createTileUniformMap(frameState, tileProvider);
|
|
2416
|
+
|
|
2417
|
+
tileProvider._drawCommands.push(command);
|
|
2418
|
+
tileProvider._uniformMaps.push(uniformMap);
|
|
2419
|
+
} else {
|
|
2420
|
+
command = tileProvider._drawCommands[tileProvider._usedDrawCommands];
|
|
2421
|
+
uniformMap = tileProvider._uniformMaps[tileProvider._usedDrawCommands];
|
|
2422
|
+
}
|
|
2423
|
+
|
|
2424
|
+
command.owner = tile;
|
|
2425
|
+
|
|
2426
|
+
++tileProvider._usedDrawCommands;
|
|
2427
|
+
|
|
2428
|
+
if (tile === tileProvider._debug.boundingSphereTile) {
|
|
2429
|
+
const obb = tileBoundingRegion.boundingVolume;
|
|
2430
|
+
const boundingSphere = tileBoundingRegion.boundingSphere;
|
|
2431
|
+
// If a debug primitive already exists for this tile, it will not be
|
|
2432
|
+
// re-created, to avoid allocation every frame. If it were possible
|
|
2433
|
+
// to have more than one selected tile, this would have to change.
|
|
2434
|
+
if (defined(obb)) {
|
|
2435
|
+
getDebugOrientedBoundingBox(obb, Color.RED).update(frameState);
|
|
2436
|
+
} else if (defined(boundingSphere)) {
|
|
2437
|
+
getDebugBoundingSphere(boundingSphere, Color.RED).update(frameState);
|
|
2438
|
+
}
|
|
2439
|
+
}
|
|
2440
|
+
|
|
2441
|
+
const uniformMapProperties = uniformMap.properties;
|
|
2442
|
+
Cartesian4.clone(initialColor, uniformMapProperties.initialColor);
|
|
2443
|
+
uniformMapProperties.oceanNormalMap = oceanNormalMap;
|
|
2444
|
+
uniformMapProperties.lightingFadeDistance.x =
|
|
2445
|
+
tileProvider.lightingFadeOutDistance;
|
|
2446
|
+
uniformMapProperties.lightingFadeDistance.y =
|
|
2447
|
+
tileProvider.lightingFadeInDistance;
|
|
2448
|
+
uniformMapProperties.nightFadeDistance.x =
|
|
2449
|
+
tileProvider.nightFadeOutDistance;
|
|
2450
|
+
uniformMapProperties.nightFadeDistance.y = tileProvider.nightFadeInDistance;
|
|
2451
|
+
uniformMapProperties.atmosphereLightIntensity =
|
|
2452
|
+
tileProvider.atmosphereLightIntensity;
|
|
2453
|
+
uniformMapProperties.atmosphereRayleighCoefficient =
|
|
2454
|
+
tileProvider.atmosphereRayleighCoefficient;
|
|
2455
|
+
uniformMapProperties.atmosphereMieCoefficient =
|
|
2456
|
+
tileProvider.atmosphereMieCoefficient;
|
|
2457
|
+
uniformMapProperties.atmosphereRayleighScaleHeight =
|
|
2458
|
+
tileProvider.atmosphereRayleighScaleHeight;
|
|
2459
|
+
uniformMapProperties.atmosphereMieScaleHeight =
|
|
2460
|
+
tileProvider.atmosphereMieScaleHeight;
|
|
2461
|
+
uniformMapProperties.atmosphereMieAnisotropy =
|
|
2462
|
+
tileProvider.atmosphereMieAnisotropy;
|
|
2463
|
+
uniformMapProperties.zoomedOutOceanSpecularIntensity =
|
|
2464
|
+
tileProvider.zoomedOutOceanSpecularIntensity;
|
|
2465
|
+
|
|
2466
|
+
const frontFaceAlphaByDistanceFinal = cameraUnderground
|
|
2467
|
+
? backFaceAlphaByDistance
|
|
2468
|
+
: frontFaceAlphaByDistance;
|
|
2469
|
+
const backFaceAlphaByDistanceFinal = cameraUnderground
|
|
2470
|
+
? frontFaceAlphaByDistance
|
|
2471
|
+
: backFaceAlphaByDistance;
|
|
2472
|
+
|
|
2473
|
+
if (defined(frontFaceAlphaByDistanceFinal)) {
|
|
2474
|
+
Cartesian4.fromElements(
|
|
2475
|
+
frontFaceAlphaByDistanceFinal.near,
|
|
2476
|
+
frontFaceAlphaByDistanceFinal.nearValue,
|
|
2477
|
+
frontFaceAlphaByDistanceFinal.far,
|
|
2478
|
+
frontFaceAlphaByDistanceFinal.farValue,
|
|
2479
|
+
uniformMapProperties.frontFaceAlphaByDistance,
|
|
2480
|
+
);
|
|
2481
|
+
Cartesian4.fromElements(
|
|
2482
|
+
backFaceAlphaByDistanceFinal.near,
|
|
2483
|
+
backFaceAlphaByDistanceFinal.nearValue,
|
|
2484
|
+
backFaceAlphaByDistanceFinal.far,
|
|
2485
|
+
backFaceAlphaByDistanceFinal.farValue,
|
|
2486
|
+
uniformMapProperties.backFaceAlphaByDistance,
|
|
2487
|
+
);
|
|
2488
|
+
}
|
|
2489
|
+
|
|
2490
|
+
Cartesian4.fromElements(
|
|
2491
|
+
undergroundColorAlphaByDistance.near,
|
|
2492
|
+
undergroundColorAlphaByDistance.nearValue,
|
|
2493
|
+
undergroundColorAlphaByDistance.far,
|
|
2494
|
+
undergroundColorAlphaByDistance.farValue,
|
|
2495
|
+
uniformMapProperties.undergroundColorAlphaByDistance,
|
|
2496
|
+
);
|
|
2497
|
+
Color.clone(undergroundColor, uniformMapProperties.undergroundColor);
|
|
2498
|
+
|
|
2499
|
+
uniformMapProperties.lambertDiffuseMultiplier = lambertDiffuseMultiplier;
|
|
2500
|
+
uniformMapProperties.vertexShadowDarkness = vertexShadowDarkness;
|
|
2501
|
+
|
|
2502
|
+
const highlightFillTile =
|
|
2503
|
+
!defined(surfaceTile.vertexArray) &&
|
|
2504
|
+
defined(tileProvider.fillHighlightColor) &&
|
|
2505
|
+
tileProvider.fillHighlightColor.alpha > 0.0;
|
|
2506
|
+
if (highlightFillTile) {
|
|
2507
|
+
Color.clone(
|
|
2508
|
+
tileProvider.fillHighlightColor,
|
|
2509
|
+
uniformMapProperties.fillHighlightColor,
|
|
2510
|
+
);
|
|
2511
|
+
}
|
|
2512
|
+
|
|
2513
|
+
uniformMapProperties.verticalExaggerationAndRelativeHeight.x = exaggeration;
|
|
2514
|
+
uniformMapProperties.verticalExaggerationAndRelativeHeight.y =
|
|
2515
|
+
exaggerationRelativeHeight;
|
|
2516
|
+
|
|
2517
|
+
uniformMapProperties.center3D = mesh.center;
|
|
2518
|
+
Cartesian3.clone(rtc, uniformMapProperties.rtc);
|
|
2519
|
+
|
|
2520
|
+
Cartesian4.clone(tileRectangle, uniformMapProperties.tileRectangle);
|
|
2521
|
+
uniformMapProperties.southAndNorthLatitude.x = southLatitude;
|
|
2522
|
+
uniformMapProperties.southAndNorthLatitude.y = northLatitude;
|
|
2523
|
+
uniformMapProperties.southMercatorYAndOneOverHeight.x = southMercatorY;
|
|
2524
|
+
uniformMapProperties.southMercatorYAndOneOverHeight.y =
|
|
2525
|
+
oneOverMercatorHeight;
|
|
2526
|
+
|
|
2527
|
+
// Convert tile limiter rectangle from cartographic to texture space using the tileRectangle.
|
|
2528
|
+
const localizedCartographicLimitRectangle =
|
|
2529
|
+
localizedCartographicLimitRectangleScratch;
|
|
2530
|
+
const cartographicLimitRectangle = clipRectangleAntimeridian(
|
|
2531
|
+
tile.rectangle,
|
|
2532
|
+
tileProvider.cartographicLimitRectangle,
|
|
2533
|
+
);
|
|
2534
|
+
|
|
2535
|
+
const localizedTranslucencyRectangle =
|
|
2536
|
+
localizedTranslucencyRectangleScratch;
|
|
2537
|
+
const clippedTranslucencyRectangle = clipRectangleAntimeridian(
|
|
2538
|
+
tile.rectangle,
|
|
2539
|
+
translucencyRectangle,
|
|
2540
|
+
);
|
|
2541
|
+
|
|
2542
|
+
Cartesian3.fromElements(
|
|
2543
|
+
hueShift,
|
|
2544
|
+
saturationShift,
|
|
2545
|
+
brightnessShift,
|
|
2546
|
+
uniformMapProperties.hsbShift,
|
|
2547
|
+
);
|
|
2548
|
+
|
|
2549
|
+
const cartographicTileRectangle = tile.rectangle;
|
|
2550
|
+
const inverseTileWidth = 1.0 / cartographicTileRectangle.width;
|
|
2551
|
+
const inverseTileHeight = 1.0 / cartographicTileRectangle.height;
|
|
2552
|
+
localizedCartographicLimitRectangle.x =
|
|
2553
|
+
(cartographicLimitRectangle.west - cartographicTileRectangle.west) *
|
|
2554
|
+
inverseTileWidth;
|
|
2555
|
+
localizedCartographicLimitRectangle.y =
|
|
2556
|
+
(cartographicLimitRectangle.south - cartographicTileRectangle.south) *
|
|
2557
|
+
inverseTileHeight;
|
|
2558
|
+
localizedCartographicLimitRectangle.z =
|
|
2559
|
+
(cartographicLimitRectangle.east - cartographicTileRectangle.west) *
|
|
2560
|
+
inverseTileWidth;
|
|
2561
|
+
localizedCartographicLimitRectangle.w =
|
|
2562
|
+
(cartographicLimitRectangle.north - cartographicTileRectangle.south) *
|
|
2563
|
+
inverseTileHeight;
|
|
2564
|
+
|
|
2565
|
+
Cartesian4.clone(
|
|
2566
|
+
localizedCartographicLimitRectangle,
|
|
2567
|
+
uniformMapProperties.localizedCartographicLimitRectangle,
|
|
2568
|
+
);
|
|
2569
|
+
|
|
2570
|
+
localizedTranslucencyRectangle.x =
|
|
2571
|
+
(clippedTranslucencyRectangle.west - cartographicTileRectangle.west) *
|
|
2572
|
+
inverseTileWidth;
|
|
2573
|
+
localizedTranslucencyRectangle.y =
|
|
2574
|
+
(clippedTranslucencyRectangle.south - cartographicTileRectangle.south) *
|
|
2575
|
+
inverseTileHeight;
|
|
2576
|
+
localizedTranslucencyRectangle.z =
|
|
2577
|
+
(clippedTranslucencyRectangle.east - cartographicTileRectangle.west) *
|
|
2578
|
+
inverseTileWidth;
|
|
2579
|
+
localizedTranslucencyRectangle.w =
|
|
2580
|
+
(clippedTranslucencyRectangle.north - cartographicTileRectangle.south) *
|
|
2581
|
+
inverseTileHeight;
|
|
2582
|
+
|
|
2583
|
+
Cartesian4.clone(
|
|
2584
|
+
localizedTranslucencyRectangle,
|
|
2585
|
+
uniformMapProperties.localizedTranslucencyRectangle,
|
|
2586
|
+
);
|
|
2587
|
+
|
|
2588
|
+
// For performance, render fog only when fog is enabled and the effect of
|
|
2589
|
+
// fog would be non-negligible. This prevents the shader from running when
|
|
2590
|
+
// the camera is in space, for example.
|
|
2591
|
+
const applyFog =
|
|
2592
|
+
enableFog &&
|
|
2593
|
+
CesiumMath.fog(tile._distance, frameState.fog.density) >
|
|
2594
|
+
CesiumMath.EPSILON3;
|
|
2595
|
+
colorCorrect = colorCorrect && (applyFog || showGroundAtmosphere);
|
|
2596
|
+
|
|
2597
|
+
let applyBrightness = false;
|
|
2598
|
+
let applyContrast = false;
|
|
2599
|
+
let applyHue = false;
|
|
2600
|
+
let applySaturation = false;
|
|
2601
|
+
let applyGamma = false;
|
|
2602
|
+
let applyAlpha = false;
|
|
2603
|
+
let applyDayNightAlpha = false;
|
|
2604
|
+
let applySplit = false;
|
|
2605
|
+
let applyCutout = false;
|
|
2606
|
+
let applyColorToAlpha = false;
|
|
2607
|
+
|
|
2608
|
+
while (numberOfDayTextures < maxTextures && imageryIndex < imageryLen) {
|
|
2609
|
+
const tileImagery = tileImageryCollection[imageryIndex];
|
|
2610
|
+
const imagery = tileImagery.readyImagery;
|
|
2611
|
+
++imageryIndex;
|
|
2612
|
+
|
|
2613
|
+
if (!defined(imagery) || imagery.imageryLayer.alpha === 0.0) {
|
|
2614
|
+
continue;
|
|
2615
|
+
}
|
|
2616
|
+
|
|
2617
|
+
const texture = tileImagery.useWebMercatorT
|
|
2618
|
+
? imagery.textureWebMercator
|
|
2619
|
+
: imagery.texture;
|
|
2620
|
+
|
|
2621
|
+
//>>includeStart('debug', pragmas.debug);
|
|
2622
|
+
if (!defined(texture)) {
|
|
2623
|
+
// Our "ready" texture isn't actually ready. This should never happen.
|
|
2624
|
+
//
|
|
2625
|
+
// Side note: It IS possible for it to not be in the READY ImageryState, though.
|
|
2626
|
+
// This can happen when a single imagery tile is shared by two terrain tiles (common)
|
|
2627
|
+
// and one of them (A) needs a geographic version of the tile because it is near the poles,
|
|
2628
|
+
// and the other (B) does not. B can and will transition the imagery tile to the READY state
|
|
2629
|
+
// without reprojecting to geographic. Then, later, A will deem that same tile not-ready-yet
|
|
2630
|
+
// because it only has the Web Mercator texture, and flip it back to the TRANSITIONING state.
|
|
2631
|
+
// The imagery tile won't be in the READY state anymore, but it's still READY enough for B's
|
|
2632
|
+
// purposes.
|
|
2633
|
+
throw new DeveloperError("readyImagery is not actually ready!");
|
|
2634
|
+
}
|
|
2635
|
+
//>>includeEnd('debug');
|
|
2636
|
+
|
|
2637
|
+
const imageryLayer = imagery.imageryLayer;
|
|
2638
|
+
|
|
2639
|
+
if (!defined(tileImagery.textureTranslationAndScale)) {
|
|
2640
|
+
tileImagery.textureTranslationAndScale =
|
|
2641
|
+
imageryLayer._calculateTextureTranslationAndScale(tile, tileImagery);
|
|
2642
|
+
}
|
|
2643
|
+
|
|
2644
|
+
uniformMapProperties.dayTextures[numberOfDayTextures] = texture;
|
|
2645
|
+
uniformMapProperties.dayTextureTranslationAndScale[numberOfDayTextures] =
|
|
2646
|
+
tileImagery.textureTranslationAndScale;
|
|
2647
|
+
uniformMapProperties.dayTextureTexCoordsRectangle[numberOfDayTextures] =
|
|
2648
|
+
tileImagery.textureCoordinateRectangle;
|
|
2649
|
+
uniformMapProperties.dayTextureUseWebMercatorT[numberOfDayTextures] =
|
|
2650
|
+
tileImagery.useWebMercatorT;
|
|
2651
|
+
|
|
2652
|
+
uniformMapProperties.dayTextureAlpha[numberOfDayTextures] =
|
|
2653
|
+
imageryLayer.alpha;
|
|
2654
|
+
applyAlpha =
|
|
2655
|
+
applyAlpha ||
|
|
2656
|
+
uniformMapProperties.dayTextureAlpha[numberOfDayTextures] !== 1.0;
|
|
2657
|
+
|
|
2658
|
+
uniformMapProperties.dayTextureNightAlpha[numberOfDayTextures] =
|
|
2659
|
+
imageryLayer.nightAlpha;
|
|
2660
|
+
applyDayNightAlpha =
|
|
2661
|
+
applyDayNightAlpha ||
|
|
2662
|
+
uniformMapProperties.dayTextureNightAlpha[numberOfDayTextures] !== 1.0;
|
|
2663
|
+
|
|
2664
|
+
uniformMapProperties.dayTextureDayAlpha[numberOfDayTextures] =
|
|
2665
|
+
imageryLayer.dayAlpha;
|
|
2666
|
+
applyDayNightAlpha =
|
|
2667
|
+
applyDayNightAlpha ||
|
|
2668
|
+
uniformMapProperties.dayTextureDayAlpha[numberOfDayTextures] !== 1.0;
|
|
2669
|
+
|
|
2670
|
+
uniformMapProperties.dayTextureBrightness[numberOfDayTextures] =
|
|
2671
|
+
imageryLayer.brightness;
|
|
2672
|
+
applyBrightness =
|
|
2673
|
+
applyBrightness ||
|
|
2674
|
+
uniformMapProperties.dayTextureBrightness[numberOfDayTextures] !==
|
|
2675
|
+
ImageryLayer.DEFAULT_BRIGHTNESS;
|
|
2676
|
+
|
|
2677
|
+
uniformMapProperties.dayTextureContrast[numberOfDayTextures] =
|
|
2678
|
+
imageryLayer.contrast;
|
|
2679
|
+
applyContrast =
|
|
2680
|
+
applyContrast ||
|
|
2681
|
+
uniformMapProperties.dayTextureContrast[numberOfDayTextures] !==
|
|
2682
|
+
ImageryLayer.DEFAULT_CONTRAST;
|
|
2683
|
+
|
|
2684
|
+
uniformMapProperties.dayTextureHue[numberOfDayTextures] =
|
|
2685
|
+
imageryLayer.hue;
|
|
2686
|
+
applyHue =
|
|
2687
|
+
applyHue ||
|
|
2688
|
+
uniformMapProperties.dayTextureHue[numberOfDayTextures] !==
|
|
2689
|
+
ImageryLayer.DEFAULT_HUE;
|
|
2690
|
+
|
|
2691
|
+
uniformMapProperties.dayTextureSaturation[numberOfDayTextures] =
|
|
2692
|
+
imageryLayer.saturation;
|
|
2693
|
+
applySaturation =
|
|
2694
|
+
applySaturation ||
|
|
2695
|
+
uniformMapProperties.dayTextureSaturation[numberOfDayTextures] !==
|
|
2696
|
+
ImageryLayer.DEFAULT_SATURATION;
|
|
2697
|
+
|
|
2698
|
+
uniformMapProperties.dayTextureOneOverGamma[numberOfDayTextures] =
|
|
2699
|
+
1.0 / imageryLayer.gamma;
|
|
2700
|
+
applyGamma =
|
|
2701
|
+
applyGamma ||
|
|
2702
|
+
uniformMapProperties.dayTextureOneOverGamma[numberOfDayTextures] !==
|
|
2703
|
+
1.0 / ImageryLayer.DEFAULT_GAMMA;
|
|
2704
|
+
|
|
2705
|
+
uniformMapProperties.dayTextureSplit[numberOfDayTextures] =
|
|
2706
|
+
imageryLayer.splitDirection;
|
|
2707
|
+
applySplit =
|
|
2708
|
+
applySplit ||
|
|
2709
|
+
uniformMapProperties.dayTextureSplit[numberOfDayTextures] !== 0.0;
|
|
2710
|
+
|
|
2711
|
+
// Update cutout rectangle
|
|
2712
|
+
let dayTextureCutoutRectangle =
|
|
2713
|
+
uniformMapProperties.dayTextureCutoutRectangles[numberOfDayTextures];
|
|
2714
|
+
if (!defined(dayTextureCutoutRectangle)) {
|
|
2715
|
+
dayTextureCutoutRectangle =
|
|
2716
|
+
uniformMapProperties.dayTextureCutoutRectangles[numberOfDayTextures] =
|
|
2717
|
+
new Cartesian4();
|
|
2718
|
+
}
|
|
2719
|
+
|
|
2720
|
+
Cartesian4.clone(Cartesian4.ZERO, dayTextureCutoutRectangle);
|
|
2721
|
+
if (defined(imageryLayer.cutoutRectangle)) {
|
|
2722
|
+
const cutoutRectangle = clipRectangleAntimeridian(
|
|
2723
|
+
cartographicTileRectangle,
|
|
2724
|
+
imageryLayer.cutoutRectangle,
|
|
2725
|
+
);
|
|
2726
|
+
const intersection = Rectangle.simpleIntersection(
|
|
2727
|
+
cutoutRectangle,
|
|
2728
|
+
cartographicTileRectangle,
|
|
2729
|
+
rectangleIntersectionScratch,
|
|
2730
|
+
);
|
|
2731
|
+
applyCutout = defined(intersection) || applyCutout;
|
|
2732
|
+
|
|
2733
|
+
dayTextureCutoutRectangle.x =
|
|
2734
|
+
(cutoutRectangle.west - cartographicTileRectangle.west) *
|
|
2735
|
+
inverseTileWidth;
|
|
2736
|
+
dayTextureCutoutRectangle.y =
|
|
2737
|
+
(cutoutRectangle.south - cartographicTileRectangle.south) *
|
|
2738
|
+
inverseTileHeight;
|
|
2739
|
+
dayTextureCutoutRectangle.z =
|
|
2740
|
+
(cutoutRectangle.east - cartographicTileRectangle.west) *
|
|
2741
|
+
inverseTileWidth;
|
|
2742
|
+
dayTextureCutoutRectangle.w =
|
|
2743
|
+
(cutoutRectangle.north - cartographicTileRectangle.south) *
|
|
2744
|
+
inverseTileHeight;
|
|
2745
|
+
}
|
|
2746
|
+
|
|
2747
|
+
// Update color to alpha
|
|
2748
|
+
let colorToAlpha =
|
|
2749
|
+
uniformMapProperties.colorsToAlpha[numberOfDayTextures];
|
|
2750
|
+
if (!defined(colorToAlpha)) {
|
|
2751
|
+
colorToAlpha = uniformMapProperties.colorsToAlpha[numberOfDayTextures] =
|
|
2752
|
+
new Cartesian4();
|
|
2753
|
+
}
|
|
2754
|
+
|
|
2755
|
+
const hasColorToAlpha =
|
|
2756
|
+
defined(imageryLayer.colorToAlpha) &&
|
|
2757
|
+
imageryLayer.colorToAlphaThreshold > 0.0;
|
|
2758
|
+
applyColorToAlpha = applyColorToAlpha || hasColorToAlpha;
|
|
2759
|
+
|
|
2760
|
+
if (hasColorToAlpha) {
|
|
2761
|
+
const color = imageryLayer.colorToAlpha;
|
|
2762
|
+
colorToAlpha.x = color.red;
|
|
2763
|
+
colorToAlpha.y = color.green;
|
|
2764
|
+
colorToAlpha.z = color.blue;
|
|
2765
|
+
colorToAlpha.w = imageryLayer.colorToAlphaThreshold;
|
|
2766
|
+
} else {
|
|
2767
|
+
colorToAlpha.w = -1.0;
|
|
2768
|
+
}
|
|
2769
|
+
|
|
2770
|
+
if (defined(imagery.credits)) {
|
|
2771
|
+
const credits = imagery.credits;
|
|
2772
|
+
for (
|
|
2773
|
+
let creditIndex = 0, creditLength = credits.length;
|
|
2774
|
+
creditIndex < creditLength;
|
|
2775
|
+
++creditIndex
|
|
2776
|
+
) {
|
|
2777
|
+
creditDisplay.addCreditToNextFrame(credits[creditIndex]);
|
|
2778
|
+
}
|
|
2779
|
+
}
|
|
2780
|
+
|
|
2781
|
+
++numberOfDayTextures;
|
|
2782
|
+
}
|
|
2783
|
+
|
|
2784
|
+
// trim texture array to the used length so we don't end up using old textures
|
|
2785
|
+
// which might get destroyed eventually
|
|
2786
|
+
uniformMapProperties.dayTextures.length = numberOfDayTextures;
|
|
2787
|
+
uniformMapProperties.waterMask = waterMaskTexture;
|
|
2788
|
+
Cartesian4.clone(
|
|
2789
|
+
waterMaskTranslationAndScale,
|
|
2790
|
+
uniformMapProperties.waterMaskTranslationAndScale,
|
|
2791
|
+
);
|
|
2792
|
+
|
|
2793
|
+
uniformMapProperties.minMaxHeight.x = encoding.minimumHeight;
|
|
2794
|
+
uniformMapProperties.minMaxHeight.y = encoding.maximumHeight;
|
|
2795
|
+
Matrix4.clone(encoding.matrix, uniformMapProperties.scaleAndBias);
|
|
2796
|
+
|
|
2797
|
+
// update clipping planes
|
|
2798
|
+
const clippingPlanes = tileProvider._clippingPlanes;
|
|
2799
|
+
const clippingPlanesEnabled =
|
|
2800
|
+
defined(clippingPlanes) && clippingPlanes.enabled && tile.isClipped;
|
|
2801
|
+
if (clippingPlanesEnabled) {
|
|
2802
|
+
uniformMapProperties.clippingPlanesEdgeColor = Color.clone(
|
|
2803
|
+
clippingPlanes.edgeColor,
|
|
2804
|
+
uniformMapProperties.clippingPlanesEdgeColor,
|
|
2805
|
+
);
|
|
2806
|
+
uniformMapProperties.clippingPlanesEdgeWidth = clippingPlanes.edgeWidth;
|
|
2807
|
+
}
|
|
2808
|
+
|
|
2809
|
+
// update clipping polygons
|
|
2810
|
+
const clippingPolygons = tileProvider._clippingPolygons;
|
|
2811
|
+
const clippingPolygonsEnabled =
|
|
2812
|
+
defined(clippingPolygons) && clippingPolygons.enabled && tile.isClipped;
|
|
2813
|
+
|
|
2814
|
+
surfaceShaderSetOptions.numberOfDayTextures = numberOfDayTextures;
|
|
2815
|
+
surfaceShaderSetOptions.applyBrightness = applyBrightness;
|
|
2816
|
+
surfaceShaderSetOptions.applyContrast = applyContrast;
|
|
2817
|
+
surfaceShaderSetOptions.applyHue = applyHue;
|
|
2818
|
+
surfaceShaderSetOptions.applySaturation = applySaturation;
|
|
2819
|
+
surfaceShaderSetOptions.applyGamma = applyGamma;
|
|
2820
|
+
surfaceShaderSetOptions.applyAlpha = applyAlpha;
|
|
2821
|
+
surfaceShaderSetOptions.applyDayNightAlpha = applyDayNightAlpha;
|
|
2822
|
+
surfaceShaderSetOptions.applySplit = applySplit;
|
|
2823
|
+
surfaceShaderSetOptions.enableFog = applyFog;
|
|
2824
|
+
surfaceShaderSetOptions.enableClippingPlanes = clippingPlanesEnabled;
|
|
2825
|
+
surfaceShaderSetOptions.clippingPlanes = clippingPlanes;
|
|
2826
|
+
surfaceShaderSetOptions.enableClippingPolygons = clippingPolygonsEnabled;
|
|
2827
|
+
surfaceShaderSetOptions.clippingPolygons = clippingPolygons;
|
|
2828
|
+
surfaceShaderSetOptions.hasImageryLayerCutout = applyCutout;
|
|
2829
|
+
surfaceShaderSetOptions.colorCorrect = colorCorrect;
|
|
2830
|
+
surfaceShaderSetOptions.highlightFillTile = highlightFillTile;
|
|
2831
|
+
surfaceShaderSetOptions.colorToAlpha = applyColorToAlpha;
|
|
2832
|
+
surfaceShaderSetOptions.showUndergroundColor = showUndergroundColor;
|
|
2833
|
+
surfaceShaderSetOptions.translucent = translucent;
|
|
2834
|
+
|
|
2835
|
+
let count = surfaceTile.renderedMesh.indices.length;
|
|
2836
|
+
if (!showSkirts) {
|
|
2837
|
+
count = surfaceTile.renderedMesh.indexCountWithoutSkirts;
|
|
2838
|
+
}
|
|
2839
|
+
|
|
2840
|
+
command.shaderProgram = tileProvider._surfaceShaderSet.getShaderProgram(
|
|
2841
|
+
surfaceShaderSetOptions,
|
|
2842
|
+
);
|
|
2843
|
+
command.castShadows = castShadows;
|
|
2844
|
+
command.receiveShadows = receiveShadows;
|
|
2845
|
+
command.renderState = renderState;
|
|
2846
|
+
command.primitiveType = PrimitiveType.TRIANGLES;
|
|
2847
|
+
command.vertexArray =
|
|
2848
|
+
surfaceTile.vertexArray || surfaceTile.fill.vertexArray;
|
|
2849
|
+
command.count = count;
|
|
2850
|
+
command.uniformMap = uniformMap;
|
|
2851
|
+
command.pass = Pass.GLOBE;
|
|
2852
|
+
|
|
2853
|
+
if (tileProvider._debug.wireframe) {
|
|
2854
|
+
createWireframeVertexArrayIfNecessary(context, tileProvider, tile);
|
|
2855
|
+
if (defined(surfaceTile.wireframeVertexArray)) {
|
|
2856
|
+
command.vertexArray = surfaceTile.wireframeVertexArray;
|
|
2857
|
+
command.primitiveType = PrimitiveType.LINES;
|
|
2858
|
+
command.count = count * 2;
|
|
2859
|
+
}
|
|
2860
|
+
}
|
|
2861
|
+
|
|
2862
|
+
let boundingVolume = command.boundingVolume;
|
|
2863
|
+
const orientedBoundingBox = command.orientedBoundingBox;
|
|
2864
|
+
|
|
2865
|
+
if (frameState.mode !== SceneMode.SCENE3D) {
|
|
2866
|
+
BoundingSphere.fromRectangleWithHeights2D(
|
|
2867
|
+
tile.rectangle,
|
|
2868
|
+
frameState.mapProjection,
|
|
2869
|
+
tileBoundingRegion.minimumHeight,
|
|
2870
|
+
tileBoundingRegion.maximumHeight,
|
|
2871
|
+
boundingVolume,
|
|
2872
|
+
);
|
|
2873
|
+
Cartesian3.fromElements(
|
|
2874
|
+
boundingVolume.center.z,
|
|
2875
|
+
boundingVolume.center.x,
|
|
2876
|
+
boundingVolume.center.y,
|
|
2877
|
+
boundingVolume.center,
|
|
2878
|
+
);
|
|
2879
|
+
|
|
2880
|
+
if (frameState.mode === SceneMode.MORPHING) {
|
|
2881
|
+
boundingVolume = BoundingSphere.union(
|
|
2882
|
+
tileBoundingRegion.boundingSphere,
|
|
2883
|
+
boundingVolume,
|
|
2884
|
+
boundingVolume,
|
|
2885
|
+
);
|
|
2886
|
+
}
|
|
2887
|
+
} else {
|
|
2888
|
+
command.boundingVolume = BoundingSphere.clone(
|
|
2889
|
+
tileBoundingRegion.boundingSphere,
|
|
2890
|
+
boundingVolume,
|
|
2891
|
+
);
|
|
2892
|
+
command.orientedBoundingBox = OrientedBoundingBox.clone(
|
|
2893
|
+
tileBoundingRegion.boundingVolume,
|
|
2894
|
+
orientedBoundingBox,
|
|
2895
|
+
);
|
|
2896
|
+
}
|
|
2897
|
+
|
|
2898
|
+
command.dirty = true;
|
|
2899
|
+
|
|
2900
|
+
if (translucent) {
|
|
2901
|
+
globeTranslucencyState.updateDerivedCommands(command, frameState);
|
|
2902
|
+
}
|
|
2903
|
+
|
|
2904
|
+
pushCommand(command, frameState);
|
|
2905
|
+
|
|
2906
|
+
renderState = otherPassesRenderState;
|
|
2907
|
+
initialColor = otherPassesInitialColor;
|
|
2908
|
+
} while (imageryIndex < imageryLen);
|
|
2909
|
+
}
|
|
2910
|
+
export default GlobeSurfaceTileProvider;
|