@cognite/reveal 4.36.0 → 4.38.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/eptBinaryDecoder.worker-AfUP5xy8.js.map +1 -0
- package/dist/index.js +13343 -12698
- package/dist/index.js.map +1 -1
- package/dist/packages/360-images/index.d.ts +7 -0
- package/dist/packages/360-images/src/collection/DefaultImage360Collection.d.ts +2 -2
- package/dist/packages/360-images/src/collection/Image360CollectionFactory.d.ts +1 -1
- package/dist/packages/360-images/src/entity/Image360Entity.d.ts +2 -1
- package/dist/packages/360-images/src/entity/Image360RevisionEntity.d.ts +2 -1
- package/dist/packages/{data-providers/src/image-360-data-providers → 360-images/src/providers}/Cdf360ImageAnnotationProvider.d.ts +6 -4
- package/dist/packages/{data-providers/src/image-360-data-providers → 360-images/src/providers}/CoreDm360ImageAnnotationProvider.d.ts +4 -3
- package/dist/packages/360-images/src/providers/Image360AnnotationProvider.d.ts +24 -0
- package/dist/packages/{data-providers/src → 360-images/src/providers}/Image360Provider.d.ts +3 -3
- package/dist/packages/{data-providers/src → 360-images/src/providers}/Image360ProviderCombiner.d.ts +5 -4
- package/dist/packages/{data-providers/src/image-360-data-providers → 360-images/src/providers}/Local360ImageProvider.d.ts +5 -4
- package/dist/packages/{data-providers/src/image-360-data-providers → 360-images/src/providers}/annotations.d.ts +1 -1
- package/dist/packages/api/src/api-helpers/Image360ApiHelper.d.ts +2 -0
- package/dist/packages/api/src/public/RevealManager.d.ts +3 -0
- package/dist/packages/api/src/public/RevealOptions.d.ts +1 -0
- package/dist/packages/api/src/public/migration/Cognite3DViewer.d.ts +23 -0
- package/dist/packages/api/src/public/migration/renderOptionsHelpers.d.ts +6 -1
- package/dist/packages/api/src/public/migration/types.d.ts +9 -0
- package/dist/packages/api/src/public/types.d.ts +1 -1
- package/dist/packages/cad-model/src/types.d.ts +4 -18
- package/dist/packages/camera-manager/src/Flexible/FlexibleCameraManager.d.ts +1 -3
- package/dist/packages/camera-manager/src/Flexible/GetPickedPointByPixelCoordinates.d.ts +1 -1
- package/dist/packages/camera-manager/src/types.d.ts +5 -0
- package/dist/packages/data-providers/index.d.ts +10 -10
- package/dist/packages/data-providers/src/DataSourceType.d.ts +2 -1
- package/dist/packages/data-providers/src/GeometryFilter.d.ts +18 -0
- package/dist/packages/{pointcloud-styling/src → data-providers/src/point-cloud-collections}/PointCloudDMVolumeCollection.d.ts +1 -1
- package/dist/packages/data-providers/src/types.d.ts +0 -21
- package/dist/packages/data-providers/src/utilities/internalAddModelOptions.d.ts +1 -1
- package/dist/packages/model-base/src/types.d.ts +2 -0
- package/dist/packages/pointcloud-styling/index.d.ts +1 -2
- package/dist/packages/pointcloud-styling/src/AnnotationIdPointCloudObjectCollection.d.ts +1 -1
- package/dist/packages/pointcloud-styling/src/utils.d.ts +1 -2
- package/dist/packages/pointclouds/src/PointCloudPickingHandler.d.ts +22 -2
- package/dist/packages/pointclouds/src/potree-three-loader/tree/PointCloudOctreePicker.d.ts +17 -0
- package/dist/packages/pointclouds/src/potree-three-loader/tree/PointCloudOctreePickerHelper.d.ts +29 -4
- package/dist/packages/rendering/index.d.ts +2 -0
- package/dist/packages/rendering/src/CadMaterialManager.d.ts +6 -1
- package/dist/packages/rendering/src/RenderPipelineProvider.d.ts +4 -1
- package/dist/packages/rendering/src/pointcloud-rendering/PointCloudMaterial.d.ts +4 -0
- package/dist/packages/rendering/src/pointcloud-rendering/PointCloudObjectAppearanceTexture.d.ts +1 -0
- package/dist/packages/rendering/src/pointcloud-rendering/constants.d.ts +44 -0
- package/dist/packages/rendering/src/render-passes/CadShadowPass.d.ts +31 -0
- package/dist/packages/rendering/src/render-passes/PostProcessingPass.d.ts +12 -1
- package/dist/packages/rendering/src/render-passes/ShadowMapPass.d.ts +56 -0
- package/dist/packages/rendering/src/render-passes/types.d.ts +3 -0
- package/dist/packages/rendering/src/render-pipeline-providers/DefaultRenderPipelineProvider.d.ts +10 -2
- package/dist/packages/rendering/src/render-pipeline-providers/types.d.ts +19 -1
- package/dist/packages/rendering/src/rendering/CadShadowReceiverForCustomObjectMaterial.d.ts +15 -0
- package/dist/packages/rendering/src/rendering/cadLighting.d.ts +5 -0
- package/dist/packages/rendering/src/rendering/shaders.d.ts +1 -0
- package/dist/packages/rendering/src/rendering/types.d.ts +1 -0
- package/dist/packages/utilities/index.d.ts +1 -0
- package/dist/packages/utilities/src/SceneHandler.d.ts +2 -0
- package/dist/packages/utilities/src/customObject/CustomObject.d.ts +8 -0
- package/dist/packages/utilities/src/customObject/ICustomObject.d.ts +6 -0
- package/dist/packages/utilities/src/renderContextState.d.ts +4 -0
- package/package.json +6 -6
- package/dist/assets/eptBinaryDecoder.worker-B63sS5sK.js.map +0 -1
- /package/dist/packages/{pointcloud-styling/src → data-providers/src/point-cloud-collections}/PointCloudObjectCollection.d.ts +0 -0
|
@@ -25,3 +25,10 @@ export { DEFAULT_IMAGE_360_OPACITY } from './src/entity/Image360VisualizationBox
|
|
|
25
25
|
export { Image360Action } from './src/Image360Action';
|
|
26
26
|
export { Image360History } from './src/Image360History';
|
|
27
27
|
export { createCollectionIdString } from './src/collection/createCollectionIdString';
|
|
28
|
+
export type { Image360Provider, Image360ProviderMap } from './src/providers/Image360Provider';
|
|
29
|
+
export { getImage360ProviderFromMap } from './src/providers/Image360Provider';
|
|
30
|
+
export { Image360ProviderCombiner } from './src/providers/Image360ProviderCombiner';
|
|
31
|
+
export { Cdf360ImageAnnotationProvider } from './src/providers/Cdf360ImageAnnotationProvider';
|
|
32
|
+
export { CoreDm360ImageAnnotationProvider } from './src/providers/CoreDm360ImageAnnotationProvider';
|
|
33
|
+
export { Local360ImageProvider } from './src/providers/Local360ImageProvider';
|
|
34
|
+
export { getAnnotationIdKey } from './src/providers/annotations';
|
|
@@ -7,10 +7,10 @@ import { Overlay3DIcon } from '../../../3d-overlays';
|
|
|
7
7
|
import { Image360AnnotationAppearance } from '../annotation/types';
|
|
8
8
|
import { ClusterScreenInfo } from '../icons/clustering';
|
|
9
9
|
import { HtmlClusterCollection } from '../icons/clustering/HtmlClusterCoordinator';
|
|
10
|
-
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, Image360FileDescriptor,
|
|
10
|
+
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, Image360FileDescriptor, InstanceReference } from '../../../data-providers';
|
|
11
|
+
import { Image360Provider } from '../providers/Image360Provider';
|
|
11
12
|
import { Image360AnnotationFilter } from '../annotation/Image360AnnotationFilter';
|
|
12
13
|
import { Matrix4, Ray } from 'three';
|
|
13
|
-
import { InstanceReference } from '../../../data-providers/src/types';
|
|
14
14
|
/**
|
|
15
15
|
* Default implementation of {@link Image360Collection}. Used for events when entering
|
|
16
16
|
* and exiting 360 image mode
|
|
@@ -4,7 +4,7 @@ import { DefaultImage360Collection } from './DefaultImage360Collection';
|
|
|
4
4
|
import { IconsOptions } from '../icons/IconCollection';
|
|
5
5
|
import { Matrix4 } from 'three';
|
|
6
6
|
import { Image360AnnotationFilterOptions } from '../annotation/types';
|
|
7
|
-
import { Image360ProviderMap } from '
|
|
7
|
+
import { Image360ProviderMap } from '../providers/Image360Provider';
|
|
8
8
|
export declare class Image360CollectionFactory {
|
|
9
9
|
private readonly _image360ProviderMap;
|
|
10
10
|
private readonly _sceneHandler;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { DeviceDescriptor, SceneHandler } from '../../../utilities';
|
|
2
|
-
import { DataSourceType
|
|
2
|
+
import { DataSourceType } from '../../../data-providers';
|
|
3
|
+
import { Image360Provider } from '../providers/Image360Provider';
|
|
3
4
|
import { Image360 } from './Image360';
|
|
4
5
|
import { Historical360ImageSet, Image360RevisionId } from '../../../data-providers/src/types';
|
|
5
6
|
import { Image360RevisionEntity } from './Image360RevisionEntity';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { Image360Descriptor, Image360RevisionId, DataSourceType
|
|
1
|
+
import { Image360Descriptor, Image360RevisionId, DataSourceType } from '../../../data-providers';
|
|
2
|
+
import { Image360Provider } from '../providers/Image360Provider';
|
|
2
3
|
import { Image360Revision } from './Image360Revision';
|
|
3
4
|
import { Image360VisualizationBox } from './Image360VisualizationBox';
|
|
4
5
|
import { JpegType } from '../utils/JpegDataStreamParser';
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { AnnotationModel } from '@cognite/sdk';
|
|
2
|
-
import { FaceName,
|
|
3
|
-
import {
|
|
4
|
-
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info,
|
|
5
|
-
import {
|
|
2
|
+
import { FaceName, Image360FileDescriptor, InstanceReference, ClassicDataSourceType, DataSourceType, DMDataSourceType, Cdf360ImageAnnotationCache } from '../../../data-providers';
|
|
3
|
+
import { Image360AnnotationFilterDelegate, Image360AnnotationProvider, Image360AnnotationSpecifier } from './Image360AnnotationProvider';
|
|
4
|
+
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, Image360AnnotationAssetQueryResult } from '../collection/Image360Collection';
|
|
5
|
+
import { DefaultImage360Collection } from '../collection/DefaultImage360Collection';
|
|
6
|
+
import { Image360Entity } from '../entity/Image360Entity';
|
|
7
|
+
import { Image360RevisionEntity } from '../entity/Image360RevisionEntity';
|
|
6
8
|
export type RevisionFaceRelation = {
|
|
7
9
|
entity: Image360Entity<ClassicDataSourceType>;
|
|
8
10
|
revision: Image360RevisionEntity<ClassicDataSourceType>;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ClassicDataSourceType, DataSourceType, DMDataSourceType } from '
|
|
2
|
-
import { Image360AnnotationFilterDelegate, Image360AnnotationProvider, Image360AnnotationSpecifier
|
|
3
|
-
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info,
|
|
1
|
+
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, InstanceReference } from '../../../data-providers';
|
|
2
|
+
import { Image360AnnotationFilterDelegate, Image360AnnotationProvider, Image360AnnotationSpecifier } from './Image360AnnotationProvider';
|
|
3
|
+
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, Image360AnnotationAssetQueryResult } from '../collection/Image360Collection';
|
|
4
|
+
import { DefaultImage360Collection } from '../collection/DefaultImage360Collection';
|
|
4
5
|
import { CogniteClient } from '@cognite/sdk';
|
|
5
6
|
export declare class CoreDm360ImageAnnotationProvider implements Image360AnnotationProvider<DMDataSourceType> {
|
|
6
7
|
private readonly _client;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, Image360RevisionId, Image360FileDescriptor } from '../../../data-providers';
|
|
2
|
+
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, Image360AnnotationAssetQueryResult } from '../collection/Image360Collection';
|
|
3
|
+
import { DefaultImage360Collection } from '../collection/DefaultImage360Collection';
|
|
4
|
+
import { Image360AnnotationInstanceReference } from '../annotation/types';
|
|
5
|
+
export type Image360AnnotationFilterDelegate<T extends DataSourceType> = (annotation: T['image360AnnotationType']) => boolean;
|
|
6
|
+
export type Image360AnnotationSpecifier<T extends DataSourceType> = {
|
|
7
|
+
revisionId: Image360RevisionId<T>;
|
|
8
|
+
fileDescriptors: Image360FileDescriptor[];
|
|
9
|
+
};
|
|
10
|
+
export interface Image360AnnotationProvider<T extends DataSourceType> {
|
|
11
|
+
getRelevant360ImageAnnotations(annotationSpecifier: Image360AnnotationSpecifier<T>): Promise<T['image360AnnotationType'][]>;
|
|
12
|
+
/**
|
|
13
|
+
* Resolves the mapping from internal file IDs (annotatedResourceId) to external IDs.
|
|
14
|
+
* This is needed to match annotations to face descriptors when descriptors use externalId.
|
|
15
|
+
* Optional - if not implemented, the caller should build mapping from descriptors only.
|
|
16
|
+
*/
|
|
17
|
+
resolveFileIdToExternalIdMapping?(annotations: T['image360AnnotationType'][], descriptors: Image360FileDescriptor[]): Promise<Map<number, string>>;
|
|
18
|
+
findImageAnnotationsForInstance(instanceFilter: Image360AnnotationInstanceReference<T>, collection: DefaultImage360Collection<T>): Promise<Image360AnnotationAssetQueryResult<T>[]>;
|
|
19
|
+
getAllImage360AnnotationInfos(source: 'assets', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<ClassicDataSourceType>[]>;
|
|
20
|
+
getAllImage360AnnotationInfos(source: 'hybrid', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetHybridAnnotationImage360Info[]>;
|
|
21
|
+
getAllImage360AnnotationInfos(source: 'cdm', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<DMDataSourceType>[]>;
|
|
22
|
+
getAllImage360AnnotationInfos(source: 'all', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<DataSourceType>[]>;
|
|
23
|
+
getAllImage360AnnotationInfos(source: 'assets' | 'hybrid' | 'cdm' | 'all', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<ClassicDataSourceType>[] | AssetAnnotationImage360Info<DMDataSourceType>[] | AssetAnnotationImage360Info<DataSourceType>[] | AssetHybridAnnotationImage360Info[]>;
|
|
24
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Image360CollectionSourceType } from '
|
|
2
|
-
import { ClassicDataSourceType, DataSourceType, DMDataSourceType } from '
|
|
3
|
-
import {
|
|
1
|
+
import { Image360CollectionSourceType } from '../types';
|
|
2
|
+
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, Image360DescriptorProvider, Image360FileProvider } from '../../../data-providers';
|
|
3
|
+
import { Image360AnnotationProvider } from './Image360AnnotationProvider';
|
|
4
4
|
export type Image360ProviderMap = Map<Image360CollectionSourceType, Image360Provider<DMDataSourceType> | Image360Provider<ClassicDataSourceType>>;
|
|
5
5
|
export declare function getImage360ProviderFromMap<T extends DataSourceType>(identifier: T['image360Identifier'], providerMap: Image360ProviderMap): Image360Provider<T>;
|
|
6
6
|
export interface Image360Provider<T extends DataSourceType> extends Image360DescriptorProvider<T>, Image360FileProvider, Image360AnnotationProvider<T> {
|
package/dist/packages/{data-providers/src → 360-images/src/providers}/Image360ProviderCombiner.d.ts
RENAMED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { Image360Provider } from './Image360Provider';
|
|
2
|
-
import { ClassicDataSourceType, DataSourceType, DMDataSourceType } from '
|
|
3
|
-
import {
|
|
4
|
-
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info,
|
|
5
|
-
import {
|
|
2
|
+
import { ClassicDataSourceType, DataSourceType, DMDataSourceType, Historical360ImageSet, Image360DescriptorProvider, Image360Face, Image360FileDescriptor, Image360FileProvider } from '../../../data-providers';
|
|
3
|
+
import { Image360AnnotationFilterDelegate, Image360AnnotationProvider, Image360AnnotationSpecifier } from './Image360AnnotationProvider';
|
|
4
|
+
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, Image360AnnotationAssetQueryResult } from '../collection/Image360Collection';
|
|
5
|
+
import { DefaultImage360Collection } from '../collection/DefaultImage360Collection';
|
|
6
|
+
import { Image360AnnotationInstanceReference } from '../annotation/types';
|
|
6
7
|
export declare class Image360ProviderCombiner<T extends DataSourceType> implements Image360Provider<T> {
|
|
7
8
|
private readonly _descriptorProvider;
|
|
8
9
|
private readonly _fileProvider;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { Image360Provider } from '
|
|
2
|
-
import { Historical360ImageSet,
|
|
1
|
+
import { Image360Provider } from './Image360Provider';
|
|
2
|
+
import { Historical360ImageSet, Image360Face, Image360FileDescriptor, InstanceReference, ClassicDataSourceType, DataSourceType, DMDataSourceType } from '../../../data-providers';
|
|
3
|
+
import { Image360AnnotationFilterDelegate, Image360AnnotationSpecifier } from './Image360AnnotationProvider';
|
|
3
4
|
import { CogniteInternalId, IdEither } from '@cognite/sdk';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
5
|
+
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, Image360AnnotationAssetQueryResult } from '../collection/Image360Collection';
|
|
6
|
+
import { DefaultImage360Collection } from '../collection/DefaultImage360Collection';
|
|
6
7
|
export declare class Local360ImageProvider implements Image360Provider<ClassicDataSourceType> {
|
|
7
8
|
private readonly _modelUrl;
|
|
8
9
|
constructor(modelUrl: string);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { DataSourceType } from '
|
|
1
|
+
import { DataSourceType } from '../../../data-providers';
|
|
2
2
|
export declare function getAnnotationIdKey(annotation: DataSourceType['image360AnnotationType']): string;
|
|
@@ -26,6 +26,7 @@ export declare class Image360ApiHelper<DataSourceT extends DataSourceType> {
|
|
|
26
26
|
private readonly onBeforeRender;
|
|
27
27
|
private readonly onKeyPressed;
|
|
28
28
|
readonly onHover: (event: PointerEvent) => void;
|
|
29
|
+
readonly onPointerLeave: () => void;
|
|
29
30
|
readonly onClick: (event: PointerEventData) => Promise<boolean>;
|
|
30
31
|
private readonly updateHoverStateOnRenderHandler;
|
|
31
32
|
constructor(cogniteClient: CogniteClient, sceneHandler: SceneHandler, domElement: HTMLElement, activeCameraManager: ProxyCameraManager, inputHandler: InputHandler, onBeforeSceneRendered: EventTrigger<BeforeSceneRenderedDelegate>, hasEventListeners?: boolean, iconsOptions?: IconsOptions);
|
|
@@ -77,6 +78,7 @@ export declare class Image360ApiHelper<DataSourceT extends DataSourceType> {
|
|
|
77
78
|
*/
|
|
78
79
|
findBestNext360ImageEntity(clickedWorldPosition: Vector3): Image360WithCollection<DataSourceT> | undefined;
|
|
79
80
|
private setHoverIconOnIntersect;
|
|
81
|
+
clearHoverIntersection(): void;
|
|
80
82
|
private exit360ImageByTween;
|
|
81
83
|
private getImageOpacity;
|
|
82
84
|
}
|
|
@@ -38,12 +38,15 @@ export declare class RevealManager {
|
|
|
38
38
|
setOutputRenderTarget(target: WebGLRenderTarget | null, autoSizeRenderTarget?: boolean): void;
|
|
39
39
|
get materialManager(): CadMaterialManager;
|
|
40
40
|
get needsRedraw(): boolean;
|
|
41
|
+
get cameraInMotion(): boolean;
|
|
41
42
|
update(camera: PerspectiveCamera): void;
|
|
42
43
|
get cadBudget(): CadModelBudget;
|
|
43
44
|
set cadBudget(budget: CadModelBudget);
|
|
44
45
|
get cadLoadedStatistics(): CadModelSectorLoadStatistics;
|
|
45
46
|
get cadRenderMode(): RenderMode;
|
|
46
47
|
set cadRenderMode(renderMode: RenderMode);
|
|
48
|
+
get shadowsEnabled(): boolean;
|
|
49
|
+
set shadowsEnabled(enabled: boolean);
|
|
47
50
|
get pointCloudBudget(): PointCloudBudget;
|
|
48
51
|
set pointCloudBudget(budget: PointCloudBudget);
|
|
49
52
|
set clippingPlanes(clippingPlanes: Plane[]);
|
|
@@ -24,6 +24,8 @@ export declare class Cognite3DViewer<DataSourceT extends DataSourceType = Classi
|
|
|
24
24
|
private readonly _domElementResizeObserver;
|
|
25
25
|
private readonly _image360ApiHelper;
|
|
26
26
|
private readonly _unsubsribeOnLoading;
|
|
27
|
+
private _onContextLost;
|
|
28
|
+
private _onContextRestored;
|
|
27
29
|
/**
|
|
28
30
|
* Returns the rendering canvas, the DOM element where the renderer draws its output.
|
|
29
31
|
*/
|
|
@@ -83,6 +85,19 @@ export declare class Cognite3DViewer<DataSourceT extends DataSourceType = Classi
|
|
|
83
85
|
* budget is shared between all added CAD models and not a per-model budget.
|
|
84
86
|
*/
|
|
85
87
|
set cadBudget(budget: CadModelBudget);
|
|
88
|
+
/**
|
|
89
|
+
* Gets whether CAD shadows are currently enabled.
|
|
90
|
+
* @beta
|
|
91
|
+
*/
|
|
92
|
+
get shadowsEnabled(): boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Enables or disables CAD shadows at runtime, along with the world-space sun shading
|
|
95
|
+
* that matches them. Turning shadows on changes the CAD look even where no shadow is
|
|
96
|
+
* cast, including ghosted nodes. The GPU resources are allocated the first time shadows
|
|
97
|
+
* are enabled.
|
|
98
|
+
* @beta
|
|
99
|
+
*/
|
|
100
|
+
set shadowsEnabled(enabled: boolean);
|
|
86
101
|
/**
|
|
87
102
|
* Returns the point cloud budget. The budget is shared between all loaded
|
|
88
103
|
* point cloud models.
|
|
@@ -98,6 +113,12 @@ export declare class Cognite3DViewer<DataSourceT extends DataSourceType = Classi
|
|
|
98
113
|
*/
|
|
99
114
|
get models(): CogniteModel<DataSourceT>[];
|
|
100
115
|
constructor(options: Cognite3DViewerOptions);
|
|
116
|
+
/**
|
|
117
|
+
* Listens for render context loss/restore. On loss, prevents the default (so the
|
|
118
|
+
* browser attempts recovery) and sets `isRenderContextLost()`; on restore, clears
|
|
119
|
+
* the flag and requests a redraw.
|
|
120
|
+
*/
|
|
121
|
+
private registerContextLossHandlers;
|
|
101
122
|
/**
|
|
102
123
|
* Get resolution options that are set on the viewer. This includes
|
|
103
124
|
* settings for max resolution and limiting resolution when moving the camera.
|
|
@@ -677,6 +698,7 @@ export declare class Cognite3DViewer<DataSourceT extends DataSourceType = Classi
|
|
|
677
698
|
* @param options
|
|
678
699
|
* @param options.stopOnHitting360Icon
|
|
679
700
|
* @param options.predicate Check whether a CustomObject should be intersected.
|
|
701
|
+
* @param options.forceWindowedPick Skip point-cloud full-frame pick caching for this call.
|
|
680
702
|
* @returns A promise that if there was an intersection then return the intersection object - otherwise it
|
|
681
703
|
* returns `null` if there were no intersections.
|
|
682
704
|
* @beta
|
|
@@ -684,6 +706,7 @@ export declare class Cognite3DViewer<DataSourceT extends DataSourceType = Classi
|
|
|
684
706
|
getAnyIntersectionFromPixel(pixelCoords: Vector2, options?: {
|
|
685
707
|
stopOnHitting360Icon?: boolean;
|
|
686
708
|
predicate?: (customObject: ICustomObject) => boolean;
|
|
709
|
+
forceWindowedPick?: boolean;
|
|
687
710
|
}): Promise<AnyIntersection<DataSourceT> | undefined>;
|
|
688
711
|
/**
|
|
689
712
|
* Event function to click on 360 images.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SsaoParameters, AntiAliasingMode } from '../../../../rendering';
|
|
1
|
+
import { EdlOptions, SsaoParameters, AntiAliasingMode } from '../../../../rendering';
|
|
2
2
|
import { DeviceDescriptor } from '../../../../utilities';
|
|
3
3
|
import { PropType } from '../../utilities/reflection';
|
|
4
4
|
import { Cognite3DViewerOptions } from './types';
|
|
@@ -30,4 +30,9 @@ export declare function determineSsaoRenderParameters(qualityHint: SsaoQualityHi
|
|
|
30
30
|
* @param devicePixelRatio Device pixel ratio set on the renderer.
|
|
31
31
|
*/
|
|
32
32
|
export declare function determineResolutionCap(rendererResolutionThreshold: number | undefined, device: DeviceDescriptor, devicePixelRatio: number): number;
|
|
33
|
+
/**
|
|
34
|
+
* Create EDL options from input options. The radius is clamped to the maximum supported radius.
|
|
35
|
+
* @param inputOptions
|
|
36
|
+
*/
|
|
37
|
+
export declare function createCompleteEdlOptions(inputOptions?: Partial<EdlOptions> | 'disabled'): EdlOptions;
|
|
33
38
|
export {};
|
|
@@ -147,6 +147,15 @@ export interface Cognite3DViewerOptions {
|
|
|
147
147
|
* Enables / disables visualizing the edges of geometry. Defaults to true.
|
|
148
148
|
*/
|
|
149
149
|
enableEdges?: boolean;
|
|
150
|
+
/**
|
|
151
|
+
* Enables shadows cast by CAD geometry, and the world-space sun shading that goes with
|
|
152
|
+
* them. Turning shadows on changes the CAD look even where no shadow is cast, including
|
|
153
|
+
* ghosted nodes. Defaults to false. Can also be toggled at runtime through
|
|
154
|
+
* {@link Cognite3DViewer.shadowsEnabled}.
|
|
155
|
+
* GPU resources for shadows are only allocated the first time they are enabled.
|
|
156
|
+
* @beta
|
|
157
|
+
*/
|
|
158
|
+
enableShadows?: boolean;
|
|
150
159
|
/** Callback to download stream progress. */
|
|
151
160
|
onLoading?: OnLoadingCallback;
|
|
152
161
|
/**
|
|
@@ -7,7 +7,7 @@ import { CognitePointCloudModel } from '../../../pointclouds';
|
|
|
7
7
|
*/
|
|
8
8
|
export type CogniteModel<T extends DataSourceType = ClassicDataSourceType> = CogniteCadModel | CognitePointCloudModel<T>;
|
|
9
9
|
export { WellKnownAsprsPointClassCodes } from '../../../pointclouds';
|
|
10
|
-
export { PointShape, PointColorType, PointSizeType } from '../../../rendering';
|
|
10
|
+
export { PointShape, PointColorType, PointSizeType, CadShadowReceiverForCustomObjectMaterial } from '../../../rendering';
|
|
11
11
|
/**
|
|
12
12
|
* A tuple of a 360 image and its collection.
|
|
13
13
|
*/
|
|
@@ -1,25 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright 2022 Cognite AS
|
|
3
|
+
*/
|
|
4
|
+
export type { GeometryFilter } from '../../data-providers';
|
|
2
5
|
/**
|
|
3
6
|
* Units supported by {@link CogniteCadModel}.
|
|
4
7
|
*/
|
|
5
8
|
export type WellKnownUnit = 'Meters' | 'Centimeters' | 'Millimeters' | 'Micrometers' | 'Kilometers' | 'Feet' | 'Inches' | 'Yards' | 'Miles' | 'Mils' | 'Microinches';
|
|
6
|
-
export type GeometryFilter = {
|
|
7
|
-
/**
|
|
8
|
-
* The bounds to load geometry within. By default this box is in CDF coordinate space which
|
|
9
|
-
* will be transformed into coordinates relative to the model using the the model transformation
|
|
10
|
-
* which can be specified using {@link https://docs.cognite.com/api/v1/#operation/update3DRevisions |the CDF API},
|
|
11
|
-
* or set in {@link https://fusion.cognite.com/ |Cognite Fusion}.
|
|
12
|
-
* @see {@link GeometryFilter.isBoundingBoxInModelCoordinates}.
|
|
13
|
-
*/
|
|
14
|
-
boundingBox?: Box3;
|
|
15
|
-
/**
|
|
16
|
-
* When set, the geometry filter `boundingBox` will be considered to be in "Reveal/ThreeJS space".
|
|
17
|
-
* Rather than CDF space which is the default. When using Reveal space, the model transformation
|
|
18
|
-
* which can be specified using {@link https://docs.cognite.com/api/v1/#operation/update3DRevisions |the CDF API},
|
|
19
|
-
* or set in {@link https://fusion.cognite.com/ |Cognite Fusion}.
|
|
20
|
-
*/
|
|
21
|
-
isBoundingBoxInModelCoordinates?: boolean;
|
|
22
|
-
};
|
|
23
9
|
export type CadModelSectorLoadStatistics = {
|
|
24
10
|
/**
|
|
25
11
|
* Estimated number of bytes to download sectors.
|
|
@@ -2,12 +2,11 @@ import { PerspectiveCamera, Scene, Box3, Vector3 } from 'three';
|
|
|
2
2
|
import { FlexibleControls } from './FlexibleControls';
|
|
3
3
|
import { FlexibleControlsOptions } from './FlexibleControlsOptions';
|
|
4
4
|
import { PointerEvents } from '../../../utilities';
|
|
5
|
-
import { CameraEventDelegate,
|
|
5
|
+
import { CameraEventDelegate, CameraManagerEventType, CameraState, RaycastCallback } from './../types';
|
|
6
6
|
import { CameraManager } from './../CameraManager';
|
|
7
7
|
import { FlexibleControlsType } from './FlexibleControlsType';
|
|
8
8
|
import { FlexibleControlsTypeChangeDelegate, IFlexibleCameraManager } from './IFlexibleCameraManager';
|
|
9
9
|
import { FlexibleCameraEventTarget } from './FlexibleCameraEventTarget';
|
|
10
|
-
type RaycastCallback = (x: number, y: number, pickBoundingBox: boolean) => Promise<CameraManagerCallbackData>;
|
|
11
10
|
/**
|
|
12
11
|
* Flexible implementation of {@link CameraManager}. The user can switch between Orbit, FirstPersion or OrbitInCenter
|
|
13
12
|
* Supports automatic update of camera near and far planes and animated change of camera position and target.
|
|
@@ -79,4 +78,3 @@ export declare class FlexibleCameraManager extends PointerEvents implements IFle
|
|
|
79
78
|
private updateControlsSensitivity;
|
|
80
79
|
static as(manager: CameraManager): FlexibleCameraManager | undefined;
|
|
81
80
|
}
|
|
82
|
-
export {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { Vector2, Vector3 } from 'three';
|
|
2
|
-
export type GetPickedPointByPixelCoordinates = (position: Vector2) => Promise<Vector3>;
|
|
2
|
+
export type GetPickedPointByPixelCoordinates = (position: Vector2, forceWindowedPick?: boolean) => Promise<Vector3>;
|
|
@@ -54,6 +54,11 @@ export type CameraManagerCallbackData = {
|
|
|
54
54
|
*/
|
|
55
55
|
pickedBoundingBox: Box3 | undefined;
|
|
56
56
|
};
|
|
57
|
+
/**
|
|
58
|
+
* Callback used by camera managers to request a raycast/pick against the scene.
|
|
59
|
+
* @beta
|
|
60
|
+
*/
|
|
61
|
+
export type RaycastCallback = (x: number, y: number, pickBoundingBox: boolean, forceWindowedPick?: boolean) => Promise<CameraManagerCallbackData>;
|
|
57
62
|
/**
|
|
58
63
|
* List of supported event types (adapted from https://stackoverflow.com/questions/44480644/string-union-to-string-array)
|
|
59
64
|
*/
|
|
@@ -5,26 +5,26 @@ export { CdfModelDataProvider } from './src/model-data-providers/CdfModelDataPro
|
|
|
5
5
|
export { CachedModelDataProvider } from './src/model-data-providers/CachedModelDataProvider';
|
|
6
6
|
export { CdfModelIdentifier } from './src/model-identifiers/CdfModelIdentifier';
|
|
7
7
|
export { CdfModelMetadataProvider } from './src/metadata-providers/CdfModelMetadataProvider';
|
|
8
|
-
export { getAnnotationIdKey } from './src/image-360-data-providers/annotations';
|
|
9
|
-
export { Cdf360ImageAnnotationProvider } from './src/image-360-data-providers/Cdf360ImageAnnotationProvider';
|
|
10
8
|
export { type Cdf360ImageAnnotationCache, createCdf360ImageAnnotationCache } from './src/image-360-data-providers/Cdf360ImageAnnotationCache';
|
|
11
9
|
export { Cdf360EventDescriptorProvider } from './src/image-360-data-providers/descriptor-providers/events/Cdf360EventDescriptorProvider';
|
|
12
|
-
export { CoreDm360ImageAnnotationProvider } from './src/image-360-data-providers/CoreDm360ImageAnnotationProvider';
|
|
13
10
|
export { Cdf360CdmDescriptorProvider } from './src/image-360-data-providers/descriptor-providers/datamodels/cdm/Cdf360CdmDescriptorProvider';
|
|
14
11
|
export { Cdf360ImageFileProvider } from './src/image-360-data-providers/Cdf360ImageFileProvider';
|
|
15
12
|
export type { Image360DataModelIdentifier, Image360CoreDataModelIdentifier, Image360LegacyDataModelIdentifier, Image360BaseIdentifier } from './src/image-360-data-providers/descriptor-providers/datamodels/system-space/Cdf360DataModelsDescriptorProvider';
|
|
16
13
|
export { Cdf360DataModelsDescriptorProvider } from './src/image-360-data-providers/descriptor-providers/datamodels/system-space/Cdf360DataModelsDescriptorProvider';
|
|
17
|
-
export { isClassic360Identifier, isCoreDmImage360Identifier, isLegacyDM360Identifier, isFdm360ImageCollectionIdentifier, isClassicMetadata360Identifier } from './src/image-360-data-providers/shared';
|
|
14
|
+
export { isClassic360Identifier, isCoreDmImage360Identifier, isLegacyDM360Identifier, isFdm360ImageCollectionIdentifier, isClassicMetadata360Identifier, isSameImage360RevisionId } from './src/image-360-data-providers/shared';
|
|
15
|
+
export { fetchCoreDm360AnnotationsForRevision } from './src/image-360-data-providers/cdm/fetchCoreDm360AnnotationsForRevision';
|
|
16
|
+
export { fetchAnnotationsForInstance, type Image360AnnotationsForInstanceResult } from './src/image-360-data-providers/cdm/fetchAnnotationsForInstance';
|
|
17
|
+
export { fetchCoreDm360AnnotationsForCollection } from './src/image-360-data-providers/cdm/fetchCoreDm360AnnotationsForCollection';
|
|
18
18
|
export type { CoreDmImage360Annotation } from './src/image-360-data-providers/cdm/types';
|
|
19
19
|
export { LocalModelDataProvider } from './src/model-data-providers/LocalModelDataProvider';
|
|
20
20
|
export { LocalModelIdentifier } from './src/model-identifiers/LocalModelIdentifier';
|
|
21
21
|
export { DMModelIdentifier } from './src/model-identifiers/DMModelIdentifier';
|
|
22
22
|
export { LocalModelMetadataProvider } from './src/metadata-providers/LocalModelMetadataProvider';
|
|
23
|
-
export { Local360ImageProvider } from './src/image-360-data-providers/Local360ImageProvider';
|
|
24
23
|
export type { ModelIdentifier } from './src/ModelIdentifier';
|
|
25
24
|
export { createModelIdentifier } from './src/ModelIdentifier';
|
|
26
25
|
export type { ModelMetadataProvider } from './src/ModelMetadataProvider';
|
|
27
26
|
export type { ModelDataProvider } from './src/ModelDataProvider';
|
|
27
|
+
export type { GeometryFilter } from './src/GeometryFilter';
|
|
28
28
|
export type { PointCloudObjectMetadata, PointCloudObject } from './src/pointcloud-stylable-object-providers/types';
|
|
29
29
|
export type { PointCloudStylableObjectProvider } from './src/PointCloudStylableObjectProvider';
|
|
30
30
|
export type { StylableObject, SerializableStylableObject } from './src/pointcloud-stylable-object-providers/StylableObject';
|
|
@@ -32,16 +32,16 @@ export { CdfPointCloudStylableObjectProvider } from './src/pointcloud-stylable-o
|
|
|
32
32
|
export { DummyPointCloudStylableObjectProvider } from './src/pointcloud-stylable-object-providers/DummyPointCloudStylableObjectProvider';
|
|
33
33
|
export { CdfPointCloudDMStylableObjectProvider } from './src/pointcloud-stylable-object-providers/pointcloud-volume-data-providers/CdfPointCloudDMStylableObjectProvider';
|
|
34
34
|
export { DummyPointCloudDMStylableObjectProvider } from './src/pointcloud-stylable-object-providers/pointcloud-volume-data-providers/DummyPointCloudDMStylableObjectProvider';
|
|
35
|
-
export type {
|
|
36
|
-
export { getImage360ProviderFromMap } from './src/Image360Provider';
|
|
37
|
-
export { Image360ProviderCombiner } from './src/Image360ProviderCombiner';
|
|
38
|
-
export type { BinaryFileProvider, JsonFileProvider, SignedFileProvider, BlobOutputMetadata, Image360Descriptor, Image360FileProvider, Image360Face, Image360Texture, Image360FileDescriptor, ImageAssetLinkAnnotationInfo, ImageInstanceLinkAnnotationInfo, InstanceReference, Image360Id, Image360RevisionId, SignedFileItem } from './src/types';
|
|
35
|
+
export type { BinaryFileProvider, JsonFileProvider, SignedFileProvider, BlobOutputMetadata, Image360Descriptor, Image360DescriptorProvider, Image360FileProvider, Image360Face, Image360Texture, Image360FileDescriptor, ImageAssetLinkAnnotationInfo, ImageInstanceLinkAnnotationInfo, InstanceReference, Image360Id, Image360RevisionId, Historical360ImageSet, FaceName, SignedFileItem } from './src/types';
|
|
39
36
|
export { File3dFormat } from './src/types';
|
|
40
37
|
export { fetchDMModelIdFromRevisionId } from './src/requests/fetchDMModelIdFromRevisionId';
|
|
41
38
|
export { isDMPointCloudVolumeObject, isClassicPointCloudVolumeObject, isDMPointCloudVolume, isClassicPointCloudVolume } from './src/utilities/utils';
|
|
42
39
|
export { getExternalIdFromDescriptor } from './src/utilities/getExternalIdFromDescriptor';
|
|
40
|
+
export { getInstanceKey } from './src/utilities/instanceIds';
|
|
43
41
|
export type { DataSourceType, ClassicDataSourceType, DMDataSourceType, ClassicModelIdentifierType, DMModelIdentifierType, InternalDataSourceType, LocalDataSourceType, LocalModelIdentifierType, GenericDataSourceType } from './src/DataSourceType';
|
|
44
|
-
export { isClassicIdentifier, isDMIdentifier, isLocalIdentifier } from './src/DataSourceType';
|
|
42
|
+
export { isClassicIdentifier, isDMIdentifier, isLocalIdentifier, isSameDMIdentifier } from './src/DataSourceType';
|
|
45
43
|
export type { LocalAddModelOptions, CommonModelOptions, InternalAddModelOptions, AddModelOptionsWithModelRevisionId } from './src/utilities/internalAddModelOptions';
|
|
46
44
|
export type { MetadataWithSignedFiles } from './src/metadata-providers/types';
|
|
47
45
|
export { SignedUrlRefresher, type FetchWithRefreshOptions } from './src/utilities/SignedUrlRefresh';
|
|
46
|
+
export { PointCloudObjectCollection, PointCloudAnnotationVolumeCollection } from './src/point-cloud-collections/PointCloudObjectCollection';
|
|
47
|
+
export { PointCloudDMVolumeCollection } from './src/point-cloud-collections/PointCloudDMVolumeCollection';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { AnnotationModel, AnnotationsAssetRef } from '@cognite/sdk';
|
|
2
2
|
import { Image360DataModelIdentifier } from './image-360-data-providers/descriptor-providers/datamodels/system-space/Cdf360DataModelsDescriptorProvider';
|
|
3
|
-
import { PointCloudAnnotationVolumeCollection
|
|
3
|
+
import { PointCloudAnnotationVolumeCollection } from './point-cloud-collections/PointCloudObjectCollection';
|
|
4
|
+
import { PointCloudDMVolumeCollection } from './point-cloud-collections/PointCloudDMVolumeCollection';
|
|
4
5
|
import { CoreDmImage360Annotation } from './image-360-data-providers/cdm/types';
|
|
5
6
|
import { DMInstanceRef } from '../../utilities';
|
|
6
7
|
/**
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Box3 } from 'three';
|
|
2
|
+
export type GeometryFilter = {
|
|
3
|
+
/**
|
|
4
|
+
* The bounds to load geometry within. By default this box is in CDF coordinate space which
|
|
5
|
+
* will be transformed into coordinates relative to the model using the the model transformation
|
|
6
|
+
* which can be specified using {@link https://docs.cognite.com/api/v1/#operation/update3DRevisions |the CDF API},
|
|
7
|
+
* or set in {@link https://fusion.cognite.com/ |Cognite Fusion}.
|
|
8
|
+
* @see {@link GeometryFilter.isBoundingBoxInModelCoordinates}.
|
|
9
|
+
*/
|
|
10
|
+
boundingBox?: Box3;
|
|
11
|
+
/**
|
|
12
|
+
* When set, the geometry filter `boundingBox` will be considered to be in "Reveal/ThreeJS space".
|
|
13
|
+
* Rather than CDF space which is the default. When using Reveal space, the model transformation
|
|
14
|
+
* which can be specified using {@link https://docs.cognite.com/api/v1/#operation/update3DRevisions |the CDF API},
|
|
15
|
+
* or set in {@link https://fusion.cognite.com/ |Cognite Fusion}.
|
|
16
|
+
*/
|
|
17
|
+
isBoundingBoxInModelCoordinates?: boolean;
|
|
18
|
+
};
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import { AnnotationModel, AnnotationsTypesImagesAssetLink, AnnotationsTypesImagesInstanceLink, IdEither } from '@cognite/sdk';
|
|
2
2
|
import { Matrix4, Texture } from 'three';
|
|
3
3
|
import { ClassicDataSourceType, DataSourceType, DMDataSourceType } from './DataSourceType';
|
|
4
|
-
import { AssetAnnotationImage360Info, AssetHybridAnnotationImage360Info, DefaultImage360Collection, Image360AnnotationAssetQueryResult, Image360AnnotationInstanceReference } from '../../360-images';
|
|
5
4
|
import { DMInstanceRef } from '../../utilities';
|
|
6
5
|
import { ModelIdentifier } from './ModelIdentifier';
|
|
7
|
-
export type Image360AnnotationFilterDelegate<T extends DataSourceType> = (annotation: T['image360AnnotationType']) => boolean;
|
|
8
6
|
export interface JsonFileProvider {
|
|
9
7
|
/**
|
|
10
8
|
* Download and parse a JSON file and return the resulting struct.
|
|
@@ -48,29 +46,10 @@ export type Image360Id<T extends DataSourceType> = Image360RevisionId<T>;
|
|
|
48
46
|
* An ID identifiying a single Image360 revision within a collection
|
|
49
47
|
*/
|
|
50
48
|
export type Image360RevisionId<T extends DataSourceType> = T extends DMDataSourceType ? DMInstanceRef : string;
|
|
51
|
-
export type Image360AnnotationSpecifier<T extends DataSourceType> = {
|
|
52
|
-
revisionId: Image360RevisionId<T>;
|
|
53
|
-
fileDescriptors: Image360FileDescriptor[];
|
|
54
|
-
};
|
|
55
49
|
/**
|
|
56
50
|
* Filter for finding linked annotations in either a classic 360 collection or a new one
|
|
57
51
|
*/
|
|
58
52
|
export type InstanceReference<T extends DataSourceType> = T extends ClassicDataSourceType ? IdEither : DMInstanceRef;
|
|
59
|
-
export interface Image360AnnotationProvider<T extends DataSourceType> {
|
|
60
|
-
getRelevant360ImageAnnotations(annotationSpecifier: Image360AnnotationSpecifier<T>): Promise<T['image360AnnotationType'][]>;
|
|
61
|
-
/**
|
|
62
|
-
* Resolves the mapping from internal file IDs (annotatedResourceId) to external IDs.
|
|
63
|
-
* This is needed to match annotations to face descriptors when descriptors use externalId.
|
|
64
|
-
* Optional - if not implemented, the caller should build mapping from descriptors only.
|
|
65
|
-
*/
|
|
66
|
-
resolveFileIdToExternalIdMapping?(annotations: T['image360AnnotationType'][], descriptors: Image360FileDescriptor[]): Promise<Map<number, string>>;
|
|
67
|
-
findImageAnnotationsForInstance(instanceFilter: Image360AnnotationInstanceReference<T>, collection: DefaultImage360Collection<T>): Promise<Image360AnnotationAssetQueryResult<T>[]>;
|
|
68
|
-
getAllImage360AnnotationInfos(source: 'assets', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<ClassicDataSourceType>[]>;
|
|
69
|
-
getAllImage360AnnotationInfos(source: 'hybrid', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetHybridAnnotationImage360Info[]>;
|
|
70
|
-
getAllImage360AnnotationInfos(source: 'cdm', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<DMDataSourceType>[]>;
|
|
71
|
-
getAllImage360AnnotationInfos(source: 'all', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<DataSourceType>[]>;
|
|
72
|
-
getAllImage360AnnotationInfos(source: 'assets' | 'hybrid' | 'cdm' | 'all', collection: DefaultImage360Collection<T>, annotationFilter: Image360AnnotationFilterDelegate<T>): Promise<AssetAnnotationImage360Info<ClassicDataSourceType>[] | AssetAnnotationImage360Info<DMDataSourceType>[] | AssetAnnotationImage360Info<DataSourceType>[] | AssetHybridAnnotationImage360Info[]>;
|
|
73
|
-
}
|
|
74
53
|
export interface Image360DescriptorProvider<T extends DataSourceType> {
|
|
75
54
|
get360ImageDescriptors(metadataFilter: T['image360Identifier'], preMultipliedRotation: boolean): Promise<Historical360ImageSet<T>[]>;
|
|
76
55
|
}
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
export type { CompletePointCloudAppearance, PointCloudAppearance } from './src/PointCloudAppearance';
|
|
5
5
|
export { DefaultPointCloudAppearance, applyDefaultsToPointCloudAppearance } from './src/PointCloudAppearance';
|
|
6
6
|
export { StyledPointCloudObjectCollection, StyledPointCloudVolumeCollection } from './src/StyledPointCloudVolumeCollection';
|
|
7
|
-
export { PointCloudObjectCollection, PointCloudAnnotationVolumeCollection } from '
|
|
7
|
+
export { PointCloudObjectCollection, PointCloudAnnotationVolumeCollection, PointCloudDMVolumeCollection } from '../data-providers';
|
|
8
8
|
export { AnnotationIdPointCloudObjectCollection } from './src/AnnotationIdPointCloudObjectCollection';
|
|
9
|
-
export { PointCloudDMVolumeCollection } from './src/PointCloudDMVolumeCollection';
|
|
10
9
|
export { isPointCloudObjectCollection, isDMInstanceRefPointCloudObjectCollection } from './src/utils';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PointCloudAnnotationVolumeCollection } from '
|
|
1
|
+
import { PointCloudAnnotationVolumeCollection } from '../../data-providers';
|
|
2
2
|
/**
|
|
3
3
|
* A simple PointCloudAnnotationVolumeCollection that consists of an explicitly provided list of annotation IDs
|
|
4
4
|
*/
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PointCloudDMVolumeCollection } from '
|
|
2
|
-
import { PointCloudAnnotationVolumeCollection } from './PointCloudObjectCollection';
|
|
1
|
+
import { PointCloudDMVolumeCollection, PointCloudAnnotationVolumeCollection } from '../../data-providers';
|
|
3
2
|
export declare function isPointCloudObjectCollection(collection: PointCloudAnnotationVolumeCollection | PointCloudDMVolumeCollection): collection is PointCloudAnnotationVolumeCollection;
|
|
4
3
|
export declare function isDMInstanceRefPointCloudObjectCollection(collection: PointCloudAnnotationVolumeCollection | PointCloudDMVolumeCollection): collection is PointCloudDMVolumeCollection;
|
|
@@ -3,13 +3,33 @@ import { IntersectInput } from '../../model-base';
|
|
|
3
3
|
import { PointCloudNode } from './PointCloudNode';
|
|
4
4
|
import { DataSourceType } from '../../data-providers';
|
|
5
5
|
import { IntersectPointCloudNodeResult } from './types';
|
|
6
|
+
import { EdlOptions } from '../../rendering';
|
|
6
7
|
export declare class PointCloudPickingHandler {
|
|
7
8
|
private readonly _normalized;
|
|
9
|
+
private readonly _drawingBufferSize;
|
|
8
10
|
private readonly _raycaster;
|
|
11
|
+
private readonly _renderer;
|
|
9
12
|
private readonly _picker;
|
|
13
|
+
private readonly _edlOptions;
|
|
10
14
|
private readonly _mutex;
|
|
11
|
-
|
|
12
|
-
|
|
15
|
+
/**
|
|
16
|
+
* @param renderer Renderer used for the pick render.
|
|
17
|
+
* @param edlOptions EDL options the point clouds are rendered with, if any. EDL shades empty pixels
|
|
18
|
+
* within its radius of a point, closing small gaps on screen that the pick render (which has no EDL)
|
|
19
|
+
* still sees as empty, so the pick window is widened to cover that radius.
|
|
20
|
+
*/
|
|
21
|
+
constructor(renderer: WebGLRenderer, edlOptions?: EdlOptions);
|
|
13
22
|
dispose(): void;
|
|
23
|
+
/**
|
|
24
|
+
* Invalidates the picker's cached full-frame pick buffer. Must be called whenever a new
|
|
25
|
+
* frame of the scene is rendered.
|
|
26
|
+
*/
|
|
27
|
+
invalidatePickCache(): void;
|
|
14
28
|
intersectPointClouds(nodes: PointCloudNode<DataSourceType>[], input: IntersectInput): Promise<IntersectPointCloudNodeResult<DataSourceType>[]>;
|
|
29
|
+
private getPickWindowSize;
|
|
15
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Pick window size in drawing buffer pixels. Odd, so the window is centered on the pick position.
|
|
33
|
+
* Wide enough to cover the EDL outline, which is drawn around points on screen but not in the pick render.
|
|
34
|
+
*/
|
|
35
|
+
export declare function computePickWindowSize(edlOptions: EdlOptions | undefined, drawingBufferHeight: number): number;
|