org.outernet.cesium-unity 1.15.3-linux.1

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.
Files changed (315) hide show
  1. package/CHANGES.md +420 -0
  2. package/CHANGES.md.meta +7 -0
  3. package/Editor/BuildCesiumForUnity.cs +186 -0
  4. package/Editor/BuildCesiumForUnity.cs.meta +11 -0
  5. package/Editor/Cesium3DTilesetEditor.cs +542 -0
  6. package/Editor/Cesium3DTilesetEditor.cs.meta +11 -0
  7. package/Editor/CesiumBingMapsRasterOverlayEditor.cs +66 -0
  8. package/Editor/CesiumBingMapsRasterOverlayEditor.cs.meta +11 -0
  9. package/Editor/CesiumCameraControllerEditor.cs +174 -0
  10. package/Editor/CesiumCameraControllerEditor.cs.meta +11 -0
  11. package/Editor/CesiumCameraManagerEditor.cs +65 -0
  12. package/Editor/CesiumCameraManagerEditor.cs.meta +11 -0
  13. package/Editor/CesiumCartographicPolygonEditor.cs +23 -0
  14. package/Editor/CesiumCartographicPolygonEditor.cs.meta +11 -0
  15. package/Editor/CesiumDebugColorizeTilesRasterOverlayEditor.cs +41 -0
  16. package/Editor/CesiumDebugColorizeTilesRasterOverlayEditor.cs.meta +11 -0
  17. package/Editor/CesiumEditor.asmdef +26 -0
  18. package/Editor/CesiumEditor.asmdef.meta +7 -0
  19. package/Editor/CesiumEditorStyle.cs +188 -0
  20. package/Editor/CesiumEditorStyle.cs.meta +11 -0
  21. package/Editor/CesiumEditorUtility.cs +394 -0
  22. package/Editor/CesiumEditorUtility.cs.meta +11 -0
  23. package/Editor/CesiumEditorWindow.cs +447 -0
  24. package/Editor/CesiumEditorWindow.cs.meta +11 -0
  25. package/Editor/CesiumFlyToControllerEditor.cs +76 -0
  26. package/Editor/CesiumFlyToControllerEditor.cs.meta +11 -0
  27. package/Editor/CesiumGeoreferenceEditor.cs +277 -0
  28. package/Editor/CesiumGeoreferenceEditor.cs.meta +11 -0
  29. package/Editor/CesiumGlobeAnchorEditor.cs +202 -0
  30. package/Editor/CesiumGlobeAnchorEditor.cs.meta +11 -0
  31. package/Editor/CesiumInspectorGUI.cs +187 -0
  32. package/Editor/CesiumInspectorGUI.cs.meta +11 -0
  33. package/Editor/CesiumIonAsset.cs +192 -0
  34. package/Editor/CesiumIonAsset.cs.meta +11 -0
  35. package/Editor/CesiumIonAssetsWindow.cs +257 -0
  36. package/Editor/CesiumIonAssetsWindow.cs.meta +11 -0
  37. package/Editor/CesiumIonRasterOverlayEditor.cs +87 -0
  38. package/Editor/CesiumIonRasterOverlayEditor.cs.meta +11 -0
  39. package/Editor/CesiumIonServerManager.cs +153 -0
  40. package/Editor/CesiumIonServerManager.cs.meta +11 -0
  41. package/Editor/CesiumIonServerSelector.cs +127 -0
  42. package/Editor/CesiumIonServerSelector.cs.meta +11 -0
  43. package/Editor/CesiumIonSession.cs +102 -0
  44. package/Editor/CesiumIonSession.cs.meta +11 -0
  45. package/Editor/CesiumPolygonRasterOverlayEditor.cs +102 -0
  46. package/Editor/CesiumPolygonRasterOverlayEditor.cs.meta +11 -0
  47. package/Editor/CesiumRasterOverlayEditor.cs +230 -0
  48. package/Editor/CesiumRasterOverlayEditor.cs.meta +11 -0
  49. package/Editor/CesiumSubSceneEditor.cs +201 -0
  50. package/Editor/CesiumSubSceneEditor.cs.meta +11 -0
  51. package/Editor/CesiumTileMapServiceRasterOverlayEditor.cs +88 -0
  52. package/Editor/CesiumTileMapServiceRasterOverlayEditor.cs.meta +11 -0
  53. package/Editor/CesiumWebMapServiceRasterOverlayEditor.cs +111 -0
  54. package/Editor/CesiumWebMapServiceRasterOverlayEditor.cs.meta +11 -0
  55. package/Editor/CesiumWebMapTileServiceRasterOverlayEditor.cs +277 -0
  56. package/Editor/CesiumWebMapTileServiceRasterOverlayEditor.cs.meta +3 -0
  57. package/Editor/CompileCesiumForUnityNative.cs +581 -0
  58. package/Editor/CompileCesiumForUnityNative.cs.meta +11 -0
  59. package/Editor/ConfigureReinterop.cs +255 -0
  60. package/Editor/ConfigureReinterop.cs.meta +11 -0
  61. package/Editor/Helpers.cs +102 -0
  62. package/Editor/Helpers.cs.meta +11 -0
  63. package/Editor/IonAssetsMultiColumnHeader.cs +45 -0
  64. package/Editor/IonAssetsMultiColumnHeader.cs.meta +11 -0
  65. package/Editor/IonAssetsTreeView.cs +214 -0
  66. package/Editor/IonAssetsTreeView.cs.meta +11 -0
  67. package/Editor/IonMissingAssetWindow.cs +65 -0
  68. package/Editor/IonMissingAssetWindow.cs.meta +11 -0
  69. package/Editor/IonTokenTroubleshootingWindow.cs +615 -0
  70. package/Editor/IonTokenTroubleshootingWindow.cs.meta +11 -0
  71. package/Editor/NativeDownloadHandler.cs +35 -0
  72. package/Editor/NativeDownloadHandler.cs.meta +11 -0
  73. package/Editor/QuickAddItem.cs +43 -0
  74. package/Editor/QuickAddItem.cs.meta +11 -0
  75. package/Editor/Resources/Cesium-128x128.png +0 -0
  76. package/Editor/Resources/Cesium-128x128.png.meta +98 -0
  77. package/Editor/Resources/Cesium-24x24.png +0 -0
  78. package/Editor/Resources/Cesium-24x24.png.meta +123 -0
  79. package/Editor/Resources/Cesium-64x64.png +0 -0
  80. package/Editor/Resources/Cesium-64x64.png.meta +98 -0
  81. package/Editor/Resources/Cesium-for-Unity-dark.png +0 -0
  82. package/Editor/Resources/Cesium-for-Unity-dark.png.meta +123 -0
  83. package/Editor/Resources/Cesium-for-Unity-light.png +0 -0
  84. package/Editor/Resources/Cesium-for-Unity-light.png.meta +123 -0
  85. package/Editor/Resources/Cesium-icon-16x16.png +0 -0
  86. package/Editor/Resources/Cesium-icon-16x16.png.meta +98 -0
  87. package/Editor/Resources/FontAwesome/attribution.txt +9 -0
  88. package/Editor/Resources/FontAwesome/attribution.txt.meta +7 -0
  89. package/Editor/Resources/FontAwesome/book-reader-solid.png +0 -0
  90. package/Editor/Resources/FontAwesome/book-reader-solid.png.meta +98 -0
  91. package/Editor/Resources/FontAwesome/book-reader-solid.svg +1 -0
  92. package/Editor/Resources/FontAwesome/book-reader-solid.svg.meta +7 -0
  93. package/Editor/Resources/FontAwesome/check-solid.png +0 -0
  94. package/Editor/Resources/FontAwesome/check-solid.png.meta +98 -0
  95. package/Editor/Resources/FontAwesome/check-solid.svg +1 -0
  96. package/Editor/Resources/FontAwesome/check-solid.svg.meta +7 -0
  97. package/Editor/Resources/FontAwesome/cloud-upload-alt-solid.png +0 -0
  98. package/Editor/Resources/FontAwesome/cloud-upload-alt-solid.png.meta +98 -0
  99. package/Editor/Resources/FontAwesome/cloud-upload-alt-solid.svg +1 -0
  100. package/Editor/Resources/FontAwesome/cloud-upload-alt-solid.svg.meta +7 -0
  101. package/Editor/Resources/FontAwesome/folder.png +0 -0
  102. package/Editor/Resources/FontAwesome/folder.png.meta +147 -0
  103. package/Editor/Resources/FontAwesome/folder.svg +5 -0
  104. package/Editor/Resources/FontAwesome/folder.svg.meta +7 -0
  105. package/Editor/Resources/FontAwesome/hands-helping-solid.png +0 -0
  106. package/Editor/Resources/FontAwesome/hands-helping-solid.png.meta +98 -0
  107. package/Editor/Resources/FontAwesome/hands-helping-solid.svg +1 -0
  108. package/Editor/Resources/FontAwesome/hands-helping-solid.svg.meta +7 -0
  109. package/Editor/Resources/FontAwesome/key-solid.png +0 -0
  110. package/Editor/Resources/FontAwesome/key-solid.png.meta +98 -0
  111. package/Editor/Resources/FontAwesome/key-solid.svg +1 -0
  112. package/Editor/Resources/FontAwesome/key-solid.svg.meta +7 -0
  113. package/Editor/Resources/FontAwesome/plus-solid.png +0 -0
  114. package/Editor/Resources/FontAwesome/plus-solid.png.meta +98 -0
  115. package/Editor/Resources/FontAwesome/plus-solid.svg +1 -0
  116. package/Editor/Resources/FontAwesome/plus-solid.svg.meta +7 -0
  117. package/Editor/Resources/FontAwesome/sign-out-alt-solid.png +0 -0
  118. package/Editor/Resources/FontAwesome/sign-out-alt-solid.png.meta +98 -0
  119. package/Editor/Resources/FontAwesome/sign-out-alt-solid.svg +1 -0
  120. package/Editor/Resources/FontAwesome/sign-out-alt-solid.svg.meta +7 -0
  121. package/Editor/Resources/FontAwesome/sync-alt-solid.png +0 -0
  122. package/Editor/Resources/FontAwesome/sync-alt-solid.png.meta +98 -0
  123. package/Editor/Resources/FontAwesome/sync-alt-solid.svg +1 -0
  124. package/Editor/Resources/FontAwesome/sync-alt-solid.svg.meta +7 -0
  125. package/Editor/Resources/FontAwesome/times-solid.png +0 -0
  126. package/Editor/Resources/FontAwesome/times-solid.png.meta +98 -0
  127. package/Editor/Resources/FontAwesome/times-solid.svg +1 -0
  128. package/Editor/Resources/FontAwesome/times-solid.svg.meta +7 -0
  129. package/Editor/Resources/FontAwesome.meta +8 -0
  130. package/Editor/Resources.meta +8 -0
  131. package/Editor/SelectIonTokenWindow.cs +249 -0
  132. package/Editor/SelectIonTokenWindow.cs.meta +11 -0
  133. package/Editor/arm64.meta +8 -0
  134. package/Editor/csc.rsp +1 -0
  135. package/Editor/csc.rsp.meta +7 -0
  136. package/Editor/libCesiumForUnityNative-Editor.so +0 -0
  137. package/Editor/libCesiumForUnityNative-Editor.so.meta +2 -0
  138. package/Editor/libCesiumForUnityNative-Runtime.so +0 -0
  139. package/Editor/libCesiumForUnityNative-Runtime.so.meta +2 -0
  140. package/Editor/x86_64.meta +8 -0
  141. package/Editor.meta +8 -0
  142. package/LICENSE +201 -0
  143. package/LICENSE.meta +7 -0
  144. package/Plugins/Standalone/libCesiumForUnityNative-Runtime.so +0 -0
  145. package/Plugins/Standalone/libCesiumForUnityNative-Runtime.so.meta +2 -0
  146. package/Plugins/Standalone.meta +8 -0
  147. package/Plugins.meta +8 -0
  148. package/README.md +39 -0
  149. package/README.md.meta +7 -0
  150. package/Reinterop.deps.json +172 -0
  151. package/Reinterop.deps.json.meta +7 -0
  152. package/Reinterop.dll +0 -0
  153. package/Reinterop.dll.meta +79 -0
  154. package/Runtime/Cesium3DTile.cs +37 -0
  155. package/Runtime/Cesium3DTile.cs.meta +11 -0
  156. package/Runtime/Cesium3DTileset.cs +788 -0
  157. package/Runtime/Cesium3DTileset.cs.meta +11 -0
  158. package/Runtime/Cesium3DTilesetLoadFailureDetails.cs +65 -0
  159. package/Runtime/Cesium3DTilesetLoadFailureDetails.cs.meta +11 -0
  160. package/Runtime/CesiumBackwardCompatibility.cs +163 -0
  161. package/Runtime/CesiumBackwardCompatibility.cs.meta +11 -0
  162. package/Runtime/CesiumBingMapsRasterOverlay.cs +72 -0
  163. package/Runtime/CesiumBingMapsRasterOverlay.cs.meta +11 -0
  164. package/Runtime/CesiumCameraController.cs +827 -0
  165. package/Runtime/CesiumCameraController.cs.meta +11 -0
  166. package/Runtime/CesiumCameraManager.cs +105 -0
  167. package/Runtime/CesiumCameraManager.cs.meta +11 -0
  168. package/Runtime/CesiumCartographicPolygon.cs +152 -0
  169. package/Runtime/CesiumCartographicPolygon.cs.meta +11 -0
  170. package/Runtime/CesiumCreditSystem.cs +343 -0
  171. package/Runtime/CesiumCreditSystem.cs.meta +11 -0
  172. package/Runtime/CesiumCreditSystemUI.cs +402 -0
  173. package/Runtime/CesiumCreditSystemUI.cs.meta +11 -0
  174. package/Runtime/CesiumDebugColorizeTilesRasterOverlay.cs +21 -0
  175. package/Runtime/CesiumDebugColorizeTilesRasterOverlay.cs.meta +11 -0
  176. package/Runtime/CesiumEllipsoid.cs +107 -0
  177. package/Runtime/CesiumEllipsoid.cs.meta +11 -0
  178. package/Runtime/CesiumFeature.cs +279 -0
  179. package/Runtime/CesiumFeature.cs.meta +11 -0
  180. package/Runtime/CesiumFeatureIdAttribute.cs +61 -0
  181. package/Runtime/CesiumFeatureIdAttribute.cs.meta +11 -0
  182. package/Runtime/CesiumFeatureIdSet.cs +165 -0
  183. package/Runtime/CesiumFeatureIdSet.cs.meta +11 -0
  184. package/Runtime/CesiumFeatureIdTexture.cs +68 -0
  185. package/Runtime/CesiumFeatureIdTexture.cs.meta +11 -0
  186. package/Runtime/CesiumFlyToController.cs +539 -0
  187. package/Runtime/CesiumFlyToController.cs.meta +11 -0
  188. package/Runtime/CesiumGeoreference.cs +628 -0
  189. package/Runtime/CesiumGeoreference.cs.meta +11 -0
  190. package/Runtime/CesiumGlobeAnchor.cs +664 -0
  191. package/Runtime/CesiumGlobeAnchor.cs.meta +11 -0
  192. package/Runtime/CesiumGlobeAnchorBackwardCompatibility0dot2dot0.cs +105 -0
  193. package/Runtime/CesiumGlobeAnchorBackwardCompatibility0dot2dot0.cs.meta +11 -0
  194. package/Runtime/CesiumIntMatN.cs +398 -0
  195. package/Runtime/CesiumIntMatN.cs.meta +11 -0
  196. package/Runtime/CesiumIntVecN.cs +525 -0
  197. package/Runtime/CesiumIntVecN.cs.meta +11 -0
  198. package/Runtime/CesiumIonRasterOverlay.cs +110 -0
  199. package/Runtime/CesiumIonRasterOverlay.cs.meta +11 -0
  200. package/Runtime/CesiumIonServer.cs +137 -0
  201. package/Runtime/CesiumIonServer.cs.meta +11 -0
  202. package/Runtime/CesiumMetadata.cs +33 -0
  203. package/Runtime/CesiumMetadata.cs.meta +11 -0
  204. package/Runtime/CesiumMetadataValue.cs +1764 -0
  205. package/Runtime/CesiumMetadataValue.cs.meta +11 -0
  206. package/Runtime/CesiumMetadataValueType.cs +203 -0
  207. package/Runtime/CesiumMetadataValueType.cs.meta +11 -0
  208. package/Runtime/CesiumModelMetadata.cs +26 -0
  209. package/Runtime/CesiumModelMetadata.cs.meta +11 -0
  210. package/Runtime/CesiumObjectPool.cs +74 -0
  211. package/Runtime/CesiumObjectPool.cs.meta +11 -0
  212. package/Runtime/CesiumObjectPools.cs +39 -0
  213. package/Runtime/CesiumObjectPools.cs.meta +11 -0
  214. package/Runtime/CesiumOriginShift.cs +146 -0
  215. package/Runtime/CesiumOriginShift.cs.meta +11 -0
  216. package/Runtime/CesiumPointCloudRenderer.cs +246 -0
  217. package/Runtime/CesiumPointCloudRenderer.cs.meta +11 -0
  218. package/Runtime/CesiumPointCloudShading.cs +76 -0
  219. package/Runtime/CesiumPointCloudShading.cs.meta +11 -0
  220. package/Runtime/CesiumPolygonRasterOverlay.cs +109 -0
  221. package/Runtime/CesiumPolygonRasterOverlay.cs.meta +11 -0
  222. package/Runtime/CesiumPrimitiveFeatures.cs +130 -0
  223. package/Runtime/CesiumPrimitiveFeatures.cs.meta +11 -0
  224. package/Runtime/CesiumPropertyArray.cs +64 -0
  225. package/Runtime/CesiumPropertyArray.cs.meta +11 -0
  226. package/Runtime/CesiumPropertyTable.cs +126 -0
  227. package/Runtime/CesiumPropertyTable.cs.meta +11 -0
  228. package/Runtime/CesiumPropertyTableProperty.cs +1734 -0
  229. package/Runtime/CesiumPropertyTableProperty.cs.meta +11 -0
  230. package/Runtime/CesiumRasterOverlay.cs +239 -0
  231. package/Runtime/CesiumRasterOverlay.cs.meta +11 -0
  232. package/Runtime/CesiumRasterOverlayLoadFailureDetails.cs +65 -0
  233. package/Runtime/CesiumRasterOverlayLoadFailureDetails.cs.meta +11 -0
  234. package/Runtime/CesiumRuntime.asmdef +32 -0
  235. package/Runtime/CesiumRuntime.asmdef.meta +7 -0
  236. package/Runtime/CesiumRuntime.cs +3 -0
  237. package/Runtime/CesiumRuntime.cs.meta +11 -0
  238. package/Runtime/CesiumRuntimeSettings.cs +188 -0
  239. package/Runtime/CesiumRuntimeSettings.cs.meta +11 -0
  240. package/Runtime/CesiumSampleHeightResult.cs +47 -0
  241. package/Runtime/CesiumSampleHeightResult.cs.meta +11 -0
  242. package/Runtime/CesiumSimplePlanarEllipsoidCurve.cs +93 -0
  243. package/Runtime/CesiumSimplePlanarEllipsoidCurve.cs.meta +11 -0
  244. package/Runtime/CesiumSubScene.cs +473 -0
  245. package/Runtime/CesiumSubScene.cs.meta +11 -0
  246. package/Runtime/CesiumTileExcluder.cs +47 -0
  247. package/Runtime/CesiumTileExcluder.cs.meta +11 -0
  248. package/Runtime/CesiumTileMapServiceRasterOverlay.cs +93 -0
  249. package/Runtime/CesiumTileMapServiceRasterOverlay.cs.meta +11 -0
  250. package/Runtime/CesiumWebMapServiceRasterOverlay.cs +129 -0
  251. package/Runtime/CesiumWebMapServiceRasterOverlay.cs.meta +11 -0
  252. package/Runtime/CesiumWebMapTileServiceRasterOverlay.cs +414 -0
  253. package/Runtime/CesiumWebMapTileServiceRasterOverlay.cs.meta +3 -0
  254. package/Runtime/CesiumWgs84Ellipsoid.cs +75 -0
  255. package/Runtime/CesiumWgs84Ellipsoid.cs.meta +11 -0
  256. package/Runtime/ConfigureReinterop.cs +926 -0
  257. package/Runtime/ConfigureReinterop.cs.meta +11 -0
  258. package/Runtime/Helpers.cs +122 -0
  259. package/Runtime/Helpers.cs.meta +11 -0
  260. package/Runtime/ICesiumRestartable.cs +17 -0
  261. package/Runtime/ICesiumRestartable.cs.meta +11 -0
  262. package/Runtime/NativeCoroutine.cs +28 -0
  263. package/Runtime/NativeCoroutine.cs.meta +11 -0
  264. package/Runtime/NativeDownloadHandler.cs +29 -0
  265. package/Runtime/NativeDownloadHandler.cs.meta +11 -0
  266. package/Runtime/Resources/CesiumCreditSystem.prefab +78 -0
  267. package/Runtime/Resources/CesiumCreditSystem.prefab.meta +7 -0
  268. package/Runtime/Resources/CesiumCreditSystemRuntimeTheme.tss +2 -0
  269. package/Runtime/Resources/CesiumCreditSystemRuntimeTheme.tss.meta +11 -0
  270. package/Runtime/Resources/CesiumCreditSystemUI.uxml +4 -0
  271. package/Runtime/Resources/CesiumCreditSystemUI.uxml.meta +10 -0
  272. package/Runtime/Resources/CesiumCreditSystemUIPanelSettings.asset +38 -0
  273. package/Runtime/Resources/CesiumCreditSystemUIPanelSettings.asset.meta +8 -0
  274. package/Runtime/Resources/CesiumDefaultTilesetMaterial.mat +232 -0
  275. package/Runtime/Resources/CesiumDefaultTilesetMaterial.mat.meta +8 -0
  276. package/Runtime/Resources/CesiumDefaultTilesetShader.shadergraph +14271 -0
  277. package/Runtime/Resources/CesiumDefaultTilesetShader.shadergraph.meta +10 -0
  278. package/Runtime/Resources/CesiumPointCloudShading.hlsl +156 -0
  279. package/Runtime/Resources/CesiumPointCloudShading.hlsl.meta +7 -0
  280. package/Runtime/Resources/CesiumPointCloudShadingMaterial.mat +125 -0
  281. package/Runtime/Resources/CesiumPointCloudShadingMaterial.mat.meta +8 -0
  282. package/Runtime/Resources/CesiumPointCloudShadingShader.shader +73 -0
  283. package/Runtime/Resources/CesiumPointCloudShadingShader.shader.meta +10 -0
  284. package/Runtime/Resources/CesiumRasterOverlay.shadersubgraph +2207 -0
  285. package/Runtime/Resources/CesiumRasterOverlay.shadersubgraph.meta +10 -0
  286. package/Runtime/Resources/CesiumSelectTexCoords.shadersubgraph +722 -0
  287. package/Runtime/Resources/CesiumSelectTexCoords.shadersubgraph.meta +10 -0
  288. package/Runtime/Resources/CesiumUnlitTilesetMaterial.mat +261 -0
  289. package/Runtime/Resources/CesiumUnlitTilesetMaterial.mat.meta +8 -0
  290. package/Runtime/Resources/CesiumUnlitTilesetShader.shadergraph +5873 -0
  291. package/Runtime/Resources/CesiumUnlitTilesetShader.shadergraph.meta +10 -0
  292. package/Runtime/Resources/DynamicCamera.prefab +253 -0
  293. package/Runtime/Resources/DynamicCamera.prefab.meta +7 -0
  294. package/Runtime/Resources/TransformTextureCoordinates.shadersubgraph +2171 -0
  295. package/Runtime/Resources/TransformTextureCoordinates.shadersubgraph.meta +10 -0
  296. package/Runtime/Resources/green1x1.png +0 -0
  297. package/Runtime/Resources/green1x1.png.meta +123 -0
  298. package/Runtime/Resources.meta +8 -0
  299. package/Runtime/TestGltfModel.cs +56 -0
  300. package/Runtime/TestGltfModel.cs.meta +11 -0
  301. package/Runtime/TestReinterop.cs +21 -0
  302. package/Runtime/TestReinterop.cs.meta +11 -0
  303. package/Runtime/UnityLifetime.cs +27 -0
  304. package/Runtime/UnityLifetime.cs.meta +11 -0
  305. package/Runtime/WaitForTask.cs +25 -0
  306. package/Runtime/WaitForTask.cs.meta +11 -0
  307. package/Runtime/csc.rsp +1 -0
  308. package/Runtime/csc.rsp.meta +7 -0
  309. package/Runtime.meta +8 -0
  310. package/ThirdParty.json +27 -0
  311. package/ThirdParty.json.meta +7 -0
  312. package/WGS84.asset +18 -0
  313. package/WGS84.asset.meta +8 -0
  314. package/package.json +29 -0
  315. package/package.json.meta +7 -0
@@ -0,0 +1,542 @@
1
+ using UnityEditor;
2
+ using UnityEngine;
3
+
4
+ namespace CesiumForUnity
5
+ {
6
+ [CustomEditor(typeof(Cesium3DTileset))]
7
+ public class Cesium3DTilesetEditor : Editor
8
+ {
9
+ private Cesium3DTileset _tileset;
10
+
11
+ private SerializedProperty _showCreditsOnScreen;
12
+
13
+ private SerializedProperty _tilesetSource;
14
+ private SerializedProperty _url;
15
+ private SerializedProperty _ionAssetID;
16
+ private SerializedProperty _ionAccessToken;
17
+ private SerializedProperty _ionServer;
18
+
19
+ private SerializedProperty _maximumScreenSpaceError;
20
+
21
+ private SerializedProperty _preloadAncestors;
22
+ private SerializedProperty _preloadSiblings;
23
+ private SerializedProperty _forbidHoles;
24
+ private SerializedProperty _maximumSimultaneousTileLoads;
25
+ private SerializedProperty _maximumCachedBytes;
26
+ private SerializedProperty _loadingDescendantLimit;
27
+
28
+ private SerializedProperty _enableFrustumCulling;
29
+ private SerializedProperty _enableFogCulling;
30
+ private SerializedProperty _enforceCulledScreenSpaceError;
31
+ private SerializedProperty _culledScreenSpaceError;
32
+
33
+ private SerializedProperty _opaqueMaterial;
34
+ //private SerializedProperty _useLodTransitions;
35
+ //private SerializedProperty _lodTransitionLength;
36
+ private SerializedProperty _generateSmoothNormals;
37
+
38
+ private SerializedProperty _pointCloudShading;
39
+
40
+ private SerializedProperty _showTilesInHierarchy;
41
+ private SerializedProperty _suspendUpdate;
42
+ private SerializedProperty _updateInEditor;
43
+ private SerializedProperty _logSelectionStats;
44
+
45
+ private SerializedProperty _createPhysicsMeshes;
46
+
47
+ private void OnEnable()
48
+ {
49
+ this._tileset = (Cesium3DTileset)target;
50
+
51
+ this._showCreditsOnScreen =
52
+ this.serializedObject.FindProperty("_showCreditsOnScreen");
53
+
54
+ this._tilesetSource = this.serializedObject.FindProperty("_tilesetSource");
55
+ this._url = this.serializedObject.FindProperty("_url");
56
+ this._ionAssetID = this.serializedObject.FindProperty("_ionAssetID");
57
+ this._ionAccessToken = this.serializedObject.FindProperty("_ionAccessToken");
58
+ this._ionServer = this.serializedObject.FindProperty("_ionServer");
59
+
60
+ this._maximumScreenSpaceError =
61
+ this.serializedObject.FindProperty("_maximumScreenSpaceError");
62
+
63
+ this._preloadAncestors = this.serializedObject.FindProperty("_preloadAncestors");
64
+ this._preloadSiblings = this.serializedObject.FindProperty("_preloadSiblings");
65
+ this._forbidHoles = this.serializedObject.FindProperty("_forbidHoles");
66
+ this._maximumSimultaneousTileLoads =
67
+ this.serializedObject.FindProperty("_maximumSimultaneousTileLoads");
68
+ this._maximumCachedBytes = this.serializedObject.FindProperty("_maximumCachedBytes");
69
+ this._loadingDescendantLimit =
70
+ this.serializedObject.FindProperty("_loadingDescendantLimit");
71
+
72
+ this._enableFrustumCulling =
73
+ this.serializedObject.FindProperty("_enableFrustumCulling");
74
+ this._enableFogCulling = this.serializedObject.FindProperty("_enableFogCulling");
75
+ this._enforceCulledScreenSpaceError =
76
+ this.serializedObject.FindProperty("_enforceCulledScreenSpaceError");
77
+ this._culledScreenSpaceError =
78
+ this.serializedObject.FindProperty("_culledScreenSpaceError");
79
+
80
+ this._opaqueMaterial = this.serializedObject.FindProperty("_opaqueMaterial");
81
+ //this._useLodTransitions = this.serializedObject.FindProperty("_useLodTransitions");
82
+ //this._lodTransitionLength =
83
+ // this.serializedObject.FindProperty("_lodTransitionLength");
84
+ this._generateSmoothNormals =
85
+ this.serializedObject.FindProperty("_generateSmoothNormals");
86
+
87
+ this._pointCloudShading = this.serializedObject.FindProperty("_pointCloudShading");
88
+
89
+ this._showTilesInHierarchy =
90
+ this.serializedObject.FindProperty("_showTilesInHierarchy");
91
+ this._suspendUpdate = this.serializedObject.FindProperty("_suspendUpdate");
92
+ this._updateInEditor = this.serializedObject.FindProperty("_updateInEditor");
93
+ this._logSelectionStats = this.serializedObject.FindProperty("_logSelectionStats");
94
+
95
+ this._createPhysicsMeshes =
96
+ this.serializedObject.FindProperty("_createPhysicsMeshes");
97
+ }
98
+
99
+ public override void OnInspectorGUI()
100
+ {
101
+ this.serializedObject.Update();
102
+
103
+ EditorGUIUtility.labelWidth = CesiumEditorStyle.inspectorLabelWidth;
104
+ this.DrawInspectorButtons();
105
+ EditorGUILayout.Space(5);
106
+ this.DrawShowCreditsOnScreenToggle();
107
+ EditorGUILayout.Space(5);
108
+ this.DrawSourceProperties();
109
+ EditorGUILayout.Space(5);
110
+ this.DrawLevelOfDetailProperties();
111
+ EditorGUILayout.Space(5);
112
+ this.DrawTileLoadingProperties();
113
+ EditorGUILayout.Space(5);
114
+ this.DrawTileCullingProperties();
115
+ EditorGUILayout.Space(5);
116
+ this.DrawRenderProperties();
117
+ EditorGUILayout.Space(5);
118
+ this.DrawPointCloudShadingProperties();
119
+ EditorGUILayout.Space(5);
120
+ this.DrawDebugProperties();
121
+ EditorGUILayout.Space(5);
122
+ this.DrawPhysicsProperties();
123
+
124
+ this.serializedObject.ApplyModifiedProperties();
125
+ }
126
+
127
+ public bool HasFrameBounds()
128
+ {
129
+ return true;
130
+ }
131
+
132
+ public Bounds OnGetFrameBounds()
133
+ {
134
+ // HACK: This function only gets called by Unity's editor when it is trying to focus the tileset.
135
+ // Return dummy bounds with infinite extent so Unity's built in focusing fails. This allows us to
136
+ // focus the editor view as we want, without it getting overwritten.
137
+
138
+ // TODO: Maybe we can use reflection or something to only do this hack when the SceneView is
139
+ // invoking this method. It is not ideal for this method to have a side-effect when it is invoked
140
+ // from anywhere else.
141
+ this._tileset.FocusTileset();
142
+ return new Bounds(
143
+ new Vector3(0, 0, 0),
144
+ new Vector3(float.PositiveInfinity, float.PositiveInfinity, float.PositiveInfinity));
145
+ }
146
+
147
+ private void DrawInspectorButtons()
148
+ {
149
+ GUILayout.BeginHorizontal();
150
+ GUIContent refreshTilesetContent = new GUIContent(
151
+ "Refresh Tileset",
152
+ "Refreshes this tileset, ensuring that all materials and other settings are " +
153
+ "applied. It is not usually necessary to invoke this, but when behind-the-scenes " +
154
+ "changes are made and not reflected in the tileset, this function can help.");
155
+ if (GUILayout.Button(refreshTilesetContent))
156
+ {
157
+ this._tileset.RecreateTileset();
158
+ }
159
+
160
+ GUIContent troubleshootTokenContent = new GUIContent(
161
+ "Troubleshoot Token",
162
+ "Check if the Cesium ion token used to access this tileset is working correctly, " +
163
+ "and fix it if necessary.");
164
+ if (GUILayout.Button(troubleshootTokenContent))
165
+ {
166
+ IonTokenTroubleshootingWindow.ShowWindow(this._tileset, false);
167
+ }
168
+ GUILayout.EndHorizontal();
169
+ }
170
+
171
+ private void DrawShowCreditsOnScreenToggle()
172
+ {
173
+ GUIContent showCreditsOnScreenContent = new GUIContent(
174
+ "Show Credits On Screen",
175
+ "Whether or not to show this tileset's credits on screen.");
176
+
177
+ EditorGUI.BeginChangeCheck();
178
+ EditorGUILayout.PropertyField(this._showCreditsOnScreen, showCreditsOnScreenContent);
179
+ if (EditorGUI.EndChangeCheck())
180
+ {
181
+ // Trigger the OnSetShowCreditsOnScreen event in Cesium3DTileset.
182
+ this._tileset.showCreditsOnScreen = this._showCreditsOnScreen.boolValue;
183
+ }
184
+ }
185
+
186
+ private void DrawSourceProperties()
187
+ {
188
+ GUILayout.Label("Source", EditorStyles.boldLabel);
189
+
190
+ GUIContent tilesetSourceContent = new GUIContent(
191
+ "Tileset Source",
192
+ "Whether this tileset should be loaded from a URL or from Cesium ion.");
193
+ EditorGUILayout.PropertyField(this._tilesetSource, tilesetSourceContent);
194
+
195
+ CesiumDataSource tilesetSource = (CesiumDataSource)this._tilesetSource.enumValueIndex;
196
+
197
+ EditorGUI.BeginDisabledGroup(tilesetSource != CesiumDataSource.FromUrl);
198
+ GUIContent urlContent = new GUIContent(
199
+ "URL",
200
+ "The URL of this tileset's \"tileset.json\" file.");
201
+ EditorGUILayout.DelayedTextField(this._url, urlContent);
202
+ EditorGUI.EndDisabledGroup();
203
+
204
+ EditorGUI.BeginDisabledGroup(tilesetSource != CesiumDataSource.FromCesiumIon);
205
+ GUIContent ionAssetIDContent = new GUIContent(
206
+ "ion Asset ID",
207
+ "The ID of the Cesium ion asset to use.");
208
+ EditorGUILayout.DelayedIntField(this._ionAssetID, ionAssetIDContent);
209
+ GUIContent ionAccessTokenContent = new GUIContent(
210
+ "ion Access Token",
211
+ "The access token to use to access the Cesium ion resource.");
212
+ EditorGUILayout.DelayedTextField(this._ionAccessToken, ionAccessTokenContent);
213
+ GUIContent ionServerContent = new GUIContent("ion Server", "The Cesium ion server to use.");
214
+ EditorGUILayout.PropertyField(this._ionServer, ionServerContent);
215
+ EditorGUI.EndDisabledGroup();
216
+ }
217
+
218
+ private void DrawLevelOfDetailProperties()
219
+ {
220
+ GUILayout.Label("Level of Detail", EditorStyles.boldLabel);
221
+
222
+ GUIContent maximumScreenSpaceErrorContent =
223
+ new GUIContent("Maximum Screen Space Error",
224
+ "The maximum number of pixels of error when rendering this tileset." +
225
+ "\n\n" +
226
+ "This is used to select an appropriate level-of-detail: A low value " +
227
+ "will cause many tiles with a high level of detail to be loaded, causing " +
228
+ "a finer visual representation of the tiles, but with a higher performance " +
229
+ "cost for loading and rendering. A higher value will cause a coarser " +
230
+ "visual representation, with lower performance requirements." +
231
+ "\n\n" +
232
+ "When a tileset uses the older layer.json / quantized-mesh format rather " +
233
+ "than 3D Tiles, this value is effectively divided by 8.0. So the default " +
234
+ "value of 16.0 corresponds to the standard value for quantized-mesh " +
235
+ "terrain of 2.0.");
236
+ EditorGUILayout.PropertyField(
237
+ this._maximumScreenSpaceError, maximumScreenSpaceErrorContent);
238
+ }
239
+
240
+ private void DrawTileLoadingProperties()
241
+ {
242
+ GUILayout.Label("Tile Loading", EditorStyles.boldLabel);
243
+
244
+ GUIContent preloadAncestorsContent = new GUIContent(
245
+ "Preload Ancestors",
246
+ "Whether to preload ancestor tiles." +
247
+ "\n\n" +
248
+ "Setting this to true optimizes the zoom-out experience and provides more " +
249
+ "detail in newly-exposed areas when panning. The down side is that it " +
250
+ "requires loading more tiles.");
251
+ EditorGUILayout.PropertyField(this._preloadAncestors, preloadAncestorsContent);
252
+
253
+ GUIContent preloadSiblingsContent = new GUIContent(
254
+ "Preload Siblings",
255
+ "Whether to preload sibling tiles." +
256
+ "\n\n" +
257
+ "Setting this to true causes tiles with the same parent as a rendered " +
258
+ "tile to be loaded, even if they are culled. Setting this to true may " +
259
+ "provide a better panning experience at the cost of loading more tiles.");
260
+ EditorGUILayout.PropertyField(this._preloadSiblings, preloadSiblingsContent);
261
+
262
+ GUIContent forbidHolesContent = new GUIContent(
263
+ "Forbid Holes",
264
+ "Whether to prevent refinement of a parent tile when a child isn't done loading." +
265
+ "\n\n" +
266
+ "When this is set to true, the tileset will guarantee that the tileset will " +
267
+ "never be rendered with holes in place of tiles that are not yet loaded," +
268
+ "even though the tile that is rendered instead may have low resolution. " +
269
+ "When false, overall loading will be faster, but newly-visible parts of the " +
270
+ "tileset may initially be blank.");
271
+ EditorGUILayout.PropertyField(this._forbidHoles, forbidHolesContent);
272
+
273
+ GUIContent maximumSimultaneousTileLoadsContent =
274
+ new GUIContent(
275
+ "Maximum Simultaneous Tile Loads",
276
+ "The maximum number of tiles that may be loaded at once." +
277
+ "\n\n" +
278
+ "When new parts of the tileset become visible, the tasks to load the " +
279
+ "corresponding tiles are put into a queue. This value determines how " +
280
+ "many of these tasks are processed at the same time. A higher value may " +
281
+ "cause the tiles to be loaded and rendered more quickly, at the cost of " +
282
+ "a higher network and processing load.");
283
+ EditorGUILayout.PropertyField(
284
+ this._maximumSimultaneousTileLoads, maximumSimultaneousTileLoadsContent);
285
+
286
+ GUIContent maximumCachedBytesContent = new GUIContent(
287
+ "Maximum Cached Bytes",
288
+ "The maximum number of bytes that may be cached." +
289
+ "\n\n" +
290
+ "Note that this value, even if 0, will never cause tiles that are needed " +
291
+ "for rendering to be unloaded. However, if the total number of loaded " +
292
+ "bytes is greater than this value, tiles will be unloaded until the " +
293
+ "total is under this number or until only required tiles remain, whichever " +
294
+ "comes first.");
295
+ EditorGUILayout.PropertyField(this._maximumCachedBytes, maximumCachedBytesContent);
296
+
297
+ GUIContent loadingDescendantLimitContent = new GUIContent(
298
+ "Loading Descendant Limit",
299
+ "The number of loading descendents a tile should allow before " +
300
+ "deciding to render itself instead of waiting." +
301
+ "\n\n" +
302
+ "Setting this to 0 will cause each level of detail to be loaded " +
303
+ "successively. This will increase the overall loading time, but cause " +
304
+ "additional detail to appear more gradually. Setting this to a high value " +
305
+ "like 1000 will decrease the overall time until the desired level of detail " +
306
+ "is achieved, but this high-detail representation will appear at once, as " +
307
+ "soon as it is loaded completely.");
308
+ EditorGUILayout.PropertyField(
309
+ this._loadingDescendantLimit, loadingDescendantLimitContent);
310
+ }
311
+
312
+ private void DrawTileCullingProperties()
313
+ {
314
+ GUILayout.Label("Tile Culling", EditorStyles.boldLabel);
315
+
316
+ //EditorGUI.BeginDisabledGroup(this._useLodTransitions.boolValue);
317
+ GUIContent enableFrustumCullingContent = new GUIContent(
318
+ "Enable Frustum Culling",
319
+ "Whether to cull tiles that are outside the frustum." +
320
+ "\n\n" +
321
+ "By default this is true, meaning that tiles that are not visible with " +
322
+ "the current camera configuration will be ignored. It can be set to false, " +
323
+ "so that these tiles are still considered for loading, refinement and rendering." +
324
+ "\n\n" +
325
+ "This will cause more tiles to be loaded, but helps to avoid holes and " +
326
+ "provides a more consistent mesh, which may be helpful for physics and shadows." +
327
+ "\n\n" +
328
+ "Note that this will always be disabled if \"Use Lod Transitions\" is set to true.");
329
+ EditorGUILayout.PropertyField(this._enableFrustumCulling, enableFrustumCullingContent);
330
+
331
+ GUIContent enableFogCullingContent = new GUIContent(
332
+ "Enable Fog Culling",
333
+ "Whether to cull tiles that are occluded by fog." +
334
+ "\n\n" +
335
+ "This does not refer to the atmospheric fog rendered by Unity, but to an " +
336
+ "internal representation of fog: Depending on the height of the camera " +
337
+ "above the ground, tiles that are far away (close to the horizon) will be " +
338
+ "culled when this flag is enabled." +
339
+ "\n\n" +
340
+ "Note that this will always be disabled if \"Use Lod Transitions\" is set to true.");
341
+ EditorGUILayout.PropertyField(this._enableFogCulling, enableFogCullingContent);
342
+ //EditorGUI.EndDisabledGroup();
343
+
344
+ GUIContent enforceCulledScreenSpaceErrorContent = new GUIContent(
345
+ "Enforce Culled Screen Space Error",
346
+ "Whether a specified screen-space error should be enforced for tiles " +
347
+ "that are outside the frustum or hidden in fog." +
348
+ "\n\n" +
349
+ "When \"Enable Frustum Culling\" and \"Enable Fog Culling\" are both true, " +
350
+ "tiles outside the view frustum or hidden in fog are effectively ignored, " +
351
+ "and so their level-of-detail doesn't matter. And in this scenario, this " +
352
+ "property is ignored." +
353
+ "\n\n" +
354
+ "However, when either of those flags are false, these \"would-be-culled\" " +
355
+ "tiles continue to be processed, and the question arises of how to handle " +
356
+ "their level-of-detail. When this property is false, refinement terminates " +
357
+ "at these tiles, no matter what their current screen-space error. The tiles " +
358
+ "are available for physics, shadows, etc., but their level-of-detail may be " +
359
+ "very low." +
360
+ "\n\n" +
361
+ "When set to true, these tiles are refined until they achieve the specified " +
362
+ "\"Culled Screen Space Error\". This allows control over the minimum quality " +
363
+ "of these would-be-culled tiles.");
364
+
365
+ EditorGUILayout.PropertyField(
366
+ this._enforceCulledScreenSpaceError, enforceCulledScreenSpaceErrorContent);
367
+
368
+ EditorGUI.BeginDisabledGroup(!this._enforceCulledScreenSpaceError.boolValue);
369
+ GUIContent culledScreenSpaceErrorContent = new GUIContent(
370
+ "Culled Screen Space Error",
371
+ "The screen-space error to be enforced for tiles that are outside " +
372
+ "the frustum or hidden in fog." +
373
+ "\n\n" +
374
+ "When \"Enable Frustum Culling\" and \"Enable Fog Culling\" are both true, " +
375
+ "tiles outside the view frustum or hidden in fog are effectively ignored, " +
376
+ "and so their level-of-detail doesn't matter. And in this scenario, this " +
377
+ "property is ignored." +
378
+ "\n\n" +
379
+ "However, when either of those flags are false, these \"would-be-culled\" " +
380
+ "tiles continue to be processed, and the question arises of how to handle " +
381
+ "their level-of-detail. When this property is false, refinement terminates " +
382
+ "at these tiles, no matter what their current screen-space error. The tiles " +
383
+ "are available for physics, shadows, etc., but their level-of-detail may be " +
384
+ "very low." +
385
+ "\n\n" +
386
+ "When set to true, these tiles are refined until they achieve the specified " +
387
+ "\"Culled Screen Space Error\". This allows control over the minimum quality " +
388
+ "of these would-be-culled tiles.");
389
+ EditorGUILayout.PropertyField(
390
+ this._culledScreenSpaceError, culledScreenSpaceErrorContent);
391
+ EditorGUI.EndDisabledGroup();
392
+ }
393
+
394
+ private void DrawRenderProperties()
395
+ {
396
+ GUILayout.Label("Render", EditorStyles.boldLabel);
397
+
398
+ GUIContent opaqueMaterialContent = new GUIContent(
399
+ "Opaque Material",
400
+ "The Material to use to render opaque parts of tiles.");
401
+ EditorGUILayout.PropertyField(this._opaqueMaterial, opaqueMaterialContent);
402
+
403
+ //GUIContent useLodTransitionsContent = new GUIContent(
404
+ // "Use Lod Transitions",
405
+ // "Use a dithering effect when transitioning between tiles of different LODs." +
406
+ // "\n\n" +
407
+ // "When this is set to true, Frustrum Culling and Fog Culling are always disabled.");
408
+ //EditorGUILayout.PropertyField(this._useLodTransitions, useLodTransitionsContent);
409
+
410
+ //EditorGUI.BeginDisabledGroup(!this._useLodTransitions.boolValue);
411
+ //GUIContent lodTransitionLengthContent = new GUIContent(
412
+ // "Lod Transition Length",
413
+ // "How long dithered LOD transitions between different tiles should take, in seconds." +
414
+ // "\n\n" +
415
+ // "Only relevant if \"Use Lod Transitions\" is true.");
416
+ //EditorGUILayout.PropertyField(this._lodTransitionLength, lodTransitionLengthContent);
417
+ //EditorGUI.EndDisabledGroup();
418
+
419
+ GUIContent generateSmoothNormalsContent = new GUIContent(
420
+ "Generate Smooth Normals",
421
+ "Whether to generate smooth normals when normals are missing in the glTF." +
422
+ "\n\n" +
423
+ "According to the glTF spec: \"When normals are not specified, client " +
424
+ "implementations should calculate flat normals.\" However, calculating flat " +
425
+ "normals requires duplicating vertices. This option allows the glTFs to be " +
426
+ "rendered with smooth normals instead when the original glTF is missing normals.");
427
+ EditorGUILayout.PropertyField(this._generateSmoothNormals, generateSmoothNormalsContent);
428
+ }
429
+
430
+ private void DrawPointCloudShadingProperties()
431
+ {
432
+ // EditorGUILayout.PropertyField will trigger OnValidate() for the tileset,
433
+ // even though the properties belong to CesiumPointCloudShading.
434
+ // To avoid refreshing the tileset every time a parameter is changed,
435
+ // the values are modified using the CesiumPointCloudShading setters instead.
436
+ GUILayout.Label("Point Cloud Shading", EditorStyles.boldLabel);
437
+
438
+ EditorGUI.BeginChangeCheck();
439
+
440
+ SerializedProperty attenuationProperty =
441
+ this._pointCloudShading.FindPropertyRelative("_attenuation");
442
+ GUIContent attenuationContent = new GUIContent(
443
+ "Attenuation",
444
+ "Whether or not to perform point attenuation. Attenuation controls the size of " +
445
+ "the points rendered based on the geometric error of their tile.");
446
+ bool attenuationValue =
447
+ EditorGUILayout.Toggle(attenuationContent, attenuationProperty.boolValue);
448
+
449
+ SerializedProperty geometricErrorScaleProperty =
450
+ this._pointCloudShading.FindPropertyRelative("_geometricErrorScale");
451
+ GUIContent geometricErrorScaleContent = new GUIContent(
452
+ "Geometric Error Scale",
453
+ "The scale to be applied to the tile's geometric error before it is used " +
454
+ "to compute attenuation. Larger values will result in larger points.");
455
+ float geometricErrorScaleValue = EditorGUILayout.FloatField(
456
+ geometricErrorScaleContent,
457
+ geometricErrorScaleProperty.floatValue);
458
+
459
+ SerializedProperty maximumAttenuationProperty =
460
+ this._pointCloudShading.FindPropertyRelative("_maximumAttenuation");
461
+ GUIContent maximumAttenuationContent = new GUIContent(
462
+ "Maximum Attenuation",
463
+ "The maximum point attenuation in pixels. If this is zero, the " +
464
+ "Cesium3DTileset's maximumScreenSpaceError will be used as the " +
465
+ "maximum point attenuation.");
466
+ float maximumAttenuationValue = EditorGUILayout.FloatField(
467
+ maximumAttenuationContent,
468
+ maximumAttenuationProperty.floatValue);
469
+
470
+ SerializedProperty baseResolutionProperty =
471
+ this._pointCloudShading.FindPropertyRelative("_baseResolution");
472
+ GUIContent baseResolutionContent = new GUIContent(
473
+ "Base Resolution",
474
+ "The average base resolution for the dataset in meters. " +
475
+ "For example, a base resolution of 0.05 assumes an original " +
476
+ "capture resolution of 5 centimeters between neighboring points." +
477
+ "\n\n" +
478
+ "This is used in place of geometric error when the tile's " +
479
+ "geometric error is 0. If this value is zero, each tile with " +
480
+ "a geometric error of 0 will have its geometric error " +
481
+ "approximated instead.");
482
+ float baseResolutionValue = EditorGUILayout.FloatField(
483
+ baseResolutionContent,
484
+ baseResolutionProperty.floatValue);
485
+
486
+ if (EditorGUI.EndChangeCheck())
487
+ {
488
+ Undo.RecordObject(
489
+ this._tileset,
490
+ "Modified Point Cloud Shading in " + this._tileset.gameObject.name);
491
+ this._tileset.pointCloudShading.attenuation = attenuationValue;
492
+ this._tileset.pointCloudShading.geometricErrorScale = geometricErrorScaleValue;
493
+ this._tileset.pointCloudShading.maximumAttenuation = maximumAttenuationValue;
494
+ this._tileset.pointCloudShading.baseResolution = baseResolutionValue;
495
+ // Force the scene view to repaint so that the changes are immediately reflected.
496
+ SceneView.RepaintAll();
497
+ }
498
+ }
499
+
500
+ private void DrawDebugProperties()
501
+ {
502
+ GUILayout.Label("Debug", EditorStyles.boldLabel);
503
+
504
+ GUIContent showTilesInHierarchyContent = new GUIContent(
505
+ "Show Tiles In Hierarchy",
506
+ "Whether to show tiles as individual game objects in the hierarchy window.");
507
+ EditorGUILayout.PropertyField(this._showTilesInHierarchy, showTilesInHierarchyContent);
508
+
509
+ GUIContent suspendUpdateContent = new GUIContent(
510
+ "Suspend Update",
511
+ "Pauses level-of-detail and culling updates of this tileset.");
512
+ EditorGUILayout.PropertyField(this._suspendUpdate, suspendUpdateContent);
513
+
514
+ GUIContent updateInEditorContent = new GUIContent(
515
+ "Update in Editor",
516
+ "If true, this tileset is ticked/updated in the editor. " +
517
+ "If false, it is only ticked while playing (including Play-in-Editor).");
518
+ EditorGUILayout.PropertyField(this._updateInEditor, updateInEditorContent);
519
+
520
+ GUIContent logSelectionStatsContent = new GUIContent(
521
+ "Log Selection Stats",
522
+ "Whether to log details about the tile selection process.");
523
+ EditorGUILayout.PropertyField(this._logSelectionStats, logSelectionStatsContent);
524
+ }
525
+
526
+ private void DrawPhysicsProperties()
527
+ {
528
+ GUILayout.Label("Physics", EditorStyles.boldLabel);
529
+
530
+ GUIContent createPhysicsMeshesContent = new GUIContent(
531
+ "Create Physics Meshes",
532
+ "Whether to generate physics meshes for this tileset." +
533
+ "\n\n" +
534
+ "Disabling this option will improve the performance of tile loading, " +
535
+ "but it will no longer be possible to collide with the tileset since " +
536
+ "the physics meshes will not be created." +
537
+ "\n\n" +
538
+ "Physics meshes cannot be generated for primitives containing points.");
539
+ EditorGUILayout.PropertyField(this._createPhysicsMeshes, createPhysicsMeshesContent);
540
+ }
541
+ }
542
+ }
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: 2a0d1b40f4e2adb43b04c60265ae0451
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant:
@@ -0,0 +1,66 @@
1
+ using UnityEditor;
2
+ using UnityEngine;
3
+
4
+ namespace CesiumForUnity
5
+ {
6
+ [CustomEditor(typeof(CesiumBingMapsRasterOverlay))]
7
+ public class CesiumBingMapsRasterOverlayEditor : Editor
8
+ {
9
+ private CesiumRasterOverlayEditor _rasterOverlayEditor;
10
+
11
+ private SerializedProperty _bingMapsKey;
12
+ private SerializedProperty _mapStyle;
13
+
14
+ private void OnEnable()
15
+ {
16
+ this._rasterOverlayEditor =
17
+ (CesiumRasterOverlayEditor)Editor.CreateEditor(
18
+ this.target,
19
+ typeof(CesiumRasterOverlayEditor));
20
+
21
+ this._bingMapsKey = this.serializedObject.FindProperty("_bingMapsKey");
22
+ this._mapStyle = this.serializedObject.FindProperty("_mapStyle");
23
+ }
24
+
25
+ private void OnDisable()
26
+ {
27
+ if (this._rasterOverlayEditor != null)
28
+ {
29
+ DestroyImmediate(this._rasterOverlayEditor);
30
+ }
31
+ }
32
+
33
+ public override void OnInspectorGUI()
34
+ {
35
+ this.serializedObject.Update();
36
+
37
+ EditorGUIUtility.labelWidth = CesiumEditorStyle.inspectorLabelWidth;
38
+ this.DrawBingMapsProperties();
39
+ EditorGUILayout.Space(5);
40
+ this.DrawRasterOverlayProperties();
41
+
42
+ this.serializedObject.ApplyModifiedProperties();
43
+ }
44
+
45
+ private void DrawBingMapsProperties()
46
+ {
47
+ GUIContent bingMapsKeyContent = new GUIContent(
48
+ "Bing Maps Key",
49
+ "The Bing Maps API key to use.");
50
+ EditorGUILayout.DelayedTextField(this._bingMapsKey, bingMapsKeyContent);
51
+
52
+ GUIContent mapStyleContent = new GUIContent(
53
+ "Map Style",
54
+ "The map style to use.");
55
+ EditorGUILayout.PropertyField(this._mapStyle, mapStyleContent);
56
+ }
57
+
58
+ private void DrawRasterOverlayProperties()
59
+ {
60
+ if (this._rasterOverlayEditor != null)
61
+ {
62
+ this._rasterOverlayEditor.OnInspectorGUI();
63
+ }
64
+ }
65
+ }
66
+ }
@@ -0,0 +1,11 @@
1
+ fileFormatVersion: 2
2
+ guid: 89413df53b087c0459062ccc3e5b006b
3
+ MonoImporter:
4
+ externalObjects: {}
5
+ serializedVersion: 2
6
+ defaultReferences: []
7
+ executionOrder: 0
8
+ icon: {instanceID: 0}
9
+ userData:
10
+ assetBundleName:
11
+ assetBundleVariant: