@itwin/ecschema-rpcinterface-tests 3.6.0-dev.62 → 3.6.0-dev.66
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/lib/dist/_07c5.bundled-tests.js.map +1 -1
- package/lib/dist/bundled-tests.js +181 -120
- package/lib/dist/bundled-tests.js.map +1 -1
- package/lib/dist/core_frontend_lib_esm_ApproximateTerrainHeightsProps_js.bundled-tests.js.map +1 -1
- package/lib/dist/object-storage.bundled-tests.js.map +1 -1
- package/lib/dist/vendors-common_temp_node_modules_pnpm_itwin_object-storage-azure_1_4_0_node_modules_itwin_obj-3576c6.bundled-tests.js.map +1 -1
- package/lib/dist/vendors-common_temp_node_modules_pnpm_loaders_gl_draco_3_2_13_node_modules_loaders_gl_draco_d-e0d984.bundled-tests.js.map +1 -1
- package/lib/dist/vendors-common_temp_node_modules_pnpm_reflect-metadata_0_1_13_node_modules_reflect-metadata_R-610cb3.bundled-tests.js.map +1 -1
- package/package.json +16 -16
|
@@ -46532,6 +46532,8 @@ var DbResult;
|
|
|
46532
46532
|
DbResult[DbResult["BE_SQLITE_ERROR_CouldNotAcquireLocksOrCodes"] = 352321546] = "BE_SQLITE_ERROR_CouldNotAcquireLocksOrCodes";
|
|
46533
46533
|
/** Recommended that the schemas found in the database be upgraded */
|
|
46534
46534
|
DbResult[DbResult["BE_SQLITE_ERROR_SchemaUpgradeRecommended"] = 369098762] = "BE_SQLITE_ERROR_SchemaUpgradeRecommended";
|
|
46535
|
+
/** schema update require data transform */
|
|
46536
|
+
DbResult[DbResult["BE_SQLITE_ERROR_DataTransformRequired"] = 385875978] = "BE_SQLITE_ERROR_DataTransformRequired";
|
|
46535
46537
|
DbResult[DbResult["BE_SQLITE_LOCKED_SHAREDCACHE"] = 262] = "BE_SQLITE_LOCKED_SHAREDCACHE";
|
|
46536
46538
|
DbResult[DbResult["BE_SQLITE_BUSY_RECOVERY"] = 261] = "BE_SQLITE_BUSY_RECOVERY";
|
|
46537
46539
|
DbResult[DbResult["BE_SQLITE_CANTOPEN_NOTEMPDIR"] = 270] = "BE_SQLITE_CANTOPEN_NOTEMPDIR";
|
|
@@ -47052,6 +47054,7 @@ class BentleyError extends Error {
|
|
|
47052
47054
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_IOERR_SHMMAP: return "BE_SQLITE_IOERR_SHMMAP";
|
|
47053
47055
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_IOERR_SEEK: return "BE_SQLITE_IOERR_SEEK";
|
|
47054
47056
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_IOERR_DELETE_NOENT: return "BE_SQLITE_IOERR_DELETE_NOENT";
|
|
47057
|
+
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_ERROR_DataTransformRequired: return "Schema update require to transform data";
|
|
47055
47058
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_ERROR_FileExists: return "File Exists";
|
|
47056
47059
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_ERROR_AlreadyOpen: return "Already Open";
|
|
47057
47060
|
case _BeSQLite__WEBPACK_IMPORTED_MODULE_0__.DbResult.BE_SQLITE_ERROR_NoPropertyTable: return "No Property Table";
|
|
@@ -48985,6 +48988,12 @@ class TransientIdSequence {
|
|
|
48985
48988
|
getNext() {
|
|
48986
48989
|
return Id64.fromLocalAndBriefcaseIds(++this._localId, 0xffffff);
|
|
48987
48990
|
}
|
|
48991
|
+
/** Preview the transient Id64String that will be returned by the next call to [[getNext]].
|
|
48992
|
+
* This is primarily useful for tests.
|
|
48993
|
+
*/
|
|
48994
|
+
peekNext() {
|
|
48995
|
+
return Id64.fromLocalAndBriefcaseIds(this._localId + 1, 0xffffff);
|
|
48996
|
+
}
|
|
48988
48997
|
}
|
|
48989
48998
|
/**
|
|
48990
48999
|
* The Guid namespace provides facilities for working with GUID strings using the "8-4-4-4-12" pattern.
|
|
@@ -55842,13 +55851,8 @@ class ContextRealityModel {
|
|
|
55842
55851
|
* @public
|
|
55843
55852
|
*/
|
|
55844
55853
|
class ContextRealityModels {
|
|
55845
|
-
/**
|
|
55846
|
-
|
|
55847
|
-
* to become out of sync with the JSON representation.
|
|
55848
|
-
* @param container The object that holds the JSON representation of the list.
|
|
55849
|
-
* @param createContextRealityModel Optional function used to instantiate ContextRealityModels added to the list.
|
|
55850
|
-
*/
|
|
55851
|
-
constructor(container, createContextRealityModel) {
|
|
55854
|
+
/** @internal */
|
|
55855
|
+
constructor(arg0, createContextRealityModel) {
|
|
55852
55856
|
this._models = [];
|
|
55853
55857
|
/** Event dispatched just before [[ContextRealityModel.planarClipMaskSettings]] is modified for one of the reality models. */
|
|
55854
55858
|
this.onPlanarClipMaskChanged = new _itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.BeEvent();
|
|
@@ -55860,9 +55864,29 @@ class ContextRealityModels {
|
|
|
55860
55864
|
this.onDisplaySettingsChanged = new _itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.BeEvent();
|
|
55861
55865
|
/** Event dispatched when a model is [[add]]ed, [[delete]]d, [[replace]]d, or [[update]]d. */
|
|
55862
55866
|
this.onChanged = new _itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.BeEvent();
|
|
55867
|
+
let container;
|
|
55868
|
+
let defer = false;
|
|
55869
|
+
if (arg0.container) {
|
|
55870
|
+
container = arg0.container;
|
|
55871
|
+
createContextRealityModel = arg0.createContextRealityModel;
|
|
55872
|
+
defer = true === arg0.deferPopulating;
|
|
55873
|
+
}
|
|
55874
|
+
else {
|
|
55875
|
+
container = arg0;
|
|
55876
|
+
}
|
|
55863
55877
|
this._container = container;
|
|
55864
55878
|
this._createModel = createContextRealityModel !== null && createContextRealityModel !== void 0 ? createContextRealityModel : ((props) => new ContextRealityModel(props));
|
|
55865
|
-
|
|
55879
|
+
if (!defer)
|
|
55880
|
+
this.populate();
|
|
55881
|
+
}
|
|
55882
|
+
/** @internal needs to be invoked after DisplayStyleSettings constructor by DisplayStyleState constructor.*/
|
|
55883
|
+
/** Populate the list of [[models]] from the container that was supplied to the constructor.
|
|
55884
|
+
* This should only be invoked once, and only if [[ContextRealityModelsArgs.deferPopulating]] was specified as `true` when calling the constructor.
|
|
55885
|
+
* @public
|
|
55886
|
+
*/
|
|
55887
|
+
populate() {
|
|
55888
|
+
(0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.assert)(this._models.length === 0, "do not call ContextRealityModels.populate more than once");
|
|
55889
|
+
const models = this._container.contextRealityModels;
|
|
55866
55890
|
if (models)
|
|
55867
55891
|
for (const model of models)
|
|
55868
55892
|
this._models.push(this.createModel(model));
|
|
@@ -56304,7 +56328,11 @@ class DisplayStyleSettings {
|
|
|
56304
56328
|
const settings = _PlanarClipMask__WEBPACK_IMPORTED_MODULE_8__.PlanarClipMaskSettings.fromJSON(props);
|
|
56305
56329
|
return settings.isValid ? settings : undefined;
|
|
56306
56330
|
});
|
|
56307
|
-
this._contextRealityModels = new _ContextRealityModel__WEBPACK_IMPORTED_MODULE_20__.ContextRealityModels(
|
|
56331
|
+
this._contextRealityModels = new _ContextRealityModel__WEBPACK_IMPORTED_MODULE_20__.ContextRealityModels({
|
|
56332
|
+
container: this._json,
|
|
56333
|
+
createContextRealityModel: options === null || options === void 0 ? void 0 : options.createContextRealityModel,
|
|
56334
|
+
deferPopulating: options === null || options === void 0 ? void 0 : options.deferContextRealityModels,
|
|
56335
|
+
});
|
|
56308
56336
|
}
|
|
56309
56337
|
/** Returns true if this is a [[DisplayStyle3dSettings]]. */
|
|
56310
56338
|
is3d() {
|
|
@@ -79494,7 +79522,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
79494
79522
|
/* eslint-disable deprecation/deprecation */
|
|
79495
79523
|
/** An RPC operation control response.
|
|
79496
79524
|
* @public
|
|
79497
|
-
* @deprecated in 3.6. The RPC system will be significantly refactored (or replaced) in version 5.0.
|
|
79498
79525
|
*/
|
|
79499
79526
|
class RpcControlResponse {
|
|
79500
79527
|
constructor() {
|
|
@@ -79503,7 +79530,6 @@ class RpcControlResponse {
|
|
|
79503
79530
|
}
|
|
79504
79531
|
/** A pending RPC operation response.
|
|
79505
79532
|
* @public
|
|
79506
|
-
* @deprecated in 3.6. The RPC system will be significantly refactored (or replaced) in version 5.0.
|
|
79507
79533
|
*/
|
|
79508
79534
|
class RpcPendingResponse extends RpcControlResponse {
|
|
79509
79535
|
/** Constructs a pending response. */
|
|
@@ -79514,7 +79540,6 @@ class RpcPendingResponse extends RpcControlResponse {
|
|
|
79514
79540
|
}
|
|
79515
79541
|
/** A RPC operation response.
|
|
79516
79542
|
* @public
|
|
79517
|
-
* @deprecated in 3.6. The RPC system will be significantly refactored (or replaced) in version 5.0.
|
|
79518
79543
|
*/
|
|
79519
79544
|
class RpcNotFoundResponse extends RpcControlResponse {
|
|
79520
79545
|
constructor() {
|
|
@@ -100677,7 +100702,11 @@ class DisplayStyleState extends _EntityState__WEBPACK_IMPORTED_MODULE_6__.Elemen
|
|
|
100677
100702
|
class DisplayStyle2dState extends DisplayStyleState {
|
|
100678
100703
|
constructor(props, iModel) {
|
|
100679
100704
|
super(props, iModel);
|
|
100680
|
-
this._settings = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_2__.DisplayStyleSettings(this.jsonProperties, {
|
|
100705
|
+
this._settings = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_2__.DisplayStyleSettings(this.jsonProperties, {
|
|
100706
|
+
createContextRealityModel: (modelProps) => this.createRealityModel(modelProps),
|
|
100707
|
+
deferContextRealityModels: true,
|
|
100708
|
+
});
|
|
100709
|
+
this._settings.contextRealityModels.populate();
|
|
100681
100710
|
this.registerSettingsEventListeners();
|
|
100682
100711
|
}
|
|
100683
100712
|
/** @internal */
|
|
@@ -100693,7 +100722,11 @@ class DisplayStyle2dState extends DisplayStyleState {
|
|
|
100693
100722
|
class DisplayStyle3dState extends DisplayStyleState {
|
|
100694
100723
|
constructor(props, iModel, source) {
|
|
100695
100724
|
super(props, iModel, source);
|
|
100696
|
-
this._settings = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_2__.DisplayStyle3dSettings(this.jsonProperties, {
|
|
100725
|
+
this._settings = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_2__.DisplayStyle3dSettings(this.jsonProperties, {
|
|
100726
|
+
createContextRealityModel: (modelProps) => this.createRealityModel(modelProps),
|
|
100727
|
+
deferContextRealityModels: true,
|
|
100728
|
+
});
|
|
100729
|
+
this._settings.contextRealityModels.populate();
|
|
100697
100730
|
this.registerSettingsEventListeners();
|
|
100698
100731
|
}
|
|
100699
100732
|
/** @internal */
|
|
@@ -119360,6 +119393,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
119360
119393
|
/* harmony export */ "OffScreenViewport": () => (/* reexport safe */ _Viewport__WEBPACK_IMPORTED_MODULE_60__.OffScreenViewport),
|
|
119361
119394
|
/* harmony export */ "OnScreenTarget": () => (/* reexport safe */ _render_webgl_Target__WEBPACK_IMPORTED_MODULE_102__.OnScreenTarget),
|
|
119362
119395
|
/* harmony export */ "OrbitGtTileTree": () => (/* reexport safe */ _tile_internal__WEBPACK_IMPORTED_MODULE_104__.OrbitGtTileTree),
|
|
119396
|
+
/* harmony export */ "OrbitGtTreeReference": () => (/* reexport safe */ _tile_internal__WEBPACK_IMPORTED_MODULE_104__.OrbitGtTreeReference),
|
|
119363
119397
|
/* harmony export */ "OrthographicViewState": () => (/* reexport safe */ _SpatialViewState__WEBPACK_IMPORTED_MODULE_48__.OrthographicViewState),
|
|
119364
119398
|
/* harmony export */ "OutputMessageAlert": () => (/* reexport safe */ _NotificationManager__WEBPACK_IMPORTED_MODULE_43__.OutputMessageAlert),
|
|
119365
119399
|
/* harmony export */ "OutputMessagePriority": () => (/* reexport safe */ _NotificationManager__WEBPACK_IMPORTED_MODULE_43__.OutputMessagePriority),
|
|
@@ -163470,6 +163504,7 @@ class OPCFormatInterpreter {
|
|
|
163470
163504
|
__webpack_require__.r(__webpack_exports__);
|
|
163471
163505
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
163472
163506
|
/* harmony export */ "OrbitGtTileTree": () => (/* binding */ OrbitGtTileTree),
|
|
163507
|
+
/* harmony export */ "OrbitGtTreeReference": () => (/* binding */ OrbitGtTreeReference),
|
|
163473
163508
|
/* harmony export */ "createOrbitGtTileTreeReference": () => (/* binding */ createOrbitGtTileTreeReference)
|
|
163474
163509
|
/* harmony export */ });
|
|
163475
163510
|
/* harmony import */ var _itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @itwin/core-bentley */ "../../core/bentley/lib/esm/core-bentley.js");
|
|
@@ -163477,10 +163512,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
163477
163512
|
/* harmony import */ var _itwin_core_geometry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @itwin/core-geometry */ "../../core/geometry/lib/esm/core-geometry.js");
|
|
163478
163513
|
/* harmony import */ var _itwin_core_orbitgt__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @itwin/core-orbitgt */ "../../core/orbitgt/lib/esm/core-orbitgt.js");
|
|
163479
163514
|
/* harmony import */ var _BackgroundMapGeometry__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../BackgroundMapGeometry */ "../../core/frontend/lib/esm/BackgroundMapGeometry.js");
|
|
163480
|
-
/* harmony import */ var
|
|
163481
|
-
/* harmony import */ var
|
|
163482
|
-
/* harmony import */ var
|
|
163483
|
-
/* harmony import */ var
|
|
163515
|
+
/* harmony import */ var _DisplayStyleState__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../DisplayStyleState */ "../../core/frontend/lib/esm/DisplayStyleState.js");
|
|
163516
|
+
/* harmony import */ var _IModelApp__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../IModelApp */ "../../core/frontend/lib/esm/IModelApp.js");
|
|
163517
|
+
/* harmony import */ var _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../RealityDataSource */ "../../core/frontend/lib/esm/RealityDataSource.js");
|
|
163518
|
+
/* harmony import */ var _render_primitives_mesh_MeshPrimitives__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../render/primitives/mesh/MeshPrimitives */ "../../core/frontend/lib/esm/render/primitives/mesh/MeshPrimitives.js");
|
|
163519
|
+
/* harmony import */ var _internal__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./internal */ "../../core/frontend/lib/esm/tile/internal.js");
|
|
163484
163520
|
/*---------------------------------------------------------------------------------------------
|
|
163485
163521
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
163486
163522
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
@@ -163497,8 +163533,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
163497
163533
|
|
|
163498
163534
|
|
|
163499
163535
|
|
|
163536
|
+
|
|
163500
163537
|
const scratchRange = _itwin_core_geometry__WEBPACK_IMPORTED_MODULE_2__.Range3d.create();
|
|
163501
163538
|
const scratchWorldFrustum = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.Frustum();
|
|
163539
|
+
function compareSourceKeys(lhs, rhs) {
|
|
163540
|
+
return (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.id, rhs.id) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.format, rhs.format) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.iTwinId, rhs.iTwinId);
|
|
163541
|
+
}
|
|
163502
163542
|
class OrbitGtTreeSupplier {
|
|
163503
163543
|
getOwner(treeId, iModel) {
|
|
163504
163544
|
return iModel.tiles.getTileTreeOwner(treeId, this);
|
|
@@ -163507,14 +163547,21 @@ class OrbitGtTreeSupplier {
|
|
|
163507
163547
|
return OrbitGtTileTree.createOrbitGtTileTree(treeId.rdSourceKey, iModel, treeId.modelId);
|
|
163508
163548
|
}
|
|
163509
163549
|
compareTileTreeIds(lhs, rhs) {
|
|
163510
|
-
|
|
163511
|
-
|
|
163512
|
-
|
|
163513
|
-
|
|
163514
|
-
|
|
163515
|
-
|
|
163516
|
-
|
|
163517
|
-
|
|
163550
|
+
return (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.modelId, rhs.modelId) || compareSourceKeys(lhs.rdSourceKey, rhs.rdSourceKey);
|
|
163551
|
+
}
|
|
163552
|
+
findCompatibleContextRealityModelId(sourceKey, style) {
|
|
163553
|
+
const owners = style.iModel.tiles.getTreeOwnersForSupplier(this);
|
|
163554
|
+
for (const owner of owners) {
|
|
163555
|
+
// Find an existing tree with the same reality data source key.
|
|
163556
|
+
if (0 === compareSourceKeys(sourceKey, owner.id.rdSourceKey)) {
|
|
163557
|
+
const modelId = owner.id.modelId;
|
|
163558
|
+
(0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.assert)(undefined !== modelId);
|
|
163559
|
+
// If the model Id is unused by any other context reality model in the view and does not identify a persistent reality model, use it.
|
|
163560
|
+
if (_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.Id64.isTransientId64(modelId) && !style.contextRealityModelStates.some((model) => model.modelId === modelId))
|
|
163561
|
+
return modelId;
|
|
163562
|
+
}
|
|
163563
|
+
}
|
|
163564
|
+
return undefined;
|
|
163518
163565
|
}
|
|
163519
163566
|
}
|
|
163520
163567
|
const orbitGtTreeSupplier = new OrbitGtTreeSupplier();
|
|
@@ -163554,12 +163601,12 @@ class OrbitGtTileTreeParams {
|
|
|
163554
163601
|
this.modelId = modelId;
|
|
163555
163602
|
this.iModel = iModel;
|
|
163556
163603
|
}
|
|
163557
|
-
get priority() { return
|
|
163604
|
+
get priority() { return _internal__WEBPACK_IMPORTED_MODULE_9__.TileLoadPriority.Context; }
|
|
163558
163605
|
}
|
|
163559
|
-
class OrbitGtRootTile extends
|
|
163606
|
+
class OrbitGtRootTile extends _internal__WEBPACK_IMPORTED_MODULE_9__.Tile {
|
|
163560
163607
|
_loadChildren(_resolve, _reject) { }
|
|
163561
163608
|
async requestContent(_isCanceled) { return undefined; }
|
|
163562
|
-
get channel() { return
|
|
163609
|
+
get channel() { return _IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.tileAdmin.channels.getForHttp("itwinjs-orbitgit"); }
|
|
163563
163610
|
async readContent(_data, _system, _isCanceled) { return {}; }
|
|
163564
163611
|
freeMemory() { }
|
|
163565
163612
|
constructor(params, tree) { super(params, tree); }
|
|
@@ -163625,7 +163672,7 @@ class TileSortProjector {
|
|
|
163625
163672
|
coordinate.z = point.z;
|
|
163626
163673
|
}
|
|
163627
163674
|
}
|
|
163628
|
-
class OrbitGtTileGraphic extends
|
|
163675
|
+
class OrbitGtTileGraphic extends _internal__WEBPACK_IMPORTED_MODULE_9__.TileUsageMarker {
|
|
163629
163676
|
constructor(graphic, viewport, time) {
|
|
163630
163677
|
super();
|
|
163631
163678
|
this.graphic = graphic;
|
|
@@ -163636,7 +163683,7 @@ class OrbitGtTileGraphic extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileUsag
|
|
|
163636
163683
|
}
|
|
163637
163684
|
}
|
|
163638
163685
|
/** @internal */
|
|
163639
|
-
class OrbitGtTileTree extends
|
|
163686
|
+
class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_9__.TileTree {
|
|
163640
163687
|
constructor(treeParams, _dataManager, cloudRange, _centerOffset, _ecefTransform) {
|
|
163641
163688
|
super(treeParams);
|
|
163642
163689
|
this._dataManager = _dataManager;
|
|
@@ -163695,7 +163742,7 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163695
163742
|
let totalPointCount = 0;
|
|
163696
163743
|
const tileCount = frameData.tilesToRender.size();
|
|
163697
163744
|
// Inform TileAdmin about tiles we are handling ourselves...
|
|
163698
|
-
|
|
163745
|
+
_IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.tileAdmin.addExternalTilesForUser(args.context.viewport, { requested: frameData.tilesToLoad.size() + (frameData.hasMissingData() ? 1 : 0), selected: tileCount, ready: tileCount });
|
|
163699
163746
|
if (debugBuilder)
|
|
163700
163747
|
debugBuilder.setSymbology(_itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.ColorDef.red, _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.ColorDef.red, 1);
|
|
163701
163748
|
let minLevel = 100, maxLevel = -100;
|
|
@@ -163716,8 +163763,8 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163716
163763
|
range.high.addInPlace(this._centerOffset);
|
|
163717
163764
|
const qParams = _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.QParams3d.fromRange(range, undefined, (tile.points8 != null) ? _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.Quantization.rangeScale8 : _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.Quantization.rangeScale16);
|
|
163718
163765
|
const featureTable = new _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.FeatureTable(1, this.modelId, _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.BatchType.Primary);
|
|
163719
|
-
const features = new
|
|
163720
|
-
const system =
|
|
163766
|
+
const features = new _render_primitives_mesh_MeshPrimitives__WEBPACK_IMPORTED_MODULE_8__.Mesh.Features(featureTable);
|
|
163767
|
+
const system = _IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.renderSystem;
|
|
163721
163768
|
const voxelSize = (range.high.x - range.low.x) / 64;
|
|
163722
163769
|
features.add(new _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.Feature(this.modelId), 1);
|
|
163723
163770
|
const tilePoints = (tile.points8 != null) ? tile.points8.toNativeBuffer() : tile.points16.toNativeBuffer();
|
|
@@ -163744,7 +163791,7 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163744
163791
|
}
|
|
163745
163792
|
args.drawGraphics();
|
|
163746
163793
|
if (frameData.hasMissingData()) {
|
|
163747
|
-
this._dataManager.loadData(frameData).then(() =>
|
|
163794
|
+
this._dataManager.loadData(frameData).then(() => _IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.tileAdmin.onTileLoad.raiseEvent(this.rootTile)).catch((_err) => undefined);
|
|
163748
163795
|
}
|
|
163749
163796
|
}
|
|
163750
163797
|
}
|
|
@@ -163773,7 +163820,7 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163773
163820
|
return isValidSASToken(props.sasToken);
|
|
163774
163821
|
}
|
|
163775
163822
|
async function createOrbitGtTileTree(rdSourceKey, iModel, modelId) {
|
|
163776
|
-
const rdSource = await
|
|
163823
|
+
const rdSource = await _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.fromKey(rdSourceKey, iModel.iTwinId);
|
|
163777
163824
|
const isContextShare = rdSourceKey.provider === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.ContextShare;
|
|
163778
163825
|
const isTilestUrl = rdSourceKey.provider === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.TilesetUrl;
|
|
163779
163826
|
let blobStringUrl;
|
|
@@ -163784,7 +163831,7 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163784
163831
|
const docRootName = realityData.rootDocument;
|
|
163785
163832
|
if (!docRootName)
|
|
163786
163833
|
return undefined;
|
|
163787
|
-
const token = await
|
|
163834
|
+
const token = await _IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.getAccessToken();
|
|
163788
163835
|
const blobUrl = await realityData.getBlobUrl(token, docRootName);
|
|
163789
163836
|
blobStringUrl = blobUrl.toString();
|
|
163790
163837
|
}
|
|
@@ -163792,7 +163839,7 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163792
163839
|
blobStringUrl = rdSourceKey.id;
|
|
163793
163840
|
}
|
|
163794
163841
|
else {
|
|
163795
|
-
const orbitGtBlobProps =
|
|
163842
|
+
const orbitGtBlobProps = _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.createOrbitGtBlobPropsFromKey(rdSourceKey);
|
|
163796
163843
|
if (orbitGtBlobProps === undefined)
|
|
163797
163844
|
return undefined;
|
|
163798
163845
|
if (!isValidOrbitGtBlobProps(orbitGtBlobProps))
|
|
@@ -163865,9 +163912,9 @@ class OrbitGtTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTree {
|
|
|
163865
163912
|
OrbitGtTileTree.createOrbitGtTileTree = createOrbitGtTileTree;
|
|
163866
163913
|
})(OrbitGtTileTree || (OrbitGtTileTree = {}));
|
|
163867
163914
|
/** Supplies a reality data [[TileTree]] from a URL. May be associated with a persistent [[GeometricModelState]], or attached at run-time via a [[ContextOrbitGtState]].
|
|
163868
|
-
* @internal
|
|
163915
|
+
* @internal exported strictly for tests.
|
|
163869
163916
|
*/
|
|
163870
|
-
class OrbitGtTreeReference extends
|
|
163917
|
+
class OrbitGtTreeReference extends _internal__WEBPACK_IMPORTED_MODULE_9__.RealityModelTileTree.Reference {
|
|
163871
163918
|
constructor(props) {
|
|
163872
163919
|
super(props);
|
|
163873
163920
|
// Create rdSourceKey if not provided
|
|
@@ -163875,24 +163922,30 @@ class OrbitGtTreeReference extends _internal__WEBPACK_IMPORTED_MODULE_8__.Realit
|
|
|
163875
163922
|
this._rdSourceKey = props.rdSourceKey;
|
|
163876
163923
|
}
|
|
163877
163924
|
else if (props.orbitGtBlob) {
|
|
163878
|
-
this._rdSourceKey =
|
|
163925
|
+
this._rdSourceKey = _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.createKeyFromOrbitGtBlobProps(props.orbitGtBlob);
|
|
163879
163926
|
}
|
|
163880
163927
|
else {
|
|
163881
163928
|
// TODO: Maybe we should throw an exception
|
|
163882
|
-
this._rdSourceKey =
|
|
163929
|
+
this._rdSourceKey = _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.createKeyFromBlobUrl("", _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.OrbitGtBlob, _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataFormat.OPC);
|
|
163883
163930
|
}
|
|
163931
|
+
// ###TODO find compatible model Id
|
|
163932
|
+
let modelId = props.modelId;
|
|
163933
|
+
if (undefined === modelId && this._source instanceof _DisplayStyleState__WEBPACK_IMPORTED_MODULE_5__.DisplayStyleState)
|
|
163934
|
+
modelId = orbitGtTreeSupplier.findCompatibleContextRealityModelId(this._rdSourceKey, this._source);
|
|
163935
|
+
this._modelId = modelId !== null && modelId !== void 0 ? modelId : props.iModel.transientIds.getNext();
|
|
163884
163936
|
const ogtTreeId = { rdSourceKey: this._rdSourceKey, modelId: this.modelId };
|
|
163885
163937
|
this.treeOwner = orbitGtTreeSupplier.getOwner(ogtTreeId, props.iModel);
|
|
163886
163938
|
}
|
|
163887
163939
|
get castsShadows() { return false; }
|
|
163940
|
+
get modelId() { return this._modelId; }
|
|
163888
163941
|
async getToolTip(hit) {
|
|
163889
163942
|
const tree = this.treeOwner.tileTree;
|
|
163890
163943
|
if (undefined === tree || hit.iModel !== tree.iModel)
|
|
163891
163944
|
return undefined;
|
|
163892
163945
|
const strings = [];
|
|
163893
|
-
strings.push(
|
|
163946
|
+
strings.push(_IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.localization.getLocalizedString("iModelJs:RealityModelTypes.OrbitGTPointCloud"));
|
|
163894
163947
|
if (this._name)
|
|
163895
|
-
strings.push(`${
|
|
163948
|
+
strings.push(`${_IModelApp__WEBPACK_IMPORTED_MODULE_6__.IModelApp.localization.getLocalizedString("iModelJs:TooltipInfo.Name")} ${this._name}`);
|
|
163896
163949
|
const div = document.createElement("div");
|
|
163897
163950
|
div.innerHTML = strings.join("<br>");
|
|
163898
163951
|
return div;
|
|
@@ -164722,10 +164775,11 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
164722
164775
|
/* harmony import */ var _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @itwin/core-common */ "../../core/common/lib/esm/core-common.js");
|
|
164723
164776
|
/* harmony import */ var _itwin_core_geometry__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @itwin/core-geometry */ "../../core/geometry/lib/esm/core-geometry.js");
|
|
164724
164777
|
/* harmony import */ var _BackgroundMapGeometry__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../BackgroundMapGeometry */ "../../core/frontend/lib/esm/BackgroundMapGeometry.js");
|
|
164725
|
-
/* harmony import */ var
|
|
164726
|
-
/* harmony import */ var
|
|
164727
|
-
/* harmony import */ var
|
|
164728
|
-
/* harmony import */ var
|
|
164778
|
+
/* harmony import */ var _DisplayStyleState__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../DisplayStyleState */ "../../core/frontend/lib/esm/DisplayStyleState.js");
|
|
164779
|
+
/* harmony import */ var _IModelApp__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../IModelApp */ "../../core/frontend/lib/esm/IModelApp.js");
|
|
164780
|
+
/* harmony import */ var _PlanarClipMaskState__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../PlanarClipMaskState */ "../../core/frontend/lib/esm/PlanarClipMaskState.js");
|
|
164781
|
+
/* harmony import */ var _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../RealityDataSource */ "../../core/frontend/lib/esm/RealityDataSource.js");
|
|
164782
|
+
/* harmony import */ var _internal__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./internal */ "../../core/frontend/lib/esm/tile/internal.js");
|
|
164729
164783
|
/*---------------------------------------------------------------------------------------------
|
|
164730
164784
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
164731
164785
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
@@ -164741,34 +164795,42 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
164741
164795
|
|
|
164742
164796
|
|
|
164743
164797
|
|
|
164798
|
+
|
|
164744
164799
|
function getUrl(content) {
|
|
164745
164800
|
return content ? (content.url ? content.url : content.uri) : undefined;
|
|
164746
164801
|
}
|
|
164747
|
-
|
|
164748
|
-
|
|
164749
|
-
|
|
164750
|
-
|
|
164751
|
-
if (0 === cmp)
|
|
164752
|
-
cmp = (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareNumbers)(lhs.z, rhs.z);
|
|
164802
|
+
var RealityTreeId;
|
|
164803
|
+
(function (RealityTreeId) {
|
|
164804
|
+
function compareOrigins(lhs, rhs) {
|
|
164805
|
+
return (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareNumbers)(lhs.x, rhs.x) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareNumbers)(lhs.y, rhs.y) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareNumbers)(lhs.z, rhs.z);
|
|
164753
164806
|
}
|
|
164754
|
-
|
|
164755
|
-
|
|
164756
|
-
|
|
164757
|
-
|
|
164758
|
-
|
|
164759
|
-
|
|
164760
|
-
|
|
164807
|
+
function compareMatrices(lhs, rhs) {
|
|
164808
|
+
for (let i = 0; i < 9; i++) {
|
|
164809
|
+
const cmp = (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareNumbers)(lhs.coffs[i], rhs.coffs[i]);
|
|
164810
|
+
if (0 !== cmp)
|
|
164811
|
+
return cmp;
|
|
164812
|
+
}
|
|
164813
|
+
return 0;
|
|
164761
164814
|
}
|
|
164762
|
-
|
|
164763
|
-
|
|
164764
|
-
|
|
164765
|
-
|
|
164766
|
-
return
|
|
164767
|
-
|
|
164768
|
-
|
|
164769
|
-
|
|
164770
|
-
|
|
164771
|
-
|
|
164815
|
+
function compareTransforms(lhs, rhs) {
|
|
164816
|
+
return compareOrigins(lhs.origin, rhs.origin) || compareMatrices(lhs.matrix, rhs.matrix);
|
|
164817
|
+
}
|
|
164818
|
+
function compareRealityDataSourceKeys(lhs, rhs) {
|
|
164819
|
+
return (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.id, rhs.id) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.format, rhs.format) || (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.iTwinId, rhs.iTwinId);
|
|
164820
|
+
}
|
|
164821
|
+
function compareWithoutModelId(lhs, rhs) {
|
|
164822
|
+
return compareRealityDataSourceKeys(lhs.rdSourceKey, rhs.rdSourceKey)
|
|
164823
|
+
|| (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareBooleans)(lhs.deduplicateVertices, rhs.deduplicateVertices)
|
|
164824
|
+
|| (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareBooleansOrUndefined)(lhs.produceGeometry, rhs.produceGeometry)
|
|
164825
|
+
|| (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.maskModelIds, rhs.maskModelIds)
|
|
164826
|
+
|| (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.comparePossiblyUndefined)((ltf, rtf) => compareTransforms(ltf, rtf), lhs.transform, rhs.transform);
|
|
164827
|
+
}
|
|
164828
|
+
RealityTreeId.compareWithoutModelId = compareWithoutModelId;
|
|
164829
|
+
function compare(lhs, rhs) {
|
|
164830
|
+
return (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStrings)(lhs.modelId, rhs.modelId) || compareWithoutModelId(lhs, rhs);
|
|
164831
|
+
}
|
|
164832
|
+
RealityTreeId.compare = compare;
|
|
164833
|
+
})(RealityTreeId || (RealityTreeId = {}));
|
|
164772
164834
|
class RealityTreeSupplier {
|
|
164773
164835
|
constructor() {
|
|
164774
164836
|
this.isEcefDependent = true;
|
|
@@ -164783,30 +164845,21 @@ class RealityTreeSupplier {
|
|
|
164783
164845
|
return RealityModelTileTree.createRealityModelTileTree(treeId.rdSourceKey, iModel, treeId.modelId, treeId.transform, opts);
|
|
164784
164846
|
}
|
|
164785
164847
|
compareTileTreeIds(lhs, rhs) {
|
|
164786
|
-
|
|
164787
|
-
|
|
164788
|
-
|
|
164789
|
-
|
|
164790
|
-
|
|
164791
|
-
|
|
164792
|
-
|
|
164793
|
-
|
|
164794
|
-
|
|
164795
|
-
|
|
164848
|
+
return RealityTreeId.compare(lhs, rhs);
|
|
164849
|
+
}
|
|
164850
|
+
findCompatibleContextRealityModelId(id, style) {
|
|
164851
|
+
const owners = style.iModel.tiles.getTreeOwnersForSupplier(this);
|
|
164852
|
+
for (const owner of owners) {
|
|
164853
|
+
// Find an existing tree with the same Id, ignoring its model Id.
|
|
164854
|
+
if (0 === RealityTreeId.compareWithoutModelId(id, owner.id)) {
|
|
164855
|
+
const modelId = owner.id.modelId;
|
|
164856
|
+
(0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.assert)(undefined !== modelId);
|
|
164857
|
+
// If the model Id is unused by any other context reality model in the view and does not identify a persistent reality model, use it.
|
|
164858
|
+
if (_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.Id64.isTransientId64(modelId) && !style.contextRealityModelStates.some((model) => model.modelId === modelId))
|
|
164859
|
+
return modelId;
|
|
164796
164860
|
}
|
|
164797
164861
|
}
|
|
164798
|
-
|
|
164799
|
-
return cmp;
|
|
164800
|
-
cmp = (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareStringsOrUndefined)(lhs.maskModelIds, rhs.maskModelIds);
|
|
164801
|
-
if (0 !== cmp)
|
|
164802
|
-
return cmp;
|
|
164803
|
-
cmp = (0,_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.compareBooleansOrUndefined)(lhs.produceGeometry, rhs.produceGeometry);
|
|
164804
|
-
if (0 !== cmp)
|
|
164805
|
-
return cmp;
|
|
164806
|
-
cmp = compareTransforms(lhs.transform, rhs.transform);
|
|
164807
|
-
if (0 !== cmp)
|
|
164808
|
-
return cmp;
|
|
164809
|
-
return compareTransforms(lhs.toEcefTransform, rhs.toEcefTransform);
|
|
164862
|
+
return undefined;
|
|
164810
164863
|
}
|
|
164811
164864
|
}
|
|
164812
164865
|
const realityTreeSupplier = new RealityTreeSupplier();
|
|
@@ -164904,7 +164957,7 @@ class RealityModelTileUtils {
|
|
|
164904
164957
|
return range ? { range, corners } : undefined;
|
|
164905
164958
|
}
|
|
164906
164959
|
static maximumSizeFromGeometricTolerance(range, geometricError) {
|
|
164907
|
-
const minToleranceRatio = true ===
|
|
164960
|
+
const minToleranceRatio = true === _IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.renderSystem.isMobile ? _IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.tileAdmin.mobileRealityTileMinToleranceRatio : 1.0; // Nominally the error on screen size of a tile. Increasing generally increases performance (fewer draw calls) at expense of higher load times.
|
|
164908
164961
|
// NB: We increase the above minToleranceRatio on mobile devices in order to help avoid pruning too often based on the memory threshold for
|
|
164909
164962
|
// pruning currently used by reality tile trees on mobile.
|
|
164910
164963
|
return minToleranceRatio * range.diagonal().magnitude() / geometricError;
|
|
@@ -165046,7 +165099,7 @@ async function expandSubTree(root, rdsource) {
|
|
|
165046
165099
|
return subTree.root;
|
|
165047
165100
|
}
|
|
165048
165101
|
/** @internal */
|
|
165049
|
-
class RealityModelTileLoader extends
|
|
165102
|
+
class RealityModelTileLoader extends _internal__WEBPACK_IMPORTED_MODULE_8__.RealityTileLoader {
|
|
165050
165103
|
constructor(tree, batchedIdMap, opts) {
|
|
165051
165104
|
var _a, _b;
|
|
165052
165105
|
super((_a = opts === null || opts === void 0 ? void 0 : opts.produceGeometry) !== null && _a !== void 0 ? _a : false);
|
|
@@ -165056,7 +165109,7 @@ class RealityModelTileLoader extends _internal__WEBPACK_IMPORTED_MODULE_7__.Real
|
|
|
165056
165109
|
let clipVolume;
|
|
165057
165110
|
if (RealityTileRegion.isGlobal(tree.tilesetJson.boundingVolume))
|
|
165058
165111
|
clipVolume = false;
|
|
165059
|
-
this._viewFlagOverrides = (0,
|
|
165112
|
+
this._viewFlagOverrides = (0,_internal__WEBPACK_IMPORTED_MODULE_8__.createDefaultViewFlagOverrides)({ lighting: true, clipVolume });
|
|
165060
165113
|
// Display edges if they are present (Cesium outline extension) and enabled for view.
|
|
165061
165114
|
this._viewFlagOverrides.visibleEdges = undefined;
|
|
165062
165115
|
this._viewFlagOverrides.hiddenEdges = undefined;
|
|
@@ -165067,7 +165120,7 @@ class RealityModelTileLoader extends _internal__WEBPACK_IMPORTED_MODULE_7__.Real
|
|
|
165067
165120
|
get wantDeduplicatedVertices() { return this._deduplicateVertices; }
|
|
165068
165121
|
get maxDepth() { return 32; } // Can be removed when element tile selector is working.
|
|
165069
165122
|
get minDepth() { return 0; }
|
|
165070
|
-
get priority() { return
|
|
165123
|
+
get priority() { return _internal__WEBPACK_IMPORTED_MODULE_8__.TileLoadPriority.Context; }
|
|
165071
165124
|
getBatchIdMap() { return this._batchedIdMap; }
|
|
165072
165125
|
get clipLowResolutionTiles() { return true; }
|
|
165073
165126
|
get viewFlagOverrides() { return this._viewFlagOverrides; }
|
|
@@ -165110,7 +165163,7 @@ class RealityModelTileLoader extends _internal__WEBPACK_IMPORTED_MODULE_7__.Real
|
|
|
165110
165163
|
}
|
|
165111
165164
|
getRequestChannel(_tile) {
|
|
165112
165165
|
// ###TODO: May want to extract the hostname from the URL.
|
|
165113
|
-
return
|
|
165166
|
+
return _IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.tileAdmin.channels.getForHttp("itwinjs-reality-model");
|
|
165114
165167
|
}
|
|
165115
165168
|
async requestTileContent(tile, isCanceled) {
|
|
165116
165169
|
const foundChild = await this.findTileInJson(this.tree.tilesetJson, tile.contentId, "");
|
|
@@ -165142,7 +165195,7 @@ class RealityModelTileLoader extends _internal__WEBPACK_IMPORTED_MODULE_7__.Real
|
|
|
165142
165195
|
}
|
|
165143
165196
|
}
|
|
165144
165197
|
/** @internal */
|
|
165145
|
-
class RealityModelTileTree extends
|
|
165198
|
+
class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_8__.RealityTileTree {
|
|
165146
165199
|
constructor(params) {
|
|
165147
165200
|
super(params);
|
|
165148
165201
|
this._isContentUnbounded = this.rootTile.contentRange.diagonal().magnitude() > 2 * _itwin_core_geometry__WEBPACK_IMPORTED_MODULE_2__.Constant.earthRadiusWGS84.equator;
|
|
@@ -165157,11 +165210,10 @@ class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_7__.Realit
|
|
|
165157
165210
|
/** @internal */
|
|
165158
165211
|
// eslint-disable-next-line no-redeclare
|
|
165159
165212
|
(function (RealityModelTileTree) {
|
|
165160
|
-
class Reference extends
|
|
165213
|
+
class Reference extends _internal__WEBPACK_IMPORTED_MODULE_8__.TileTreeReference {
|
|
165161
165214
|
constructor(props) {
|
|
165162
165215
|
super();
|
|
165163
165216
|
this._name = undefined !== props.name ? props.name : "";
|
|
165164
|
-
this._modelId = props.modelId ? props.modelId : props.iModel.transientIds.getNext();
|
|
165165
165217
|
let transform;
|
|
165166
165218
|
if (undefined !== props.tilesetToDbTransform) {
|
|
165167
165219
|
const tf = _itwin_core_geometry__WEBPACK_IMPORTED_MODULE_2__.Transform.fromJSON(props.tilesetToDbTransform);
|
|
@@ -165173,11 +165225,10 @@ class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_7__.Realit
|
|
|
165173
165225
|
this._source = props.source;
|
|
165174
165226
|
this._getDisplaySettings = () => props.getDisplaySettings();
|
|
165175
165227
|
if (props.planarClipMask)
|
|
165176
|
-
this._planarClipMask =
|
|
165228
|
+
this._planarClipMask = _PlanarClipMaskState__WEBPACK_IMPORTED_MODULE_6__.PlanarClipMaskState.create(props.planarClipMask);
|
|
165177
165229
|
if (undefined !== props.classifiers)
|
|
165178
|
-
this._classifier = (0,
|
|
165230
|
+
this._classifier = (0,_internal__WEBPACK_IMPORTED_MODULE_8__.createClassifierTileTreeReference)(props.classifiers, this, props.iModel, props.source);
|
|
165179
165231
|
}
|
|
165180
|
-
get modelId() { return this._modelId; }
|
|
165181
165232
|
// public get classifiers(): SpatialClassifiers | undefined { return undefined !== this._classifier ? this._classifier.classifiers : undefined; }
|
|
165182
165233
|
get planarClipMask() { return this._planarClipMask; }
|
|
165183
165234
|
set planarClipMask(planarClipMask) { this._planarClipMask = planarClipMask; }
|
|
@@ -165243,7 +165294,7 @@ class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_7__.Realit
|
|
|
165243
165294
|
if (args) {
|
|
165244
165295
|
args.graphics.realityModelDisplaySettings = this._getDisplaySettings();
|
|
165245
165296
|
args.graphics.realityModelRange = args.tree.rootTile.contentRange;
|
|
165246
|
-
if (args.tree instanceof
|
|
165297
|
+
if (args.tree instanceof _internal__WEBPACK_IMPORTED_MODULE_8__.RealityTileTree) {
|
|
165247
165298
|
const maxSSE = args.tree.loader.maximumScreenSpaceError;
|
|
165248
165299
|
if (undefined !== maxSSE)
|
|
165249
165300
|
args.maximumScreenSpaceError = maxSSE;
|
|
@@ -165254,7 +165305,7 @@ class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_7__.Realit
|
|
|
165254
165305
|
}
|
|
165255
165306
|
RealityModelTileTree.Reference = Reference;
|
|
165256
165307
|
async function createRealityModelTileTree(rdSourceKey, iModel, modelId, tilesetToDb, opts) {
|
|
165257
|
-
const rdSource = await
|
|
165308
|
+
const rdSource = await _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.fromKey(rdSourceKey, iModel.iTwinId);
|
|
165258
165309
|
// If we can get a valid connection from sourceKey, returns the tile tree
|
|
165259
165310
|
if (rdSource) {
|
|
165260
165311
|
// Serialize the reality data source key into a string to uniquely identify this tile tree
|
|
@@ -165262,8 +165313,8 @@ class RealityModelTileTree extends _internal__WEBPACK_IMPORTED_MODULE_7__.Realit
|
|
|
165262
165313
|
if (tileTreeId === undefined)
|
|
165263
165314
|
return undefined;
|
|
165264
165315
|
const props = await getTileTreeProps(rdSource, tilesetToDb, iModel);
|
|
165265
|
-
const loader = new RealityModelTileLoader(props, new
|
|
165266
|
-
const gcsConverterAvailable = await (0,
|
|
165316
|
+
const loader = new RealityModelTileLoader(props, new _internal__WEBPACK_IMPORTED_MODULE_8__.BatchedTileIdMap(iModel), opts);
|
|
165317
|
+
const gcsConverterAvailable = await (0,_internal__WEBPACK_IMPORTED_MODULE_8__.getGcsConverterAvailable)(iModel);
|
|
165267
165318
|
const params = new RealityModelTileTreeParams(tileTreeId, iModel, modelId, loader, gcsConverterAvailable, props.tilesetToEcef);
|
|
165268
165319
|
return new RealityModelTileTree(params);
|
|
165269
165320
|
}
|
|
@@ -165330,20 +165381,29 @@ class RealityTreeReference extends RealityModelTileTree.Reference {
|
|
|
165330
165381
|
if (props.rdSourceKey)
|
|
165331
165382
|
this._rdSourceKey = props.rdSourceKey;
|
|
165332
165383
|
else
|
|
165333
|
-
this._rdSourceKey =
|
|
165384
|
+
this._rdSourceKey = _RealityDataSource__WEBPACK_IMPORTED_MODULE_7__.RealityDataSource.createKeyFromUrl((_a = props.url) !== null && _a !== void 0 ? _a : "", _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.ContextShare);
|
|
165334
165385
|
if (this._produceGeometry)
|
|
165335
165386
|
this.collectTileGeometry = (collector) => this._collectTileGeometry(collector);
|
|
165387
|
+
let modelId = props.modelId;
|
|
165388
|
+
if (undefined === modelId && this._source instanceof _DisplayStyleState__WEBPACK_IMPORTED_MODULE_4__.DisplayStyleState) {
|
|
165389
|
+
const treeId = this.createTreeId(_itwin_core_bentley__WEBPACK_IMPORTED_MODULE_0__.Id64.invalid);
|
|
165390
|
+
modelId = realityTreeSupplier.findCompatibleContextRealityModelId(treeId, this._source);
|
|
165391
|
+
}
|
|
165392
|
+
this._modelId = modelId !== null && modelId !== void 0 ? modelId : props.iModel.transientIds.getNext();
|
|
165336
165393
|
}
|
|
165337
|
-
get
|
|
165338
|
-
|
|
165394
|
+
get modelId() { return this._modelId; }
|
|
165395
|
+
createTreeId(modelId) {
|
|
165396
|
+
return {
|
|
165339
165397
|
rdSourceKey: this._rdSourceKey,
|
|
165340
165398
|
transform: this._transform,
|
|
165341
|
-
modelId
|
|
165399
|
+
modelId,
|
|
165342
165400
|
maskModelIds: this.maskModelIds,
|
|
165343
165401
|
deduplicateVertices: this._wantWiremesh,
|
|
165344
165402
|
produceGeometry: this._produceGeometry,
|
|
165345
165403
|
};
|
|
165346
|
-
|
|
165404
|
+
}
|
|
165405
|
+
get treeOwner() {
|
|
165406
|
+
return realityTreeSupplier.getOwner(this.createTreeId(this.modelId), this._iModel);
|
|
165347
165407
|
}
|
|
165348
165408
|
_createGeometryTreeReference() {
|
|
165349
165409
|
const ref = new RealityTreeReference({
|
|
@@ -165407,21 +165467,21 @@ class RealityTreeReference extends RealityModelTileTree.Reference {
|
|
|
165407
165467
|
// Case insensitive
|
|
165408
165468
|
switch (type.toUpperCase()) {
|
|
165409
165469
|
case _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.DefaultSupportedTypes.RealityMesh3dTiles.toUpperCase():
|
|
165410
|
-
strings.push(
|
|
165470
|
+
strings.push(_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.localization.getLocalizedString("iModelJs:RealityModelTypes.RealityMesh3DTiles"));
|
|
165411
165471
|
break;
|
|
165412
165472
|
case _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.DefaultSupportedTypes.Terrain3dTiles.toUpperCase():
|
|
165413
|
-
strings.push(
|
|
165473
|
+
strings.push(_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.localization.getLocalizedString("iModelJs:RealityModelTypes.Terrain3DTiles"));
|
|
165414
165474
|
break;
|
|
165415
165475
|
case _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.DefaultSupportedTypes.Cesium3dTiles.toUpperCase():
|
|
165416
|
-
strings.push(
|
|
165476
|
+
strings.push(_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.localization.getLocalizedString("iModelJs:RealityModelTypes.Cesium3DTiles"));
|
|
165417
165477
|
break;
|
|
165418
165478
|
}
|
|
165419
165479
|
}
|
|
165420
165480
|
if (this._name) {
|
|
165421
|
-
strings.push(`${
|
|
165481
|
+
strings.push(`${_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.localization.getLocalizedString("iModelJs:TooltipInfo.Name")} ${this._name}`);
|
|
165422
165482
|
}
|
|
165423
165483
|
else {
|
|
165424
|
-
const cesiumAsset = this._rdSourceKey.provider === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.CesiumIonAsset ?
|
|
165484
|
+
const cesiumAsset = this._rdSourceKey.provider === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.CesiumIonAsset ? _internal__WEBPACK_IMPORTED_MODULE_8__.CesiumIonAssetProvider.parseCesiumUrl(this._rdSourceKey.id) : undefined;
|
|
165425
165485
|
strings.push(cesiumAsset ? `Cesium Asset: ${cesiumAsset.id}` : this._rdSourceKey.id);
|
|
165426
165486
|
}
|
|
165427
165487
|
if (batch !== undefined)
|
|
@@ -165435,7 +165495,7 @@ class RealityTreeReference extends RealityModelTileTree.Reference {
|
|
|
165435
165495
|
addLogoCards(cards) {
|
|
165436
165496
|
if (this._rdSourceKey.provider === _itwin_core_common__WEBPACK_IMPORTED_MODULE_1__.RealityDataProvider.CesiumIonAsset && !cards.dataset.openStreetMapLogoCard) {
|
|
165437
165497
|
cards.dataset.openStreetMapLogoCard = "true";
|
|
165438
|
-
cards.appendChild(
|
|
165498
|
+
cards.appendChild(_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.makeLogoCard({ heading: "OpenStreetMap", notice: `©<a href=\"https://www.openstreetmap.org/copyright\">OpenStreetMap</a> ${_IModelApp__WEBPACK_IMPORTED_MODULE_5__.IModelApp.localization.getLocalizedString("iModelJs:BackgroundMap:OpenStreetMapContributors")}` }));
|
|
165439
165499
|
}
|
|
165440
165500
|
}
|
|
165441
165501
|
}
|
|
@@ -170080,6 +170140,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
170080
170140
|
/* harmony export */ "ModelMapLayerTileTreeReference": () => (/* reexport safe */ _PrimaryTileTree__WEBPACK_IMPORTED_MODULE_69__.ModelMapLayerTileTreeReference),
|
|
170081
170141
|
/* harmony export */ "OPCFormatInterpreter": () => (/* reexport safe */ _OPCFormatInterpreter__WEBPACK_IMPORTED_MODULE_78__.OPCFormatInterpreter),
|
|
170082
170142
|
/* harmony export */ "OrbitGtTileTree": () => (/* reexport safe */ _OrbitGtTileTree__WEBPACK_IMPORTED_MODULE_71__.OrbitGtTileTree),
|
|
170143
|
+
/* harmony export */ "OrbitGtTreeReference": () => (/* reexport safe */ _OrbitGtTileTree__WEBPACK_IMPORTED_MODULE_71__.OrbitGtTreeReference),
|
|
170083
170144
|
/* harmony export */ "PlanarTilePatch": () => (/* reexport safe */ _map_MapTile__WEBPACK_IMPORTED_MODULE_58__.PlanarTilePatch),
|
|
170084
170145
|
/* harmony export */ "QuadId": () => (/* reexport safe */ _map_QuadId__WEBPACK_IMPORTED_MODULE_2__.QuadId),
|
|
170085
170146
|
/* harmony export */ "ReadonlyTileUserSet": () => (/* reexport safe */ _TileUserSet__WEBPACK_IMPORTED_MODULE_29__.ReadonlyTileUserSet),
|
|
@@ -303133,7 +303194,7 @@ module.exports = JSON.parse('{"name":"axios","version":"0.21.4","description":"P
|
|
|
303133
303194
|
/***/ ((module) => {
|
|
303134
303195
|
|
|
303135
303196
|
"use strict";
|
|
303136
|
-
module.exports = JSON.parse('{"name":"@itwin/core-frontend","version":"3.6.0-dev.
|
|
303197
|
+
module.exports = JSON.parse('{"name":"@itwin/core-frontend","version":"3.6.0-dev.66","description":"iTwin.js frontend components","main":"lib/cjs/core-frontend.js","module":"lib/esm/core-frontend.js","typings":"lib/cjs/core-frontend","license":"MIT","scripts":{"build":"npm run -s copy:public && npm run -s build:cjs","build:ci":"npm run -s build && npm run -s build:esm","build:cjs":"npm run -s copy:js:cjs && tsc 1>&2 --outDir lib/cjs","build:esm":"npm run -s copy:js:esm && tsc 1>&2 --module ES2020 --outDir lib/esm","clean":"rimraf lib .rush/temp/package-deps*.json","copy:public":"cpx \\"./src/public/**/*\\" ./lib/public","copy:js:cjs":"cpx \\"./src/**/*.js\\" ./lib/cjs","copy:js:esm":"cpx \\"./src/**/*.js\\" ./lib/esm","docs":"betools docs --includes=../../generated-docs/extract --json=../../generated-docs/core/core-frontend/file.json --tsIndexFile=./core-frontend.ts --onlyJson --excludes=webgl/**/*,**/primitives,**/map/*.d.ts,**/tile/*.d.ts,**/*-css.ts","extract-api":"betools extract-api --entry=core-frontend && npm run extract-extension-api","extract-extension-api":"eslint --no-eslintrc -c \\"../../tools/eslint-plugin/dist/configs/extension-exports-config.js\\" \\"./src/**/*.ts\\" 1>&2","lint":"eslint -f visualstudio \\"./src/**/*.ts\\" 1>&2","pseudolocalize":"betools pseudolocalize --englishDir ./src/public/locales/en --out ./public/locales/en-PSEUDO","test":"npm run -s webpackTests && certa -r chrome","cover":"npm -s test","test:debug":"certa -r chrome --debug","webpackTests":"webpack --config ./src/test/utils/webpack.config.js 1>&2"},"repository":{"type":"git","url":"https://github.com/iTwin/itwinjs-core/tree/master/core/frontend"},"keywords":["Bentley","BIM","iModel","digital-twin","iTwin"],"author":{"name":"Bentley Systems, Inc.","url":"http://www.bentley.com"},"peerDependencies":{"@itwin/appui-abstract":"workspace:^3.6.0-dev.66","@itwin/core-bentley":"workspace:^3.6.0-dev.66","@itwin/core-common":"workspace:^3.6.0-dev.66","@itwin/core-geometry":"workspace:^3.6.0-dev.66","@itwin/core-orbitgt":"workspace:^3.6.0-dev.66","@itwin/core-quantity":"workspace:^3.6.0-dev.66","@itwin/webgl-compatibility":"workspace:^3.6.0-dev.66"},"//devDependencies":["NOTE: All peerDependencies should also be listed as devDependencies since peerDependencies are not considered by npm install","NOTE: All tools used by scripts in this package must be listed as devDependencies"],"devDependencies":{"@itwin/appui-abstract":"workspace:*","@itwin/build-tools":"workspace:*","@itwin/core-bentley":"workspace:*","@itwin/core-common":"workspace:*","@itwin/core-geometry":"workspace:*","@itwin/core-orbitgt":"workspace:*","@itwin/core-quantity":"workspace:*","@itwin/certa":"workspace:*","@itwin/eslint-plugin":"workspace:*","@itwin/webgl-compatibility":"workspace:*","@types/chai":"4.3.1","@types/chai-as-promised":"^7","@types/deep-assign":"^0.1.0","@types/lodash":"^4.14.0","@types/mocha":"^8.2.2","@types/node":"18.11.5","@types/qs":"^6.5.0","@types/semver":"7.3.10","@types/superagent":"^4.1.14","@types/sinon":"^9.0.0","babel-loader":"~8.2.5","babel-plugin-istanbul":"~6.1.1","chai":"^4.1.2","chai-as-promised":"^7","cpx2":"^3.0.0","eslint":"^7.11.0","glob":"^7.1.2","mocha":"^10.0.0","nyc":"^15.1.0","rimraf":"^3.0.2","sinon":"^9.0.2","source-map-loader":"^4.0.0","typescript":"~4.4.0","webpack":"^5.64.4"},"//dependencies":["NOTE: these dependencies should be only for things that DO NOT APPEAR IN THE API","NOTE: core-frontend should remain UI technology agnostic, so no react/angular dependencies are allowed"],"dependencies":{"@itwin/object-storage-azure":"~1.4.0","@itwin/cloud-agnostic-core":"~1.4.0","@itwin/object-storage-core":"~1.4.0","@itwin/core-i18n":"workspace:*","@itwin/core-telemetry":"workspace:*","@loaders.gl/core":"^3.1.6","@loaders.gl/draco":"^3.1.6","deep-assign":"^2.0.0","fuse.js":"^3.3.0","lodash":"^4.17.10","qs":"^6.5.3","semver":"^7.3.5","superagent":"^7.1.5","wms-capabilities":"0.4.0","reflect-metadata":"0.1.13"},"nyc":{"extends":"./node_modules/@itwin/build-tools/.nycrc"},"eslintConfig":{"plugins":["@itwin"],"extends":"plugin:@itwin/itwinjs-recommended","rules":{"@itwin/no-internal-barrel-imports":["error",{"required-barrel-modules":["./src/tile/internal.ts"]}],"@itwin/public-extension-exports":["error",{"releaseTags":["public","preview"],"outputApiFile":false}]},"overrides":[{"files":["*.test.ts","*.test.tsx","**/test/**/*.ts"],"rules":{"@itwin/no-internal-barrel-imports":"off"}}]}}');
|
|
303137
303198
|
|
|
303138
303199
|
/***/ })
|
|
303139
303200
|
|