@procore/bim-webviewer-sdk 15.1.0 → 15.2.0-BIM-4193.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/CHANGELOG.md +27 -0
- package/dist/Procore.Bim.Webviewer.d.ts +92 -26
- package/dist/Procore.Bim.Webviewer.js +1 -1
- package/dist/types/src/Webviewer.d.ts +40 -25
- package/dist/types/src/api/analytic_events/analyticKeys.d.ts +5 -0
- package/dist/types/src/api/analytic_events/payloadFactories.d.ts +1 -0
- package/dist/types/src/api/types/Model.d.ts +0 -21
- package/dist/types/src/api/types/ModelRevision.d.ts +9 -0
- package/dist/types/src/api/types/Viewpoint.d.ts +15 -0
- package/dist/types/src/components/Tool.d.ts +19 -0
- package/dist/types/src/components/ToolBarComponent/ToolBarComponent.d.ts +31 -5
- package/dist/types/src/components/ToolBarTools.d.ts +17 -16
- package/dist/types/src/components/ViewpointManager/ViewpointManager.d.ts +10 -2
- package/dist/types/src/components/ViewpointManager/__tests__/fixtures.d.ts +5 -1
- package/dist/types/src/components/WindowModelObjectComponent/WindowModelObjectComponent.d.ts +1 -1
- package/dist/types/src/components/WindowSettingsComponent.d.ts +1 -1
- package/dist/types/src/components/WindowTreeViewComponent.d.ts +4 -4
- package/dist/types/src/components/WindowViewPropertiesComponent/WindowViewPropertiesComponent.d.ts +1 -1
- package/dist/types/src/controllers/Bootstrapper.d.ts +0 -1
- package/dist/types/src/controllers/CacheController.d.ts +2 -1
- package/dist/types/src/controllers/RenderController.d.ts +1 -3
- package/dist/types/src/controllers/RenderControllerProxy.d.ts +1 -0
- package/dist/types/src/controllers/RenderControllerWorker.d.ts +1 -0
- package/dist/types/src/controllers/RendererFactory.d.ts +1 -1
- package/dist/types/src/procoregl/HiddenNodeServices/HiddenNodeServices.d.ts +1 -1
- package/dist/types/src/procoregl/PartitionsRenderer.d.ts +3 -1
- package/dist/types/src/procoregl/PartitionsRendererImpl.d.ts +7 -12
- package/dist/types/src/procoregl/ViewerRenderer.d.ts +5 -18
- package/dist/types/src/pwfreader/PWF.d.ts +14 -7
- package/dist/types/src/pwfreader/streaming/PartitionProxy.d.ts +7 -6
- package/dist/types/src/sdk.d.ts +12 -3
- package/dist/types/src/sectioning/SectionController.d.ts +2 -2
- package/dist/types/src/types/WebviewerOptions.d.ts +3 -2
- package/dist/types/src/utils/ApiMetaData/ApiMetaData.d.ts +1 -1
- package/dist/types/src/utils/ApiMetaData/__tests__/mocks.d.ts +1 -1
- package/dist/types/src/utils/Enums.d.ts +13 -12
- package/dist/types/src/viewpoint/ViewpointFactory.d.ts +5 -1
- package/dist/types/src/viewpoint/types.d.ts +5 -1
- package/package.json +1 -1
- package/dist/types/src/components/ToolEnum.d.ts +0 -4
- package/dist/types/src/procoregl/RelevantMeshnodesSet/RelevantMeshnodesSet.d.ts +0 -31
- package/dist/types/src/procoregl/StandardRenderer.d.ts +0 -91
- package/dist/types/src/procoregl/StandardRendererImpl.d.ts +0 -63
- package/dist/types/src/procoregl/__tests__/StandardRenderer.test.d.ts +0 -1
|
@@ -5,39 +5,54 @@ import { ObjectFilter } from './types/ObjectFilter';
|
|
|
5
5
|
import { PublicNode } from './types/PublicNode';
|
|
6
6
|
import { NavigationMode } from './navigation/NavigationModes';
|
|
7
7
|
import { SectionDataAutodeskFormat, SectionDataProcoreFormat } from './sectioning/SectionController';
|
|
8
|
-
import type { Viewpoint, Visibility } from './api/types/
|
|
8
|
+
import type { Viewpoint, Visibility } from './api/types/Viewpoint';
|
|
9
9
|
import type { CssColor } from './components/Markup/SvgRenderer';
|
|
10
10
|
import { RenderMode } from './utils/constants';
|
|
11
11
|
export declare class Webviewer {
|
|
12
12
|
options: Options;
|
|
13
13
|
static readonly tools: {
|
|
14
|
-
|
|
14
|
+
readonly ALL: 0;
|
|
15
|
+
readonly BOTTOMTOOL: 1;
|
|
16
|
+
readonly FLOORPLAN: 2;
|
|
17
|
+
readonly OBJECTMODELTREE: 3;
|
|
18
|
+
readonly MODELVIEWS: 4;
|
|
19
|
+
readonly COACHMARKS: 5;
|
|
20
|
+
readonly COACHMARKSHIDDEN: 6;
|
|
21
|
+
readonly COACHMARKSECTION: 7;
|
|
22
|
+
readonly MEASUREMENT_SD: 8;
|
|
23
|
+
readonly SETTINGS: 9;
|
|
24
|
+
readonly CONTEXTMENU: 10;
|
|
25
|
+
readonly COACHMARKSFOV: 11;
|
|
26
|
+
readonly VIEW_PROPERTIES: 12;
|
|
27
|
+
readonly LOADING: 13;
|
|
28
|
+
readonly XRAY_MODE: 14;
|
|
29
|
+
readonly SECTION_BOX: 15;
|
|
15
30
|
};
|
|
16
31
|
static readonly toolbar_enum: {
|
|
17
|
-
NONE:
|
|
18
|
-
HOME:
|
|
19
|
-
NAV_DEFAULT:
|
|
20
|
-
NAV_FLY:
|
|
21
|
-
NAV_ORBIT:
|
|
22
|
-
OBJECT:
|
|
23
|
-
PREMEASURE:
|
|
24
|
-
MEASURE:
|
|
25
|
-
SETTING:
|
|
26
|
-
VIEW:
|
|
27
|
-
PROPERTIES:
|
|
28
|
-
CONTEXT_MENU:
|
|
29
|
-
XRAY_MODE:
|
|
30
|
-
SECTION_BOX:
|
|
32
|
+
readonly NONE: 0;
|
|
33
|
+
readonly HOME: 1;
|
|
34
|
+
readonly NAV_DEFAULT: 2;
|
|
35
|
+
readonly NAV_FLY: 3;
|
|
36
|
+
readonly NAV_ORBIT: 4;
|
|
37
|
+
readonly OBJECT: 5;
|
|
38
|
+
readonly PREMEASURE: 6;
|
|
39
|
+
readonly MEASURE: 7;
|
|
40
|
+
readonly SETTING: 8;
|
|
41
|
+
readonly VIEW: 9;
|
|
42
|
+
readonly PROPERTIES: 10;
|
|
43
|
+
readonly CONTEXT_MENU: 11;
|
|
44
|
+
readonly XRAY_MODE: 12;
|
|
45
|
+
readonly SECTION_BOX: 13;
|
|
46
|
+
};
|
|
47
|
+
static readonly action: {
|
|
48
|
+
readonly NONE: -1;
|
|
49
|
+
readonly PAN: 1;
|
|
50
|
+
readonly KEYMOVE: 2;
|
|
51
|
+
readonly ROTATE: 3;
|
|
52
|
+
readonly FLY: 4;
|
|
53
|
+
readonly ORBIT: 5;
|
|
54
|
+
readonly STRAFE: 6;
|
|
31
55
|
};
|
|
32
|
-
static readonly action: Readonly<{
|
|
33
|
-
NONE: -1;
|
|
34
|
-
PAN: 1;
|
|
35
|
-
KEYMOVE: 2;
|
|
36
|
-
ROTATE: 3;
|
|
37
|
-
FLY: 4;
|
|
38
|
-
ORBIT: 5;
|
|
39
|
-
STRAFE: 6;
|
|
40
|
-
}>;
|
|
41
56
|
events: {
|
|
42
57
|
addEventListener: (eventName: string, callback: any) => void;
|
|
43
58
|
removeEventListener: (eventName: string, callback: any) => void;
|
|
@@ -27,6 +27,7 @@ export type BimModelsDownloadCompletedPayload = {
|
|
|
27
27
|
input_file_size: number;
|
|
28
28
|
model_type: ModelType;
|
|
29
29
|
model_cached: boolean;
|
|
30
|
+
file_extraction_id?: string;
|
|
30
31
|
total_partitions_size?: number;
|
|
31
32
|
total_partitions_size_compressed?: number;
|
|
32
33
|
num_partitions?: number;
|
|
@@ -52,6 +53,7 @@ export type InitializationTrackEventPayload = ModelInitializationPayload & {
|
|
|
52
53
|
file_name: string;
|
|
53
54
|
file_type: string;
|
|
54
55
|
input_file_size: number;
|
|
56
|
+
file_extraction_id?: string;
|
|
55
57
|
};
|
|
56
58
|
export declare const sectionBoxes: {
|
|
57
59
|
readonly enabled: `${string}.enabled`;
|
|
@@ -67,6 +69,7 @@ export declare const SECTION_BOX_ORIGIN: {
|
|
|
67
69
|
readonly OBJECT_TREE: "object_tree";
|
|
68
70
|
readonly OBJECT_TREE_ACTIONS: "object_tree_actions";
|
|
69
71
|
readonly SDK: "sdk";
|
|
72
|
+
readonly SDK_VIEWPOINT: "sdk_viewpoint";
|
|
70
73
|
readonly TOOLBAR: "toolbar";
|
|
71
74
|
readonly COACHMARK_SECTIONING: "coachmark_sectioning";
|
|
72
75
|
readonly VIEWS: "views";
|
|
@@ -111,6 +114,8 @@ export declare const RENDER_MODE_ORIGIN: {
|
|
|
111
114
|
readonly OBJECT_TREE: "object_tree";
|
|
112
115
|
readonly OBJECT_TREE_ACTIONS: "object_tree_actions";
|
|
113
116
|
readonly SDK: "sdk";
|
|
117
|
+
readonly SDK_VIEWPOINT: "sdk_viewpoint";
|
|
114
118
|
readonly TOOLBAR: "toolbar";
|
|
115
119
|
readonly HOTKEY: "hotkey";
|
|
116
120
|
};
|
|
121
|
+
export type RenderModeOrigin = (typeof RENDER_MODE_ORIGIN)[keyof typeof RENDER_MODE_ORIGIN];
|
|
@@ -4,6 +4,7 @@ export declare const getModelMetaData: () => Promise<{
|
|
|
4
4
|
file_name: string;
|
|
5
5
|
file_type: string;
|
|
6
6
|
input_file_size: number;
|
|
7
|
+
file_extraction_id?: string | undefined;
|
|
7
8
|
}>;
|
|
8
9
|
export declare const getInitializationEventPayload: (params: {
|
|
9
10
|
streaming?: boolean | undefined;
|
|
@@ -1,24 +1,3 @@
|
|
|
1
|
-
export type Visibility = {
|
|
2
|
-
default_visibility: boolean;
|
|
3
|
-
exceptions: {
|
|
4
|
-
object_ids: number[];
|
|
5
|
-
object_ranges: [number, number][];
|
|
6
|
-
};
|
|
7
|
-
};
|
|
8
|
-
export type Viewpoint = {
|
|
9
|
-
camera_data: string;
|
|
10
|
-
sections_data: string;
|
|
11
|
-
redlines_data: string;
|
|
12
|
-
visibility?: Visibility;
|
|
13
|
-
};
|
|
14
|
-
export type ModelRevisionViewpoint = Viewpoint & {
|
|
15
|
-
primary: boolean;
|
|
16
|
-
};
|
|
17
1
|
export type Model = {
|
|
18
2
|
id: number;
|
|
19
3
|
};
|
|
20
|
-
export type ModelRevision = {
|
|
21
|
-
id: number;
|
|
22
|
-
revision: number;
|
|
23
|
-
viewpoints: ModelRevisionViewpoint[];
|
|
24
|
-
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { RenderMode } from '../../utils/constants';
|
|
2
|
+
export type Visibility = {
|
|
3
|
+
default_visibility: boolean;
|
|
4
|
+
exceptions: {
|
|
5
|
+
object_ids: number[];
|
|
6
|
+
object_ranges: [number, number][];
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
export type Viewpoint = {
|
|
10
|
+
camera_data: string;
|
|
11
|
+
sections_data: string;
|
|
12
|
+
redlines_data: string;
|
|
13
|
+
visibility?: Visibility | null;
|
|
14
|
+
render_mode?: RenderMode | null;
|
|
15
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare const TOOL: {
|
|
2
|
+
readonly ALL: 0;
|
|
3
|
+
readonly BOTTOMTOOL: 1;
|
|
4
|
+
readonly FLOORPLAN: 2;
|
|
5
|
+
readonly OBJECTMODELTREE: 3;
|
|
6
|
+
readonly MODELVIEWS: 4;
|
|
7
|
+
readonly COACHMARKS: 5;
|
|
8
|
+
readonly COACHMARKSHIDDEN: 6;
|
|
9
|
+
readonly COACHMARKSECTION: 7;
|
|
10
|
+
readonly MEASUREMENT_SD: 8;
|
|
11
|
+
readonly SETTINGS: 9;
|
|
12
|
+
readonly CONTEXTMENU: 10;
|
|
13
|
+
readonly COACHMARKSFOV: 11;
|
|
14
|
+
readonly VIEW_PROPERTIES: 12;
|
|
15
|
+
readonly LOADING: 13;
|
|
16
|
+
readonly XRAY_MODE: 14;
|
|
17
|
+
readonly SECTION_BOX: 15;
|
|
18
|
+
};
|
|
19
|
+
export type Tool = (typeof TOOL)[keyof typeof TOOL];
|
|
@@ -11,22 +11,48 @@ export class ToolBarComponent {
|
|
|
11
11
|
toolbarElement: HTMLDivElement | null;
|
|
12
12
|
toolbarMarginTop: number;
|
|
13
13
|
toolStringMap: Readonly<{
|
|
14
|
-
|
|
14
|
+
9: any;
|
|
15
|
+
5: any;
|
|
16
|
+
10: any;
|
|
17
|
+
6: any;
|
|
18
|
+
1: any;
|
|
19
|
+
8: any;
|
|
20
|
+
2: any;
|
|
21
|
+
3: any;
|
|
22
|
+
4: any;
|
|
23
|
+
12: any;
|
|
24
|
+
13: any;
|
|
15
25
|
}>;
|
|
16
26
|
toolIconMap: Readonly<{
|
|
17
|
-
|
|
27
|
+
9: "nav-icon-views";
|
|
28
|
+
5: "nav-icon-objects";
|
|
29
|
+
10: "nav-icon-properties";
|
|
30
|
+
6: "nav-icon-measure";
|
|
31
|
+
1: "nav-icon-cursor-home";
|
|
32
|
+
8: "nav-icon-settings";
|
|
33
|
+
2: "nav-icon-cursor-default";
|
|
34
|
+
3: "nav-icon-cursor-fly";
|
|
35
|
+
4: "nav-icon-cursor-orbit";
|
|
36
|
+
12: "nav-icon-xray-mode";
|
|
37
|
+
13: "nav-icon-section-box";
|
|
18
38
|
}>;
|
|
19
39
|
toolEnumMap: Readonly<{
|
|
20
|
-
|
|
40
|
+
4: 9;
|
|
41
|
+
3: 5;
|
|
42
|
+
12: 10;
|
|
43
|
+
8: 6;
|
|
44
|
+
15: 13;
|
|
45
|
+
14: 12;
|
|
46
|
+
9: 8;
|
|
21
47
|
}>;
|
|
22
48
|
toolTip: HTMLDivElement;
|
|
23
49
|
toolTimeout: NodeJS.Timeout | null;
|
|
24
50
|
createTools(): void;
|
|
25
51
|
createToolTip(): HTMLDivElement;
|
|
26
52
|
setEdges(toolbar: any): void;
|
|
27
|
-
getToolIcon(tool: any):
|
|
53
|
+
getToolIcon(tool: any): any;
|
|
28
54
|
getToolText(tool: any): any;
|
|
29
|
-
getToolBarEnum(tool: any):
|
|
55
|
+
getToolBarEnum(tool: any): any;
|
|
30
56
|
getToolId(tool: any): string;
|
|
31
57
|
createToolBarButton(tool: any, clickFunction?: null): HTMLDivElement;
|
|
32
58
|
createDividerLine(id: any): HTMLDivElement;
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
1
|
+
export declare const TOOL_BAR_TOOLS: {
|
|
2
|
+
readonly NONE: 0;
|
|
3
|
+
readonly HOME: 1;
|
|
4
|
+
readonly NAV_DEFAULT: 2;
|
|
5
|
+
readonly NAV_FLY: 3;
|
|
6
|
+
readonly NAV_ORBIT: 4;
|
|
7
|
+
readonly OBJECT: 5;
|
|
8
|
+
readonly PREMEASURE: 6;
|
|
9
|
+
readonly MEASURE: 7;
|
|
10
|
+
readonly SETTING: 8;
|
|
11
|
+
readonly VIEW: 9;
|
|
12
|
+
readonly PROPERTIES: 10;
|
|
13
|
+
readonly CONTEXT_MENU: 11;
|
|
14
|
+
readonly XRAY_MODE: 12;
|
|
15
|
+
readonly SECTION_BOX: 13;
|
|
16
|
+
};
|
|
17
|
+
export type ToolBarTools = (typeof TOOL_BAR_TOOLS)[keyof typeof TOOL_BAR_TOOLS];
|
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
import type { Markup } from '../Markup';
|
|
2
2
|
import type { RenderControllerProxy } from '../../controllers/RenderControllerProxy';
|
|
3
3
|
import type { SectionBoxDisplayManager } from '../../sectioning/SectionBoxDisplayManager';
|
|
4
|
-
import type { Viewpoint, Visibility } from '../../api/types/
|
|
4
|
+
import type { Viewpoint, Visibility } from '../../api/types/Viewpoint';
|
|
5
|
+
import type { RenderModeOrigin, SectionBoxOrigin } from '../../api/analytic_events/analyticKeys';
|
|
6
|
+
type ViewpointOrigins = {
|
|
7
|
+
sectionBox?: SectionBoxOrigin;
|
|
8
|
+
renderMode?: RenderModeOrigin;
|
|
9
|
+
};
|
|
5
10
|
export declare class ViewpointManager {
|
|
6
11
|
private renderController;
|
|
7
12
|
private sectionBoxDisplayManager;
|
|
@@ -14,7 +19,10 @@ export declare class ViewpointManager {
|
|
|
14
19
|
activateHomeViewpoint: () => Promise<void>;
|
|
15
20
|
private activateViewpoint;
|
|
16
21
|
getViewpoint(): Promise<Viewpoint>;
|
|
17
|
-
setViewpoint(viewpoint: Viewpoint
|
|
22
|
+
setViewpoint(viewpoint: Viewpoint, options?: {
|
|
23
|
+
origins?: ViewpointOrigins;
|
|
24
|
+
}): Promise<void>;
|
|
18
25
|
setVisibility(visibility: Visibility): Promise<void>;
|
|
19
26
|
getVisibility(): Promise<Visibility>;
|
|
20
27
|
}
|
|
28
|
+
export {};
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import type { Viewpoint } from '../../../api/types/
|
|
1
|
+
import type { Viewpoint } from '../../../api/types/Viewpoint';
|
|
2
2
|
import type { InternalViewpoint } from '../../../viewpoint/types';
|
|
3
3
|
export declare const VIEWPOINT: Viewpoint;
|
|
4
4
|
export declare const VIEWPOINT_NO_SECTION: Viewpoint;
|
|
5
5
|
export declare const VIEWPOINT_NO_REDLINES: Viewpoint;
|
|
6
|
+
export declare const VIEWPOINT_NOTHING_HIDDEN: Viewpoint;
|
|
7
|
+
export declare const VIEWPOINT_NO_RENDER_MODE: Viewpoint;
|
|
6
8
|
export declare const INTERNAL_VIEWPOINT: InternalViewpoint;
|
|
7
9
|
export declare const INTERNAL_VIEWPOINT_NO_SECTION: InternalViewpoint;
|
|
8
10
|
export declare const INTERNAL_VIEWPOINT_NO_REDLINES: InternalViewpoint;
|
|
11
|
+
export declare const INTERNAL_VIEWPOINT_NOTHING_HIDDEN: InternalViewpoint;
|
|
12
|
+
export declare const INTERNAL_VIEWPOINT_NO_RENDER_MODE: InternalViewpoint;
|
|
9
13
|
export declare const homeViewpoint: InternalViewpoint;
|
|
10
14
|
export declare const homeViewpointWithoutRedlinesOrSections: InternalViewpoint;
|
package/dist/types/src/components/WindowModelObjectComponent/WindowModelObjectComponent.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export function WindowModelObjectComponent(options: any, renderController: any, apiController: any, contextMenuEnabled: any): void;
|
|
2
2
|
export class WindowModelObjectComponent {
|
|
3
3
|
constructor(options: any, renderController: any, apiController: any, contextMenuEnabled: any);
|
|
4
|
-
toolId:
|
|
4
|
+
toolId: 3;
|
|
5
5
|
onhideupdate: () => Promise<void>;
|
|
6
6
|
onselectedupdated: (selectedNodeIds: any) => Promise<void>;
|
|
7
7
|
onobjectselectedfrommodel: (payload: any) => Promise<void>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export function WindowSettingsComponent(options: any, pubsub: any, settings: any): void;
|
|
2
2
|
export class WindowSettingsComponent {
|
|
3
3
|
constructor(options: any, pubsub: any, settings: any);
|
|
4
|
-
toolId:
|
|
4
|
+
toolId: 9;
|
|
5
5
|
settings: any;
|
|
6
6
|
clickEvent: (e: any) => void;
|
|
7
7
|
dispose(): void;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export function WindowTreeViewComponent(options: any, api: any, render: any,
|
|
1
|
+
export function WindowTreeViewComponent(options: any, api: any, render: any, viewpointManager: any): void;
|
|
2
2
|
export class WindowTreeViewComponent {
|
|
3
|
-
constructor(options: any, api: any, render: any,
|
|
4
|
-
toolId:
|
|
3
|
+
constructor(options: any, api: any, render: any, viewpointManager: any);
|
|
4
|
+
toolId: 4;
|
|
5
5
|
api: any;
|
|
6
6
|
render: any;
|
|
7
|
-
|
|
7
|
+
viewpointManager: any;
|
|
8
8
|
tree: {};
|
|
9
9
|
folderLevels: {};
|
|
10
10
|
viewpointsDict: {};
|
package/dist/types/src/components/WindowViewPropertiesComponent/WindowViewPropertiesComponent.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export function WindowViewPropertiesComponent(options: any, render: any): void;
|
|
2
2
|
export class WindowViewPropertiesComponent {
|
|
3
3
|
constructor(options: any, render: any);
|
|
4
|
-
toolId:
|
|
4
|
+
toolId: 12;
|
|
5
5
|
render: any;
|
|
6
6
|
viewPropertiesId: string;
|
|
7
7
|
searchTerm: string;
|
|
@@ -13,7 +13,6 @@ export declare class Bootstrapper {
|
|
|
13
13
|
static initSceneGraphCount: number;
|
|
14
14
|
static initTreeServicesCount: number;
|
|
15
15
|
static initGeometryCount: number;
|
|
16
|
-
static initRelevantMeshnodesSetCount: number;
|
|
17
16
|
static initDownloadCount: number;
|
|
18
17
|
static partitionStepsCount: number;
|
|
19
18
|
static maxStepsPerPartition: number;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { GeometryBundle } from '../types/WebviewerOptions';
|
|
2
2
|
import { FileVersion, PropertiesFile } from '../api/types/FileExtraction';
|
|
3
|
-
import { Model
|
|
3
|
+
import { Model } from '../api/types/Model';
|
|
4
|
+
import { ModelRevision } from '../api/types/ModelRevision';
|
|
4
5
|
export type FileVersionStoreItem = {
|
|
5
6
|
fileId: FileVersion['file_id'];
|
|
6
7
|
fileVersionId: FileVersion['id'];
|
|
@@ -98,9 +98,7 @@ export class RenderController {
|
|
|
98
98
|
initGeometry(): {
|
|
99
99
|
isComplete: boolean;
|
|
100
100
|
};
|
|
101
|
-
initRelevantMeshnodesSet():
|
|
102
|
-
isComplete: boolean;
|
|
103
|
-
};
|
|
101
|
+
initRelevantMeshnodesSet(): any;
|
|
104
102
|
initGlobalBoundingBox(): void;
|
|
105
103
|
initNavigationModel(): void;
|
|
106
104
|
navigationModel: NavigationModel | undefined;
|
|
@@ -294,6 +294,7 @@ export class RenderControllerProxy {
|
|
|
294
294
|
setHotkeysEnabled(enabled: any): void;
|
|
295
295
|
partitionUrlsFromMeshnodeIndices(meshnodeIndices: any): any;
|
|
296
296
|
isPartitionedModel(): boolean | Promise<any>;
|
|
297
|
+
captureModelStats(): void;
|
|
297
298
|
}
|
|
298
299
|
export namespace RenderControllerProxy {
|
|
299
300
|
namespace NAVIGATION_MODE {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { ViewerRenderer } from '../procoregl/ViewerRenderer';
|
|
2
2
|
export declare class RendererFactory {
|
|
3
|
-
static createViewerRenderer(canvas: HTMLCanvasElement, offsetWidth: number, offsetHeight: number
|
|
3
|
+
static createViewerRenderer(canvas: HTMLCanvasElement, offsetWidth: number, offsetHeight: number): ViewerRenderer;
|
|
4
4
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { PWF } from '../../pwfreader/PWF';
|
|
2
2
|
import type { InternalNode, ObjectTree } from '../ObjectTree';
|
|
3
|
-
import type { Visibility } from '../../api/types/
|
|
3
|
+
import type { Visibility } from '../../api/types/Viewpoint';
|
|
4
4
|
export declare class HiddenNodeServices {
|
|
5
5
|
private hiddenObjectCount;
|
|
6
6
|
private hiddenMeshnodeIndices;
|
|
@@ -39,7 +39,9 @@ export class PartitionsRenderer {
|
|
|
39
39
|
[key: string]: any;
|
|
40
40
|
};
|
|
41
41
|
firstPassAtRest: boolean;
|
|
42
|
-
|
|
42
|
+
renderingOpaques: boolean;
|
|
43
|
+
renderingTransparents: boolean;
|
|
44
|
+
initialize: (sceneGraph: any, meshnodes: any, measureSet: any, selectedNodeServices: any, colorServices: any) => void;
|
|
43
45
|
render: (scene: any, camera: any) => void;
|
|
44
46
|
cleanBuffer: () => void;
|
|
45
47
|
setRenderMode: (renderMode: any) => void;
|
|
@@ -3,8 +3,7 @@ import { WASMTree } from './WASMTree';
|
|
|
3
3
|
import { Meshnode } from '../pwfreader/shared/Meshnode';
|
|
4
4
|
import { SelectedNodeServices } from './SelectedNodeServices';
|
|
5
5
|
import { ColorServices } from './ColorServices';
|
|
6
|
-
import {
|
|
7
|
-
import { PWF } from '../pwfreader/PWF';
|
|
6
|
+
import { ViewerRenderer } from './ViewerRenderer';
|
|
8
7
|
import { RenderMode } from '../utils/constants';
|
|
9
8
|
type PartitionedModelRendererArgs = {
|
|
10
9
|
antialias: boolean;
|
|
@@ -13,15 +12,16 @@ type PartitionedModelRendererArgs = {
|
|
|
13
12
|
canvas: HTMLCanvasElement;
|
|
14
13
|
};
|
|
15
14
|
export declare class PartitionsRendererImpl implements ViewerRenderer {
|
|
16
|
-
private renderer;
|
|
15
|
+
private readonly renderer;
|
|
17
16
|
constructor(params: PartitionedModelRendererArgs);
|
|
18
|
-
initialize(sceneGraph: WASMTree | KDTree, meshnodes: Meshnode[], measureSet: number[],
|
|
19
|
-
detailsInMotion: number;
|
|
20
|
-
detailsAtRest: number;
|
|
21
|
-
}, selectedNodeServices: SelectedNodeServices, colorServices: ColorServices): void;
|
|
17
|
+
initialize(sceneGraph: WASMTree | KDTree, meshnodes: Meshnode[], measureSet: number[], selectedNodeServices: SelectedNodeServices, colorServices: ColorServices): void;
|
|
22
18
|
render(scene: THREE.Scene, camera: THREE.Camera): void;
|
|
23
19
|
cleanBuffer(): void;
|
|
24
20
|
setRenderMode(mode: RenderMode): void;
|
|
21
|
+
setDetailsParam(detailsParam: {
|
|
22
|
+
detailsInMotion: number;
|
|
23
|
+
detailsAtRest: number;
|
|
24
|
+
}): void;
|
|
25
25
|
getRenderMode(): string;
|
|
26
26
|
getRenderingStage(): string;
|
|
27
27
|
get autoClear(): boolean;
|
|
@@ -46,8 +46,6 @@ export declare class PartitionsRendererImpl implements ViewerRenderer {
|
|
|
46
46
|
readRenderTargetPixels(renderTarget: THREE.WebGLRenderTarget, x: number, y: number, width: number, height: number, buffer: Uint8Array): void;
|
|
47
47
|
get clippingPlanes(): any[];
|
|
48
48
|
set clippingPlanes(clippingPlanes: any[]);
|
|
49
|
-
setPWF(pwf: PWF): void;
|
|
50
|
-
setFarPlane(): void;
|
|
51
49
|
get refresh(): boolean;
|
|
52
50
|
set refresh(refresh: boolean);
|
|
53
51
|
dispose(): void;
|
|
@@ -55,9 +53,6 @@ export declare class PartitionsRendererImpl implements ViewerRenderer {
|
|
|
55
53
|
loadMeshShader(): void;
|
|
56
54
|
enableBackFaceFillColor(state: boolean): void;
|
|
57
55
|
renderSection(scene: THREE.Scene, camera: THREE.Camera): void;
|
|
58
|
-
populateRelevantMeshnodesSet(_params: CacheEstimatorArgs): {
|
|
59
|
-
isComplete: boolean;
|
|
60
|
-
};
|
|
61
56
|
getWebGLRenderer(): THREE.WebGLRenderer;
|
|
62
57
|
}
|
|
63
58
|
export {};
|
|
@@ -3,21 +3,9 @@ import { WASMTree } from './WASMTree';
|
|
|
3
3
|
import { Meshnode } from '../pwfreader/shared/Meshnode';
|
|
4
4
|
import { SelectedNodeServices } from './SelectedNodeServices';
|
|
5
5
|
import { ColorServices } from './ColorServices';
|
|
6
|
-
import { PWF } from '../pwfreader/PWF';
|
|
7
6
|
import { RenderMode } from '../utils/constants';
|
|
8
|
-
export type CacheEstimatorArgs = {
|
|
9
|
-
scene: THREE.Scene;
|
|
10
|
-
camera: THREE.Camera;
|
|
11
|
-
zenith: number;
|
|
12
|
-
azimuth: number;
|
|
13
|
-
position: THREE.Vector3;
|
|
14
|
-
lookAt: THREE.Vector3;
|
|
15
|
-
};
|
|
16
7
|
export interface ViewerRenderer {
|
|
17
|
-
initialize(sceneGraph: WASMTree | KDTree, meshnodes: Meshnode[], measureSet: number[],
|
|
18
|
-
detailsInMotion: number;
|
|
19
|
-
detailsAtRest: number;
|
|
20
|
-
}, selectedNodeServices: SelectedNodeServices, colorServices: ColorServices): void;
|
|
8
|
+
initialize(sceneGraph: WASMTree | KDTree, meshnodes: Meshnode[], measureSet: number[], selectedNodeServices: SelectedNodeServices, colorServices: ColorServices): void;
|
|
21
9
|
autoClear: boolean;
|
|
22
10
|
domElement: HTMLCanvasElement;
|
|
23
11
|
clippingPlanes: any[];
|
|
@@ -41,15 +29,14 @@ export interface ViewerRenderer {
|
|
|
41
29
|
readRenderTargetPixels(renderTarget: THREE.WebGLRenderTarget, x: number, y: number, width: number, height: number, buffer: Uint8Array): void;
|
|
42
30
|
setRenderMode(mode: RenderMode): void;
|
|
43
31
|
getRenderMode(): string;
|
|
32
|
+
setDetailsParam(detailsParam: {
|
|
33
|
+
detailsInMotion: number;
|
|
34
|
+
detailsAtRest: number;
|
|
35
|
+
}): void;
|
|
44
36
|
getRenderingStage(): string;
|
|
45
37
|
dispose(): void;
|
|
46
38
|
enableBackFaceFillColor(state: boolean): void;
|
|
47
39
|
loadMeshShader(): void;
|
|
48
40
|
renderSection(scene: THREE.Scene, camera: THREE.Camera): void;
|
|
49
|
-
setPWF(pwf: PWF): void;
|
|
50
|
-
setFarPlane(): void;
|
|
51
|
-
populateRelevantMeshnodesSet(args: CacheEstimatorArgs): {
|
|
52
|
-
isComplete: boolean;
|
|
53
|
-
};
|
|
54
41
|
getWebGLRenderer(): THREE.WebGLRenderer;
|
|
55
42
|
}
|
|
@@ -22,6 +22,10 @@ export class PWF {
|
|
|
22
22
|
_gl: any;
|
|
23
23
|
manifest: any;
|
|
24
24
|
_numMeshnodes: number;
|
|
25
|
+
detailsParams: {
|
|
26
|
+
detailsInMotion: number;
|
|
27
|
+
detailsAtRest: number;
|
|
28
|
+
};
|
|
25
29
|
loadPWFVersion(version: any): void;
|
|
26
30
|
version: typeof V1 | typeof V2 | undefined;
|
|
27
31
|
setArrayBuffers(nodeAB: any, meshnodeAB: any, meshAB: any): void;
|
|
@@ -29,12 +33,12 @@ export class PWF {
|
|
|
29
33
|
nodeAB: any;
|
|
30
34
|
meshnodeAB: any;
|
|
31
35
|
meshAB: any;
|
|
32
|
-
detailsParams: {
|
|
33
|
-
[key: string]: any;
|
|
34
|
-
} | undefined;
|
|
35
36
|
setPartitionedModelBuffers(nodeAB: any, meshnodeAB: any, partitionProxiesAB: any): void;
|
|
36
37
|
partitionProxiesAB: ArrayBuffer | undefined;
|
|
37
|
-
|
|
38
|
+
computeDetailsParam(totalFaces: any): {
|
|
39
|
+
detailsInMotion: number;
|
|
40
|
+
detailsAtRest: number;
|
|
41
|
+
};
|
|
38
42
|
getNumPartitions(): number;
|
|
39
43
|
initPwfParser(): void;
|
|
40
44
|
pwfModelParser: PWFModelParser | undefined;
|
|
@@ -112,9 +116,12 @@ export class PWF {
|
|
|
112
116
|
forEachNode(callback: any): void;
|
|
113
117
|
getMeshVerticesAndFaces(meshRef: any, meshnodeOffset: any): import("./shared/MeshServices").MeshVerticesAndFaces;
|
|
114
118
|
findFirstObject(meshnodeIndex: any): import("./shared/Node").Node;
|
|
115
|
-
captureModelStats():
|
|
116
|
-
|
|
117
|
-
|
|
119
|
+
captureModelStats(): {
|
|
120
|
+
detailsInMotion: number;
|
|
121
|
+
detailsAtRest: number;
|
|
122
|
+
};
|
|
123
|
+
captureStandardModelStats(pwfModel: any): number;
|
|
124
|
+
capturePartitionedModelStats(pwfModel: any): number;
|
|
118
125
|
numFirstObjects(): number;
|
|
119
126
|
#private;
|
|
120
127
|
}
|
|
@@ -24,13 +24,14 @@ export declare class PartitionProxy {
|
|
|
24
24
|
};
|
|
25
25
|
private _byteLength?;
|
|
26
26
|
private _compressedByteLength?;
|
|
27
|
-
|
|
28
|
-
PartitionsLoaded: number;
|
|
29
|
-
MeshesLoaded: number;
|
|
30
|
-
VerticesLoaded: number;
|
|
31
|
-
FacesLoaded: number;
|
|
32
|
-
};
|
|
27
|
+
private stats;
|
|
33
28
|
constructor(pwfPartitionProxy: PWFPartitionProxy);
|
|
29
|
+
meshCount(): number;
|
|
30
|
+
incrementMeshCount(numMeshes: number): void;
|
|
31
|
+
vertexCount(): number;
|
|
32
|
+
incrementVertexCount(numVertices: number): void;
|
|
33
|
+
faceCount(): number;
|
|
34
|
+
incrementFaceCount(numFaces: number): void;
|
|
34
35
|
partitionId(): number;
|
|
35
36
|
partitionUrl(): string;
|
|
36
37
|
meshnodeOffsets(): Uint32Array;
|
package/dist/types/src/sdk.d.ts
CHANGED
|
@@ -6,9 +6,11 @@ export { Cache };
|
|
|
6
6
|
export { Webviewer } from './Webviewer';
|
|
7
7
|
export { BenchmarkReporter as Benchmark } from './utils/Benchmark';
|
|
8
8
|
export { TestRoutineRecorder } from './utils/Benchmark';
|
|
9
|
-
export type { Options,
|
|
9
|
+
export type { Options, GeometryBundle, FileExtractionModePwfV1OverrideOptions, FileExtractionModePwfV2OverrideOptions, FileExtractionModeOptions, ModelRevisionModePwfV2Options, ModelRevisionModePwfV1Options, PwfV1Bundle, PwfV2Bundle, CommonOptions, FeatureFlags, } from './types/WebviewerOptions';
|
|
10
10
|
export type { GeometryFile, FileExtraction, BimFileUpload, FileExtractionItem, WebFormatExtractionItem, PropertiesExtractionItem, FileVersion, Attachment, PropertiesFile, } from './api/types/FileExtraction';
|
|
11
|
-
export type {
|
|
11
|
+
export type { Model } from './api/types/Model';
|
|
12
|
+
export type { ModelRevision, ModelRevisionViewpoint, } from './api/types/ModelRevision';
|
|
13
|
+
export type { Viewpoint, Visibility } from './api/types/Viewpoint';
|
|
12
14
|
export type { Project } from './api/types/Project';
|
|
13
15
|
export type { Vector2, Vector3, BoundingBox } from './types/Math';
|
|
14
16
|
export type { CssColor, RGB, RGBA, HEX } from './components/Markup/SvgRenderer';
|
|
@@ -20,6 +22,13 @@ export type { ObjectFilter, FilterField } from './types/ObjectFilter';
|
|
|
20
22
|
export { FILTER_FIELD } from './types/ObjectFilter';
|
|
21
23
|
export type { NavigationMode } from './navigation/NavigationModes';
|
|
22
24
|
export { NAV_MODE } from './navigation/NavigationModes';
|
|
23
|
-
export {
|
|
25
|
+
export { RENDER_MODE } from './utils/constants';
|
|
26
|
+
export type { RenderMode } from './utils/constants';
|
|
27
|
+
export { TOOL } from './components/Tool';
|
|
28
|
+
export type { Tool } from './components/Tool';
|
|
29
|
+
export { TOOL_BAR_TOOLS } from './components/ToolBarTools';
|
|
30
|
+
export type { ToolBarTools } from './components/ToolBarTools';
|
|
31
|
+
export { ACTION } from './utils/Enums';
|
|
32
|
+
export type { Action } from './utils/Enums';
|
|
24
33
|
declare const version: string;
|
|
25
34
|
export { version };
|