@liveroom-tech/react-immersive 6.1.3 → 6.2.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/dist/DownloadedEnvironment-NHM4U2LJ.mjs +1 -0
- package/dist/{SequencesTab-66VBWTO5.mjs → SequencesTab-VZKEKAUG.mjs} +1 -1
- package/dist/StreamingTilesModel-6Z7SIC2J.mjs +16 -0
- package/dist/binding-builder.css +1 -1
- package/dist/binding-builder.d.mts +3 -3
- package/dist/binding-builder.d.ts +3 -3
- package/dist/binding-builder.js +59 -58
- package/dist/binding-builder.mjs +1 -1
- package/dist/chunk-25WC5KDO.mjs +50 -0
- package/dist/chunk-2AJK643D.mjs +1 -0
- package/dist/chunk-3OCHN3CA.mjs +1 -0
- package/dist/chunk-7OVEHDDE.mjs +1 -0
- package/dist/chunk-KFLS7GI6.mjs +1 -0
- package/dist/{chunk-B75URXOE.mjs → chunk-KYXJG3TX.mjs} +1 -1
- package/dist/chunk-LD7QWHB4.mjs +3 -0
- package/dist/{chunk-LKKH4PO7.mjs → chunk-NMRTI3NQ.mjs} +1 -1
- package/dist/chunk-RKDATTUM.mjs +1 -0
- package/dist/chunk-RXZ4Q7CY.mjs +1 -0
- package/dist/chunk-TUYVYSN5.mjs +1 -0
- package/dist/chunk-UAZ6I25Y.mjs +1 -0
- package/dist/chunk-UCD76KQ6.mjs +1 -0
- package/dist/chunk-UHRJ2RBF.mjs +1 -0
- package/dist/chunk-UTVFRMYW.mjs +47 -0
- package/dist/chunk-YKDDNX2D.mjs +69 -0
- package/dist/exportSceneMesh-YJFOLFHS.mjs +1 -0
- package/dist/hosted.css +1 -1
- package/dist/hosted.d.mts +4 -4
- package/dist/hosted.d.ts +4 -4
- package/dist/hosted.js +58 -57
- package/dist/hosted.mjs +1 -1
- package/dist/index.css +1 -1
- package/dist/index.d.mts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +52 -51
- package/dist/index.mjs +1 -1
- package/dist/meshFormats-4C6NHYOA.mjs +1 -0
- package/dist/{modelViewerProps-Bo48RDq6.d.ts → modelFileResolver-CVmON8hg.d.mts} +459 -895
- package/dist/{modelViewerProps-DkvYb1GH.d.mts → modelFileResolver-CVmON8hg.d.ts} +459 -895
- package/dist/modelViewerProps-BBnZTFO-.d.ts +949 -0
- package/dist/modelViewerProps-CIY4nsNY.d.mts +949 -0
- package/dist/{publicProps-DJSccx3b.d.ts → publicProps-BARVwXu7.d.ts} +2 -1
- package/dist/{publicProps-DN0-8tBm.d.mts → publicProps-n0Yvr_Km.d.mts} +2 -1
- package/dist/simple-model-viewer.css +1 -1
- package/dist/simple-model-viewer.d.mts +35 -4
- package/dist/simple-model-viewer.d.ts +35 -4
- package/dist/simple-model-viewer.js +5 -5
- package/dist/simple-model-viewer.mjs +1 -1
- package/dist/utils.d.mts +4 -4
- package/dist/utils.d.ts +4 -4
- package/dist/utils.js +3 -3
- package/dist/utils.mjs +1 -1
- package/dist/xrRuntime-5S7KYUVB.mjs +1 -0
- package/package.json +7 -4
- package/dist/chunk-4RYMXBK6.mjs +0 -47
- package/dist/chunk-5P7ETEAN.mjs +0 -50
- package/dist/chunk-6Q6YZ7O5.mjs +0 -1
- package/dist/chunk-EC542N4J.mjs +0 -1
- package/dist/chunk-JK7GRGRG.mjs +0 -1
- package/dist/chunk-U3BQMOC3.mjs +0 -83
- package/dist/chunk-VMYNX63T.mjs +0 -3
- package/dist/modelFileResolver-B2B3F3d1.d.mts +0 -464
- package/dist/modelFileResolver-B2B3F3d1.d.ts +0 -464
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
import { Object3D, Material } from 'three';
|
|
2
|
-
import { e as ViewerModelBounds, R as ReducedMotionSetting, d as ModelViewerLabels, V as ViewerLoading, g as ViewerReveal, b as ModelFormat, f as ViewerModelInfo } from './modelFileResolver-B2B3F3d1.mjs';
|
|
3
|
-
import { ReactNode } from 'react';
|
|
4
|
-
import { CameraControls } from '@react-three/drei';
|
|
5
|
-
|
|
6
1
|
type ViewerCameraState = {
|
|
7
2
|
position: [number, number, number];
|
|
8
3
|
target: [number, number, number];
|
|
@@ -369,6 +364,8 @@ type SceneLight = {
|
|
|
369
364
|
decay?: number;
|
|
370
365
|
angle?: number;
|
|
371
366
|
penumbra?: number;
|
|
367
|
+
/** Spot/directional aim point; unset aims at the origin (model centre with shadows). */
|
|
368
|
+
target?: [number, number, number];
|
|
372
369
|
attachedToCamera: boolean;
|
|
373
370
|
/** Follow a model object instead of using the world-space position. */
|
|
374
371
|
attachment?: SceneLightAttachment;
|
|
@@ -410,7 +407,7 @@ type SceneShadowConfig = {
|
|
|
410
407
|
normalBias: number;
|
|
411
408
|
radius: number;
|
|
412
409
|
};
|
|
413
|
-
declare const ENVIRONMENT_PRESETS: readonly ["apartment", "city", "dawn", "forest", "lobby", "night", "park", "studio", "sunset", "warehouse"];
|
|
410
|
+
declare const ENVIRONMENT_PRESETS: readonly ["neutral", "apartment", "city", "dawn", "forest", "lobby", "night", "park", "studio", "sunset", "warehouse"];
|
|
414
411
|
type EnvironmentPreset = (typeof ENVIRONMENT_PRESETS)[number];
|
|
415
412
|
type SceneEnvironmentConfig = {
|
|
416
413
|
source: "preset" | "custom";
|
|
@@ -878,6 +875,8 @@ type AnimationClipState = {
|
|
|
878
875
|
reverse: boolean;
|
|
879
876
|
};
|
|
880
877
|
type AnimationPlaybackState = {
|
|
878
|
+
/** Playback intent is preserved while offscreen rendering is suspended. */
|
|
879
|
+
isRenderPaused?: boolean;
|
|
881
880
|
/** The clip played most recently, while it's active. */
|
|
882
881
|
currentClip: string | null;
|
|
883
882
|
/** Whether any clip is playing. */
|
|
@@ -906,6 +905,7 @@ type AnimationControls = {
|
|
|
906
905
|
subscribe?: (listener: (state: AnimationPlaybackState) => void) => () => void;
|
|
907
906
|
};
|
|
908
907
|
type ViewerAnimationsProps = {
|
|
908
|
+
isRenderPaused: boolean;
|
|
909
909
|
clips: string[];
|
|
910
910
|
clipDetails: AnimationClipInfo[];
|
|
911
911
|
currentClip: string | null;
|
|
@@ -1226,311 +1226,463 @@ type ObjectPointerEvent = {
|
|
|
1226
1226
|
surface?: ObjectSurfacePoint;
|
|
1227
1227
|
};
|
|
1228
1228
|
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
/** Start with the panel closed. On small screens it always starts closed. */
|
|
1235
|
-
defaultClosed?: boolean;
|
|
1236
|
-
onConfigurationChange?: (configuration: ProductConfiguration, checkoutUrl: string | null) => void;
|
|
1237
|
-
};
|
|
1238
|
-
|
|
1239
|
-
type ComparisonCategory = "identity" | "appearance" | "transform" | "visibility" | "data" | "behavior" | "scene";
|
|
1240
|
-
type ComparisonStatus = "added" | "removed" | "modified" | "unchanged" | "ambiguous";
|
|
1241
|
-
type ConfigurationComparisonInput = {
|
|
1242
|
-
objectBindings: Record<string, ObjectBinding>;
|
|
1243
|
-
sceneConfig?: SceneConfig;
|
|
1244
|
-
};
|
|
1245
|
-
type SemanticComparisonOptions = {
|
|
1246
|
-
/** Default: modelObjectId. Metadata matching is exact and never guesses duplicates. */
|
|
1247
|
-
matchBy?: "modelObjectId" | "id" | {
|
|
1248
|
-
metadataKey: string;
|
|
1249
|
-
};
|
|
1250
|
-
/** Explicit binding-key pairs, before key -> after key. Must be one-to-one. */
|
|
1251
|
-
mapping?: Record<string, string>;
|
|
1252
|
-
/** Absolute tolerance for numeric properties. Default: 0.000001. */
|
|
1253
|
-
tolerance?: number;
|
|
1254
|
-
ignoreMetadataKeys?: string[];
|
|
1255
|
-
};
|
|
1256
|
-
type ComparisonChange = {
|
|
1257
|
-
path: string;
|
|
1258
|
-
category: ComparisonCategory;
|
|
1259
|
-
before?: unknown;
|
|
1260
|
-
after?: unknown;
|
|
1261
|
-
};
|
|
1262
|
-
type ComparisonObject = {
|
|
1263
|
-
id: string;
|
|
1264
|
-
identity: string;
|
|
1229
|
+
/** One choice in a row of material variants. */
|
|
1230
|
+
type MaterialVariantOption = {
|
|
1231
|
+
/** The variant's name, as `sceneConfig.model.activeVariants` lists it. */
|
|
1232
|
+
name: string;
|
|
1233
|
+
/** The name without its group, for display: "Red" for "Paint: Red". */
|
|
1265
1234
|
label: string;
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
changes: ComparisonChange[];
|
|
1272
|
-
message?: string;
|
|
1273
|
-
};
|
|
1274
|
-
type ConfigurationComparisonReport = {
|
|
1275
|
-
version: 1;
|
|
1276
|
-
objects: ComparisonObject[];
|
|
1277
|
-
counts: Record<ComparisonStatus, number>;
|
|
1278
|
-
sceneChanges: ComparisonChange[];
|
|
1279
|
-
};
|
|
1280
|
-
type ComparisonHighlight = {
|
|
1281
|
-
objectId: string;
|
|
1282
|
-
color: string;
|
|
1235
|
+
/**
|
|
1236
|
+
* The colour of the variant's main material, as a CSS colour, when that
|
|
1237
|
+
* material is a plain colour rather than a texture.
|
|
1238
|
+
*/
|
|
1239
|
+
swatch?: string;
|
|
1283
1240
|
};
|
|
1284
|
-
/** Compare authored configuration data. Does not infer geometry changes from meshes or URLs. */
|
|
1285
|
-
declare function compareViewerConfigurations(before: ConfigurationComparisonInput, after: ConfigurationComparisonInput, options?: SemanticComparisonOptions): ConfigurationComparisonReport;
|
|
1286
|
-
|
|
1287
|
-
/** Serializable, controlled viewer props. Assets stay at their durable URLs. */
|
|
1288
|
-
type ViewerConfiguration = Pick<ModelViewerProps, "activeModelId" | "modelUrl" | "modelFormat" | "tilesetUrl" | "models" | "mergeModels" | "sceneConfig" | "isolation" | "multiSelectedKeys" | "activeAnnotation" | "annotationCategories" | "backgroundColor" | "shadows" | "cinematic" | "cameraControllerType" | "objectTransformSpace" | "arScaleMode" | "usdzUrl" | "measurements" | "measurementSettings" | "measurementUnit" | "measurementModelId">;
|
|
1289
|
-
/** Unversioned camera/visibility/selection links remain readable. */
|
|
1290
|
-
type ShareableViewerState = {
|
|
1291
|
-
version?: 1;
|
|
1292
|
-
camera?: ViewerCameraState;
|
|
1293
|
-
hidden?: string[];
|
|
1294
|
-
selected?: string | null;
|
|
1295
|
-
/** Full bindings, including materials, decals, transforms and metadata. */
|
|
1296
|
-
objectBindings?: Record<string, ObjectBinding>;
|
|
1297
|
-
configuration?: ViewerConfiguration;
|
|
1298
|
-
};
|
|
1299
|
-
/** Application-owned persistence. load may return parsed data or saved JSON. */
|
|
1300
|
-
type ViewerStateStorage = {
|
|
1301
|
-
save: (state: ShareableViewerState) => Promise<string>;
|
|
1302
|
-
load: (id: string) => Promise<unknown>;
|
|
1303
|
-
};
|
|
1304
|
-
declare const MAX_VIEWER_STATE_BYTES: number;
|
|
1305
|
-
/** JSON suitable for a file, database or application-owned storage adapter. */
|
|
1306
|
-
declare function serializeViewerState(state: ShareableViewerState, baseUrl?: string): string;
|
|
1307
|
-
/** Validate portable data. For live blob images use prepareViewerState first. */
|
|
1308
|
-
declare function parseViewerState(input: unknown, baseUrl?: string): ShareableViewerState;
|
|
1309
1241
|
/**
|
|
1310
|
-
*
|
|
1311
|
-
*
|
|
1242
|
+
* Variants that take turns: choosing one replaces the group's other choice.
|
|
1243
|
+
* Variants in different groups combine, like a paint colour and a wheel style.
|
|
1312
1244
|
*/
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
instanceId?: string;
|
|
1318
|
-
objectBindings?: NonNullable<ShareableViewerState["objectBindings"]>;
|
|
1319
|
-
materialOverrides?: Record<string, Material | Material[]>;
|
|
1320
|
-
/** Authored autoplay clips and sequences to include in Quick Look. */
|
|
1321
|
-
sceneConfig?: Pick<SceneConfig, "animations" | "sequences">;
|
|
1322
|
-
};
|
|
1323
|
-
type ARExportOptions = {
|
|
1324
|
-
scaleMode?: "normalized" | "real-world";
|
|
1325
|
-
/** Longest texture dimension, default 2048; from 256 to 4096. */
|
|
1326
|
-
maxTextureSize?: number;
|
|
1327
|
-
signal?: AbortSignal;
|
|
1328
|
-
};
|
|
1329
|
-
type ARSnapshot = {
|
|
1330
|
-
blob: Blob;
|
|
1331
|
-
meshCount: number;
|
|
1332
|
-
triangleCount: number;
|
|
1333
|
-
/** Applied scale after centering horizontally and resting on Y=0. */
|
|
1334
|
-
scale: number;
|
|
1335
|
-
warnings: string[];
|
|
1336
|
-
};
|
|
1337
|
-
type ARHandoffRequest = {
|
|
1338
|
-
/** Stable key for this configuration and application-supplied asset version. */
|
|
1339
|
-
configurationKey: string;
|
|
1340
|
-
/** Detached live data. Local model URLs may still be temporary. */
|
|
1341
|
-
state: ShareableViewerState;
|
|
1342
|
-
signal: AbortSignal;
|
|
1343
|
-
/** Exports the current geometry and supported authored animation to USDZ. */
|
|
1344
|
-
exportUSDZ: () => Promise<ARSnapshot>;
|
|
1345
|
-
};
|
|
1346
|
-
type ARHandoffStatus = "idle" | "preparing" | "ready" | "error" | "stale";
|
|
1347
|
-
type ARHandoffOptions = {
|
|
1348
|
-
/** Change this when replacing an asset at the same URL, or after direct scene mutations. */
|
|
1349
|
-
assetVersion?: string;
|
|
1350
|
-
maxTextureSize?: number;
|
|
1351
|
-
/** Store large phone configurations using the same adapter in the receiving viewer. */
|
|
1352
|
-
storage?: ViewerStateStorage;
|
|
1353
|
-
/** Read this feature's configuration hash on arrival. Default true. */
|
|
1354
|
-
autoRestore?: boolean;
|
|
1355
|
-
/** Application-owned conversion/cache for assets unsupported by the local exporter. */
|
|
1356
|
-
createUSDZ?: (request: ARHandoffRequest) => Promise<Blob | string>;
|
|
1357
|
-
/** Application-owned upload/sharing path, including support for local model files. */
|
|
1358
|
-
createMobileUrl?: (request: ARHandoffRequest) => Promise<string>;
|
|
1359
|
-
onStatusChange?: (status: ARHandoffStatus) => void;
|
|
1360
|
-
onError?: (error: Error) => void;
|
|
1245
|
+
type MaterialVariantGroup = {
|
|
1246
|
+
/** "Paint" for variants named "Paint: Red" or "Paint / Red"; null otherwise. */
|
|
1247
|
+
name: string | null;
|
|
1248
|
+
variants: MaterialVariantOption[];
|
|
1361
1249
|
};
|
|
1250
|
+
/**
|
|
1251
|
+
* The active variants after choosing `name`: it replaces any other variant of
|
|
1252
|
+
* its group, so a paint colour swaps for another while the wheels stay.
|
|
1253
|
+
*/
|
|
1254
|
+
declare function chooseMaterialVariant(activeVariants: readonly string[], name: string, groups: readonly MaterialVariantGroup[]): string[];
|
|
1362
1255
|
|
|
1363
|
-
|
|
1364
|
-
type AssetTransform = {
|
|
1365
|
-
position?: [number, number, number];
|
|
1366
|
-
rotation?: [number, number, number];
|
|
1367
|
-
scale?: [number, number, number];
|
|
1368
|
-
};
|
|
1369
|
-
type AssetPlacement = AssetTransform & {
|
|
1370
|
-
label?: string;
|
|
1371
|
-
visible?: boolean;
|
|
1372
|
-
deleted?: boolean;
|
|
1373
|
-
};
|
|
1374
|
-
/** Standalone editor placement state, keyed by persistent model identity. */
|
|
1375
|
-
type SceneComposition = {
|
|
1376
|
-
version: 1;
|
|
1377
|
-
placements: Record<string, AssetPlacement>;
|
|
1378
|
-
gridSize: number;
|
|
1379
|
-
};
|
|
1380
|
-
declare function parseAssetTransform(value: unknown): AssetTransform;
|
|
1381
|
-
/** Snap the instance origin on the shared X/Z plane. */
|
|
1382
|
-
declare function snapAssetToGrid(transform: AssetTransform, size: number): AssetTransform;
|
|
1383
|
-
/** Place the transformed asset's lowest bound on the Y=0 ground plane. */
|
|
1384
|
-
declare function groundAsset(transform: AssetTransform, bounds: {
|
|
1256
|
+
type ViewerModelBounds = {
|
|
1385
1257
|
min: [number, number, number];
|
|
1386
1258
|
max: [number, number, number];
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
type
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
extensionsRequired?: string[];
|
|
1408
|
-
failedResources?: string[];
|
|
1409
|
-
};
|
|
1410
|
-
type AssetTextureDiagnostic = {
|
|
1411
|
-
name: string;
|
|
1412
|
-
width: number | null;
|
|
1413
|
-
height: number | null;
|
|
1414
|
-
compressed: boolean;
|
|
1415
|
-
/** RGBA8 with mipmaps for ordinary textures; actual mip bytes for compressed textures. */
|
|
1416
|
-
estimatedBytes: number | null;
|
|
1417
|
-
};
|
|
1418
|
-
type AssetDiagnosticsReport = {
|
|
1419
|
-
version: 1;
|
|
1420
|
-
status: "ready" | "failed";
|
|
1421
|
-
scope: "asset" | "resident-tiles";
|
|
1422
|
-
source: AssetDiagnosticsSource;
|
|
1423
|
-
/** A format convention, not verification of the model author's physical scale. */
|
|
1424
|
-
units: "meters (glTF convention)" | "unknown";
|
|
1425
|
-
bounds: ViewerModelBounds | null;
|
|
1426
|
-
statistics: {
|
|
1427
|
-
meshes: number;
|
|
1428
|
-
instances: number;
|
|
1429
|
-
geometries: number;
|
|
1430
|
-
materials: number;
|
|
1431
|
-
textures: number;
|
|
1432
|
-
/** Unique geometry data, not repeated instances or per-frame rendered triangles. */
|
|
1433
|
-
vertices: number;
|
|
1434
|
-
triangles: number;
|
|
1435
|
-
geometryBytes: number;
|
|
1436
|
-
estimatedTextureBytes: number;
|
|
1437
|
-
unknownTextureSizes: number;
|
|
1438
|
-
meshesWithoutUvs: number;
|
|
1439
|
-
meshesWithoutNormals: number;
|
|
1440
|
-
} | null;
|
|
1441
|
-
textures: AssetTextureDiagnostic[];
|
|
1442
|
-
extensions: {
|
|
1443
|
-
name: string;
|
|
1444
|
-
required: boolean;
|
|
1445
|
-
recognized: boolean;
|
|
1446
|
-
}[];
|
|
1447
|
-
issues: AssetDiagnosticIssue[];
|
|
1448
|
-
};
|
|
1449
|
-
type InspectAssetOptions = {
|
|
1450
|
-
source?: AssetDiagnosticsSource;
|
|
1451
|
-
scope?: AssetDiagnosticsReport["scope"];
|
|
1452
|
-
};
|
|
1453
|
-
type StreamingDiagnostics = {
|
|
1454
|
-
cachedBytes: number | null;
|
|
1455
|
-
budgetBytes: number;
|
|
1456
|
-
cachedTiles: number | null;
|
|
1457
|
-
downloading: number;
|
|
1458
|
-
parsing: number;
|
|
1459
|
-
cacheFull: boolean;
|
|
1460
|
-
/** Existing memory-pressure adaptation's multiplier; 1 is the requested detail. */
|
|
1461
|
-
detailFactor: number;
|
|
1462
|
-
errorTarget: number;
|
|
1463
|
-
};
|
|
1464
|
-
type ViewerRuntimeStats = {
|
|
1465
|
-
sampledAt: string;
|
|
1466
|
-
renderer: "webgl" | "webgpu";
|
|
1467
|
-
/** Last completed renderer pass; may be a post-processing or shadow pass. */
|
|
1468
|
-
drawCalls: number | null;
|
|
1469
|
-
triangles: number | null;
|
|
1470
|
-
geometries: number | null;
|
|
1471
|
-
textures: number | null;
|
|
1472
|
-
/** Spacing of consecutive active frame callbacks, not CPU/GPU execution time. */
|
|
1473
|
-
frameIntervalMs: number | null;
|
|
1474
|
-
fps: number | null;
|
|
1475
|
-
frameSamples: number;
|
|
1476
|
-
renderMode: "always" | "demand" | "never";
|
|
1477
|
-
quality: {
|
|
1478
|
-
profile: PerformanceProfile;
|
|
1479
|
-
reducedGpuLoad: boolean;
|
|
1480
|
-
dpr: number;
|
|
1481
|
-
shadows: boolean;
|
|
1482
|
-
/** Whether the quality profile/backend permits the post-processing stack. */
|
|
1483
|
-
postProcessing: boolean;
|
|
1484
|
-
};
|
|
1485
|
-
streaming: StreamingDiagnostics | null;
|
|
1259
|
+
center: [number, number, number];
|
|
1260
|
+
size: [number, number, number];
|
|
1261
|
+
};
|
|
1262
|
+
/** What `onModelLoaded` reports about a model that finished loading. */
|
|
1263
|
+
type ViewerModelInfo = {
|
|
1264
|
+
/** Bounds in world space, where the viewer placed the model. */
|
|
1265
|
+
bounds: ViewerModelBounds;
|
|
1266
|
+
/** Number of meshes in the loaded scene. */
|
|
1267
|
+
objectCount: number;
|
|
1268
|
+
/**
|
|
1269
|
+
* Names of the glTF material variants (KHR_materials_variants) the model
|
|
1270
|
+
* offers, in file order; empty when it has none. Show them by setting
|
|
1271
|
+
* `sceneConfig.model.activeVariants`.
|
|
1272
|
+
*/
|
|
1273
|
+
materialVariants: string[];
|
|
1274
|
+
/**
|
|
1275
|
+
* The same variants as option groups, with their display labels and
|
|
1276
|
+
* swatches. One variant from each group can show at once.
|
|
1277
|
+
*/
|
|
1278
|
+
materialVariantGroups: MaterialVariantGroup[];
|
|
1486
1279
|
};
|
|
1487
1280
|
|
|
1488
|
-
/**
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1281
|
+
/** Built-in viewer text. Override only the keys your application needs. */
|
|
1282
|
+
declare const DEFAULT_MODEL_VIEWER_LABELS: {
|
|
1283
|
+
readonly verifyingLicense: "Verifying License";
|
|
1284
|
+
readonly checkingYourLicenseKey: "Checking your license key...";
|
|
1285
|
+
readonly createDevelopmentKey: "Create a free development key";
|
|
1286
|
+
readonly invalidLicense: "Invalid License";
|
|
1287
|
+
readonly licenseHasBeenRevokedOrHasExpired: "License has been revoked or has expired";
|
|
1288
|
+
readonly failedToLoadPleaseContactTheSiteAdministrator: "Failed to load. Please contact the site administrator.";
|
|
1289
|
+
readonly contextRestoringTitle: "Reloading viewer…";
|
|
1290
|
+
readonly contextLostTitle: "3D view interrupted";
|
|
1291
|
+
readonly contextRestoringMessage: "Rebuilding the 3D view. Please wait…";
|
|
1292
|
+
readonly contextLostMessage: "The graphics connection was interrupted. The viewer will rebuild when it returns, or you can reload it now.";
|
|
1293
|
+
readonly reloadViewer: "Reload viewer";
|
|
1294
|
+
readonly texturePositioningHint: "Drag to move · Scroll to zoom · Click elsewhere to finish";
|
|
1295
|
+
readonly texturePositioningStartHint: "Double-click to move or zoom";
|
|
1296
|
+
readonly dismiss: "Dismiss";
|
|
1297
|
+
readonly missingUVsAreShownInMagenta: "Missing UVs are shown in magenta.";
|
|
1298
|
+
readonly viewThisModelInARWithAppleQuickLook: "View this model in AR with Apple Quick Look";
|
|
1299
|
+
readonly sequencePlayer: "Sequence player";
|
|
1300
|
+
readonly sequenceSelect: "Sequence";
|
|
1301
|
+
readonly sequencePlay: "Play sequence";
|
|
1302
|
+
readonly sequencePause: "Pause sequence";
|
|
1303
|
+
readonly sequenceStop: "Stop and restore scene";
|
|
1304
|
+
readonly sequencePlayhead: "Sequence playhead";
|
|
1305
|
+
readonly sequenceTime: "Sequence time";
|
|
1306
|
+
readonly sequenceIssues: "Unavailable sequence targets";
|
|
1307
|
+
readonly arConfiguredButton: "AR handoff";
|
|
1308
|
+
readonly arConfiguredTitle: "Take this configuration to AR";
|
|
1309
|
+
readonly arConfiguredDescription: "Your current materials, visible models and placements are included.";
|
|
1310
|
+
readonly arSnapshotStale: "Updating AR to include your latest changes…";
|
|
1311
|
+
readonly arPreparing: "Preparing your scene…";
|
|
1312
|
+
readonly arStart: "Start AR";
|
|
1313
|
+
readonly arStarting: "Starting AR…";
|
|
1314
|
+
readonly arCheckingSupport: "Checking AR support…";
|
|
1315
|
+
readonly arUnavailable: "AR is unavailable in this browser. Open this link in an AR-capable browser on your phone.";
|
|
1316
|
+
readonly arStartFailed: "Could not start AR. Check camera permissions and try again.";
|
|
1317
|
+
readonly arAnimations: "AR animations";
|
|
1318
|
+
readonly arAnimationSelect: "Animation";
|
|
1319
|
+
readonly arAnimationSaved: "Default";
|
|
1320
|
+
readonly arAnimationNone: "No animation";
|
|
1321
|
+
readonly arAnimationClips: "Model clips";
|
|
1322
|
+
readonly arAnimationSequences: "Sequences";
|
|
1323
|
+
readonly arAnimationPlay: "Play animation";
|
|
1324
|
+
readonly arAnimationPause: "Pause animation";
|
|
1325
|
+
readonly arRefresh: "Refresh AR";
|
|
1326
|
+
readonly arRetry: "Try again";
|
|
1327
|
+
readonly arExportDetails: "Export details";
|
|
1328
|
+
readonly arPrepare: "Prepare AR";
|
|
1329
|
+
readonly arPrepareAgain: "Prepare again";
|
|
1330
|
+
readonly arDownloadUSDZ: "Download USDZ for iPhone/iPad";
|
|
1331
|
+
readonly arScanConfigured: "Scan to open this configuration on your phone.";
|
|
1332
|
+
readonly arOpenConfiguredLink: "Open configuration link";
|
|
1333
|
+
readonly viewInAR: "View in AR";
|
|
1334
|
+
readonly openThisExperienceOnAPhoneForAR: "Open this experience on a phone for AR";
|
|
1335
|
+
readonly openOnPhone: "Open on phone";
|
|
1336
|
+
readonly viewThisModelInYourSpace: "View this model in your space";
|
|
1337
|
+
readonly viewThisModelInVR: "View this model in VR";
|
|
1338
|
+
readonly closePhoneHandoff: "Close phone handoff";
|
|
1339
|
+
readonly arScanCode: "Scan the code and choose AR.";
|
|
1340
|
+
readonly qrCodeToOpenThisModelOnAPhone: "QR code to open this model on a phone";
|
|
1341
|
+
readonly disableUVChecker: "Disable UV checker";
|
|
1342
|
+
readonly enableUVChecker: "Enable UV checker";
|
|
1343
|
+
readonly explodedView: "Exploded view";
|
|
1344
|
+
readonly explodeAmount: "Explode amount";
|
|
1345
|
+
readonly removeSectionCut: "Remove section cut";
|
|
1346
|
+
readonly sectionCut: "Section cut";
|
|
1347
|
+
readonly sectionAxis: "Section axis";
|
|
1348
|
+
readonly sectionPosition: "Section position";
|
|
1349
|
+
readonly keepTheOtherSide: "Keep the other side";
|
|
1350
|
+
readonly pauseCinematic: "Pause cinematic";
|
|
1351
|
+
readonly playCinematic: "Play cinematic";
|
|
1352
|
+
readonly stopCinematicAndResetCamera: "Stop cinematic and reset camera";
|
|
1353
|
+
readonly cancel: "Cancel";
|
|
1354
|
+
readonly annotationCategories: "Annotation categories";
|
|
1355
|
+
readonly annotations: "Annotations";
|
|
1356
|
+
readonly all: "All";
|
|
1357
|
+
readonly uncategorized: "Uncategorized";
|
|
1358
|
+
readonly decalDragHint: "Drag the decal on the object. Release to save; Escape to cancel.";
|
|
1359
|
+
readonly showAll: "Show all";
|
|
1360
|
+
readonly materialVariants: "Material variants";
|
|
1361
|
+
readonly startGuidedTour: "Start guided tour";
|
|
1362
|
+
readonly guidedTour: "Guided Tour";
|
|
1363
|
+
readonly previousAnnotation: "Previous annotation";
|
|
1364
|
+
readonly previous: "Prev";
|
|
1365
|
+
readonly stopGuidedTour: "Stop guided tour";
|
|
1366
|
+
readonly nextAnnotation: "Next annotation";
|
|
1367
|
+
readonly next: "Next";
|
|
1368
|
+
readonly exitFullscreen: "Exit fullscreen";
|
|
1369
|
+
readonly enterFullscreen: "Enter fullscreen";
|
|
1370
|
+
readonly resetCameraView: "Reset camera view";
|
|
1371
|
+
readonly orbitControl: "Orbit Control";
|
|
1372
|
+
readonly pointLock: "Pointer lock";
|
|
1373
|
+
readonly cameraController: "Camera controller";
|
|
1374
|
+
readonly cameraControllerSettings: "Camera controller settings";
|
|
1375
|
+
readonly downloadGLB: "Download GLB";
|
|
1376
|
+
readonly downloadGLBDescription: "All visible models, material edits and animations in one file. No annotations or separate editor model slots. Duplicate mesh names may change on reimport.";
|
|
1377
|
+
readonly downloadCombinedGLB: "Download as one GLB";
|
|
1378
|
+
readonly downloadSeparateGLBs: "Download separate GLBs";
|
|
1379
|
+
readonly downloadSeparateGLBsDescription: "One GLB file per model";
|
|
1380
|
+
readonly downloadPNG: "Download PNG";
|
|
1381
|
+
readonly downloadUVLayout: "Download UV Layout";
|
|
1382
|
+
readonly videoFormat: "Video format";
|
|
1383
|
+
readonly auto: "Auto";
|
|
1384
|
+
readonly recordTurntableVideo: "Record turntable video";
|
|
1385
|
+
readonly recordCinematicVideo: "Record cinematic video";
|
|
1386
|
+
readonly videoUnsupported: "Video recording is not supported in this browser.";
|
|
1387
|
+
readonly downloadOptions: "Download options";
|
|
1388
|
+
readonly exporting: "Exporting…";
|
|
1389
|
+
readonly download: "Download";
|
|
1390
|
+
readonly annotationTitlePlaceholder: "Title *";
|
|
1391
|
+
readonly description: "Description";
|
|
1392
|
+
readonly ok: "OK";
|
|
1393
|
+
readonly arRelocate: "Relocate";
|
|
1394
|
+
readonly tapToPlace: "Tap to place";
|
|
1395
|
+
readonly closeAnnotation: "Close annotation";
|
|
1396
|
+
readonly learnMore: "Learn more";
|
|
1397
|
+
readonly stopMeasuring: "Stop measuring";
|
|
1398
|
+
readonly startMeasuring: "Start measuring";
|
|
1399
|
+
readonly toggleBoundingDimensions: "Toggle bounding dimensions";
|
|
1400
|
+
readonly measurementTool: "Measurement tool";
|
|
1401
|
+
readonly distance: "Distance";
|
|
1402
|
+
readonly angle: "Angle";
|
|
1403
|
+
readonly area: "Area";
|
|
1404
|
+
readonly pointToPlane: "Point to plane";
|
|
1405
|
+
readonly wrap: "Circumference (Edge)";
|
|
1406
|
+
readonly wrapHorizontal: "Circumference (Horizontal)";
|
|
1407
|
+
readonly measurementSnapping: "Measurement snapping";
|
|
1408
|
+
readonly noSnapping: "No snapping";
|
|
1409
|
+
readonly snapAuto: "Snap: auto";
|
|
1410
|
+
readonly snapVertex: "Snap: vertex";
|
|
1411
|
+
readonly snapEdge: "Snap: edge";
|
|
1412
|
+
readonly undoMeasurementPoint: "Undo measurement point";
|
|
1413
|
+
readonly clearMeasurements: "Clear measurements";
|
|
1414
|
+
readonly finishArea: "Finish area";
|
|
1415
|
+
readonly savedMeasurements: "Saved measurements ({count})";
|
|
1416
|
+
readonly noSavedMeasurements: "No saved measurements yet. Pick points in the preview, then save a measurement here.";
|
|
1417
|
+
readonly measurementFiles: "Import / export";
|
|
1418
|
+
readonly measurementSourceUnit: "Model units";
|
|
1419
|
+
readonly measurementDisplayUnit: "Display units";
|
|
1420
|
+
readonly measurementName: "Name";
|
|
1421
|
+
readonly measurementNamePlaceholder: "e.g. Door width";
|
|
1422
|
+
readonly saveMeasurement: "Save";
|
|
1423
|
+
readonly knownMeasurementDistance: "Known length";
|
|
1424
|
+
readonly calibrationUnit: "Calibration unit";
|
|
1425
|
+
readonly calibrateMeasurement: "Calibrate";
|
|
1426
|
+
readonly measurementCalibrationHint: "Pick two distance points, enter their known length, then calibrate.";
|
|
1427
|
+
readonly measurementCalibratedScale: "Calibrated: 1 model unit = {scale} m";
|
|
1428
|
+
readonly resetMeasurementCalibration: "Reset calibration";
|
|
1429
|
+
readonly showSavedMeasurement: "Show {name}";
|
|
1430
|
+
readonly renameSavedMeasurement: "Rename {name}";
|
|
1431
|
+
readonly deleteSavedMeasurement: "Delete {name}";
|
|
1432
|
+
readonly exportMeasurementJson: "Export JSON";
|
|
1433
|
+
readonly exportMeasurementCsv: "Export CSV";
|
|
1434
|
+
readonly importMeasurementJson: "Import JSON";
|
|
1435
|
+
readonly measurementReady: "Ready";
|
|
1436
|
+
readonly measurementApproximate: "Approximate LOD";
|
|
1437
|
+
readonly measurementModelChanged: "Different model";
|
|
1438
|
+
readonly measurementObjectMissing: "Object unavailable";
|
|
1439
|
+
readonly measurementGeometryChanged: "Geometry changed — measure again";
|
|
1440
|
+
readonly measurementPoseChanged: "Pose changed — measure again";
|
|
1441
|
+
readonly measurementObjectHidden: "Object hidden";
|
|
1442
|
+
readonly measurementInvalid: "Invalid measurement";
|
|
1443
|
+
readonly measurementWaiting: "Waiting for model";
|
|
1444
|
+
readonly openSceneObjectsPanel: "Open scene objects panel";
|
|
1445
|
+
readonly sceneObjects: "Scene Objects";
|
|
1446
|
+
readonly searchNodesLabels: "Search nodes, labels";
|
|
1447
|
+
readonly closeSceneObjectsPanel: "Close scene objects panel";
|
|
1448
|
+
readonly objectNavigator: "Objects in the 3D view";
|
|
1449
|
+
readonly compareBefore: "Before";
|
|
1450
|
+
readonly compareAfter: "After";
|
|
1451
|
+
readonly compareDivider: "Comparison divider";
|
|
1452
|
+
readonly viewIn3D: "View in 3D";
|
|
1453
|
+
readonly objectNavigatorHint: "Arrow keys browse · Enter selects · Esc clears";
|
|
1454
|
+
readonly selectionCleared: "Selection cleared";
|
|
1455
|
+
readonly cameraKeyboardHelp: "3D view. Arrow keys orbit, Shift with Up or Down zooms, and W, A, S, D, Space and C move the camera.";
|
|
1456
|
+
readonly isolate: "Isolate";
|
|
1457
|
+
readonly hide: "Hide";
|
|
1458
|
+
readonly show: "Show";
|
|
1459
|
+
readonly closePanel: "Close panel";
|
|
1460
|
+
readonly actions: "Actions";
|
|
1461
|
+
readonly openPanel: "Open panel";
|
|
1462
|
+
readonly close: "Close";
|
|
1463
|
+
readonly position: "Position";
|
|
1464
|
+
readonly decalNudgeHint: "Click to fine-tune · Hold to move";
|
|
1465
|
+
readonly decalNudgeControls: "Move decal in small steps";
|
|
1466
|
+
readonly text: "Text";
|
|
1467
|
+
readonly yourText: "Your text";
|
|
1468
|
+
readonly textToAdd: "Text to add";
|
|
1469
|
+
readonly textColour: "Text color";
|
|
1470
|
+
readonly addText: "Add text";
|
|
1471
|
+
readonly image: "Image";
|
|
1472
|
+
readonly chooseImage: "Choose image";
|
|
1473
|
+
readonly imageToAdd: "Image to add";
|
|
1474
|
+
readonly added: "Added";
|
|
1475
|
+
readonly colour: "Color";
|
|
1476
|
+
readonly size: "Size";
|
|
1477
|
+
readonly turn: "Turn";
|
|
1478
|
+
readonly rotation: "Rotation";
|
|
1479
|
+
readonly dragTheDecalAcrossTheObjectsSurface: "Drag the decal across the object's surface";
|
|
1480
|
+
readonly move: "Move";
|
|
1481
|
+
readonly remove: "Remove";
|
|
1482
|
+
readonly noneAddedYet: "None added yet";
|
|
1483
|
+
readonly done: "Done";
|
|
1484
|
+
readonly moveForward: "Move forward";
|
|
1485
|
+
readonly moveLeft: "Move left";
|
|
1486
|
+
readonly moveRight: "Move right";
|
|
1487
|
+
readonly moveBackward: "Move backward";
|
|
1488
|
+
readonly productOptions: "Options";
|
|
1489
|
+
readonly productOptionsFor: "{product} options";
|
|
1490
|
+
readonly productReset: "Reset";
|
|
1491
|
+
readonly productOptional: "optional";
|
|
1492
|
+
readonly productNone: "None";
|
|
1493
|
+
readonly productAlsoChanges: "Also changes: {changes}";
|
|
1494
|
+
readonly productUnavailable: "Currently unavailable.";
|
|
1495
|
+
readonly productQuantity: "Quantity";
|
|
1496
|
+
readonly productCheckingPrice: "Checking price and availability…";
|
|
1497
|
+
readonly productTotal: "Total";
|
|
1498
|
+
readonly productAddToCart: "Add to cart";
|
|
1499
|
+
readonly productAddingToCart: "Adding…";
|
|
1500
|
+
readonly productRequestQuote: "Request quote";
|
|
1501
|
+
readonly productRequestingQuote: "Requesting…";
|
|
1502
|
+
readonly productRefresh: "Refresh";
|
|
1503
|
+
readonly productBuy: "Buy now";
|
|
1504
|
+
readonly productCopyLink: "Copy link";
|
|
1505
|
+
readonly productLinkCopied: "Link copied";
|
|
1506
|
+
readonly productShowOptions: "Show options";
|
|
1507
|
+
readonly productHideOptions: "Hide options";
|
|
1508
|
+
readonly productIssues: "Configuration issues";
|
|
1509
|
+
readonly productRequestDone: "Request completed.";
|
|
1510
|
+
readonly productSaved: "Saved: {id}";
|
|
1511
|
+
readonly sceneSettings: "Scene Settings";
|
|
1512
|
+
readonly background: "Background";
|
|
1513
|
+
readonly backgroundColor: "Background Color";
|
|
1514
|
+
readonly showEnvironmentAsBackground: "Show as background";
|
|
1515
|
+
readonly backgroundBlur: "Background Blur";
|
|
1516
|
+
readonly environmentPreset: "Preset";
|
|
1517
|
+
readonly environmentIntensity: "Intensity";
|
|
1518
|
+
readonly toneMapping: "Tone Mapping";
|
|
1519
|
+
readonly toneMappingAces: "ACES Filmic";
|
|
1520
|
+
readonly toneMappingAgx: "AgX";
|
|
1521
|
+
readonly toneMappingNeutral: "Neutral";
|
|
1522
|
+
readonly toneMappingNone: "None";
|
|
1523
|
+
readonly ground: "Ground";
|
|
1524
|
+
readonly groundShadow: "Ground Shadow";
|
|
1525
|
+
readonly groundShadowOpacity: "Shadow Opacity";
|
|
1526
|
+
readonly floorGrid: "Floor Grid";
|
|
1527
|
+
readonly display: "Display";
|
|
1528
|
+
readonly wireframe: "Wireframe";
|
|
1529
|
+
readonly autoRotateSpeed: "Rotation Speed";
|
|
1530
|
+
readonly fieldOfView: "Field of View";
|
|
1531
|
+
readonly modelInfo: "Model";
|
|
1532
|
+
readonly modelInfoObjects: "Objects";
|
|
1533
|
+
readonly modelInfoTriangles: "Triangles";
|
|
1534
|
+
readonly modelInfoMaterials: "Materials";
|
|
1535
|
+
readonly resetSettings: "Reset Settings";
|
|
1536
|
+
readonly environment: "Environment";
|
|
1537
|
+
readonly autoRotate: "Auto Rotate";
|
|
1538
|
+
readonly lighting: "Lighting";
|
|
1539
|
+
readonly exposure: "Exposure";
|
|
1540
|
+
readonly ambientLightIntensity: "Ambient Light Intensity";
|
|
1541
|
+
readonly ambientLightColor: "Ambient Light Color";
|
|
1542
|
+
readonly directLightIntensity: "Direct Light Intensity";
|
|
1543
|
+
readonly directLightColor: "Direct Light Color";
|
|
1544
|
+
readonly searchObjects: "Search objects";
|
|
1545
|
+
readonly uploadedModel: "Uploaded model";
|
|
1546
|
+
readonly clear: "Clear";
|
|
1547
|
+
readonly chooseModel: "Choose model";
|
|
1548
|
+
readonly loadingModel: "Loading model...";
|
|
1549
|
+
readonly releaseToLoadYourModel: "Release to load your model";
|
|
1550
|
+
readonly arFindSurface: "Move your device over a flat surface";
|
|
1551
|
+
readonly arReleaseToPlace: "Release to place";
|
|
1552
|
+
readonly arGestureHint: "Pinch to resize · Twist to rotate";
|
|
1553
|
+
readonly angleFirstArmHint: "Pick the first arm";
|
|
1554
|
+
readonly angleVertexHint: "Pick the angle's vertex";
|
|
1555
|
+
readonly angleSecondArmHint: "Pick the second arm";
|
|
1556
|
+
readonly angleNewHint: "Pick a point to start a new angle";
|
|
1557
|
+
readonly areaNewHint: "Pick a point to start a new area";
|
|
1558
|
+
readonly areaCornersHint: "Pick polygon corners in order, then Finish area";
|
|
1559
|
+
readonly pointToPlaneFaceHint: "Pick the reference face";
|
|
1560
|
+
readonly pointToPlanePointHint: "Pick a point to measure its perpendicular distance";
|
|
1561
|
+
readonly pointToPlaneNewHint: "Pick a face to start a new measurement";
|
|
1562
|
+
readonly distanceHint: "Pick points on the model to measure distances";
|
|
1563
|
+
readonly wrapHint: "Click a point on the surface to measure its circumference, following the surface (best for limbs)";
|
|
1564
|
+
readonly wrapHorizontalHint: "Click a point to measure a level circumference around it (best for the torso/waist)";
|
|
1565
|
+
readonly visibleEntries: "{count} visible entries";
|
|
1566
|
+
readonly objectCount: "{count} objects";
|
|
1567
|
+
readonly annotationMarker: "Annotation {id}: {title}";
|
|
1568
|
+
readonly recordingVideo: "Recording video · {progress}%";
|
|
1569
|
+
readonly isolatedObjects: "Isolated: {count} objects";
|
|
1570
|
+
readonly largeModelWarning: "Very large model ({millions}M triangles) — it may render and move slowly on this device, and click/hover selection on the model is disabled. Use the objects panel to select parts.";
|
|
1571
|
+
readonly preparingLargeModel: "Preparing large model ({millions}M triangles) — the first display can take a while on this device...";
|
|
1572
|
+
readonly enterAR: "Enter AR";
|
|
1573
|
+
readonly enterVR: "Enter VR";
|
|
1574
|
+
readonly decalImage: "Image {index}";
|
|
1575
|
+
readonly decalText: "Text {index}";
|
|
1576
|
+
readonly decalAdded: "{count} added";
|
|
1577
|
+
readonly up: "up";
|
|
1578
|
+
readonly down: "down";
|
|
1579
|
+
readonly left: "left";
|
|
1580
|
+
readonly right: "right";
|
|
1581
|
+
readonly moveDecal: "Move decal {direction}";
|
|
1582
|
+
readonly moveDecalOnSurface: "Move {direction} on the visible surface";
|
|
1583
|
+
readonly showAllObject: "Show all {name}";
|
|
1584
|
+
readonly isolateObject: "Isolate {name}";
|
|
1585
|
+
readonly isolatedObject: "Isolated: {name}";
|
|
1586
|
+
readonly hideObject: "Hide {name}";
|
|
1587
|
+
readonly showObject: "Show {name}";
|
|
1588
|
+
readonly objectSelected: "{name} selected";
|
|
1589
|
+
readonly objectNavigatorPosition: "{position} of {count}";
|
|
1590
|
+
readonly compareDividerValue: "{before} {percent}%, {after} {rest}%";
|
|
1591
|
+
readonly bindingMismatchOne: "1 object binding doesn't match this model";
|
|
1592
|
+
readonly bindingMismatchMany: "{count} object bindings don't match this model";
|
|
1593
|
+
readonly simpleLargeModelWarning: "Very large model detected ({millions}M triangles) — it may render and move slowly on this device, and click/hover selection on the model is disabled. Use the scene objects panel to select parts.";
|
|
1594
|
+
readonly dropModelHint: "Drag and drop {formats} here";
|
|
1595
|
+
readonly retryModelLoad: "Retry loading model";
|
|
1596
|
+
readonly loadErrorTitle: "This model couldn't be loaded";
|
|
1597
|
+
readonly loadErrorNotFound: "Nothing was found at this address ({status}). Check that modelUrl points to the file.";
|
|
1598
|
+
readonly loadErrorDenied: "The server refused access to the file ({status}). Check that the file is public, or that a signed URL hasn't expired.";
|
|
1599
|
+
readonly loadErrorStatus: "The server responded with {status} when the file was requested.";
|
|
1600
|
+
readonly loadErrorNetwork: "The download was blocked or failed. Check that the URL is correct and, if the file is on another domain, that its server allows cross-origin requests (CORS) from this site.";
|
|
1601
|
+
readonly loadErrorHtml: "The server sent back a web page instead of a model. There's probably no file at this path: many servers answer a missing file with their index.html.";
|
|
1602
|
+
readonly loadErrorInvalidFile: "The file couldn't be read as {format}. Check that it's a valid {format} file.";
|
|
1603
|
+
readonly loadErrorInvalidExplicitFormat: "The file couldn't be read as {format}. Check that it's a valid {format} file and that modelFormat matches it.";
|
|
1604
|
+
readonly loadErrorMissingFormat: "The file couldn't be read as {format}. The URL has no file extension, so set modelFormat to the file's format.";
|
|
1605
|
+
readonly loadErrorPointCloud: "This PLY file is a point cloud: it has points but no faces, and the viewer shows meshes. Turn it into a mesh first, for example with MeshLab or Blender.";
|
|
1606
|
+
readonly measurementReferenceFaceRequired: "Pick a triangle face to define the reference plane.";
|
|
1607
|
+
readonly measurementTooManyPoints: "Finish or clear this measurement before adding more points.";
|
|
1608
|
+
readonly measurementAngleDistinct: "Pick a point away from the angle's vertex.";
|
|
1609
|
+
readonly areaMinimumPoints: "Pick at least three points to finish the area.";
|
|
1610
|
+
readonly areaDistinctPoints: "Area points must be distinct.";
|
|
1611
|
+
readonly areaStraightLine: "Area points must not lie on one straight line.";
|
|
1612
|
+
readonly areaNotPlanar: "Area points must lie on one plane.";
|
|
1613
|
+
readonly areaEdgesCross: "Area edges must not cross or touch each other.";
|
|
1614
|
+
readonly areaZero: "The polygon has no measurable area.";
|
|
1615
|
+
readonly decalSurfaceMissing: "Could not find a surface on this object for the decal.";
|
|
1616
|
+
readonly decalDirectionMissing: "No visible surface in that direction. Try another arrow or rotate the view.";
|
|
1617
|
+
readonly fullscreenExitFailed: "Could not exit fullscreen. Press Escape to exit.";
|
|
1618
|
+
readonly fullscreenEnterFailed: "Could not enter fullscreen. Check your browser or iframe fullscreen permissions and try again.";
|
|
1619
|
+
readonly uvCoordinatesMissing: "This model does not contain UV coordinates.";
|
|
1620
|
+
readonly uvExportFailed: "Could not create the UV layout archive.";
|
|
1621
|
+
readonly videoExportFailed: "Could not export the video.";
|
|
1622
|
+
readonly videoNotReady: "Viewer not ready for video export.";
|
|
1623
|
+
readonly videoExitXR: "Exit the XR session before recording a video.";
|
|
1624
|
+
readonly videoAlreadyRecording: "A video export is already in progress.";
|
|
1625
|
+
readonly videoPathRequired: "Enable a cinematic camera path before recording it.";
|
|
1626
|
+
readonly videoDurationInvalid: "Video duration must be greater than 0 and at most 300 seconds.";
|
|
1627
|
+
readonly videoFrameRateInvalid: "Video frame rate must be between 1 and 60.";
|
|
1628
|
+
readonly videoBitrateInvalid: "Video bitrate must be a positive number.";
|
|
1629
|
+
readonly videoContextLost: "Video export stopped because the WebGL context was lost.";
|
|
1630
|
+
readonly videoTimedOut: "Video export timed out. Keep the viewer tab visible while recording.";
|
|
1631
|
+
readonly videoEncodingFailed: "The browser could not encode the video.";
|
|
1632
|
+
readonly videoEmpty: "The browser produced an empty video.";
|
|
1633
|
+
readonly videoDidNotStart: "Video recording did not start.";
|
|
1634
|
+
readonly videoWebMUnsupported: "Video recording as WEBM is not supported in this browser.";
|
|
1635
|
+
readonly videoMP4Unsupported: "Video recording as MP4 is not supported in this browser.";
|
|
1636
|
+
readonly videoGIFUnsupported: "Video recording as GIF is not supported in this browser.";
|
|
1637
|
+
readonly videoGifWidthInvalid: "GIF width must be a whole number of pixels from 16 to 4096.";
|
|
1638
|
+
readonly environmentNeutral: "neutral";
|
|
1639
|
+
readonly environmentApartment: "apartment";
|
|
1640
|
+
readonly environmentCity: "city";
|
|
1641
|
+
readonly environmentDawn: "dawn";
|
|
1642
|
+
readonly environmentForest: "forest";
|
|
1643
|
+
readonly environmentLobby: "lobby";
|
|
1644
|
+
readonly environmentNight: "night";
|
|
1645
|
+
readonly environmentPark: "park";
|
|
1646
|
+
readonly environmentStudio: "studio";
|
|
1647
|
+
readonly environmentSunset: "sunset";
|
|
1648
|
+
readonly environmentWarehouse: "warehouse";
|
|
1649
|
+
readonly color: "Color";
|
|
1650
|
+
readonly material: "Material";
|
|
1651
|
+
readonly texturePreview: "texture preview";
|
|
1652
|
+
readonly noTextureApplied: "No texture applied";
|
|
1653
|
+
readonly noTextureCoordinates: "This part has no texture coordinates, so an image can't be placed on it.";
|
|
1654
|
+
readonly replaceImage: "Replace image";
|
|
1655
|
+
readonly uploadImage: "Upload image";
|
|
1656
|
+
readonly removeTexture: "Remove texture";
|
|
1657
|
+
readonly texturePosition: "Texture position";
|
|
1658
|
+
readonly offsetX: "Offset X";
|
|
1659
|
+
readonly offsetY: "Offset Y";
|
|
1660
|
+
readonly confirmTexturePosition: "Confirm this texture position and exit positioning mode";
|
|
1661
|
+
readonly donePositioning: "Done positioning";
|
|
1662
|
+
readonly textureOffsetHint: "Double-click the object in the preview to drag its texture directly (scroll to zoom), or edit its offset numerically.";
|
|
1663
|
+
readonly actionToggleLight: "Toggle Light";
|
|
1664
|
+
readonly actionChangeLightColor: "Change Light Color";
|
|
1665
|
+
readonly actionSetBrightness: "Set Brightness";
|
|
1666
|
+
readonly actionChangeColor: "Change Color";
|
|
1667
|
+
readonly actionChangeMaterial: "Change Material";
|
|
1668
|
+
readonly actionToggleVisibility: "Toggle Visibility";
|
|
1669
|
+
};
|
|
1670
|
+
type ModelViewerLabelKey = keyof typeof DEFAULT_MODEL_VIEWER_LABELS;
|
|
1671
|
+
/** Plain-text overrides; dynamic labels use named {placeholders}. */
|
|
1672
|
+
type ModelViewerLabels = Partial<Record<ModelViewerLabelKey, string>>;
|
|
1673
|
+
|
|
1674
|
+
/**
|
|
1675
|
+
* When a viewer starts its 3D view on its own. `"lazy"` waits until it's on
|
|
1676
|
+
* or near the screen and shares the page's live 3D views with the other lazy
|
|
1677
|
+
* viewers, so a page of viewers stays within the browser's limit. `"eager"`
|
|
1678
|
+
* starts at once and keeps its view.
|
|
1679
|
+
*/
|
|
1680
|
+
type ViewerLoading = "lazy" | "eager";
|
|
1681
|
+
/**
|
|
1682
|
+
* Whether the 3D view starts on its own (`"auto"`) or waits on the poster
|
|
1683
|
+
* until the visitor asks for it with a "View in 3D" button (`"interaction"`).
|
|
1684
|
+
*/
|
|
1685
|
+
type ViewerReveal = "auto" | "interaction";
|
|
1534
1686
|
|
|
1535
1687
|
type CameraLimits = {
|
|
1536
1688
|
/** Closest the camera can get to its target, in scene units. Default 0. */
|
|
@@ -1560,601 +1712,13 @@ type CameraLimits = {
|
|
|
1560
1712
|
boundaryFriction?: number;
|
|
1561
1713
|
};
|
|
1562
1714
|
|
|
1563
|
-
type MouseControllerPosition = 'bottom-left' | 'bottom-right' | 'top-left' | 'top-right' | 'center' | 'center-bottom' | 'center-top';
|
|
1564
|
-
|
|
1565
|
-
type XRScaleMode = "normalized" | "real-world";
|
|
1566
|
-
|
|
1567
|
-
/** A starting set of ModelViewer props for a common kind of page. */
|
|
1568
|
-
type ModelViewerPreset = "minimal" | "showcase" | "configurator" | "inspector";
|
|
1569
|
-
type ModelViewerUiOptions = {
|
|
1570
|
-
/** The left panel for the selected object. Default `true`. */
|
|
1571
|
-
objectPanel?: boolean;
|
|
1572
|
-
/** The right panel listing the model's objects. Default `true`. */
|
|
1573
|
-
sceneObjects?: boolean;
|
|
1574
|
-
/** The download button; a string also sets the file name. Default `true`. */
|
|
1575
|
-
download?: boolean | string;
|
|
1576
|
-
/** The reset-view button. Default `true`. */
|
|
1577
|
-
reset?: boolean;
|
|
1578
|
-
/** The viewer fullscreen toggle in the action bar. Default `false`. */
|
|
1579
|
-
fullscreen?: boolean;
|
|
1580
|
-
/** The loading overlay and load-error message. Default `true`. */
|
|
1581
|
-
loadingOverlay?: boolean;
|
|
1582
|
-
/** The axis gizmo in the top-right corner. Default `false`. */
|
|
1583
|
-
viewGizmo?: boolean;
|
|
1584
|
-
/** The on-screen movement pad; an object also places it. Default `false`. */
|
|
1585
|
-
mouseController?: boolean | {
|
|
1586
|
-
position?: MouseControllerPosition;
|
|
1587
|
-
opacity?: number;
|
|
1588
|
-
};
|
|
1589
|
-
/** Previous/Stop/Next controls for annotation tours. Default `true`. */
|
|
1590
|
-
annotationNavigation?: boolean;
|
|
1591
|
-
/** Show an annotation's details when its marker is hovered. Default `false`. */
|
|
1592
|
-
annotationOnHover?: boolean;
|
|
1593
|
-
/** Category filter chips. Default `true` when annotations have categories. */
|
|
1594
|
-
annotationFilters?: boolean;
|
|
1595
|
-
/** Highlight objects under the pointer. Default `true`. */
|
|
1596
|
-
highlightOnHover?: boolean;
|
|
1597
|
-
/** Swatch rows for the model's glTF material variants, one per option group. Default `true`. */
|
|
1598
|
-
materialVariants?: boolean;
|
|
1599
|
-
/**
|
|
1600
|
-
* A tab stop for moving through and selecting objects with the keyboard,
|
|
1601
|
-
* shown only while it has focus. Default `true`.
|
|
1602
|
-
*/
|
|
1603
|
-
objectNavigator?: boolean;
|
|
1604
|
-
};
|
|
1605
1715
|
/**
|
|
1606
|
-
*
|
|
1607
|
-
*
|
|
1716
|
+
* Whether the viewer cuts motion that starts on its own: `"user"` follows the
|
|
1717
|
+
* visitor's `prefers-reduced-motion` setting, `"always"` and `"never"` override
|
|
1718
|
+
* it.
|
|
1608
1719
|
*/
|
|
1609
|
-
type
|
|
1610
|
-
/** Shown in the Offset fields instead of the binding's offset. */
|
|
1611
|
-
offset?: [number, number];
|
|
1612
|
-
/** Shown in the Rotation field instead of the binding's, in degrees (0–360). */
|
|
1613
|
-
rotationDegrees?: number;
|
|
1614
|
-
/** Replaces the viewer's write when an Offset field changes. */
|
|
1615
|
-
onOffsetChange?: (objectId: string, axisIndex: 0 | 1, value: number) => void;
|
|
1616
|
-
/** Replaces the viewer's write when the Rotation field changes. */
|
|
1617
|
-
onRotationChange?: (objectId: string, degrees: number) => void;
|
|
1618
|
-
/** Whether to show "Done positioning" rather than the hint. */
|
|
1619
|
-
isPositioning?: boolean;
|
|
1620
|
-
/** Called after "Done positioning" ends Move/Zoom mode. */
|
|
1621
|
-
onEndPositioning?: () => void;
|
|
1622
|
-
};
|
|
1623
|
-
type ModelViewerToolsOptions = {
|
|
1624
|
-
/** Distance and dimension tools; an object also sets the unit. Default `false`. */
|
|
1625
|
-
measure?: boolean | {
|
|
1626
|
-
unit?: string;
|
|
1627
|
-
};
|
|
1628
|
-
/** The UV checker toggle. Default `false`. */
|
|
1629
|
-
uvChecker?: boolean;
|
|
1630
|
-
/** The exploded-view slider. Default `false`. */
|
|
1631
|
-
explode?: boolean;
|
|
1632
|
-
/** The section-cut tool, to cut the model open along an axis. Default `false`. */
|
|
1633
|
-
section?: boolean;
|
|
1634
|
-
/** A compact player for authored scene sequences. Default true. */
|
|
1635
|
-
sequences?: boolean;
|
|
1636
|
-
/** Isolate buttons in the scene objects panel, and a "Show all" pill. Default `false`. */
|
|
1637
|
-
isolate?: boolean;
|
|
1638
|
-
/** Texture offset, rotation and Move/Zoom for textured objects. Default `false`. */
|
|
1639
|
-
texturePositioning?: boolean | TexturePositioningControls;
|
|
1640
|
-
};
|
|
1641
|
-
type ModelViewerControlsOptions = {
|
|
1642
|
-
/** Orbit, pan and zoom with the pointer. Default `true`. */
|
|
1643
|
-
enabled?: boolean;
|
|
1644
|
-
/** Move the camera with the keyboard while the canvas has focus. Default `false`. */
|
|
1645
|
-
keyboard?: boolean;
|
|
1646
|
-
/**
|
|
1647
|
-
* Cut motion the viewer starts on its own (auto-rotate, cinematic autoplay,
|
|
1648
|
-
* camera glides). `"user"` follows the visitor's reduced-motion setting.
|
|
1649
|
-
* Default `"user"`.
|
|
1650
|
-
*/
|
|
1651
|
-
reducedMotion?: ReducedMotionSetting;
|
|
1652
|
-
/** Allow zooming. Default `true`. */
|
|
1653
|
-
zoom?: boolean;
|
|
1654
|
-
/** Zoom to an object when it's selected. Default `true`. */
|
|
1655
|
-
zoomOnSelect?: boolean;
|
|
1656
|
-
/** Turn the model slowly; a number sets the speed (1 is normal). Default `false`. */
|
|
1657
|
-
autoRotate?: boolean | number;
|
|
1658
|
-
/** Re-frame the model, or the selected object it zoomed to, when the viewer is resized. Default `true`. */
|
|
1659
|
-
refitOnResize?: boolean;
|
|
1660
|
-
/** Distance, angle and pan limits for the camera. */
|
|
1661
|
-
limits?: CameraLimits;
|
|
1662
|
-
/** Movement pad speed. Default `0.08`. */
|
|
1663
|
-
moveSensitivity?: number;
|
|
1664
|
-
/** Movement pad zoom speed. Default `1`. */
|
|
1665
|
-
zoomSensitivity?: number;
|
|
1666
|
-
};
|
|
1667
|
-
type ModelViewerPerfOptions = {
|
|
1668
|
-
/** `"demand"` draws only when something changes. Default `"demand"`. */
|
|
1669
|
-
renderMode?: "always" | "demand";
|
|
1670
|
-
/** Highest device pixel ratio to render at. Default `2`. */
|
|
1671
|
-
maxDpr?: number;
|
|
1672
|
-
/** `"low"` trades quality for speed on weak devices. Default `"auto"`. */
|
|
1673
|
-
profile?: PerformanceProfile;
|
|
1674
|
-
/** Needed for Download PNG and captureImage; costs GPU time. Default `false`. */
|
|
1675
|
-
preserveDrawingBuffer?: boolean;
|
|
1676
|
-
/**
|
|
1677
|
-
* Draw with three's WebGPU renderer where the browser has WebGPU, WebGL
|
|
1678
|
-
* elsewhere. Leaves out post-processing effects, contact shadows and WebXR.
|
|
1679
|
-
* Default `false`.
|
|
1680
|
-
*/
|
|
1681
|
-
webgpu?: boolean;
|
|
1682
|
-
};
|
|
1683
|
-
type ModelViewerTilesOptions = {
|
|
1684
|
-
/** A 3D Tiles `tileset.json` to stream instead of loading `modelUrl` whole. */
|
|
1685
|
-
url?: string | null;
|
|
1686
|
-
/** Screen-space error target; lower is sharper. Default `8`. */
|
|
1687
|
-
errorTarget?: number;
|
|
1688
|
-
/** Most parsed tiles kept in memory. Default `800`. */
|
|
1689
|
-
cacheSize?: number;
|
|
1690
|
-
};
|
|
1691
|
-
type ModelViewerXrOptions = {
|
|
1692
|
-
/** "View in your space" (AR) and "Enter VR". Default `false`. */
|
|
1693
|
-
enabled?: boolean;
|
|
1694
|
-
/** A USDZ file for iOS AR Quick Look. */
|
|
1695
|
-
usdzUrl?: string;
|
|
1696
|
-
/** How the model is sized in AR. Default `"normalized"`. */
|
|
1697
|
-
scaleMode?: XRScaleMode;
|
|
1698
|
-
/** The page the desktop QR code opens on a phone. Default: the current page. */
|
|
1699
|
-
mobileHandoffUrl?: string;
|
|
1700
|
-
/** Prepare the edited configuration for USDZ and phone handoff. Opt-in. */
|
|
1701
|
-
arHandoff?: boolean | ARHandoffOptions;
|
|
1702
|
-
};
|
|
1703
|
-
type ModelViewerDecoderOptions = {
|
|
1704
|
-
/** Directory of the DRACO decoder files, or `false`. */
|
|
1705
|
-
draco?: string | false;
|
|
1706
|
-
/** Directory of the Basis/KTX2 transcoder files, or `false`. */
|
|
1707
|
-
ktx2?: string | false;
|
|
1708
|
-
/** Enable the bundled Meshopt decoder. Default `true`. */
|
|
1709
|
-
meshopt?: boolean;
|
|
1710
|
-
};
|
|
1711
|
-
type GroupedModelViewerProps = {
|
|
1712
|
-
/**
|
|
1713
|
-
* A starting set of props for a common kind of page. Anything else you pass
|
|
1714
|
-
* overrides it.
|
|
1715
|
-
*/
|
|
1716
|
-
preset?: ModelViewerPreset;
|
|
1717
|
-
ui?: ModelViewerUiOptions;
|
|
1718
|
-
tools?: ModelViewerToolsOptions;
|
|
1719
|
-
controls?: ModelViewerControlsOptions;
|
|
1720
|
-
perf?: ModelViewerPerfOptions;
|
|
1721
|
-
tiles?: ModelViewerTilesOptions;
|
|
1722
|
-
xr?: ModelViewerXrOptions;
|
|
1723
|
-
decoders?: ModelViewerDecoderOptions;
|
|
1724
|
-
};
|
|
1725
|
-
/** What each preset sets. Props that aren't listed keep their defaults. */
|
|
1726
|
-
declare const MODEL_VIEWER_PRESETS: Readonly<Record<ModelViewerPreset, Readonly<Partial<ModelViewerProps>>>>;
|
|
1727
|
-
|
|
1728
|
-
type DecalMoveTarget = {
|
|
1729
|
-
objectId: string;
|
|
1730
|
-
decal: ObjectBindingDecal;
|
|
1731
|
-
onCommit: (surface: ObjectSurfacePoint) => void;
|
|
1732
|
-
onCancel: () => void;
|
|
1733
|
-
};
|
|
1734
|
-
|
|
1735
|
-
type CameraControllerType = "orbit" | "pointerLock";
|
|
1736
|
-
|
|
1737
|
-
/** One bindable object in a model, as reported by `onObjectCatalog`. */
|
|
1738
|
-
type ViewerObjectInfo = {
|
|
1739
|
-
/** The node identifier bindings are keyed by. */
|
|
1740
|
-
name: string;
|
|
1741
|
-
triangles: number;
|
|
1742
|
-
/**
|
|
1743
|
-
* Axis-aligned bounds in the model's own units, in Z-up coordinates (the 3D
|
|
1744
|
-
* Tiles convention): a glTF point (x, y, z) is (x, -z, y) here.
|
|
1745
|
-
*/
|
|
1746
|
-
minimum: [number, number, number];
|
|
1747
|
-
maximum: [number, number, number];
|
|
1748
|
-
};
|
|
1720
|
+
type ReducedMotionSetting = "user" | "always" | "never";
|
|
1749
1721
|
|
|
1750
|
-
type
|
|
1751
|
-
position: [number, number, number];
|
|
1752
|
-
target: [number, number, number];
|
|
1753
|
-
/**
|
|
1754
|
-
* Orbit angles in radians, as BindingBuilder captures them: position and
|
|
1755
|
-
* target alone can't represent the rotation straight above or below the
|
|
1756
|
-
* target. Leave them out when writing waypoints by hand.
|
|
1757
|
-
*/
|
|
1758
|
-
azimuthAngle?: number;
|
|
1759
|
-
polarAngle?: number;
|
|
1760
|
-
segmentDuration?: number;
|
|
1761
|
-
};
|
|
1762
|
-
type CinematicConfig = {
|
|
1763
|
-
waypoints?: CinematicWaypoint[];
|
|
1764
|
-
duration?: number;
|
|
1765
|
-
loop?: boolean;
|
|
1766
|
-
autoPlay?: boolean;
|
|
1767
|
-
};
|
|
1768
|
-
|
|
1769
|
-
/** Which three.js renderer draws a viewer. */
|
|
1770
|
-
type RendererBackend = "webgl" | "webgpu";
|
|
1771
|
-
|
|
1772
|
-
type CaptureImageOptions = {
|
|
1773
|
-
width?: number;
|
|
1774
|
-
height?: number;
|
|
1775
|
-
transparent?: boolean;
|
|
1776
|
-
type?: "image/png" | "image/jpeg";
|
|
1777
|
-
quality?: number;
|
|
1778
|
-
};
|
|
1779
|
-
|
|
1780
|
-
type CaptureVideoOptions = {
|
|
1781
|
-
/** Defaults to cinematic when a path is enabled, otherwise turntable. */
|
|
1782
|
-
mode?: "cinematic" | "turntable";
|
|
1783
|
-
/**
|
|
1784
|
-
* Auto prefers WebM, then MP4. `"gif"` makes an animated GIF that loops
|
|
1785
|
-
* forever. Explicit formats reject if unsupported.
|
|
1786
|
-
*/
|
|
1787
|
-
format?: "auto" | "webm" | "mp4" | "gif";
|
|
1788
|
-
/**
|
|
1789
|
-
* Seconds per pass, in (0, 300]. Defaults to path timing, or an orbit of
|
|
1790
|
-
* 24s (8s for a GIF).
|
|
1791
|
-
*/
|
|
1792
|
-
duration?: number;
|
|
1793
|
-
/** Capture frame rate, from 1 to 60. Default 30 (15 for a GIF). */
|
|
1794
|
-
fps?: number;
|
|
1795
|
-
/** Encoder target bitrate in bits per second. Default 8,000,000. Not used for GIFs. */
|
|
1796
|
-
videoBitsPerSecond?: number;
|
|
1797
|
-
/**
|
|
1798
|
-
* GIF width in pixels, from 16 to 4096; the height follows the canvas. Never
|
|
1799
|
-
* wider than the canvas. Default 480.
|
|
1800
|
-
*/
|
|
1801
|
-
gifWidth?: number;
|
|
1802
|
-
/** Aborting discards the recording and restores the viewer. */
|
|
1803
|
-
signal?: AbortSignal;
|
|
1804
|
-
};
|
|
1805
|
-
|
|
1806
|
-
type ViewerCameraPreset = {
|
|
1807
|
-
position: [number, number, number];
|
|
1808
|
-
target: [number, number, number];
|
|
1809
|
-
fov?: number | null;
|
|
1810
|
-
zoom?: number;
|
|
1811
|
-
azimuthAngle?: number;
|
|
1812
|
-
polarAngle?: number;
|
|
1813
|
-
};
|
|
1814
|
-
type UseViewerCameraOptions = {
|
|
1815
|
-
/** Camera position applied once when each model becomes ready. */
|
|
1816
|
-
initialPosition?: [number, number, number];
|
|
1817
|
-
/** Orbit target applied once when each model becomes ready. */
|
|
1818
|
-
initialTarget?: [number, number, number];
|
|
1819
|
-
/** Whether the initial position/target should animate. Defaults to false. */
|
|
1820
|
-
initialTransition?: boolean;
|
|
1821
|
-
/** Named views that can be opened with goToPreset. */
|
|
1822
|
-
presets?: Record<string, ViewerCameraPreset>;
|
|
1823
|
-
};
|
|
1824
|
-
type HomeCameraState = {
|
|
1825
|
-
position: [number, number, number];
|
|
1826
|
-
target: [number, number, number];
|
|
1827
|
-
};
|
|
1828
|
-
type ViewerReadyState = {
|
|
1829
|
-
objectBindings: Record<string, ObjectBinding>;
|
|
1830
|
-
homeCameraState: HomeCameraState | null;
|
|
1831
|
-
captureImage: (options?: CaptureImageOptions) => Promise<string>;
|
|
1832
|
-
/** Whether a streamed model is still fetching tiles for the current view. */
|
|
1833
|
-
isLoadingTiles: () => boolean;
|
|
1834
|
-
/** Records one cinematic pass or turntable revolution as a video Blob. */
|
|
1835
|
-
captureVideo: (options?: CaptureVideoOptions) => Promise<Blob>;
|
|
1836
|
-
invalidate: () => void;
|
|
1837
|
-
/**
|
|
1838
|
-
* The renderer drawing the viewer: "webgpu" only when ModelViewer's
|
|
1839
|
-
* `webgpu` asked for it and the browser has WebGPU.
|
|
1840
|
-
*/
|
|
1841
|
-
rendererBackend: RendererBackend;
|
|
1842
|
-
/**
|
|
1843
|
-
* The live three.js scene, camera-controls instance, and model nodes, for
|
|
1844
|
-
* integrations the rest of the API doesn't cover. Their shapes are those
|
|
1845
|
-
* libraries' own and can change with them.
|
|
1846
|
-
*/
|
|
1847
|
-
raw: {
|
|
1848
|
-
controls: CameraControls;
|
|
1849
|
-
scene: Object3D | null;
|
|
1850
|
-
/** Model nodes by binding key and node name. */
|
|
1851
|
-
nodes: Record<string, Object3D>;
|
|
1852
|
-
};
|
|
1853
|
-
};
|
|
1854
|
-
type ViewerCameraProps = {
|
|
1855
|
-
cameraState: ViewerCameraState | null;
|
|
1856
|
-
cameraPresets: Record<string, ViewerCameraPreset>;
|
|
1857
|
-
resetView: () => Promise<boolean>;
|
|
1858
|
-
focusObject: (objectId: string) => Promise<boolean>;
|
|
1859
|
-
fitScene: () => Promise<boolean>;
|
|
1860
|
-
setCameraTarget: (target: [number, number, number], enableTransition?: boolean) => Promise<boolean>;
|
|
1861
|
-
setCameraState: (state: ViewerCameraState, enableTransition?: boolean) => Promise<boolean>;
|
|
1862
|
-
lookAt: (position: [number, number, number], target: [number, number, number], enableTransition?: boolean) => Promise<boolean>;
|
|
1863
|
-
/**
|
|
1864
|
-
* Orbits the camera around its target to the given angles, in degrees.
|
|
1865
|
-
* Azimuth is the horizontal angle (0 is the front, +Z; 90 the right, +X);
|
|
1866
|
-
* polar is the vertical angle (0 straight down, 90 level, 180 straight up).
|
|
1867
|
-
*/
|
|
1868
|
-
orbitTo: (azimuthDegrees: number, polarDegrees: number, enableTransition?: boolean) => Promise<boolean>;
|
|
1869
|
-
dollyTo: (distance: number, enableTransition?: boolean) => Promise<boolean>;
|
|
1870
|
-
savePreset: (name: string) => ViewerCameraState | null;
|
|
1871
|
-
goToPreset: (name: string, enableTransition?: boolean) => Promise<boolean>;
|
|
1872
|
-
handleCameraChange: (state: ViewerCameraState) => void;
|
|
1873
|
-
handleViewerReady: (viewer: ViewerReadyState) => void;
|
|
1874
|
-
};
|
|
1875
|
-
declare function useViewerCamera(options?: UseViewerCameraOptions): ViewerCameraProps;
|
|
1876
|
-
|
|
1877
|
-
type ObjectTransformSpace = "local" | "world";
|
|
1878
|
-
|
|
1879
|
-
type ModelMergeSource = {
|
|
1880
|
-
url: string;
|
|
1881
|
-
namePrefix: string;
|
|
1882
|
-
};
|
|
1883
|
-
|
|
1884
|
-
type AnnotationMarker = SceneAnnotationMarker & {
|
|
1885
|
-
markerId?: string;
|
|
1886
|
-
};
|
|
1887
|
-
type CustomObjectBindingDataPanelProps = {
|
|
1888
|
-
isOpen: boolean;
|
|
1889
|
-
selectedObject: ObjectBinding | null;
|
|
1890
|
-
currentAction: ObjectActionEvent | null;
|
|
1891
|
-
onClose: () => void;
|
|
1892
|
-
onAction: (event: ObjectActionEvent) => void;
|
|
1893
|
-
};
|
|
1894
|
-
type CustomSceneObjectsPanelProps = {
|
|
1895
|
-
objectBindings: Record<string, ObjectBinding>;
|
|
1896
|
-
onAction?: (event: ObjectActionEvent) => void;
|
|
1897
|
-
onFocus?: (binding: ObjectBinding) => void;
|
|
1898
|
-
onHover?: (binding: ObjectBinding | null) => void;
|
|
1899
|
-
};
|
|
1900
|
-
type ModelViewerProps = GroupedModelViewerProps & {
|
|
1901
|
-
/** Plain-text overrides for built-in UI labels. Missing keys use English. */
|
|
1902
|
-
labels?: ModelViewerLabels;
|
|
1903
|
-
modelUrl: string;
|
|
1904
|
-
/**
|
|
1905
|
-
* An image shown in the viewer's place until its 3D view is drawn: a render
|
|
1906
|
-
* or photo of the model, best framed as the viewer frames it. Fitted inside
|
|
1907
|
-
* the viewer; set the CSS variable `--ri-poster-fit: cover` to fill it.
|
|
1908
|
-
*/
|
|
1909
|
-
poster?: string;
|
|
1910
|
-
/**
|
|
1911
|
-
* `"lazy"` (default) starts the 3D view when the viewer is on or near the
|
|
1912
|
-
* screen. When the page needs room for viewers in view, one scrolled away
|
|
1913
|
-
* from goes back to a picture of itself, and comes back as it was. `"eager"`
|
|
1914
|
-
* starts at once and keeps its view.
|
|
1915
|
-
*/
|
|
1916
|
-
loading?: ViewerLoading;
|
|
1917
|
-
/**
|
|
1918
|
-
* `"interaction"` keeps the poster, with a "View in 3D" button, until the
|
|
1919
|
-
* visitor asks for the 3D view. Default `"auto"`.
|
|
1920
|
-
*/
|
|
1921
|
-
reveal?: ViewerReveal;
|
|
1922
|
-
/** Optional 3D Tiles manifest used instead of loading `modelUrl` monolithically. */
|
|
1923
|
-
tilesetUrl?: string | null;
|
|
1924
|
-
/** Screen-space error target for streamed 3D Tiles. Lower is sharper. */
|
|
1925
|
-
tilesErrorTarget?: number;
|
|
1926
|
-
/** Maximum number of parsed tiles retained by the client cache. */
|
|
1927
|
-
tilesCacheSize?: number;
|
|
1928
|
-
/**
|
|
1929
|
-
* Every bindable object in the model: each named mesh, under the identifier
|
|
1930
|
-
* bindings are keyed by. Reported each time a model loads; for a streamed
|
|
1931
|
-
* model it comes from the catalog beside `tileset.json`, before the tiles
|
|
1932
|
-
* that contain those objects have necessarily loaded.
|
|
1933
|
-
*/
|
|
1934
|
-
onObjectCatalog?: (objects: ViewerObjectInfo[]) => void;
|
|
1935
|
-
/** Explicit format for extensionless or signed model URLs. */
|
|
1936
|
-
modelFormat?: ModelFormat;
|
|
1937
|
-
licenseKey: string;
|
|
1938
|
-
hideLicenseCheckingOverlay?: boolean;
|
|
1939
|
-
/**
|
|
1940
|
-
* The model's interactive objects, keyed by node name. Defaults to `"auto"`:
|
|
1941
|
-
* a default binding for every mesh, generated when the model loads and
|
|
1942
|
-
* reported through `onObjectBindingsChange`.
|
|
1943
|
-
*/
|
|
1944
|
-
objectBindings?: Record<string, ObjectBinding> | "auto";
|
|
1945
|
-
selectedObject?: ObjectBinding | null;
|
|
1946
|
-
/** Transient bounds outlines for semantic comparison; never modify authored materials. */
|
|
1947
|
-
comparisonHighlights?: readonly ComparisonHighlight[];
|
|
1948
|
-
/**
|
|
1949
|
-
* Binding keys of several selected objects. Each is outlined in green.
|
|
1950
|
-
* While set, the single-selection (blue) outline is hidden.
|
|
1951
|
-
*/
|
|
1952
|
-
multiSelectedKeys?: readonly string[];
|
|
1953
|
-
/** Explicit nodes to outline together, overriding multiSelectedKeys. */
|
|
1954
|
-
selectedObjectRefs?: Object3D[] | null;
|
|
1955
|
-
/** Color of the multi-selection outlines. Defaults to green. */
|
|
1956
|
-
selectedObjectOutlineColor?: string;
|
|
1957
|
-
panelHoveredObject?: ObjectBinding | null;
|
|
1958
|
-
onObjectBindingsChange?: (next: Record<string, ObjectBinding>) => void;
|
|
1959
|
-
onObjectSelect?: (binding: ObjectBinding | null) => void;
|
|
1960
|
-
onObjectHover?: (binding: ObjectBinding | null) => void;
|
|
1961
|
-
/**
|
|
1962
|
-
* An object was double-clicked. Return `true` to skip the viewer's own
|
|
1963
|
-
* double-click behavior: moving the orbit point to that spot, or starting
|
|
1964
|
-
* texture positioning when that's enabled.
|
|
1965
|
-
*/
|
|
1966
|
-
onObjectDoubleClick?: (event: ObjectPointerEvent) => boolean | void;
|
|
1967
|
-
/** A decal on the model was double-clicked (the editor uses this to enable Move). */
|
|
1968
|
-
onDecalDoubleClick?: (binding: ObjectBinding, decalId: string) => void;
|
|
1969
|
-
/**
|
|
1970
|
-
* An object was right-clicked or, on touch screens, long-pressed. Use it to
|
|
1971
|
-
* open your own menu at `clientX`/`clientY`. A right-drag still pans.
|
|
1972
|
-
*/
|
|
1973
|
-
onObjectContextMenu?: (event: ObjectPointerEvent) => void;
|
|
1974
|
-
/** Editor preview: grab this decal and drag it over its object's surface. */
|
|
1975
|
-
decalMove?: DecalMoveTarget | null;
|
|
1976
|
-
/** The model finished loading: its bounds and mesh count. */
|
|
1977
|
-
onModelLoaded?: (model: ViewerModelInfo) => void;
|
|
1978
|
-
/** Opt-in inspection of the active loaded asset, including its merged nodes. */
|
|
1979
|
-
onAssetDiagnostics?: (report: AssetDiagnosticsReport) => void;
|
|
1980
|
-
/** Opt-in sampled statistics for this viewer's entire canvas. Does not force frames. */
|
|
1981
|
-
onRuntimeStats?: (stats: ViewerRuntimeStats) => void;
|
|
1982
|
-
/** Runtime sampling interval, clamped to 250–10000 ms; default 1000 ms. */
|
|
1983
|
-
runtimeStatsIntervalMs?: number;
|
|
1984
|
-
onLoadError?: (error: unknown) => void;
|
|
1985
|
-
onProgress?: (event: ProgressEvent) => void;
|
|
1986
|
-
onCameraControllerChange?: (controller: CameraControllerType) => void;
|
|
1987
|
-
cameraControllerType?: CameraControllerType;
|
|
1988
|
-
onAction?: (event: ObjectActionEvent) => void;
|
|
1989
|
-
onHiddenObjectsChange?: (next: Record<string, boolean>) => void;
|
|
1990
|
-
/** Opt-in interaction analytics; no telemetry is sent by the viewer. */
|
|
1991
|
-
onEngagement?: (event: ViewerEngagementEvent) => void | Promise<void>;
|
|
1992
|
-
/** Log engagement events in the developer console. Default `false`. */
|
|
1993
|
-
debugEngagement?: boolean;
|
|
1994
|
-
/** The camera moved. Fires often while the user orbits, pans or zooms. */
|
|
1995
|
-
onCameraChange?: (state: ViewerCameraState) => void;
|
|
1996
|
-
onViewerReady?: (viewer: ViewerReadyState) => void;
|
|
1997
|
-
onTextureUpload?: (file: File, objectId: string) => Promise<string>;
|
|
1998
|
-
onAnimationsReady?: (controls: AnimationControls) => void;
|
|
1999
|
-
onModelAnimationsReady?: (url: string, controls: AnimationControls) => void;
|
|
2000
|
-
onAnnotationsChange?: (annotations: AnnotationMarker[]) => void;
|
|
2001
|
-
activeAnnotation?: AnnotationMarker | null;
|
|
2002
|
-
onActiveAnnotationChange?: (annotation: AnnotationMarker | null) => void;
|
|
2003
|
-
camera?: ViewerCameraConfig;
|
|
2004
|
-
cameraLimits?: CameraLimits;
|
|
2005
|
-
backgroundColor?: string;
|
|
2006
|
-
shadows?: boolean;
|
|
2007
|
-
showObjectBindingDataPanel?: boolean;
|
|
2008
|
-
customObjectBindingDataPanel?: (props: CustomObjectBindingDataPanelProps) => ReactNode;
|
|
2009
|
-
customSceneObjectsPanel?: (props: CustomSceneObjectsPanelProps) => ReactNode;
|
|
2010
|
-
showSceneObjectsPanel?: boolean;
|
|
2011
|
-
showDownloadButton?: boolean;
|
|
2012
|
-
downloadFilename?: string;
|
|
2013
|
-
showResetButton?: boolean;
|
|
2014
|
-
/** Fullscreen action button; grouped form: `ui.fullscreen`. Default `false`. */
|
|
2015
|
-
showFullscreenButton?: boolean;
|
|
2016
|
-
showLoadingOverlay?: boolean;
|
|
2017
|
-
showMouseController?: boolean;
|
|
2018
|
-
mouseControllerPosition?: MouseControllerPosition;
|
|
2019
|
-
mouseControllerOpacity?: number;
|
|
2020
|
-
moveSensitivity?: number;
|
|
2021
|
-
zoomSensitivity?: number;
|
|
2022
|
-
sceneConfig?: SceneConfig;
|
|
2023
|
-
disableZoom?: boolean;
|
|
2024
|
-
zoomOnSelected?: boolean;
|
|
2025
|
-
highlightOnHover?: boolean;
|
|
2026
|
-
onAutoFit?: () => Promise<boolean>;
|
|
2027
|
-
enableCameraControls?: boolean;
|
|
2028
|
-
moveModeEnabled?: boolean;
|
|
2029
|
-
/** Shows a draggable corner handle to resize the selected object, independently of moveModeEnabled. */
|
|
2030
|
-
scaleModeEnabled?: boolean;
|
|
2031
|
-
/** Aligns PivotControls to the scene or to the selected object. */
|
|
2032
|
-
objectTransformSpace?: ObjectTransformSpace;
|
|
2033
|
-
/** Enables canvas-focused camera shortcuts. Disabled by default. */
|
|
2034
|
-
enableKeyboardNavigation?: boolean;
|
|
2035
|
-
/**
|
|
2036
|
-
* Cuts motion the viewer starts on its own: auto-rotate and cinematic
|
|
2037
|
-
* autoplay don't start, and camera moves jump instead of gliding. `"user"`
|
|
2038
|
-
* (default) follows the visitor's `prefers-reduced-motion` setting;
|
|
2039
|
-
* `"always"` and `"never"` override it.
|
|
2040
|
-
*/
|
|
2041
|
-
reducedMotion?: ReducedMotionSetting;
|
|
2042
|
-
refitOnResize?: boolean;
|
|
2043
|
-
renderMode?: "always" | "demand";
|
|
2044
|
-
maxDpr?: number;
|
|
2045
|
-
preserveDrawingBuffer?: boolean;
|
|
2046
|
-
webgpu?: boolean;
|
|
2047
|
-
performanceProfile?: PerformanceProfile;
|
|
2048
|
-
dracoDecoderPath?: string | false;
|
|
2049
|
-
ktx2TranscoderPath?: string | false;
|
|
2050
|
-
meshopt?: boolean;
|
|
2051
|
-
showMeasureTools?: boolean;
|
|
2052
|
-
showUvCheckerButton?: boolean;
|
|
2053
|
-
showExplodeControls?: boolean;
|
|
2054
|
-
isolation?: ViewerIsolation | null;
|
|
2055
|
-
onIsolationChange?: (isolation: ViewerIsolation | null) => void;
|
|
2056
|
-
showIsolateControls?: boolean;
|
|
2057
|
-
showSectionTools?: boolean;
|
|
2058
|
-
/**
|
|
2059
|
-
* Lets visitors choose from `sceneConfig.product`, in a panel over the model.
|
|
2060
|
-
* `true` uses the defaults; an object connects services, links and callbacks.
|
|
2061
|
-
*/
|
|
2062
|
-
productOptions?: boolean | ViewerProductOptions;
|
|
2063
|
-
showMaterialVariants?: boolean;
|
|
2064
|
-
showObjectNavigator?: boolean;
|
|
2065
|
-
cinematic?: boolean | CinematicConfig;
|
|
2066
|
-
measurementUnit?: string;
|
|
2067
|
-
/** Controlled named measurements; otherwise sceneConfig.measurements or local state. */
|
|
2068
|
-
measurements?: SavedMeasurement[];
|
|
2069
|
-
onMeasurementsChange?: (measurements: SavedMeasurement[]) => void;
|
|
2070
|
-
/** Authored/display units and optional metres-per-unit calibration. */
|
|
2071
|
-
measurementSettings?: MeasurementSettings;
|
|
2072
|
-
/** Stable asset id for measurements when uploaded files receive new blob URLs. */
|
|
2073
|
-
measurementModelId?: string;
|
|
2074
|
-
onMeasurementSettingsChange?: (settings: MeasurementSettings) => void;
|
|
2075
|
-
enableXR?: boolean;
|
|
2076
|
-
usdzUrl?: string;
|
|
2077
|
-
arScaleMode?: XRScaleMode;
|
|
2078
|
-
mobileHandoffUrl?: string;
|
|
2079
|
-
/** Prepare the edited configuration for USDZ and phone handoff. Opt-in. */
|
|
2080
|
-
arHandoff?: boolean | ARHandoffOptions;
|
|
2081
|
-
/** Receive sequence controls on load, or null when disconnected. */
|
|
2082
|
-
onSequencesReady?: (controls: SequenceControls | null) => void;
|
|
2083
|
-
/** Show a compact player when sceneConfig contains sequences. Default true. */
|
|
2084
|
-
showSequenceControls?: boolean;
|
|
2085
|
-
/** Honor sequence autoPlay flags. Default true; reduced motion disables autoplay. */
|
|
2086
|
-
sequenceAutoPlay?: boolean;
|
|
2087
|
-
showAnnotationNavigation?: boolean;
|
|
2088
|
-
showAnnotationOnHover?: boolean;
|
|
2089
|
-
showAnnotationFilters?: boolean;
|
|
2090
|
-
annotationCategories?: string[] | null;
|
|
2091
|
-
onAnnotationCategoriesChange?: (categories: string[] | null) => void;
|
|
2092
|
-
onSceneConfigChange?: (config: SceneConfig) => void;
|
|
2093
|
-
showViewGizmo?: boolean;
|
|
2094
|
-
/**
|
|
2095
|
-
* Your own UI over the 3D view: badges, HUDs, custom panels. It sits above
|
|
2096
|
-
* the model and below the viewer's toolbars. The layer lets pointer events
|
|
2097
|
-
* through to the model; its direct children receive them, so position them
|
|
2098
|
-
* yourself (for example `position: "absolute"`).
|
|
2099
|
-
*/
|
|
2100
|
-
overlay?: ReactNode;
|
|
2101
|
-
/**
|
|
2102
|
-
* react-three-fiber elements rendered inside the scene, for anything the
|
|
2103
|
-
* viewer can't do itself. They work with three.js directly, so they're
|
|
2104
|
-
* outside the viewer's own API and can break when three.js or
|
|
2105
|
-
* react-three-fiber change.
|
|
2106
|
-
*/
|
|
2107
|
-
unsafe_sceneChildren?: ReactNode;
|
|
2108
|
-
autoRotate?: boolean;
|
|
2109
|
-
autoRotateSpeed?: number;
|
|
2110
|
-
/**
|
|
2111
|
-
* Texture positioning for objects with an uploaded texture: Offset and
|
|
2112
|
-
* Rotation fields in the Change Material panel, and Move/Zoom mode on
|
|
2113
|
-
* double-click (drag to move, scroll to scale). Off by default. Pass `true`,
|
|
2114
|
-
* or an object to take over parts of it; changes are written to the
|
|
2115
|
-
* binding's `style.material.texture`.
|
|
2116
|
-
*/
|
|
2117
|
-
texturePositioning?: boolean | TexturePositioningControls;
|
|
2118
|
-
extraModelUrls?: string[];
|
|
2119
|
-
onExtraModelError?: (url: string, error: unknown) => void;
|
|
2120
|
-
onExtraModelLoaded?: (url: string, scene: Object3D) => void;
|
|
2121
|
-
originalNodePoses?: Record<string, {
|
|
2122
|
-
position: [number, number, number];
|
|
2123
|
-
rotation?: [number, number, number];
|
|
2124
|
-
scale?: [number, number, number];
|
|
2125
|
-
}>;
|
|
2126
|
-
/** Each entry supplies its own bindings. Uncontrolled edits are kept per instance (id ?? url). */
|
|
2127
|
-
models?: ModelViewerModelEntry[];
|
|
2128
|
-
/** Select an explicit instance ID, allowing several entries to reuse one URL. */
|
|
2129
|
-
activeModelId?: string;
|
|
2130
|
-
/** Instance switcher callback; preferred over onModelChange in ID mode. */
|
|
2131
|
-
onActiveModelChange?: (id: string) => void;
|
|
2132
|
-
mergeModels?: ModelMergeSource[];
|
|
2133
|
-
onMergeModelLoaded?: (url: string, mergedRoot: Object3D) => void;
|
|
2134
|
-
onMergeModelError?: (url: string, error: unknown) => void;
|
|
2135
|
-
/** Selects a model from the switcher. The switcher is hidden when omitted. */
|
|
2136
|
-
onModelChange?: (url: string) => void;
|
|
2137
|
-
};
|
|
2138
|
-
type ModelViewerModelEntry = {
|
|
2139
|
-
url: string;
|
|
2140
|
-
/** Stable unique instance identity. Required when URLs repeat. Object IDs stay local to each instance. */
|
|
2141
|
-
id?: string;
|
|
2142
|
-
/** Whole-asset placement; independent of node transforms and scene model rotation. */
|
|
2143
|
-
transform?: AssetTransform;
|
|
2144
|
-
/** Hide this whole instance without changing its object bindings. */
|
|
2145
|
-
visible?: boolean;
|
|
2146
|
-
/** Display name for the model switcher; falls back to the URL's filename. */
|
|
2147
|
-
label?: string;
|
|
2148
|
-
/** Bindings for this model; used in preference to top-level objectBindings. */
|
|
2149
|
-
objectBindings: Record<string, ObjectBinding>;
|
|
2150
|
-
originalNodePoses?: Record<string, {
|
|
2151
|
-
position: [number, number, number];
|
|
2152
|
-
rotation?: [number, number, number];
|
|
2153
|
-
scale?: [number, number, number];
|
|
2154
|
-
}>;
|
|
2155
|
-
mergeModels?: ModelMergeSource[];
|
|
2156
|
-
/** Scene settings for this slot while parked; the active slot uses the viewer's sceneConfig. */
|
|
2157
|
-
sceneConfig?: SceneConfig;
|
|
2158
|
-
};
|
|
1722
|
+
type ModelFormat = "glb" | "gltf" | "obj" | "fbx" | "usdz" | "stl" | "ply";
|
|
2159
1723
|
|
|
2160
|
-
export {
|
|
1724
|
+
export { type ObjectBindingTextureSlot as $, type AnimationAction as A, type BindingEdit as B, type CameraAction as C, DEFAULT_MODEL_VIEWER_LABELS as D, type EnvironmentPreset as E, type ModelFormat as F, type GlitchModeName as G, type ModelViewerLabelKey as H, type IsolatedObjectBindings as I, type ModelViewerLabels as J, type KernelSizeName as K, type ObjectActionEvent as L, MATERIAL_BLENDING_MODES as M, type ObjectBinding as N, type ObjectActionEffect as O, type ObjectBindingAction as P, type ObjectBindingCameraState as Q, type ObjectBindingDecal as R, type ObjectBindingMaterial as S, type ObjectBindingMaterialBlendingMode as T, type ObjectBindingMaterialSide as U, type ObjectBindingPatch as V, type ObjectBindingSelector as W, type ObjectBindingStatus as X, type ObjectBindingStyle as Y, type ObjectBindingTarget as Z, type ObjectBindingTextureChannel as _, type AnimationActionEffect as a, type SceneStyleRule as a$, type ObjectBindingTransform as a0, type ObjectBindingType as a1, type ObjectBindingsActionEffect as a2, type ObjectPointerEvent as a3, type ObjectSurfacePoint as a4, type ProductAppearance as a5, type ProductAvailability as a6, type ProductCheckoutContext as a7, type ProductCheckoutLink as a8, type ProductCommerceAdapter as a9, type SceneCameraConfig as aA, type SceneCinematicConfig as aB, type SceneCinematicWaypoint as aC, type SceneConfig as aD, type SceneConfigActionEffect as aE, type SceneConfigPatch as aF, type SceneEnvironmentConfig as aG, type SceneGroundShadowConfig as aH, type SceneLight as aI, type SceneLightAttachment as aJ, type SceneLightType as aK, type SceneLightingConfig as aL, type SceneModelConfig as aM, type SceneModelRenderer as aN, type ScenePostProcessingConfig as aO, type SceneProductConfig as aP, type SceneSectionAxis as aQ, type SceneSectionConfig as aR, type SceneSectionPlane as aS, type SceneSectionPreset as aT, type SceneSectionSettings as aU, type SceneSelectionSet as aV, type SceneSequence as aW, type SceneShadowConfig as aX, type SceneStyleColorScale as aY, type SceneStyleCondition as aZ, type SceneStylePulse as a_, type ProductCommerceContext as aa, type ProductCommerceResult as ab, type ProductConfiguration as ac, type ProductConfigurationIssue as ad, type ProductDefinition as ae, type ProductDefinitionWarning as af, type ProductGroupDisplay as ag, type ProductOption as ah, type ProductOptionGroup as ai, type ProductOptionRef as aj, type ProductOptionRule as ak, type ProductOptionState as al, type ProductPrice as am, type ProductPricing as an, type ProductSelections as ao, type ProductSku as ap, type RampTypeName as aq, type ReducedMotionSetting as ar, type SavedMeasurement as as, type SceneAnimationClipConfig as at, type SceneAnimationConfig as au, type SceneAnnotationCameraView as av, type SceneAnnotationImage as aw, type SceneAnnotationLink as ax, type SceneAnnotationMarker as ay, type SceneBackgroundConfig as az, type AnimationClipInfo as b, type SceneWireframeConfig as b0, type SequenceCameraView as b1, type SequenceControls as b2, type SequenceEasing as b3, type SequenceKeyframe as b4, type SequenceObjectProperty as b5, type SequencePlaybackState as b6, type SequenceTarget as b7, type SequenceTrack as b8, type SequenceValue as b9, type SequenceVector3 as ba, type StyledObjectBindings as bb, type StyledObjectPulse as bc, type ViewerAnimationsProps as bd, type ViewerCameraConfig as be, type ViewerCameraState as bf, type ViewerIsolation as bg, type ViewerLoading as bh, type ViewerModelBounds as bi, type ViewerModelInfo as bj, type ViewerReveal as bk, type VisibilityActionEffect as bl, applyIsolation as bm, applyStyleRules as bn, chooseMaterialVariant as bo, colorScaleValue as bp, isolatedBindingKeys as bq, material as br, parseSelectionSets as bs, patchBindings as bt, patchSceneConfig as bu, selectBindingKeys as bv, selectBindings as bw, useViewerAnimations as bx, type AnimationClipState as c, type AnimationClipStatus as d, type AnimationControls as e, type AnimationLoopMode as f, type AnimationPlayOptions as g, type AnimationPlaybackState as h, type CameraActionEffect as i, type CameraLimits as j, DEFAULT_SCENE_CONFIG as k, DEFAULT_SECTION_CONFIG as l, type DeepPartial as m, type IsolationActionEffect as n, MATERIAL_SIDES as o, type MaterialVariantGroup as p, type MaterialVariantOption as q, type MeasurementAnchor as r, type MeasurementCollection as s, type MeasurementPoint as t, type MeasurementPosition as u, type MeasurementResult as v, type MeasurementSettings as w, type MeasurementStatus as x, type MeasurementTool as y, type MeasurementUnit as z };
|