@itwin/frontend-devtools 4.0.0-dev.8 → 4.0.0-dev.80
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/CHANGELOG.md +41 -1
- package/README.md +1 -1
- package/lib/cjs/ClipboardUtilities.d.ts +8 -8
- package/lib/cjs/ClipboardUtilities.js +26 -26
- package/lib/cjs/FrontEndDevTools.d.ts +19 -19
- package/lib/cjs/FrontEndDevTools.js +221 -221
- package/lib/cjs/FrontEndDevTools.js.map +1 -1
- package/lib/cjs/effects/Convolution.d.ts +68 -68
- package/lib/cjs/effects/Convolution.js +148 -148
- package/lib/cjs/effects/Convolution.js.map +1 -1
- package/lib/cjs/effects/EffectTools.d.ts +33 -33
- package/lib/cjs/effects/EffectTools.js +67 -68
- package/lib/cjs/effects/EffectTools.js.map +1 -1
- package/lib/cjs/effects/Explosion.d.ts +12 -12
- package/lib/cjs/effects/Explosion.js +168 -168
- package/lib/cjs/effects/Explosion.js.map +1 -1
- package/lib/cjs/effects/FlipImage.d.ts +30 -30
- package/lib/cjs/effects/FlipImage.js +79 -79
- package/lib/cjs/effects/FlipImage.js.map +1 -1
- package/lib/cjs/effects/LensDistortion.d.ts +34 -34
- package/lib/cjs/effects/LensDistortion.js +88 -88
- package/lib/cjs/effects/LensDistortion.js.map +1 -1
- package/lib/cjs/effects/Random.d.ts +24 -24
- package/lib/cjs/effects/Random.js +49 -49
- package/lib/cjs/effects/Saturation.d.ts +30 -30
- package/lib/cjs/effects/Saturation.js +59 -59
- package/lib/cjs/effects/Saturation.js.map +1 -1
- package/lib/cjs/effects/Snow.d.ts +76 -76
- package/lib/cjs/effects/Snow.js +187 -187
- package/lib/cjs/effects/Snow.js.map +1 -1
- package/lib/cjs/effects/Vignette.d.ts +39 -39
- package/lib/cjs/effects/Vignette.js +79 -79
- package/lib/cjs/effects/Vignette.js.map +1 -1
- package/lib/cjs/frontend-devtools.d.ts +82 -82
- package/lib/cjs/frontend-devtools.js +102 -98
- package/lib/cjs/frontend-devtools.js.map +1 -1
- package/lib/cjs/tools/AnimationIntervalTool.d.ts +15 -15
- package/lib/cjs/tools/AnimationIntervalTool.js +30 -30
- package/lib/cjs/tools/AnimationIntervalTool.js.map +1 -1
- package/lib/cjs/tools/ChangeUnitsTool.d.ts +15 -15
- package/lib/cjs/tools/ChangeUnitsTool.js +41 -41
- package/lib/cjs/tools/ChangeUnitsTool.js.map +1 -1
- package/lib/cjs/tools/ClipTools.d.ts +67 -67
- package/lib/cjs/tools/ClipTools.js +161 -164
- package/lib/cjs/tools/ClipTools.js.map +1 -1
- package/lib/cjs/tools/DisplayStyleTools.d.ts +145 -145
- package/lib/cjs/tools/DisplayStyleTools.js +368 -370
- package/lib/cjs/tools/DisplayStyleTools.js.map +1 -1
- package/lib/cjs/tools/EmphasizeElementsTool.d.ts +60 -60
- package/lib/cjs/tools/EmphasizeElementsTool.js +154 -154
- package/lib/cjs/tools/EmphasizeElementsTool.js.map +1 -1
- package/lib/cjs/tools/FrustumDecoration.d.ts +57 -57
- package/lib/cjs/tools/FrustumDecoration.js +374 -374
- package/lib/cjs/tools/FrustumDecoration.js.map +1 -1
- package/lib/cjs/tools/InspectElementTool.d.ts +42 -42
- package/lib/cjs/tools/InspectElementTool.js +198 -198
- package/lib/cjs/tools/InspectElementTool.js.map +1 -1
- package/lib/cjs/tools/MapLayerTool.d.ts +264 -264
- package/lib/cjs/tools/MapLayerTool.d.ts.map +1 -1
- package/lib/cjs/tools/MapLayerTool.js +509 -507
- package/lib/cjs/tools/MapLayerTool.js.map +1 -1
- package/lib/cjs/tools/MeasureTileLoadTime.d.ts +12 -12
- package/lib/cjs/tools/MeasureTileLoadTime.js +63 -63
- package/lib/cjs/tools/MeasureTileLoadTime.js.map +1 -1
- package/lib/cjs/tools/ModelAppearanceTools.d.ts +86 -86
- package/lib/cjs/tools/ModelAppearanceTools.js +183 -183
- package/lib/cjs/tools/ModelAppearanceTools.js.map +1 -1
- package/lib/cjs/tools/PlanProjectionTools.d.ts +40 -40
- package/lib/cjs/tools/PlanProjectionTools.js +149 -149
- package/lib/cjs/tools/PlanProjectionTools.js.map +1 -1
- package/lib/cjs/tools/PlanarMaskTools.d.ts +182 -182
- package/lib/cjs/tools/PlanarMaskTools.js +391 -393
- package/lib/cjs/tools/PlanarMaskTools.js.map +1 -1
- package/lib/cjs/tools/ProjectExtents.d.ts +41 -41
- package/lib/cjs/tools/ProjectExtents.js +110 -110
- package/lib/cjs/tools/ProjectExtents.js.map +1 -1
- package/lib/cjs/tools/RealityModelTools.d.ts +116 -116
- package/lib/cjs/tools/RealityModelTools.js +281 -281
- package/lib/cjs/tools/RealityModelTools.js.map +1 -1
- package/lib/cjs/tools/RealityTransitionTool.d.ts +25 -25
- package/lib/cjs/tools/RealityTransitionTool.js +115 -116
- package/lib/cjs/tools/RealityTransitionTool.js.map +1 -1
- package/lib/cjs/tools/RenderSystemTools.d.ts +38 -38
- package/lib/cjs/tools/RenderSystemTools.js +69 -70
- package/lib/cjs/tools/RenderSystemTools.js.map +1 -1
- package/lib/cjs/tools/RenderTargetTools.d.ts +107 -107
- package/lib/cjs/tools/RenderTargetTools.d.ts.map +1 -1
- package/lib/cjs/tools/RenderTargetTools.js +174 -174
- package/lib/cjs/tools/RenderTargetTools.js.map +1 -1
- package/lib/cjs/tools/ReportWebGLCompatibilityTool.d.ts +11 -11
- package/lib/cjs/tools/ReportWebGLCompatibilityTool.js +30 -30
- package/lib/cjs/tools/ReportWebGLCompatibilityTool.js.map +1 -1
- package/lib/cjs/tools/SavedViews.d.ts +46 -46
- package/lib/cjs/tools/SavedViews.js +136 -136
- package/lib/cjs/tools/SavedViews.js.map +1 -1
- package/lib/cjs/tools/ScheduleScriptTools.d.ts +37 -37
- package/lib/cjs/tools/ScheduleScriptTools.js +157 -159
- package/lib/cjs/tools/ScheduleScriptTools.js.map +1 -1
- package/lib/cjs/tools/SelectionTools.d.ts +28 -28
- package/lib/cjs/tools/SelectionTools.js +87 -87
- package/lib/cjs/tools/SelectionTools.js.map +1 -1
- package/lib/cjs/tools/SetGpuMemoryLimitTool.d.ts +15 -15
- package/lib/cjs/tools/SetGpuMemoryLimitTool.js +33 -33
- package/lib/cjs/tools/SetGpuMemoryLimitTool.js.map +1 -1
- package/lib/cjs/tools/SourceAspectIdTools.d.ts +40 -40
- package/lib/cjs/tools/SourceAspectIdTools.js +85 -86
- package/lib/cjs/tools/SourceAspectIdTools.js.map +1 -1
- package/lib/cjs/tools/TileRequestDecoration.d.ts +12 -12
- package/lib/cjs/tools/TileRequestDecoration.js +83 -83
- package/lib/cjs/tools/TileRequestDecoration.js.map +1 -1
- package/lib/cjs/tools/TileTreeBoundsDecoration.d.ts +11 -11
- package/lib/cjs/tools/TileTreeBoundsDecoration.js +74 -74
- package/lib/cjs/tools/TileTreeBoundsDecoration.js.map +1 -1
- package/lib/cjs/tools/ToolTipProvider.d.ts +15 -15
- package/lib/cjs/tools/ToolTipProvider.js +66 -66
- package/lib/cjs/tools/ToolTipProvider.js.map +1 -1
- package/lib/cjs/tools/ViewportTools.d.ts +218 -218
- package/lib/cjs/tools/ViewportTools.d.ts.map +1 -1
- package/lib/cjs/tools/ViewportTools.js +516 -516
- package/lib/cjs/tools/ViewportTools.js.map +1 -1
- package/lib/cjs/tools/parseArgs.d.ts +23 -23
- package/lib/cjs/tools/parseArgs.js +51 -51
- package/lib/cjs/tools/parseBoolean.d.ts +8 -8
- package/lib/cjs/tools/parseBoolean.js +26 -26
- package/lib/cjs/tools/parseToggle.d.ts +8 -8
- package/lib/cjs/tools/parseToggle.js +25 -25
- package/lib/cjs/ui/Button.d.ts +29 -29
- package/lib/cjs/ui/Button.d.ts.map +1 -1
- package/lib/cjs/ui/Button.js +26 -26
- package/lib/cjs/ui/CheckBox.d.ts +23 -23
- package/lib/cjs/ui/CheckBox.d.ts.map +1 -1
- package/lib/cjs/ui/CheckBox.js +27 -27
- package/lib/cjs/ui/ColorInput.d.ts +27 -27
- package/lib/cjs/ui/ColorInput.d.ts.map +1 -1
- package/lib/cjs/ui/ColorInput.js +53 -53
- package/lib/cjs/ui/ComboBox.d.ts +28 -28
- package/lib/cjs/ui/ComboBox.d.ts.map +1 -1
- package/lib/cjs/ui/ComboBox.js +42 -42
- package/lib/cjs/ui/DataList.d.ts +27 -27
- package/lib/cjs/ui/DataList.d.ts.map +1 -1
- package/lib/cjs/ui/DataList.js +39 -39
- package/lib/cjs/ui/NestedMenu.d.ts +19 -19
- package/lib/cjs/ui/NestedMenu.d.ts.map +1 -1
- package/lib/cjs/ui/NestedMenu.js +46 -46
- package/lib/cjs/ui/NumericInput.d.ts +35 -35
- package/lib/cjs/ui/NumericInput.d.ts.map +1 -1
- package/lib/cjs/ui/NumericInput.js +61 -61
- package/lib/cjs/ui/RadioBox.d.ts +29 -29
- package/lib/cjs/ui/RadioBox.d.ts.map +1 -1
- package/lib/cjs/ui/RadioBox.js +76 -76
- package/lib/cjs/ui/Slider.d.ts +28 -28
- package/lib/cjs/ui/Slider.d.ts.map +1 -1
- package/lib/cjs/ui/Slider.js +42 -42
- package/lib/cjs/ui/TextBox.d.ts +32 -32
- package/lib/cjs/ui/TextBox.d.ts.map +1 -1
- package/lib/cjs/ui/TextBox.js +56 -56
- package/lib/cjs/widgets/DiagnosticsPanel.d.ts +37 -37
- package/lib/cjs/widgets/DiagnosticsPanel.js +81 -81
- package/lib/cjs/widgets/FpsTracker.d.ts +19 -19
- package/lib/cjs/widgets/FpsTracker.js +56 -56
- package/lib/cjs/widgets/GpuProfiler.d.ts +16 -16
- package/lib/cjs/widgets/GpuProfiler.js +192 -192
- package/lib/cjs/widgets/KeyinField.d.ts +61 -61
- package/lib/cjs/widgets/KeyinField.js +186 -187
- package/lib/cjs/widgets/KeyinField.js.map +1 -1
- package/lib/cjs/widgets/MemoryTracker.d.ts +27 -27
- package/lib/cjs/widgets/MemoryTracker.js +242 -243
- package/lib/cjs/widgets/MemoryTracker.js.map +1 -1
- package/lib/cjs/widgets/RenderCommandBreakdown.d.ts +15 -15
- package/lib/cjs/widgets/RenderCommandBreakdown.js +67 -68
- package/lib/cjs/widgets/RenderCommandBreakdown.js.map +1 -1
- package/lib/cjs/widgets/TileMemoryBreakdown.d.ts +30 -30
- package/lib/cjs/widgets/TileMemoryBreakdown.js +203 -204
- package/lib/cjs/widgets/TileMemoryBreakdown.js.map +1 -1
- package/lib/cjs/widgets/TileStatisticsTracker.d.ts +21 -21
- package/lib/cjs/widgets/TileStatisticsTracker.d.ts.map +1 -1
- package/lib/cjs/widgets/TileStatisticsTracker.js +144 -142
- package/lib/cjs/widgets/TileStatisticsTracker.js.map +1 -1
- package/lib/cjs/widgets/ToolSettingsTracker.d.ts +9 -9
- package/lib/cjs/widgets/ToolSettingsTracker.js +211 -211
- package/lib/cjs/widgets/ToolSettingsTracker.js.map +1 -1
- package/lib/esm/ClipboardUtilities.d.ts +8 -8
- package/lib/esm/ClipboardUtilities.js +22 -22
- package/lib/esm/FrontEndDevTools.d.ts +19 -19
- package/lib/esm/FrontEndDevTools.js +218 -217
- package/lib/esm/FrontEndDevTools.js.map +1 -1
- package/lib/esm/effects/Convolution.d.ts +68 -68
- package/lib/esm/effects/Convolution.js +144 -138
- package/lib/esm/effects/Convolution.js.map +1 -1
- package/lib/esm/effects/EffectTools.d.ts +33 -33
- package/lib/esm/effects/EffectTools.js +63 -62
- package/lib/esm/effects/EffectTools.js.map +1 -1
- package/lib/esm/effects/Explosion.d.ts +12 -12
- package/lib/esm/effects/Explosion.js +165 -164
- package/lib/esm/effects/Explosion.js.map +1 -1
- package/lib/esm/effects/FlipImage.d.ts +30 -30
- package/lib/esm/effects/FlipImage.js +76 -74
- package/lib/esm/effects/FlipImage.js.map +1 -1
- package/lib/esm/effects/LensDistortion.d.ts +34 -34
- package/lib/esm/effects/LensDistortion.js +85 -83
- package/lib/esm/effects/LensDistortion.js.map +1 -1
- package/lib/esm/effects/Random.d.ts +24 -24
- package/lib/esm/effects/Random.js +41 -41
- package/lib/esm/effects/Saturation.d.ts +30 -30
- package/lib/esm/effects/Saturation.js +56 -54
- package/lib/esm/effects/Saturation.js.map +1 -1
- package/lib/esm/effects/Snow.d.ts +76 -76
- package/lib/esm/effects/Snow.js +184 -182
- package/lib/esm/effects/Snow.js.map +1 -1
- package/lib/esm/effects/Vignette.d.ts +39 -39
- package/lib/esm/effects/Vignette.js +76 -74
- package/lib/esm/effects/Vignette.js.map +1 -1
- package/lib/esm/frontend-devtools.d.ts +82 -82
- package/lib/esm/frontend-devtools.js +86 -86
- package/lib/esm/tools/AnimationIntervalTool.d.ts +15 -15
- package/lib/esm/tools/AnimationIntervalTool.js +27 -26
- package/lib/esm/tools/AnimationIntervalTool.js.map +1 -1
- package/lib/esm/tools/ChangeUnitsTool.d.ts +15 -15
- package/lib/esm/tools/ChangeUnitsTool.js +38 -37
- package/lib/esm/tools/ChangeUnitsTool.js.map +1 -1
- package/lib/esm/tools/ClipTools.d.ts +67 -67
- package/lib/esm/tools/ClipTools.js +158 -158
- package/lib/esm/tools/ClipTools.js.map +1 -1
- package/lib/esm/tools/DisplayStyleTools.d.ts +145 -145
- package/lib/esm/tools/DisplayStyleTools.js +364 -356
- package/lib/esm/tools/DisplayStyleTools.js.map +1 -1
- package/lib/esm/tools/EmphasizeElementsTool.d.ts +60 -60
- package/lib/esm/tools/EmphasizeElementsTool.js +150 -145
- package/lib/esm/tools/EmphasizeElementsTool.js.map +1 -1
- package/lib/esm/tools/FrustumDecoration.d.ts +57 -57
- package/lib/esm/tools/FrustumDecoration.js +370 -367
- package/lib/esm/tools/FrustumDecoration.js.map +1 -1
- package/lib/esm/tools/InspectElementTool.d.ts +42 -42
- package/lib/esm/tools/InspectElementTool.js +195 -194
- package/lib/esm/tools/InspectElementTool.js.map +1 -1
- package/lib/esm/tools/MapLayerTool.d.ts +264 -264
- package/lib/esm/tools/MapLayerTool.d.ts.map +1 -1
- package/lib/esm/tools/MapLayerTool.js +506 -485
- package/lib/esm/tools/MapLayerTool.js.map +1 -1
- package/lib/esm/tools/MeasureTileLoadTime.d.ts +12 -12
- package/lib/esm/tools/MeasureTileLoadTime.js +60 -59
- package/lib/esm/tools/MeasureTileLoadTime.js.map +1 -1
- package/lib/esm/tools/ModelAppearanceTools.d.ts +86 -86
- package/lib/esm/tools/ModelAppearanceTools.js +180 -172
- package/lib/esm/tools/ModelAppearanceTools.js.map +1 -1
- package/lib/esm/tools/PlanProjectionTools.d.ts +40 -40
- package/lib/esm/tools/PlanProjectionTools.js +146 -143
- package/lib/esm/tools/PlanProjectionTools.js.map +1 -1
- package/lib/esm/tools/PlanarMaskTools.d.ts +182 -182
- package/lib/esm/tools/PlanarMaskTools.js +387 -377
- package/lib/esm/tools/PlanarMaskTools.js.map +1 -1
- package/lib/esm/tools/ProjectExtents.d.ts +41 -41
- package/lib/esm/tools/ProjectExtents.js +105 -104
- package/lib/esm/tools/ProjectExtents.js.map +1 -1
- package/lib/esm/tools/RealityModelTools.d.ts +116 -116
- package/lib/esm/tools/RealityModelTools.js +278 -268
- package/lib/esm/tools/RealityModelTools.js.map +1 -1
- package/lib/esm/tools/RealityTransitionTool.d.ts +25 -25
- package/lib/esm/tools/RealityTransitionTool.js +112 -112
- package/lib/esm/tools/RealityTransitionTool.js.map +1 -1
- package/lib/esm/tools/RenderSystemTools.d.ts +38 -38
- package/lib/esm/tools/RenderSystemTools.js +65 -63
- package/lib/esm/tools/RenderSystemTools.js.map +1 -1
- package/lib/esm/tools/RenderTargetTools.d.ts +107 -107
- package/lib/esm/tools/RenderTargetTools.d.ts.map +1 -1
- package/lib/esm/tools/RenderTargetTools.js +169 -159
- package/lib/esm/tools/RenderTargetTools.js.map +1 -1
- package/lib/esm/tools/ReportWebGLCompatibilityTool.d.ts +11 -11
- package/lib/esm/tools/ReportWebGLCompatibilityTool.js +27 -26
- package/lib/esm/tools/ReportWebGLCompatibilityTool.js.map +1 -1
- package/lib/esm/tools/SavedViews.d.ts +46 -46
- package/lib/esm/tools/SavedViews.js +131 -128
- package/lib/esm/tools/SavedViews.js.map +1 -1
- package/lib/esm/tools/ScheduleScriptTools.d.ts +37 -37
- package/lib/esm/tools/ScheduleScriptTools.js +154 -153
- package/lib/esm/tools/ScheduleScriptTools.js.map +1 -1
- package/lib/esm/tools/SelectionTools.d.ts +28 -28
- package/lib/esm/tools/SelectionTools.js +84 -82
- package/lib/esm/tools/SelectionTools.js.map +1 -1
- package/lib/esm/tools/SetGpuMemoryLimitTool.d.ts +15 -15
- package/lib/esm/tools/SetGpuMemoryLimitTool.js +30 -29
- package/lib/esm/tools/SetGpuMemoryLimitTool.js.map +1 -1
- package/lib/esm/tools/SourceAspectIdTools.d.ts +40 -40
- package/lib/esm/tools/SourceAspectIdTools.js +81 -80
- package/lib/esm/tools/SourceAspectIdTools.js.map +1 -1
- package/lib/esm/tools/TileRequestDecoration.d.ts +12 -12
- package/lib/esm/tools/TileRequestDecoration.js +80 -79
- package/lib/esm/tools/TileRequestDecoration.js.map +1 -1
- package/lib/esm/tools/TileTreeBoundsDecoration.d.ts +11 -11
- package/lib/esm/tools/TileTreeBoundsDecoration.js +71 -70
- package/lib/esm/tools/TileTreeBoundsDecoration.js.map +1 -1
- package/lib/esm/tools/ToolTipProvider.d.ts +15 -15
- package/lib/esm/tools/ToolTipProvider.js +63 -62
- package/lib/esm/tools/ToolTipProvider.js.map +1 -1
- package/lib/esm/tools/ViewportTools.d.ts +218 -218
- package/lib/esm/tools/ViewportTools.d.ts.map +1 -1
- package/lib/esm/tools/ViewportTools.js +511 -492
- package/lib/esm/tools/ViewportTools.js.map +1 -1
- package/lib/esm/tools/parseArgs.d.ts +23 -23
- package/lib/esm/tools/parseArgs.js +47 -47
- package/lib/esm/tools/parseBoolean.d.ts +8 -8
- package/lib/esm/tools/parseBoolean.js +22 -22
- package/lib/esm/tools/parseToggle.d.ts +8 -8
- package/lib/esm/tools/parseToggle.js +21 -21
- package/lib/esm/ui/Button.d.ts +29 -29
- package/lib/esm/ui/Button.d.ts.map +1 -1
- package/lib/esm/ui/Button.js +22 -22
- package/lib/esm/ui/CheckBox.d.ts +23 -23
- package/lib/esm/ui/CheckBox.d.ts.map +1 -1
- package/lib/esm/ui/CheckBox.js +23 -23
- package/lib/esm/ui/ColorInput.d.ts +27 -27
- package/lib/esm/ui/ColorInput.d.ts.map +1 -1
- package/lib/esm/ui/ColorInput.js +48 -48
- package/lib/esm/ui/ComboBox.d.ts +28 -28
- package/lib/esm/ui/ComboBox.d.ts.map +1 -1
- package/lib/esm/ui/ComboBox.js +38 -38
- package/lib/esm/ui/DataList.d.ts +27 -27
- package/lib/esm/ui/DataList.d.ts.map +1 -1
- package/lib/esm/ui/DataList.js +34 -34
- package/lib/esm/ui/NestedMenu.d.ts +19 -19
- package/lib/esm/ui/NestedMenu.d.ts.map +1 -1
- package/lib/esm/ui/NestedMenu.js +42 -42
- package/lib/esm/ui/NumericInput.d.ts +35 -35
- package/lib/esm/ui/NumericInput.d.ts.map +1 -1
- package/lib/esm/ui/NumericInput.js +56 -56
- package/lib/esm/ui/RadioBox.d.ts +29 -29
- package/lib/esm/ui/RadioBox.d.ts.map +1 -1
- package/lib/esm/ui/RadioBox.js +72 -72
- package/lib/esm/ui/Slider.d.ts +28 -28
- package/lib/esm/ui/Slider.d.ts.map +1 -1
- package/lib/esm/ui/Slider.js +38 -38
- package/lib/esm/ui/TextBox.d.ts +32 -32
- package/lib/esm/ui/TextBox.d.ts.map +1 -1
- package/lib/esm/ui/TextBox.js +52 -52
- package/lib/esm/widgets/DiagnosticsPanel.d.ts +37 -37
- package/lib/esm/widgets/DiagnosticsPanel.js +77 -77
- package/lib/esm/widgets/FpsTracker.d.ts +19 -19
- package/lib/esm/widgets/FpsTracker.js +52 -52
- package/lib/esm/widgets/GpuProfiler.d.ts +16 -16
- package/lib/esm/widgets/GpuProfiler.js +188 -188
- package/lib/esm/widgets/KeyinField.d.ts +61 -61
- package/lib/esm/widgets/KeyinField.js +182 -183
- package/lib/esm/widgets/KeyinField.js.map +1 -1
- package/lib/esm/widgets/MemoryTracker.d.ts +27 -27
- package/lib/esm/widgets/MemoryTracker.js +237 -238
- package/lib/esm/widgets/MemoryTracker.js.map +1 -1
- package/lib/esm/widgets/RenderCommandBreakdown.d.ts +15 -15
- package/lib/esm/widgets/RenderCommandBreakdown.js +63 -64
- package/lib/esm/widgets/RenderCommandBreakdown.js.map +1 -1
- package/lib/esm/widgets/TileMemoryBreakdown.d.ts +30 -30
- package/lib/esm/widgets/TileMemoryBreakdown.js +199 -200
- package/lib/esm/widgets/TileMemoryBreakdown.js.map +1 -1
- package/lib/esm/widgets/TileStatisticsTracker.d.ts +21 -21
- package/lib/esm/widgets/TileStatisticsTracker.d.ts.map +1 -1
- package/lib/esm/widgets/TileStatisticsTracker.js +140 -138
- package/lib/esm/widgets/TileStatisticsTracker.js.map +1 -1
- package/lib/esm/widgets/ToolSettingsTracker.d.ts +9 -9
- package/lib/esm/widgets/ToolSettingsTracker.js +208 -207
- package/lib/esm/widgets/ToolSettingsTracker.js.map +1 -1
- package/package.json +14 -14
|
@@ -1,269 +1,279 @@
|
|
|
1
|
-
/*---------------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
|
-
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
|
-
*--------------------------------------------------------------------------------------------*/
|
|
5
|
-
/** @packageDocumentation
|
|
6
|
-
* @module Tools
|
|
7
|
-
*/
|
|
8
|
-
import { FeatureAppearance } from "@itwin/core-common";
|
|
9
|
-
import { getCesiumAssetUrl, IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from "@itwin/core-frontend";
|
|
10
|
-
import { copyStringToClipboard } from "../ClipboardUtilities";
|
|
11
|
-
import { parseBoolean } from "./parseBoolean";
|
|
12
|
-
import { parseToggle } from "./parseToggle";
|
|
13
|
-
/** This tool attaches a specified reality model.
|
|
14
|
-
* @beta
|
|
15
|
-
*/
|
|
16
|
-
|
|
17
|
-
static get minArgs() { return 1; }
|
|
18
|
-
static get maxArgs() { return 1; }
|
|
19
|
-
/** This method runs the tool, attaching a specified reality model.
|
|
20
|
-
* @param data a [[ContextRealityModelProps]] JSON representation
|
|
21
|
-
*/
|
|
22
|
-
async run(data) {
|
|
23
|
-
const props = JSON.parse(data);
|
|
24
|
-
const vp = IModelApp.viewManager.selectedView;
|
|
25
|
-
if (vp === undefined)
|
|
26
|
-
return false;
|
|
27
|
-
if (props === undefined || props.tilesetUrl === undefined) {
|
|
28
|
-
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, `Properties ${props} are not valid`));
|
|
29
|
-
}
|
|
30
|
-
vp.displayStyle.attachRealityModel(props);
|
|
31
|
-
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `Reality Model ${props.tilesetUrl} attached`));
|
|
32
|
-
return true;
|
|
33
|
-
}
|
|
34
|
-
/** Executes this tool's run method with args[0] containing `data`.
|
|
35
|
-
* @see [[run]]
|
|
36
|
-
*/
|
|
37
|
-
async parseAndRun(...args) {
|
|
38
|
-
return this.run(args[0]);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
AttachRealityModelTool.toolId = "AttachRealityModelTool";
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
static get
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
const
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
export
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
return
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
IModelApp.
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
}
|
|
268
|
-
|
|
1
|
+
/*---------------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
3
|
+
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
4
|
+
*--------------------------------------------------------------------------------------------*/
|
|
5
|
+
/** @packageDocumentation
|
|
6
|
+
* @module Tools
|
|
7
|
+
*/
|
|
8
|
+
import { FeatureAppearance } from "@itwin/core-common";
|
|
9
|
+
import { getCesiumAssetUrl, IModelApp, NotifyMessageDetails, OutputMessagePriority, Tool } from "@itwin/core-frontend";
|
|
10
|
+
import { copyStringToClipboard } from "../ClipboardUtilities";
|
|
11
|
+
import { parseBoolean } from "./parseBoolean";
|
|
12
|
+
import { parseToggle } from "./parseToggle";
|
|
13
|
+
/** This tool attaches a specified reality model.
|
|
14
|
+
* @beta
|
|
15
|
+
*/
|
|
16
|
+
class AttachRealityModelTool extends Tool {
|
|
17
|
+
static get minArgs() { return 1; }
|
|
18
|
+
static get maxArgs() { return 1; }
|
|
19
|
+
/** This method runs the tool, attaching a specified reality model.
|
|
20
|
+
* @param data a [[ContextRealityModelProps]] JSON representation
|
|
21
|
+
*/
|
|
22
|
+
async run(data) {
|
|
23
|
+
const props = JSON.parse(data);
|
|
24
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
25
|
+
if (vp === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (props === undefined || props.tilesetUrl === undefined) {
|
|
28
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Error, `Properties ${props} are not valid`));
|
|
29
|
+
}
|
|
30
|
+
vp.displayStyle.attachRealityModel(props);
|
|
31
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `Reality Model ${props.tilesetUrl} attached`));
|
|
32
|
+
return true;
|
|
33
|
+
}
|
|
34
|
+
/** Executes this tool's run method with args[0] containing `data`.
|
|
35
|
+
* @see [[run]]
|
|
36
|
+
*/
|
|
37
|
+
async parseAndRun(...args) {
|
|
38
|
+
return this.run(args[0]);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
AttachRealityModelTool.toolId = "AttachRealityModelTool";
|
|
42
|
+
export { AttachRealityModelTool };
|
|
43
|
+
/** This tool saves a reality model's JSON representation to the system clipboard.
|
|
44
|
+
* @beta */
|
|
45
|
+
class SaveRealityModelTool extends Tool {
|
|
46
|
+
static get minArgs() { return 0; }
|
|
47
|
+
static get maxArgs() { return 1; }
|
|
48
|
+
/** This method runs the tool, saving a reality model's JSON representation to the system clipboard.
|
|
49
|
+
* @param name the name of the reality model to copy; if undefined, copy the last found reality model
|
|
50
|
+
*/
|
|
51
|
+
async run(name) {
|
|
52
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
53
|
+
if (vp === undefined)
|
|
54
|
+
return false;
|
|
55
|
+
vp.displayStyle.forEachRealityModel((realityModel) => {
|
|
56
|
+
if (name === undefined || realityModel.name === name) {
|
|
57
|
+
copyStringToClipboard(JSON.stringify(realityModel.toJSON()));
|
|
58
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `Reality Model ${realityModel.name} copied to clipboard`));
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
return true;
|
|
62
|
+
}
|
|
63
|
+
/** Executes this tool's run method with args[0] containing `name`.
|
|
64
|
+
* @see [[run]]
|
|
65
|
+
*/
|
|
66
|
+
async parseAndRun(...args) {
|
|
67
|
+
return this.run(args.length > 0 ? args[0] : undefined);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
SaveRealityModelTool.toolId = "SaveRealityModelTool";
|
|
71
|
+
export { SaveRealityModelTool };
|
|
72
|
+
function changeRealityModelAppearanceOverrides(vp, overrides, index) {
|
|
73
|
+
if (index < 0) {
|
|
74
|
+
for (const model of vp.displayStyle.settings.contextRealityModels.models)
|
|
75
|
+
model.appearanceOverrides = model.appearanceOverrides ? model.appearanceOverrides.clone(overrides) : FeatureAppearance.fromJSON(overrides);
|
|
76
|
+
return vp.displayStyle.settings.contextRealityModels.models.length > 0;
|
|
77
|
+
}
|
|
78
|
+
else {
|
|
79
|
+
const model = vp.displayStyle.settings.contextRealityModels.models[index];
|
|
80
|
+
if (!model)
|
|
81
|
+
return false;
|
|
82
|
+
model.appearanceOverrides = model.appearanceOverrides ? model.appearanceOverrides.clone(overrides) : FeatureAppearance.fromJSON(overrides);
|
|
83
|
+
return true;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
function appearanceChangedString(index) {
|
|
87
|
+
return index < 0 ? `All Reality Models` : `Reality Model at Index: ${index}`;
|
|
88
|
+
}
|
|
89
|
+
/** Set reality model appearance override for transparency in display style.
|
|
90
|
+
* @beta
|
|
91
|
+
*/
|
|
92
|
+
class SetRealityModelTransparencyTool extends Tool {
|
|
93
|
+
static get minArgs() { return 1; }
|
|
94
|
+
static get maxArgs() { return 2; }
|
|
95
|
+
async run(transparency, index) {
|
|
96
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
97
|
+
if (vp === undefined)
|
|
98
|
+
return false;
|
|
99
|
+
const changed = changeRealityModelAppearanceOverrides(vp, { transparency }, index);
|
|
100
|
+
if (changed)
|
|
101
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `${appearanceChangedString(index)} set to transparency: ${transparency}`));
|
|
102
|
+
return true;
|
|
103
|
+
}
|
|
104
|
+
async parseAndRun(...args) {
|
|
105
|
+
return this.run(parseFloat(args[0]), args.length > 1 ? parseInt(args[1], 10) : -1);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
SetRealityModelTransparencyTool.toolId = "SetRealityModelTransparencyTool";
|
|
109
|
+
export { SetRealityModelTransparencyTool };
|
|
110
|
+
/** Set reality model appearance override for locatable in display style.
|
|
111
|
+
* @beta
|
|
112
|
+
*/
|
|
113
|
+
class SetRealityModelLocateTool extends Tool {
|
|
114
|
+
static get minArgs() { return 1; }
|
|
115
|
+
static get maxArgs() { return 2; }
|
|
116
|
+
async run(locate, index) {
|
|
117
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
118
|
+
if (vp === undefined)
|
|
119
|
+
return false;
|
|
120
|
+
const nonLocatable = locate ? undefined : true;
|
|
121
|
+
const changed = changeRealityModelAppearanceOverrides(vp, { nonLocatable }, index);
|
|
122
|
+
if (changed)
|
|
123
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `${appearanceChangedString(index)} set to locate: ${locate}`));
|
|
124
|
+
return true;
|
|
125
|
+
}
|
|
126
|
+
async parseAndRun(...args) {
|
|
127
|
+
const locate = parseBoolean(args[0]);
|
|
128
|
+
return locate === undefined ? false : this.run(locate, args.length > 1 ? parseInt(args[1], 10) : -1);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
SetRealityModelLocateTool.toolId = "SetRealityModelLocateTool";
|
|
132
|
+
export { SetRealityModelLocateTool };
|
|
133
|
+
/** Set reality model appearance override for emphasized in display style.
|
|
134
|
+
* @beta
|
|
135
|
+
*/
|
|
136
|
+
class SetRealityModelEmphasizedTool extends Tool {
|
|
137
|
+
static get minArgs() { return 1; }
|
|
138
|
+
static get maxArgs() { return 2; }
|
|
139
|
+
async run(emphasized, index) {
|
|
140
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
141
|
+
if (vp === undefined)
|
|
142
|
+
return false;
|
|
143
|
+
const changed = changeRealityModelAppearanceOverrides(vp, { emphasized }, index);
|
|
144
|
+
if (changed)
|
|
145
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `${appearanceChangedString(index)} set to emphasized: ${emphasized}`));
|
|
146
|
+
return true;
|
|
147
|
+
}
|
|
148
|
+
async parseAndRun(...args) {
|
|
149
|
+
const emphasized = parseBoolean(args[0]);
|
|
150
|
+
return emphasized === undefined ? false : this.run(emphasized ? true : undefined, args.length > 1 ? parseInt(args[1], 10) : -1);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
SetRealityModelEmphasizedTool.toolId = "SetRealityModelEmphasizedTool";
|
|
154
|
+
export { SetRealityModelEmphasizedTool };
|
|
155
|
+
/** Detach reality model from display style.
|
|
156
|
+
* @beta
|
|
157
|
+
*/
|
|
158
|
+
class DetachRealityModelTool extends Tool {
|
|
159
|
+
static get minArgs() { return 0; }
|
|
160
|
+
static get maxArgs() { return 1; }
|
|
161
|
+
async run(index) {
|
|
162
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
163
|
+
if (vp === undefined)
|
|
164
|
+
return false;
|
|
165
|
+
if (index < 0) {
|
|
166
|
+
vp.displayStyle.settings.contextRealityModels.models.forEach((model) => vp.displayStyle.settings.contextRealityModels.delete(model));
|
|
167
|
+
return true;
|
|
168
|
+
}
|
|
169
|
+
else {
|
|
170
|
+
const model = vp.displayStyle.settings.contextRealityModels.models[index];
|
|
171
|
+
if (!model)
|
|
172
|
+
return false;
|
|
173
|
+
vp.displayStyle.settings.contextRealityModels.delete(model);
|
|
174
|
+
return true;
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
async parseAndRun(...args) {
|
|
178
|
+
return this.run(args.length > 0 ? parseInt(args[0], 10) : -1);
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
DetachRealityModelTool.toolId = "ViewportDetachRealityModel";
|
|
182
|
+
export { DetachRealityModelTool };
|
|
183
|
+
/** Set reality model appearance override for color in display style.
|
|
184
|
+
* @beta
|
|
185
|
+
*/
|
|
186
|
+
class SetRealityModelColorTool extends Tool {
|
|
187
|
+
static get minArgs() { return 3; }
|
|
188
|
+
static get maxArgs() { return 4; }
|
|
189
|
+
async run(rgb, index) {
|
|
190
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
191
|
+
if (vp === undefined)
|
|
192
|
+
return false;
|
|
193
|
+
const changed = changeRealityModelAppearanceOverrides(vp, { rgb }, index);
|
|
194
|
+
if (changed)
|
|
195
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `${appearanceChangedString(index)} set to RGB color: (${rgb.r}, ${rgb.g}, ${rgb.b})`));
|
|
196
|
+
return true;
|
|
197
|
+
}
|
|
198
|
+
async parseAndRun(...args) {
|
|
199
|
+
return this.run({ r: parseFloat(args[0]), g: parseFloat(args[1]), b: parseFloat(args[2]) }, args.length > 3 ? parseInt(args[3], 10) : -1);
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
SetRealityModelColorTool.toolId = "SetRealityModelColorTool";
|
|
203
|
+
export { SetRealityModelColorTool };
|
|
204
|
+
/** Clear reality model appearance override in display style.
|
|
205
|
+
* @beta
|
|
206
|
+
*/
|
|
207
|
+
class ClearRealityModelAppearanceOverrides extends Tool {
|
|
208
|
+
static get minArgs() { return 0; }
|
|
209
|
+
static get maxArgs() { return 1; }
|
|
210
|
+
async run(index) {
|
|
211
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
212
|
+
if (!vp)
|
|
213
|
+
return false;
|
|
214
|
+
const model = vp.displayStyle.settings.contextRealityModels.models[index];
|
|
215
|
+
if (!model)
|
|
216
|
+
return false;
|
|
217
|
+
model.appearanceOverrides = undefined;
|
|
218
|
+
return true;
|
|
219
|
+
}
|
|
220
|
+
async parseAndRun(...args) {
|
|
221
|
+
return this.run(args[0] === undefined ? -1 : parseInt(args[0], 10));
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
ClearRealityModelAppearanceOverrides.toolId = "ClearRealityModelAppearanceOverrides";
|
|
225
|
+
export { ClearRealityModelAppearanceOverrides };
|
|
226
|
+
/** Attach a cesium asset from the Ion ID and key.
|
|
227
|
+
* @beta
|
|
228
|
+
*/
|
|
229
|
+
class AttachCesiumAssetTool extends Tool {
|
|
230
|
+
static get minArgs() { return 1; }
|
|
231
|
+
static get maxArgs() { return 2; }
|
|
232
|
+
async run(assetId, requestKey) {
|
|
233
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
234
|
+
if (vp === undefined)
|
|
235
|
+
return false;
|
|
236
|
+
// attach using getCesiumAssetUrl
|
|
237
|
+
const accessKey = requestKey ? requestKey : IModelApp.tileAdmin.cesiumIonKey ? IModelApp.tileAdmin.cesiumIonKey : "";
|
|
238
|
+
const props = {
|
|
239
|
+
tilesetUrl: getCesiumAssetUrl(assetId, accessKey),
|
|
240
|
+
};
|
|
241
|
+
// Alternative new way to attach using rdSourceKey
|
|
242
|
+
// const rdSourceKey = RealityDataSource.createCesiumIonAssetKey(assetId, accessKey);
|
|
243
|
+
// const props: ContextRealityModelProps = { rdSourceKey, tilesetUrl: getCesiumAssetUrl(assetId, accessKey) };
|
|
244
|
+
vp.displayStyle.attachRealityModel(props);
|
|
245
|
+
IModelApp.notifications.outputMessage(new NotifyMessageDetails(OutputMessagePriority.Info, `Cesium Asset #${assetId} attached`));
|
|
246
|
+
return true;
|
|
247
|
+
}
|
|
248
|
+
async parseAndRun(...args) {
|
|
249
|
+
const assetId = parseInt(args[0], 10);
|
|
250
|
+
return Number.isNaN(assetId) ? false : this.run(assetId, args[1]);
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
AttachCesiumAssetTool.toolId = "AttachCesiumAssetTool";
|
|
254
|
+
export { AttachCesiumAssetTool };
|
|
255
|
+
/** Turn on/off display of OpenStreetMap buildings
|
|
256
|
+
* @beta
|
|
257
|
+
*/
|
|
258
|
+
class ToggleOSMBuildingDisplay extends Tool {
|
|
259
|
+
static get minArgs() { return 0; }
|
|
260
|
+
static get maxArgs() { return 2; }
|
|
261
|
+
async run(onOff, transparency) {
|
|
262
|
+
const vp = IModelApp.viewManager.selectedView;
|
|
263
|
+
if (vp === undefined)
|
|
264
|
+
return false;
|
|
265
|
+
if (onOff === undefined)
|
|
266
|
+
onOff = undefined === vp.displayStyle.getOSMBuildingRealityModel(); // Toggle current state.
|
|
267
|
+
const appearanceOverrides = (transparency !== undefined && transparency > 0 && transparency < 1) ? FeatureAppearance.fromJSON({ transparency }) : undefined;
|
|
268
|
+
vp.displayStyle.setOSMBuildingDisplay({ onOff, appearanceOverrides });
|
|
269
|
+
return true;
|
|
270
|
+
}
|
|
271
|
+
async parseAndRun(...args) {
|
|
272
|
+
const toggle = parseToggle(args[0]);
|
|
273
|
+
const transparency = args.length > 0 ? parseFloat(args[1]) : undefined;
|
|
274
|
+
return typeof toggle === "string" ? false : this.run(toggle, transparency);
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
ToggleOSMBuildingDisplay.toolId = "SetBuildingDisplay";
|
|
278
|
+
export { ToggleOSMBuildingDisplay };
|
|
269
279
|
//# sourceMappingURL=RealityModelTools.js.map
|