@realsee/five 6.4.0-alpha.9 → 6.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/docs/assets/navigation.js +1 -1
- package/docs/assets/search.js +1 -1
- package/docs/classes/five.Camera.html +6 -5
- package/docs/classes/five.CustomShader.html +1 -1
- package/docs/classes/five.Draco.html +13 -0
- package/docs/classes/five.Five.html +60 -59
- package/docs/classes/five.KTX2.html +10 -0
- package/docs/classes/five.Model.html +24 -24
- package/docs/classes/five.ModelViewLayer.html +6 -6
- package/docs/classes/five.PBMMesh.html +1 -1
- package/docs/classes/five.PBMMeshMaterial.html +52 -37
- package/docs/classes/five.PBMPointCloudMaterial.html +40 -34
- package/docs/classes/five.PBMSkinnedMesh.html +5 -0
- package/docs/classes/five.TextureLoader.html +2 -2
- package/docs/classes/five.Tile.html +3 -2
- package/docs/classes/five.Tile3DModel.html +11 -4
- package/docs/classes/five.TileCubeTextureTarget.html +4 -3
- package/docs/classes/five.TileNode.html +1 -1
- package/docs/classes/five.Tileset.html +10 -3
- package/docs/classes/five.Trajectory.html +2 -2
- package/docs/classes/five.Work.html +15 -13
- package/docs/functions/five.defaultImageURLTransform.html +1 -1
- package/docs/functions/five.imageSupport.html +1 -1
- package/docs/functions/five.loadAt3d.html +1 -1
- package/docs/functions/five.loadB3dm.html +1 -1
- package/docs/functions/five.loadDome.html +1 -1
- package/docs/functions/five.loadDomez.html +1 -1
- package/docs/functions/five.loadFbx.html +1 -1
- package/docs/functions/five.loadGltf.html +1 -0
- package/docs/functions/five.loadPbm.html +1 -1
- package/docs/functions/five.loadPly.html +1 -1
- package/docs/functions/five.loadPnts.html +1 -1
- package/docs/functions/five.loadX3p.html +1 -1
- package/docs/functions/five.parseWork.html +1 -1
- package/docs/interfaces/five.CustomShaderInitArgs.html +2 -2
- package/docs/interfaces/five.FiveInitArgs.html +5 -3
- package/docs/interfaces/five.FiveLoadOptions.html +10 -24
- package/docs/interfaces/five.FloorplanControllerCustomInitArgs.html +3 -7
- package/docs/interfaces/five.ImageOptions.html +2 -2
- package/docs/interfaces/five.ImageURLMappings.html +1 -1
- package/docs/interfaces/five.ImageURLOptions.html +8 -8
- package/docs/interfaces/five.LoosePanoWork.html +9 -0
- package/docs/interfaces/five.MapviewControllerCustomInitArgs.html +11 -13
- package/docs/interfaces/five.PBMParameters.html +12 -6
- package/docs/interfaces/five.PanoramaControllerCustomInitArgs.html +6 -4
- package/docs/interfaces/five.TextureOptions.html +2 -2
- package/docs/interfaces/five.Tile3DModelLoaderOptions.html +3 -2
- package/docs/interfaces/five.Tile3dLayerOptions.html +14 -10
- package/docs/interfaces/five.TopviewControllerCustomInitArgs.html +3 -7
- package/docs/interfaces/five.VRPanoramaControllerCustomInitArgs.html +6 -4
- package/docs/interfaces/five.WorkCubeImage.html +8 -8
- package/docs/interfaces/five.WorkImage.html +10 -10
- package/docs/interfaces/five.WorkInitial.html +8 -8
- package/docs/interfaces/five.WorkModel.html +6 -6
- package/docs/interfaces/five.WorkModelLayer.html +2 -2
- package/docs/interfaces/five.WorkObserver.html +20 -20
- package/docs/interfaces/five.WorkResolvedObserver.html +20 -20
- package/docs/interfaces/five.WorkTile.html +2 -2
- package/docs/interfaces/five.WorkVideo.html +4 -4
- package/docs/interfaces/five.XRPanoramaControllerCustomInitArgs.html +6 -4
- package/docs/modules/five.html +8 -1
- package/docs/types/five.ControllerCustomInitTypes.html +1 -1
- package/docs/types/five.LooseWorkPanorama.html +1 -1
- package/docs/types/five.Mirror.html +1 -1
- package/docs/types/five.ModelMaterialValues.html +1 -1
- package/docs/types/five.Models.html +5 -5
- package/docs/types/five.ParseWorkOptions.html +1 -1
- package/docs/types/five.ParsedResultType.html +1 -1
- package/docs/types/five.Tile3dOptions.html +1 -1
- package/docs/types/five.TileContentData.html +1 -1
- package/docs/types/five.TilesetFrameState.html +1 -1
- package/docs/types/five.TrajectoryContentData.html +1 -1
- package/docs/types/five.Works.html +1 -1
- package/docs/variables/five.controllersDefaultInitArgs.html +1 -0
- package/docs/variables/five.defaultPbmParameters.html +1 -1
- package/docs/variables/five.draco-1.html +1 -0
- package/docs/variables/five.ktx2-1.html +1 -0
- package/five/index.d.ts +191 -61
- package/five/index.js +110 -110
- package/five/index.mjs +13922 -12425
- package/gltf-loader/index.js +4 -4
- package/gltf-loader/index.mjs +147 -147
- package/line/index.js +3 -3
- package/line/index.mjs +10 -10
- package/package.json +9 -2
- package/plugins/index.js +2 -2
- package/plugins/index.mjs +2 -2
- package/react/index.js +2 -2
- package/react/index.mjs +2 -2
- package/shader-lib/index.d.ts +38 -0
- package/shader-lib/index.js +111 -17
- package/shader-lib/index.mjs +350 -82
- package/sticker/index.js +3 -3
- package/sticker/index.mjs +7 -7
- package/umd/five-gltf-loader.js +5 -5
- package/umd/five-line.js +3 -3
- package/umd/five-plugins.js +2 -2
- package/umd/five-react.js +2 -2
- package/umd/five-shader-lib.js +111 -17
- package/umd/five-sticker.js +3 -3
- package/umd/five-vfx.js +2 -2
- package/umd/five-vue.js +2 -2
- package/umd/five.js +52 -52
- package/vfx/index.js +2 -2
- package/vfx/index.mjs +2 -2
- package/vue/index.js +2 -2
- package/vue/index.mjs +2 -2
- package/work-downloader/index.d.ts +33 -0
- package/work-downloader/index.js +255 -0
- package/work-downloader/index.mjs +750 -0
- package/docs/functions/five.loadGlb.html +0 -1
package/five/index.d.ts
CHANGED
|
@@ -134,6 +134,7 @@ export declare class Camera extends THREE_2.Camera {
|
|
|
134
134
|
autoNearFar: boolean;
|
|
135
135
|
needsRender: boolean;
|
|
136
136
|
refineModel: boolean;
|
|
137
|
+
environment: THREE_2.Texture | null;
|
|
137
138
|
private lastValues;
|
|
138
139
|
constructor(fov: number, aspect?: number, near?: number, far?: number, perspToOrtho?: THREE_2.Vector2, resolution?: THREE_2.Vector2, pixelRatio?: number);
|
|
139
140
|
get orthoDistance(): number;
|
|
@@ -254,6 +255,16 @@ export declare type ControllerEventTypes = {
|
|
|
254
255
|
"error"(error: Error): void;
|
|
255
256
|
};
|
|
256
257
|
|
|
258
|
+
export declare const controllersDefaultInitArgs: {
|
|
259
|
+
Floorplan: Required<FloorplanControllerCustomInitArgs>;
|
|
260
|
+
Topview: Required<TopviewControllerCustomInitArgs>;
|
|
261
|
+
Panorama: Required<PanoramaControllerCustomInitArgs>;
|
|
262
|
+
VRPanorama: Required<VRPanoramaControllerCustomInitArgs>;
|
|
263
|
+
Model: Required<ModelControllerCustomInitArgs>;
|
|
264
|
+
Mapview: Required<MapviewControllerCustomInitArgs>;
|
|
265
|
+
XRPanorama: Required<XRPanoramaControllerCustomInitArgs>;
|
|
266
|
+
};
|
|
267
|
+
|
|
257
268
|
export declare class CullingVolume {
|
|
258
269
|
static get MASK_OUTSIDE(): number;
|
|
259
270
|
static get MASK_INSIDE(): number;
|
|
@@ -285,7 +296,7 @@ export declare class CustomShader {
|
|
|
285
296
|
}
|
|
286
297
|
|
|
287
298
|
export declare interface CustomShaderInitArgs {
|
|
288
|
-
type: Array<'none' | 'basic' | 'phong' | 'pointcloud'>;
|
|
299
|
+
type: Array<'none' | 'basic' | 'phong' | 'standard' | 'pointcloud'>;
|
|
289
300
|
vertex?: Partial<VertexShaderChunks>;
|
|
290
301
|
fragment?: Partial<FragmentShaderChunks>;
|
|
291
302
|
uniforms?: {
|
|
@@ -306,6 +317,33 @@ export declare function defaultImageURLTransform(source: string, options: ImageU
|
|
|
306
317
|
|
|
307
318
|
export declare const defaultPbmParameters: PBMParameters;
|
|
308
319
|
|
|
320
|
+
export declare class Draco {
|
|
321
|
+
decoderPath: string;
|
|
322
|
+
private decoderPending;
|
|
323
|
+
private decoderConfig;
|
|
324
|
+
private workerLimit;
|
|
325
|
+
private workerNextTaskID;
|
|
326
|
+
private workerSourceURL;
|
|
327
|
+
private workerPool;
|
|
328
|
+
constructor();
|
|
329
|
+
setDecoderPath(decoderPath: string): void;
|
|
330
|
+
setDecoderConfig(config: any): this;
|
|
331
|
+
setWorkerLimit(workerLimit: number): this;
|
|
332
|
+
decodeDracoFile(buffer: ArrayBuffer, callback: (geometry: THREE_2.BufferGeometry) => void, attributeIDs: Record<string, string>, attributeTypes: Record<string, any>): void;
|
|
333
|
+
decodeGeometry(buffer: ArrayBuffer, taskConfig?: {
|
|
334
|
+
attributeIDs: Record<string, string>;
|
|
335
|
+
attributeTypes: Record<string, any>;
|
|
336
|
+
useUniqueIDs: boolean;
|
|
337
|
+
}): Promise<THREE_2.BufferGeometry>;
|
|
338
|
+
_createGeometry(geometryData: any): THREE_2.BufferGeometry;
|
|
339
|
+
_initDecoder(): Promise<void>;
|
|
340
|
+
_getWorker(taskID: number, taskCost: number): Promise<Worker>;
|
|
341
|
+
_releaseTask(worker: Worker, taskID: number): void;
|
|
342
|
+
dispose(): this;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
export declare const draco: Draco;
|
|
346
|
+
|
|
309
347
|
/**
|
|
310
348
|
* Five 事件列表
|
|
311
349
|
* @description
|
|
@@ -565,6 +603,7 @@ export declare class Five extends Subscribe<EventTypes> {
|
|
|
565
603
|
private _enableIOSEDR;
|
|
566
604
|
private _enableEDL;
|
|
567
605
|
private _enableHQ;
|
|
606
|
+
enableLayeringRendering: boolean;
|
|
568
607
|
constructor(initArgs?: FiveInitArgs);
|
|
569
608
|
get panoIndex(): number;
|
|
570
609
|
/**
|
|
@@ -870,7 +909,6 @@ export declare class Five extends Subscribe<EventTypes> {
|
|
|
870
909
|
private throwError;
|
|
871
910
|
private loadModel;
|
|
872
911
|
private commonParams;
|
|
873
|
-
private resetController;
|
|
874
912
|
private applyController;
|
|
875
913
|
/** 移除事件绑定 */
|
|
876
914
|
private removeEventListeners;
|
|
@@ -1047,6 +1085,10 @@ export declare interface FiveInitArgs {
|
|
|
1047
1085
|
* @returns 返回的请求
|
|
1048
1086
|
*/
|
|
1049
1087
|
requestProxy?(url: string): string | Promise<string>;
|
|
1088
|
+
/**
|
|
1089
|
+
* 是否开启分层渲染,默认开启
|
|
1090
|
+
*/
|
|
1091
|
+
enableLayeringRendering?: boolean;
|
|
1050
1092
|
}
|
|
1051
1093
|
|
|
1052
1094
|
export declare interface FiveLoadOptions {
|
|
@@ -1054,34 +1096,27 @@ export declare interface FiveLoadOptions {
|
|
|
1054
1096
|
duration?: number;
|
|
1055
1097
|
/** 切换运动全景图效果 */
|
|
1056
1098
|
effect?: MovePanoEffect;
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
/** XR眼镜模式下的特定参数 */
|
|
1070
|
-
xrPanorama?: ControllerCustomInitTypes["XRPanorama"];
|
|
1099
|
+
model?: {
|
|
1100
|
+
light?: boolean;
|
|
1101
|
+
/**
|
|
1102
|
+
* 模型贴图的配置参数
|
|
1103
|
+
* @description
|
|
1104
|
+
* 可以动态对配置在 `work` 数据中的模型贴图在 runtime 做 url 调整。
|
|
1105
|
+
* 平衡加载时间和图片质量
|
|
1106
|
+
*/
|
|
1107
|
+
textureOptions?: TextureOptions;
|
|
1108
|
+
/** 模型 3d-tile 参数 */
|
|
1109
|
+
"3d-tiles"?: Tile3dOptions;
|
|
1110
|
+
};
|
|
1071
1111
|
/**
|
|
1072
|
-
*
|
|
1073
|
-
*
|
|
1074
|
-
* 可以动态对配置在 `work` 数据中的全景图片在 runtime 做 url 调整。
|
|
1075
|
-
* 平衡加载时间和图片质量
|
|
1112
|
+
* @deprecated
|
|
1113
|
+
* 请通过 model.textureOptions 设置
|
|
1076
1114
|
*/
|
|
1077
|
-
|
|
1115
|
+
textureOptions?: TextureOptions;
|
|
1078
1116
|
/**
|
|
1079
|
-
*
|
|
1080
|
-
*
|
|
1081
|
-
* 可以动态对配置在 `work` 数据中的模型贴图在 runtime 做 url 调整。
|
|
1082
|
-
* 平衡加载时间和图片质量
|
|
1117
|
+
* @deprecated
|
|
1118
|
+
* 请通过 model.textureOptions 设置
|
|
1083
1119
|
*/
|
|
1084
|
-
textureOptions?: TextureOptions;
|
|
1085
1120
|
"3d-tiles"?: Tile3dOptions;
|
|
1086
1121
|
}
|
|
1087
1122
|
|
|
@@ -1127,12 +1162,6 @@ export declare interface FloorplanControllerCustomInitArgs {
|
|
|
1127
1162
|
maxFov?: number;
|
|
1128
1163
|
/** 最小相机可视角度 */
|
|
1129
1164
|
minFov?: number;
|
|
1130
|
-
/**
|
|
1131
|
-
* 模型是否限制在屏幕中
|
|
1132
|
-
* bounding-center 模型包围盒中心必须在屏幕内
|
|
1133
|
-
* none 不限制
|
|
1134
|
-
*/
|
|
1135
|
-
modelInScreen?: 'boundingbox-center' | 'none';
|
|
1136
1165
|
/** 鼠标焦点环自定义创建器 */
|
|
1137
1166
|
intersectMeshCreator?: () => IntersectMeshInterface;
|
|
1138
1167
|
}
|
|
@@ -1189,13 +1218,13 @@ export declare interface ImageOptions {
|
|
|
1189
1218
|
*/
|
|
1190
1219
|
transform?: (url: string, options: ImageURLOptions) => string;
|
|
1191
1220
|
/** 图片尺寸参数 尽量使用 2 的幂次 如 512 1024 2048 */
|
|
1192
|
-
size?:
|
|
1221
|
+
size?: ImageURLOptions['size'];
|
|
1193
1222
|
/** 图片质量参数(0-100) */
|
|
1194
|
-
quality?:
|
|
1223
|
+
quality?: ImageURLOptions['quality'];
|
|
1195
1224
|
/** 图片格式参数 */
|
|
1196
|
-
format?:
|
|
1225
|
+
format?: ImageURLOptions['format'];
|
|
1197
1226
|
/** 锐化参数 海外不支持 */
|
|
1198
|
-
sharpen?:
|
|
1227
|
+
sharpen?: ImageURLOptions['sharpen'];
|
|
1199
1228
|
mappings?: ImageURLMappings;
|
|
1200
1229
|
}
|
|
1201
1230
|
|
|
@@ -1224,7 +1253,7 @@ export declare interface ImageURLOptions {
|
|
|
1224
1253
|
/** 图片质量参数(0-100) */
|
|
1225
1254
|
quality?: number;
|
|
1226
1255
|
/** 图片格式参数 */
|
|
1227
|
-
format?: "jpg" | "png" | "heif" | "webp" | "avif";
|
|
1256
|
+
format?: "jpg" | "jpeg" | "png" | "heif" | "heic" | "webp" | "avif";
|
|
1228
1257
|
/** 图片裁切 */
|
|
1229
1258
|
cut?: [x: number, y: number, width: number, height: number];
|
|
1230
1259
|
/** 锐化参数 海外不支持 */
|
|
@@ -1277,6 +1306,25 @@ export declare interface IntersectMeshInterface extends THREE_2.Object3D {
|
|
|
1277
1306
|
|
|
1278
1307
|
export declare function isPanoId(id: any): id is PanoId;
|
|
1279
1308
|
|
|
1309
|
+
export declare class KTX2 {
|
|
1310
|
+
transcoderPath: string;
|
|
1311
|
+
private workerPool;
|
|
1312
|
+
private transcoderBinary;
|
|
1313
|
+
private transcoderPending;
|
|
1314
|
+
private workerSourceURL;
|
|
1315
|
+
private workerConfig;
|
|
1316
|
+
constructor();
|
|
1317
|
+
setTranscoderPath(transcoderPath: string): void;
|
|
1318
|
+
detectSupport(renderer: THREE_2.WebGLRenderer): this;
|
|
1319
|
+
init(): Promise<void>;
|
|
1320
|
+
parse(buffer: ArrayBuffer): Promise<THREE_2.CompressedTexture>;
|
|
1321
|
+
_createTextureFrom(transcodeResult: any): Promise<THREE_2.CompressedTexture>;
|
|
1322
|
+
_createTexture(buffers: ArrayBuffer[]): Promise<THREE_2.CompressedTexture>;
|
|
1323
|
+
dispose(): this;
|
|
1324
|
+
}
|
|
1325
|
+
|
|
1326
|
+
export declare const ktx2: KTX2;
|
|
1327
|
+
|
|
1280
1328
|
/**
|
|
1281
1329
|
* 过时的事件列表
|
|
1282
1330
|
*/
|
|
@@ -1698,6 +1746,7 @@ export declare type LegacyEventType = {
|
|
|
1698
1746
|
};
|
|
1699
1747
|
|
|
1700
1748
|
export declare function loadAt3d(url: string, options?: {
|
|
1749
|
+
light?: boolean;
|
|
1701
1750
|
textureOptions?: TextureOptions;
|
|
1702
1751
|
textureBaseUri?: string;
|
|
1703
1752
|
textureArray?: string[];
|
|
@@ -1706,46 +1755,51 @@ export declare function loadAt3d(url: string, options?: {
|
|
|
1706
1755
|
|
|
1707
1756
|
export declare function loadB3dm(url: string, options?: {
|
|
1708
1757
|
upAxis?: 'Y' | 'Z';
|
|
1758
|
+
light?: boolean;
|
|
1709
1759
|
fetcher?: Fetcher;
|
|
1710
1760
|
}): Promise<ParsedResultType>;
|
|
1711
1761
|
|
|
1712
1762
|
export declare function loadDome(url: string, options?: {
|
|
1763
|
+
light?: boolean;
|
|
1713
1764
|
textureOptions?: TextureOptions;
|
|
1714
1765
|
textureBaseUri?: string;
|
|
1715
1766
|
fetcher?: Fetcher;
|
|
1716
1767
|
}): Promise<ParsedResultType>;
|
|
1717
1768
|
|
|
1718
1769
|
export declare function loadDomez(url: string, options?: {
|
|
1770
|
+
light?: boolean;
|
|
1719
1771
|
textureOptions?: TextureOptions;
|
|
1720
1772
|
textureBaseUri?: string;
|
|
1721
1773
|
fetcher?: Fetcher;
|
|
1722
1774
|
}): Promise<ParsedResultType>;
|
|
1723
1775
|
|
|
1724
1776
|
export declare function loadFbx(url: string, options?: {
|
|
1725
|
-
|
|
1777
|
+
light?: boolean;
|
|
1726
1778
|
fetcher?: Fetcher;
|
|
1727
1779
|
}): Promise<ParsedResultType>;
|
|
1728
1780
|
|
|
1729
|
-
export declare function
|
|
1781
|
+
export declare function loadGltf(url: string, options?: {
|
|
1730
1782
|
upAxis?: 'Y' | 'Z';
|
|
1783
|
+
light?: boolean;
|
|
1731
1784
|
fetcher?: Fetcher;
|
|
1732
1785
|
}): Promise<ParsedResultType>;
|
|
1733
1786
|
|
|
1734
1787
|
export declare function loadPbm(url: string, options?: {
|
|
1788
|
+
light?: boolean;
|
|
1735
1789
|
textureOptions?: TextureOptions;
|
|
1736
1790
|
textureBaseUri?: string;
|
|
1737
1791
|
textureArray?: string[];
|
|
1738
1792
|
fetcher?: Fetcher;
|
|
1739
1793
|
}): Promise<ParsedResultType>;
|
|
1740
1794
|
|
|
1741
|
-
export declare function loadPly<Type extends 'geometry' | '
|
|
1795
|
+
export declare function loadPly<Type extends 'geometry' | 'line' | 'pbmMesh' | 'pbmPointCloud', ResultType = {
|
|
1742
1796
|
'geometry': THREE_2.BufferGeometry;
|
|
1743
|
-
'
|
|
1744
|
-
'
|
|
1745
|
-
'line': THREE_2.Line<THREE_2.BufferGeometry, THREE_2.LineBasicMaterial>;
|
|
1797
|
+
'line': THREE_2.Line<THREE_2.BufferGeometry>;
|
|
1798
|
+
'pbmMesh': PBMMesh;
|
|
1746
1799
|
'pbmPointCloud': PBMPointCloud;
|
|
1747
1800
|
}[Type]>(url: string, options?: {
|
|
1748
1801
|
upAxis?: 'Y' | 'Z';
|
|
1802
|
+
light?: boolean;
|
|
1749
1803
|
propertyNameMapping?: Record<string, string>;
|
|
1750
1804
|
customPropertyMapping?: Record<string, {
|
|
1751
1805
|
itemType: 'float32' | 'uint32' | 'int32' | 'uint16' | 'int16' | 'uint8' | 'int8';
|
|
@@ -1763,10 +1817,21 @@ export declare function loadPnts(url: string, options?: {
|
|
|
1763
1817
|
|
|
1764
1818
|
export declare function loadX3p(url: string, options?: {
|
|
1765
1819
|
color?: THREE_2.Color;
|
|
1766
|
-
|
|
1820
|
+
light?: boolean;
|
|
1767
1821
|
fetcher?: Fetcher;
|
|
1768
1822
|
}): Promise<ParsedResultType>;
|
|
1769
1823
|
|
|
1824
|
+
export declare interface LoosePanoWork {
|
|
1825
|
+
code?: string;
|
|
1826
|
+
up: string;
|
|
1827
|
+
down: string;
|
|
1828
|
+
right: string;
|
|
1829
|
+
left: string;
|
|
1830
|
+
front: string;
|
|
1831
|
+
back: string;
|
|
1832
|
+
size: number;
|
|
1833
|
+
}
|
|
1834
|
+
|
|
1770
1835
|
export declare type LooseWork = {
|
|
1771
1836
|
work_code?: string;
|
|
1772
1837
|
code?: string;
|
|
@@ -1849,7 +1914,7 @@ export declare type LooseWorkPanorama = {
|
|
|
1849
1914
|
back: string;
|
|
1850
1915
|
};
|
|
1851
1916
|
tiles?: number[];
|
|
1852
|
-
|
|
1917
|
+
size_list?: number[];
|
|
1853
1918
|
};
|
|
1854
1919
|
|
|
1855
1920
|
export declare type LooseWorkVideo = {
|
|
@@ -1882,11 +1947,9 @@ export declare interface MapviewControllerCustomInitArgs {
|
|
|
1882
1947
|
*/
|
|
1883
1948
|
cameraType?: "perspective" | "orthographic" | "auto";
|
|
1884
1949
|
/**
|
|
1885
|
-
*
|
|
1886
|
-
* bounding-center 模型包围盒中心必须在屏幕内
|
|
1887
|
-
* none 不限制
|
|
1950
|
+
* 相机电子围栏
|
|
1888
1951
|
*/
|
|
1889
|
-
|
|
1952
|
+
cameraFence?: THREE_2.Box3 | THREE_2.Sphere | null;
|
|
1890
1953
|
/** 鼠标焦点环自定义创建器 */
|
|
1891
1954
|
intersectMeshCreator?: () => IntersectMeshInterface;
|
|
1892
1955
|
}
|
|
@@ -2018,6 +2081,7 @@ export declare class Model extends THREE_2.Object3D {
|
|
|
2018
2081
|
* @param options - 图片参数
|
|
2019
2082
|
*/
|
|
2020
2083
|
load(work: Work, options?: {
|
|
2084
|
+
light?: boolean;
|
|
2021
2085
|
textureOptions?: TextureOptions;
|
|
2022
2086
|
"3d-tiles"?: Tile3dOptions;
|
|
2023
2087
|
}): Promise<void>;
|
|
@@ -2410,6 +2474,8 @@ export declare interface PanoramaControllerCustomInitArgs extends PanoramaLikeCo
|
|
|
2410
2474
|
panoTapTriggerRadius?: number;
|
|
2411
2475
|
/** 地面观察点标识自定义创建器 */
|
|
2412
2476
|
panoCircleMeshCreator?: (pano: Pano) => PanoCircleMeshInterface;
|
|
2477
|
+
/** TiledCubeTextureLevel */
|
|
2478
|
+
tiledCubeTextureLevel?: number;
|
|
2413
2479
|
/**
|
|
2414
2480
|
* 全景瓦片登记
|
|
2415
2481
|
* @param fov - 当前 fov
|
|
@@ -2458,9 +2524,10 @@ export declare interface PanoTextureEvent extends BaseEvent {
|
|
|
2458
2524
|
}
|
|
2459
2525
|
|
|
2460
2526
|
export declare type ParsedResultType<Scene = THREE_2.Object3D> = {
|
|
2461
|
-
type: 'unknown' | 'b3dm' | 'pnts' | 'at3d' | 'pbm' | 'dome' | 'domez' | '
|
|
2527
|
+
type: 'unknown' | 'b3dm' | 'pnts' | 'at3d' | 'pbm' | 'dome' | 'domez' | 'gltf' | 'ply' | 'obj' | 'fbx' | 'x3p';
|
|
2462
2528
|
upAxis: 'Z';
|
|
2463
2529
|
byteLength: number;
|
|
2530
|
+
memoryUsage: number;
|
|
2464
2531
|
uri: string;
|
|
2465
2532
|
scene: Scene;
|
|
2466
2533
|
textures: THREE_2.Texture[];
|
|
@@ -2473,7 +2540,7 @@ export declare type ParsedResultType<Scene = THREE_2.Object3D> = {
|
|
|
2473
2540
|
* @param options - 配置参数, 可以在此二次设置 baseURL 等参数
|
|
2474
2541
|
* @returns - 签署过的 Work 数据结构
|
|
2475
2542
|
*/
|
|
2476
|
-
export declare function parseWork(obj: Work | LooseWork | string | any, options?: ParseWorkOptions): Work;
|
|
2543
|
+
export declare function parseWork(obj: Work | LoosePanoWork | LooseWork | string | any, options?: ParseWorkOptions): Work;
|
|
2477
2544
|
|
|
2478
2545
|
export declare type ParseWorkOptions = {
|
|
2479
2546
|
/** 位姿 */
|
|
@@ -2523,11 +2590,13 @@ export declare class PBMMesh extends THREE_2.Mesh<THREE_2.BufferGeometry, PBMMes
|
|
|
2523
2590
|
|
|
2524
2591
|
/** PBM 材质 */
|
|
2525
2592
|
export declare class PBMMeshMaterial extends THREE_2.ShaderMaterial implements PBMParameters {
|
|
2526
|
-
shaderType: 'none' | 'basic' | 'phong';
|
|
2593
|
+
shaderType: 'none' | 'basic' | 'phong' | 'standard';
|
|
2527
2594
|
/** 更新版本 */
|
|
2528
2595
|
syncModelVersion?: string;
|
|
2596
|
+
vertexTangents: boolean;
|
|
2529
2597
|
/** 内置参数 */
|
|
2530
2598
|
color: THREE_2.Color;
|
|
2599
|
+
colorAlpha: number;
|
|
2531
2600
|
map: THREE_2.Texture | null;
|
|
2532
2601
|
lightMap: THREE_2.Texture | null;
|
|
2533
2602
|
lightMapIntensity: number;
|
|
@@ -2535,8 +2604,15 @@ export declare class PBMMeshMaterial extends THREE_2.ShaderMaterial implements P
|
|
|
2535
2604
|
aoMapIntensity: number;
|
|
2536
2605
|
specularMap: THREE_2.Texture | null;
|
|
2537
2606
|
specular: THREE_2.Color;
|
|
2607
|
+
roughnessMap: THREE_2.Texture | null;
|
|
2608
|
+
roughness: number;
|
|
2609
|
+
metalnessMap: THREE_2.Texture | null;
|
|
2610
|
+
metalness: number;
|
|
2538
2611
|
alphaMap: THREE_2.Texture | null;
|
|
2612
|
+
alphaMode: 'OPAQUE' | 'MASK' | 'BLEND';
|
|
2613
|
+
combine: THREE_2.Combine | null;
|
|
2539
2614
|
envMap: THREE_2.Texture | THREE_2.CubeTexture | null;
|
|
2615
|
+
envMapIntensity: number;
|
|
2540
2616
|
reflectivity: number;
|
|
2541
2617
|
refractionRatio: number;
|
|
2542
2618
|
emissiveMap: THREE_2.Texture | null;
|
|
@@ -2607,9 +2683,15 @@ export declare class PBMMeshMaterial extends THREE_2.ShaderMaterial implements P
|
|
|
2607
2683
|
colorSaturation: number;
|
|
2608
2684
|
/** HSV亮度调整值*/
|
|
2609
2685
|
colorBrightness: number;
|
|
2686
|
+
/** outline增益*/
|
|
2687
|
+
outlineGain: number;
|
|
2688
|
+
/** distance增益 */
|
|
2689
|
+
distanceGain: number;
|
|
2690
|
+
/** 半透明叠加渲染*/
|
|
2691
|
+
useAddBlend: boolean;
|
|
2610
2692
|
/** 所属楼层*/
|
|
2611
|
-
|
|
2612
|
-
constructor(shaderType?: 'none' | 'basic' | 'phong', parameters?: Partial<PBMParameters>);
|
|
2693
|
+
floorIndex: number;
|
|
2694
|
+
constructor(shaderType?: 'none' | 'basic' | 'phong' | 'standard', parameters?: Partial<PBMParameters>);
|
|
2613
2695
|
onBeforeCompile(shader: THREE_2.Shader, renderer: THREE_2.WebGLRenderer): void;
|
|
2614
2696
|
refreshUniforms(renderer?: THREE_2.WebGLRenderer): void;
|
|
2615
2697
|
update(renderer: THREE_2.WebGLRenderer, camera: Camera, model: Model): void;
|
|
@@ -2678,6 +2760,12 @@ export declare interface PBMParameters {
|
|
|
2678
2760
|
colorSaturation: number;
|
|
2679
2761
|
/** 亮度调整值*/
|
|
2680
2762
|
colorBrightness: number;
|
|
2763
|
+
/** 半透明叠加渲染*/
|
|
2764
|
+
useAddBlend: boolean;
|
|
2765
|
+
/** outline增益*/
|
|
2766
|
+
outlineGain: number;
|
|
2767
|
+
/** distance增益*/
|
|
2768
|
+
distanceGain: number;
|
|
2681
2769
|
/** 高程着色材质*/
|
|
2682
2770
|
gradientTexture: THREE_2.Texture | null;
|
|
2683
2771
|
}
|
|
@@ -2743,17 +2831,30 @@ export declare class PBMPointCloudMaterial extends THREE_2.ShaderMaterial implem
|
|
|
2743
2831
|
/** 高程彩色图*/
|
|
2744
2832
|
gradientTexture: PBMParameters['gradientTexture'];
|
|
2745
2833
|
/** 所属楼层*/
|
|
2746
|
-
|
|
2834
|
+
floorIndex: number;
|
|
2747
2835
|
/** 饱HSV和度调整值*/
|
|
2748
2836
|
colorSaturation: number;
|
|
2749
2837
|
/** HSV亮度调整值*/
|
|
2750
2838
|
colorBrightness: number;
|
|
2839
|
+
/** outline增益*/
|
|
2840
|
+
outlineGain: number;
|
|
2841
|
+
/** distance增益*/
|
|
2842
|
+
distanceGain: number;
|
|
2843
|
+
/** 半透明叠加渲染*/
|
|
2844
|
+
useAddBlend: boolean;
|
|
2751
2845
|
constructor(parameters?: Partial<PBMParameters>);
|
|
2752
2846
|
onBeforeCompile(shader: THREE_2.Shader, renderer: THREE_2.WebGLRenderer): void;
|
|
2753
2847
|
update(renderer: THREE_2.WebGLRenderer, camera: Camera, model: Model): void;
|
|
2754
2848
|
copy(source: PBMPointCloudMaterial): this;
|
|
2755
2849
|
}
|
|
2756
2850
|
|
|
2851
|
+
export declare class PBMSkinnedMesh extends THREE_2.SkinnedMesh<THREE_2.BufferGeometry, PBMMeshMaterial[]> {
|
|
2852
|
+
geometry: THREE_2.BufferGeometry;
|
|
2853
|
+
material: PBMMeshMaterial[];
|
|
2854
|
+
constructor(geometry: THREE_2.BufferGeometry, materials: PBMMeshMaterial[], useVertexTexture?: boolean);
|
|
2855
|
+
update(renderer: THREE_2.WebGLRenderer, camera: Camera, model: Model, tile?: Tile): void;
|
|
2856
|
+
}
|
|
2857
|
+
|
|
2757
2858
|
/**
|
|
2758
2859
|
* 相机位姿
|
|
2759
2860
|
* @document ../../../guides/coordinate.md
|
|
@@ -3073,6 +3174,7 @@ export declare class Tile {
|
|
|
3073
3174
|
loadStateUpdateTime: number;
|
|
3074
3175
|
loadfailRetryDelay: number;
|
|
3075
3176
|
byteLength: number;
|
|
3177
|
+
memoryUsage: number;
|
|
3076
3178
|
} | null;
|
|
3077
3179
|
level: number;
|
|
3078
3180
|
levelOfContent: number;
|
|
@@ -3117,6 +3219,7 @@ export declare class Tile {
|
|
|
3117
3219
|
get hasEmptyContent(): boolean;
|
|
3118
3220
|
get contentReady(): boolean;
|
|
3119
3221
|
get contentByteLength(): number;
|
|
3222
|
+
get contentMemoryUsage(): number;
|
|
3120
3223
|
getScreenSpaceError(frameState: TilesetFrameState, distanceToCamera: number, useParentGeometricError: boolean): number;
|
|
3121
3224
|
getPriority(): number;
|
|
3122
3225
|
}
|
|
@@ -3132,6 +3235,10 @@ export declare interface Tile3dLayerOptions {
|
|
|
3132
3235
|
minLevelOfDetail?: number;
|
|
3133
3236
|
/** 模型显示最大细化层级 */
|
|
3134
3237
|
maxLevelOfDetail?: number;
|
|
3238
|
+
/** 模型显示最小细化误差 */
|
|
3239
|
+
minGeometricError?: number;
|
|
3240
|
+
/** 模型显示最大细化误差 */
|
|
3241
|
+
maxGeometricError?: number;
|
|
3135
3242
|
/** 模型越层级加载 */
|
|
3136
3243
|
skipLevelOfDetail?: boolean;
|
|
3137
3244
|
/** 模型是否最密 */
|
|
@@ -3151,8 +3258,11 @@ export declare interface Tile3dLayerOptions {
|
|
|
3151
3258
|
}
|
|
3152
3259
|
|
|
3153
3260
|
export declare class Tile3DModel extends THREE_2.Object3D {
|
|
3261
|
+
static DEFAULT_PANORAMA_MIN_GEOMETRIC_ERROR: number;
|
|
3154
3262
|
static DEFAULT_MIN_LEVEL_OF_DETAIL: number;
|
|
3155
3263
|
static DEFAULT_MAX_LEVEL_OF_DETAIL: number;
|
|
3264
|
+
static DEFAULT_MIN_GEOMETRIC_ERROR: number;
|
|
3265
|
+
static DEFAULT_MAX_GEOMETRIC_ERROR: number;
|
|
3156
3266
|
static DEFAULT_MAX_MEMORY_USAGE: number;
|
|
3157
3267
|
static DEFAULT_MAX_SCREEN_SPACE_ERROR: number;
|
|
3158
3268
|
static DEFAULT_SKIP_LEVEL_OF_DETAIL: boolean;
|
|
@@ -3165,6 +3275,7 @@ export declare class Tile3DModel extends THREE_2.Object3D {
|
|
|
3165
3275
|
modelsLoaded: any;
|
|
3166
3276
|
debug: 'root-bounding-volume' | 'selected-bounding-volume' | 'none';
|
|
3167
3277
|
type: 'point_cloud' | 'mesh';
|
|
3278
|
+
light: boolean;
|
|
3168
3279
|
upAxis: string;
|
|
3169
3280
|
model: Model;
|
|
3170
3281
|
viewLayer?: ModelViewLayer;
|
|
@@ -3182,7 +3293,9 @@ export declare class Tile3DModel extends THREE_2.Object3D {
|
|
|
3182
3293
|
tileset: Tileset;
|
|
3183
3294
|
minLevelOfDetail: number;
|
|
3184
3295
|
maxLevelOfDetail: number;
|
|
3185
|
-
|
|
3296
|
+
maxGeometricError: number;
|
|
3297
|
+
minGeometricError: number;
|
|
3298
|
+
panoramaMinGeometricError: number;
|
|
3186
3299
|
boundingBox: THREE_2.Box3;
|
|
3187
3300
|
needsRefined: boolean;
|
|
3188
3301
|
refined: boolean;
|
|
@@ -3224,6 +3337,7 @@ export declare class Tile3DModel extends THREE_2.Object3D {
|
|
|
3224
3337
|
set loadAll(value: boolean);
|
|
3225
3338
|
get maxScreenSpaceError(): number;
|
|
3226
3339
|
set maxScreenSpaceError(value: number);
|
|
3340
|
+
get currentMaxScreenSpaceError(): number;
|
|
3227
3341
|
get trajectories(): Trajectory[];
|
|
3228
3342
|
localToEnu(vector: THREE_2.Vector3): THREE_2.Vector3;
|
|
3229
3343
|
enuToLocal(vector: THREE_2.Vector3): THREE_2.Vector3;
|
|
@@ -3251,6 +3365,7 @@ export declare class Tile3DModel extends THREE_2.Object3D {
|
|
|
3251
3365
|
/** Advanced loader options */
|
|
3252
3366
|
export declare interface Tile3DModelLoaderOptions {
|
|
3253
3367
|
name: string;
|
|
3368
|
+
light: boolean;
|
|
3254
3369
|
type: 'point_cloud' | 'mesh';
|
|
3255
3370
|
upAxis: string;
|
|
3256
3371
|
url: string;
|
|
@@ -3293,6 +3408,7 @@ export declare type TileCacheOptions = {
|
|
|
3293
3408
|
export declare type TileContentData = {
|
|
3294
3409
|
type: ParsedResultType['type'];
|
|
3295
3410
|
byteLength: number;
|
|
3411
|
+
memoryUsage: number;
|
|
3296
3412
|
uri: string;
|
|
3297
3413
|
object: TileNode;
|
|
3298
3414
|
};
|
|
@@ -3315,6 +3431,7 @@ export declare class TileCubeTextureTarget {
|
|
|
3315
3431
|
static DEFAULT_MAX_REQUEST: number;
|
|
3316
3432
|
name: string;
|
|
3317
3433
|
needsRender: boolean;
|
|
3434
|
+
baseLevel: number;
|
|
3318
3435
|
maxRequest: number;
|
|
3319
3436
|
private disposed;
|
|
3320
3437
|
private loadedCubeNodes;
|
|
@@ -3372,7 +3489,7 @@ export declare class TileNode extends THREE_2.Object3D {
|
|
|
3372
3489
|
private contentObject;
|
|
3373
3490
|
private disposers;
|
|
3374
3491
|
materials: THREE_2.Material[];
|
|
3375
|
-
pbmObjects: (PBMMesh | PBMPointCloud)[];
|
|
3492
|
+
pbmObjects: (PBMMesh | PBMSkinnedMesh | PBMPointCloud)[];
|
|
3376
3493
|
constructor(name: string, contentObject: THREE_2.Object3D, disposer?: () => void);
|
|
3377
3494
|
generateBvhTree(): Promise<this>;
|
|
3378
3495
|
intersectRaycaster(raycaster: THREE_2.Raycaster, sortByDistance?: boolean, target?: Intersection[]): Intersection[];
|
|
@@ -3401,6 +3518,8 @@ export declare type TileRequestSchedulerOptions = {
|
|
|
3401
3518
|
|
|
3402
3519
|
export declare class Tileset {
|
|
3403
3520
|
static DEFAULT_MAX_MEMORY_USAGE: number;
|
|
3521
|
+
static DEFAULT_MEMORY_OVERFLOW: number;
|
|
3522
|
+
static DEFAULT_MEMORY_ADJUSTED_SCREEN_SPACE_ERROR: boolean;
|
|
3404
3523
|
static DEFAULT_MAX_SCREEN_SPACE_ERROR: number;
|
|
3405
3524
|
static DEFAULT_SKIP_LEVEL_OF_DETAIL: boolean;
|
|
3406
3525
|
static DEFAULT_MOST_DETAIL: boolean;
|
|
@@ -3428,6 +3547,8 @@ export declare class Tileset {
|
|
|
3428
3547
|
frameNumber: number;
|
|
3429
3548
|
minLevelOfDetail: number;
|
|
3430
3549
|
maxLevelOfDetail: number;
|
|
3550
|
+
minGeometricError: number;
|
|
3551
|
+
maxGeometricError: number;
|
|
3431
3552
|
properties: Record<string, any>;
|
|
3432
3553
|
options: TilesetOptions;
|
|
3433
3554
|
root: Tile;
|
|
@@ -3436,12 +3557,15 @@ export declare class Tileset {
|
|
|
3436
3557
|
transformIsIdentity: boolean;
|
|
3437
3558
|
geometricError: number;
|
|
3438
3559
|
cache: TileCache;
|
|
3560
|
+
currentMaxScreenSpaceError: number;
|
|
3439
3561
|
requestScheduler: TileRequestScheduler;
|
|
3562
|
+
private cacheMemoryUsageInBytes;
|
|
3440
3563
|
private normalTraverser;
|
|
3441
3564
|
private skipTraverser;
|
|
3442
3565
|
private mostDetailTraverser;
|
|
3443
|
-
private memoryUsageInBytes;
|
|
3444
3566
|
maxMemoryUsage: number;
|
|
3567
|
+
memoryOverflow: number;
|
|
3568
|
+
memoryAdjustedScreenSpaceError: boolean;
|
|
3445
3569
|
maxScreenSpaceError: number;
|
|
3446
3570
|
skipLevelOfDetail: boolean;
|
|
3447
3571
|
mostDetail: boolean;
|
|
@@ -3459,6 +3583,7 @@ export declare class Tileset {
|
|
|
3459
3583
|
pointLength: number;
|
|
3460
3584
|
floorLength: number;
|
|
3461
3585
|
constructor(id: string, header: TilesetHeader, options: TilesetOptions);
|
|
3586
|
+
private adjustScreenSpaceError;
|
|
3462
3587
|
private get traverser();
|
|
3463
3588
|
/** Release resources */
|
|
3464
3589
|
reset(): void;
|
|
@@ -3470,11 +3595,10 @@ export declare type TilesetFrameState = {
|
|
|
3470
3595
|
time: number;
|
|
3471
3596
|
camera: {
|
|
3472
3597
|
type: "PerspectiveCamera" | "OrthographicCamera";
|
|
3473
|
-
near: number;
|
|
3474
|
-
far: number;
|
|
3475
3598
|
position: THREE.Vector3;
|
|
3476
3599
|
direction: THREE.Vector3;
|
|
3477
3600
|
up: THREE.Vector3;
|
|
3601
|
+
projectionMatrix: THREE.Matrix4;
|
|
3478
3602
|
visible: boolean;
|
|
3479
3603
|
refine: boolean;
|
|
3480
3604
|
};
|
|
@@ -3484,6 +3608,8 @@ export declare type TilesetFrameState = {
|
|
|
3484
3608
|
sseDenominator: number;
|
|
3485
3609
|
minLevelOfDetail: number;
|
|
3486
3610
|
maxLevelOfDetail: number;
|
|
3611
|
+
minGeometricError: number;
|
|
3612
|
+
maxGeometricError: number;
|
|
3487
3613
|
};
|
|
3488
3614
|
|
|
3489
3615
|
export declare interface TilesetHeader {
|
|
@@ -3577,12 +3703,14 @@ export declare class Trajectory {
|
|
|
3577
3703
|
loadStateUpdateTime: number;
|
|
3578
3704
|
loadfailRetryDelay: number;
|
|
3579
3705
|
byteLength: number;
|
|
3706
|
+
memoryUsage: number;
|
|
3580
3707
|
};
|
|
3581
3708
|
constructor(index: number, header: TrajectoryHeader, tileset: Tileset);
|
|
3582
3709
|
}
|
|
3583
3710
|
|
|
3584
3711
|
export declare type TrajectoryContentData = {
|
|
3585
3712
|
byteLength: number;
|
|
3713
|
+
memoryUsage: number;
|
|
3586
3714
|
uri: string;
|
|
3587
3715
|
object: TrajectoryNode;
|
|
3588
3716
|
positionArray: ArrayLike<number>;
|
|
@@ -3649,6 +3777,8 @@ export declare type WebXRControllerType = 'tap' | 'press' | 'axes' | 'buttonUp'
|
|
|
3649
3777
|
export declare class Work {
|
|
3650
3778
|
/** 名称 */
|
|
3651
3779
|
name: string;
|
|
3780
|
+
/** 根地址 */
|
|
3781
|
+
baseURL: string;
|
|
3652
3782
|
/** 编号 */
|
|
3653
3783
|
workCode: string;
|
|
3654
3784
|
/** 允许访问的安全域名 */
|
|
@@ -3688,7 +3818,7 @@ export declare class Work {
|
|
|
3688
3818
|
* @returns - 签署过的 Work 数据结构
|
|
3689
3819
|
*/
|
|
3690
3820
|
static parse: typeof parseWork;
|
|
3691
|
-
constructor(obj: Work | LooseWork | (Work | LooseWork)[] | any, options: ParseWorkOptions);
|
|
3821
|
+
constructor(obj: Work | LoosePanoWork | LooseWork | (Work | LooseWork)[] | any, options: ParseWorkOptions);
|
|
3692
3822
|
toJSON(): any;
|
|
3693
3823
|
}
|
|
3694
3824
|
|