@relu-interactives/spatial-ecs 0.4.0 → 0.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/dist/{System-QjjSc6LZ.d.cts → System-ln4Q7Eot.d.cts} +1 -1
- package/dist/{System-QjjSc6LZ.d.ts → System-ln4Q7Eot.d.ts} +1 -1
- package/dist/{XRHandPose-Csd3QGkj.d.ts → XRHandPose-BImIa4ZS.d.ts} +37 -2
- package/dist/{XRHandPose-Capx-RTD.d.cts → XRHandPose-CxPv-LBo.d.cts} +37 -2
- package/dist/{chunk-ZWONFM2F.js → chunk-4AK4I3QF.js} +2 -2
- package/dist/{chunk-ZWONFM2F.js.map → chunk-4AK4I3QF.js.map} +1 -1
- package/dist/{chunk-2GTFFLGG.js → chunk-4DWZK4X4.js} +3 -3
- package/dist/{chunk-2GTFFLGG.js.map → chunk-4DWZK4X4.js.map} +1 -1
- package/dist/{chunk-24ZMSBR7.js → chunk-LAOFCFEI.js} +18 -4
- package/dist/chunk-LAOFCFEI.js.map +1 -0
- package/dist/{chunk-OWQPGEBB.js → chunk-SGADE55G.js} +14 -5
- package/dist/chunk-SGADE55G.js.map +1 -0
- package/dist/components/index.d.cts +3 -3
- package/dist/components/index.d.ts +3 -3
- package/dist/components/index.js +1 -1
- package/dist/docs/guide/mixed-reality.md +120 -0
- package/dist/factories/index.cjs +20 -0
- package/dist/factories/index.cjs.map +1 -1
- package/dist/factories/index.d.cts +5 -3
- package/dist/factories/index.d.ts +5 -3
- package/dist/factories/index.js +3 -3
- package/dist/{index-SC9Mgjht.d.cts → index-CBdnIyI8.d.cts} +1 -1
- package/dist/{index-BRATaqTT.d.ts → index-CQsHUez3.d.cts} +5 -41
- package/dist/{index-C1rprGz_.d.cts → index-CuGqxuk-.d.ts} +5 -41
- package/dist/{index-BAeeVJ6f.d.ts → index-n7SeH119.d.ts} +1 -1
- package/dist/index.cjs +34 -10
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -8
- package/dist/index.d.ts +9 -8
- package/dist/index.js +8 -8
- package/dist/systems/index.cjs +14 -0
- package/dist/systems/index.cjs.map +1 -1
- package/dist/systems/index.d.cts +2 -2
- package/dist/systems/index.d.ts +2 -2
- package/dist/systems/index.js +3 -3
- package/dist/types.d.cts +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/worldSnapshotUtils.d.cts +1 -1
- package/dist/worldSnapshotUtils.d.ts +1 -1
- package/package.json +1 -1
- package/dist/chunk-24ZMSBR7.js.map +0 -1
- package/dist/chunk-OWQPGEBB.js.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, U as RigidbodyState, g as ColliderState, P as PhysicsComponent, p as EntityType, I as ImageComponent, r as ImageTargetAnchor, q as ImageTarget, L as LightComponent, M as MaterialComponent, F as MeshComponent, G as MeshGeometryComponent, K as ModelComponent, N as Name, O as Object3DRef, X as ScriptEntry, W as ScriptComponent, Z as ScriptObjectComponentInput, Y as ScriptObjectComponent, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, x as InstancedMeshKind, H as MeshGeometryParameters, w as InstancedMeshComponent, u as InstanceSlotComponent, a7 as VideoComponent,
|
|
2
|
-
import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-
|
|
1
|
+
import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, U as RigidbodyState, g as ColliderState, P as PhysicsComponent, p as EntityType, I as ImageComponent, r as ImageTargetAnchor, q as ImageTarget, L as LightComponent, M as MaterialComponent, F as MeshComponent, G as MeshGeometryComponent, K as ModelComponent, N as Name, O as Object3DRef, X as ScriptEntry, W as ScriptComponent, Z as ScriptObjectComponentInput, Y as ScriptObjectComponent, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, x as InstancedMeshKind, H as MeshGeometryParameters, w as InstancedMeshComponent, u as InstanceSlotComponent, a7 as VideoComponent, ai as XRRigComponent, a5 as VRTeleportAreaComponent, ab as XRHandPoseComponent, a9 as XRAnchorComponent, ad as XRInteractableComponent, af as XRInteractorComponent, ah as XRInteractorSideComponent } from '../XRHandPose-CxPv-LBo.cjs';
|
|
2
|
+
import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-ln4Q7Eot.cjs';
|
|
3
3
|
import * as THREE from 'three';
|
|
4
4
|
import '@dimforge/rapier3d-compat';
|
|
5
5
|
import '../handPose-DlcTtqgx.cjs';
|
|
@@ -81,6 +81,8 @@ declare function createVRTeleportAreaComponent(world: World, entityId: number, .
|
|
|
81
81
|
|
|
82
82
|
declare function createXRHandPoseComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRHandPoseComponent>): XRHandPoseComponent;
|
|
83
83
|
|
|
84
|
+
declare function createXRAnchorComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRAnchorComponent>): XRAnchorComponent;
|
|
85
|
+
|
|
84
86
|
declare function createXRInteractableComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRInteractableComponent>): XRInteractableComponent;
|
|
85
87
|
|
|
86
88
|
declare function createXRInteractorComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRInteractorComponent>): XRInteractorComponent;
|
|
@@ -91,4 +93,4 @@ declare function registerDefaultComponentFactories(objectManagementSystem: Objec
|
|
|
91
93
|
|
|
92
94
|
declare function registerDefaultFactories(objectManagementSystem: ObjectManagementSystem): void;
|
|
93
95
|
|
|
94
|
-
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories };
|
|
96
|
+
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRAnchorComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, U as RigidbodyState, g as ColliderState, P as PhysicsComponent, p as EntityType, I as ImageComponent, r as ImageTargetAnchor, q as ImageTarget, L as LightComponent, M as MaterialComponent, F as MeshComponent, G as MeshGeometryComponent, K as ModelComponent, N as Name, O as Object3DRef, X as ScriptEntry, W as ScriptComponent, Z as ScriptObjectComponentInput, Y as ScriptObjectComponent, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, x as InstancedMeshKind, H as MeshGeometryParameters, w as InstancedMeshComponent, u as InstanceSlotComponent, a7 as VideoComponent,
|
|
2
|
-
import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-
|
|
1
|
+
import { A as AnimationComponent, b as AudioComponent, c as CameraComponentOptions, C as CameraComponent, U as RigidbodyState, g as ColliderState, P as PhysicsComponent, p as EntityType, I as ImageComponent, r as ImageTargetAnchor, q as ImageTarget, L as LightComponent, M as MaterialComponent, F as MeshComponent, G as MeshGeometryComponent, K as ModelComponent, N as Name, O as Object3DRef, X as ScriptEntry, W as ScriptComponent, Z as ScriptObjectComponentInput, Y as ScriptObjectComponent, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, x as InstancedMeshKind, H as MeshGeometryParameters, w as InstancedMeshComponent, u as InstanceSlotComponent, a7 as VideoComponent, ai as XRRigComponent, a5 as VRTeleportAreaComponent, ab as XRHandPoseComponent, a9 as XRAnchorComponent, ad as XRInteractableComponent, af as XRInteractorComponent, ah as XRInteractorSideComponent } from '../XRHandPose-BImIa4ZS.js';
|
|
2
|
+
import { l as World, g as EnvironmentState, E as Environment, P as ParentId, i as PostprocessingState, h as Postprocessing, T as TransformComponent, O as ObjectManagementSystem } from '../System-ln4Q7Eot.js';
|
|
3
3
|
import * as THREE from 'three';
|
|
4
4
|
import '@dimforge/rapier3d-compat';
|
|
5
5
|
import '../handPose-DlcTtqgx.js';
|
|
@@ -81,6 +81,8 @@ declare function createVRTeleportAreaComponent(world: World, entityId: number, .
|
|
|
81
81
|
|
|
82
82
|
declare function createXRHandPoseComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRHandPoseComponent>): XRHandPoseComponent;
|
|
83
83
|
|
|
84
|
+
declare function createXRAnchorComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRAnchorComponent>): XRAnchorComponent;
|
|
85
|
+
|
|
84
86
|
declare function createXRInteractableComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRInteractableComponent>): XRInteractableComponent;
|
|
85
87
|
|
|
86
88
|
declare function createXRInteractorComponent(world: World, entityId: number, ...args: ConstructorParameters<typeof XRInteractorComponent>): XRInteractorComponent;
|
|
@@ -91,4 +93,4 @@ declare function registerDefaultComponentFactories(objectManagementSystem: Objec
|
|
|
91
93
|
|
|
92
94
|
declare function registerDefaultFactories(objectManagementSystem: ObjectManagementSystem): void;
|
|
93
95
|
|
|
94
|
-
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories };
|
|
96
|
+
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRAnchorComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories };
|
package/dist/factories/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
import '../chunk-
|
|
1
|
+
export { createAnimationComponent, createAudioComponent, createCameraComponent, createEntityTypeComponent, createEnvironmentComponent, createImageComponent, createImageTargetAnchorComponent, createImageTargetComponent, createInstanceSlotComponent, createInstancedMeshComponent, createLightComponent, createMaterialComponent, createMeshComponent, createMeshGeometryComponent, createModelComponent, createNameComponent, createObject3DRefComponent, createParentIdComponent, createPhysicsComponent, createPostprocessingComponent, createScriptComponent, createScriptObjectComponent, createSelectableComponent, createSelectionTransformStateComponent, createSpriteComponent, createTransformComponent, createVRTeleportAreaComponent, createVideoComponent, createXRAnchorComponent, createXRHandPoseComponent, createXRInteractableComponent, createXRInteractorComponent, createXRInteractorSideComponent, createXRRigComponent, registerDefaultComponentFactories, registerDefaultFactories } from '../chunk-SGADE55G.js';
|
|
2
|
+
import '../chunk-4DWZK4X4.js';
|
|
3
|
+
import '../chunk-4AK4I3QF.js';
|
|
4
4
|
import '../chunk-OY7ZODZP.js';
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { k as EcsSystem, l as World, r as EntityId } from './System-
|
|
1
|
+
import { k as EcsSystem, l as World, r as EntityId } from './System-ln4Q7Eot.cjs';
|
|
2
2
|
import * as THREE from 'three';
|
|
3
3
|
import { m as XrHandJoints, r as XrHandShape } from './handPose-DlcTtqgx.cjs';
|
|
4
4
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_POSE_CURLS, n as DEFAULT_POSE_DIRECTIONS, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, I as ImageComponent, q as ImageTarget, r as ImageTargetAnchor, s as ImageTargetAnchorOptions, t as ImageTargetReference, u as InstanceSlotComponent, v as InstanceTransform, w as InstancedMeshComponent, x as InstancedMeshKind, L as LightComponent, y as LightValueState, M as MaterialComponent, z as MaterialTypeValue, B as MaterialValueState, F as MeshComponent, G as MeshGeometryComponent, H as MeshGeometryParameters, J as MeshGeometryParametersByKind, K as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, Q as PhysicsState, R as PlaneMeshParameters, S as RadiusHeightMeshParameters, T as RadiusMeshParameters, U as RigidbodyState, V as RigidbodyType, W as ScriptComponent, X as ScriptEntry, Y as ScriptObjectComponent, Z as ScriptObjectComponentInput, _ as ScriptObjectRuntimeState, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, a2 as TextureFilteringValue, a3 as TransformModeValue, a4 as TransformSpaceValue, a5 as VRTeleportAreaComponent, a6 as VRTeleportAreaOptions, a7 as VideoComponent, a8 as VrTeleportShape, a9 as
|
|
2
|
-
import { C as Component, D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-
|
|
1
|
+
import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_POSE_CURLS, n as DEFAULT_POSE_DIRECTIONS, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, I as ImageComponent, q as ImageTarget, r as ImageTargetAnchor, s as ImageTargetAnchorOptions, t as ImageTargetReference, u as InstanceSlotComponent, v as InstanceTransform, w as InstancedMeshComponent, x as InstancedMeshKind, L as LightComponent, y as LightValueState, M as MaterialComponent, z as MaterialTypeValue, B as MaterialValueState, F as MeshComponent, G as MeshGeometryComponent, H as MeshGeometryParameters, J as MeshGeometryParametersByKind, K as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, Q as PhysicsState, R as PlaneMeshParameters, S as RadiusHeightMeshParameters, T as RadiusMeshParameters, U as RigidbodyState, V as RigidbodyType, W as ScriptComponent, X as ScriptEntry, Y as ScriptObjectComponent, Z as ScriptObjectComponentInput, _ as ScriptObjectRuntimeState, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, a2 as TextureFilteringValue, a3 as TransformModeValue, a4 as TransformSpaceValue, a5 as VRTeleportAreaComponent, a6 as VRTeleportAreaOptions, a7 as VideoComponent, a8 as VrTeleportShape, a9 as XRAnchorComponent, aa as XRAnchorOptions, ab as XRHandPoseComponent, ac as XRHandPoseOptions, ad as XRInteractableComponent, ae as XRInteractableOptions, af as XRInteractorComponent, ag as XRInteractorOptions, ah as XRInteractorSideComponent, ai as XRRigComponent, aj as XRRigOptions, ak as XrAttachPoint, al as XrDistanceGrabBehavior, am as XrEnvironmentPhysics, an as XrGrabGesture, ao as XrGrabHands, ap as XrGrabReach, aq as XrHandPoseEntry, ar as XrHandPreset, as as XrInteractorSide, at as XrInteractorType, au as XrLocomotionMode, av as XrTrackingOrigin, aw as XrTwoHandRotation, ax as createAttachPoint, ay as createHandPoseEntry, az as defaultMaterialValue, aA as handPoseDefinitionFor, aB as normalizePhysicsState, aC as setPhysicsLiveRef } from './XRHandPose-CxPv-LBo.cjs';
|
|
2
|
+
import { C as Component, D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-ln4Q7Eot.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Marks the ROOT entity of a prefab instance and records its link to the
|
|
@@ -99,41 +99,6 @@ declare class XREnvironmentComponent extends Component {
|
|
|
99
99
|
constructor(kind: XrEnvironmentKind, semanticLabel?: string | null, orientation?: XrEnvironmentOrientation | null);
|
|
100
100
|
}
|
|
101
101
|
|
|
102
|
-
/** Optional initializer for {@link XRAnchorComponent}. */
|
|
103
|
-
type XRAnchorOptions = {
|
|
104
|
-
/** Whether the entity should anchor at all. Defaults to `true`. */
|
|
105
|
-
enabled?: boolean;
|
|
106
|
-
};
|
|
107
|
-
/**
|
|
108
|
-
* Pins an entity to a real-world position.
|
|
109
|
-
*
|
|
110
|
-
* A headset's idea of where the room is keeps being refined while a session
|
|
111
|
-
* runs — it re-recognises the space, corrects drift, and quietly shifts its
|
|
112
|
-
* coordinate system by a few centimetres. Content placed at fixed scene
|
|
113
|
-
* coordinates does not move with those corrections, so a vase carefully set on a
|
|
114
|
-
* real table gradually slides off it.
|
|
115
|
-
*
|
|
116
|
-
* An anchor is the runtime's own handle on a point in the room. Attaching this
|
|
117
|
-
* component hands the entity's pose over to that handle, so the entity moves
|
|
118
|
-
* exactly as the runtime's understanding of the room moves and stays put
|
|
119
|
-
* relative to the real world.
|
|
120
|
-
*
|
|
121
|
-
* Because the anchor OWNS the transform once created, moving the entity by
|
|
122
|
-
* script or by physics has no lasting effect — release it first if you want to
|
|
123
|
-
* move it, then re-anchor.
|
|
124
|
-
*
|
|
125
|
-
* Anchors last only as long as the session. Persisting one across launches
|
|
126
|
-
* needs `requestPersistentHandle`, which is still a draft extension and not
|
|
127
|
-
* supported here.
|
|
128
|
-
*
|
|
129
|
-
* @category Components
|
|
130
|
-
*/
|
|
131
|
-
declare class XRAnchorComponent extends Component {
|
|
132
|
-
/** Whether the entity should anchor. Turning this off releases the anchor. */
|
|
133
|
-
enabled: boolean;
|
|
134
|
-
constructor(options?: XRAnchorOptions);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
102
|
declare const index_AnimationComponent: typeof AnimationComponent;
|
|
138
103
|
declare const index_AnimationComponentOptions: typeof AnimationComponentOptions;
|
|
139
104
|
declare const index_AudioComponent: typeof AudioComponent;
|
|
@@ -216,9 +181,8 @@ declare const index_VRTeleportAreaOptions: typeof VRTeleportAreaOptions;
|
|
|
216
181
|
declare const index_Vec3: typeof Vec3;
|
|
217
182
|
declare const index_VideoComponent: typeof VideoComponent;
|
|
218
183
|
declare const index_VrTeleportShape: typeof VrTeleportShape;
|
|
219
|
-
type index_XRAnchorComponent = XRAnchorComponent;
|
|
220
184
|
declare const index_XRAnchorComponent: typeof XRAnchorComponent;
|
|
221
|
-
|
|
185
|
+
declare const index_XRAnchorOptions: typeof XRAnchorOptions;
|
|
222
186
|
type index_XREnvironmentComponent = XREnvironmentComponent;
|
|
223
187
|
declare const index_XREnvironmentComponent: typeof XREnvironmentComponent;
|
|
224
188
|
declare const index_XRHandPoseComponent: typeof XRHandPoseComponent;
|
|
@@ -252,7 +216,7 @@ declare const index_handPoseDefinitionFor: typeof handPoseDefinitionFor;
|
|
|
252
216
|
declare const index_normalizePhysicsState: typeof normalizePhysicsState;
|
|
253
217
|
declare const index_setPhysicsLiveRef: typeof setPhysicsLiveRef;
|
|
254
218
|
declare namespace index {
|
|
255
|
-
export { index_AnimationComponent as AnimationComponent, index_AnimationComponentOptions as AnimationComponentOptions, index_AudioComponent as AudioComponent, index_CameraComponent as CameraComponent, index_CameraComponentOptions as CameraComponentOptions, index_CameraProjection as CameraProjection, index_CameraRuntimeType as CameraRuntimeType, index_ColliderShape as ColliderShape, index_ColliderState as ColliderState, index_CubeMeshParameters as CubeMeshParameters, index_DEFAULT_COLLIDER_STATE as DEFAULT_COLLIDER_STATE, index_DEFAULT_ENVIRONMENT_STATE as DEFAULT_ENVIRONMENT_STATE, index_DEFAULT_INSTANCED_MESH_PARAMETERS as DEFAULT_INSTANCED_MESH_PARAMETERS, index_DEFAULT_INSTANCE_TRANSFORM as DEFAULT_INSTANCE_TRANSFORM, index_DEFAULT_MESH_GEOMETRY_PARAMETERS as DEFAULT_MESH_GEOMETRY_PARAMETERS, index_DEFAULT_PHYSICS_STATE as DEFAULT_PHYSICS_STATE, index_DEFAULT_POSE_CURLS as DEFAULT_POSE_CURLS, index_DEFAULT_POSE_DIRECTIONS as DEFAULT_POSE_DIRECTIONS, index_DEFAULT_POSTPROCESSING_STATE as DEFAULT_POSTPROCESSING_STATE, index_DEFAULT_RIGIDBODY_STATE as DEFAULT_RIGIDBODY_STATE, index_EditableMeshObjectKind as EditableMeshObjectKind, index_EntityType as EntityType, index_Environment as Environment, index_EnvironmentFogState as EnvironmentFogState, index_EnvironmentFogType as EnvironmentFogType, index_EnvironmentGradientEffect as EnvironmentGradientEffect, index_EnvironmentSkyboxState as EnvironmentSkyboxState, index_EnvironmentSkyboxType as EnvironmentSkyboxType, index_EnvironmentState as EnvironmentState, index_ImageComponent as ImageComponent, index_ImageTarget as ImageTarget, index_ImageTargetAnchor as ImageTargetAnchor, index_ImageTargetAnchorOptions as ImageTargetAnchorOptions, index_ImageTargetReference as ImageTargetReference, index_InstanceSlotComponent as InstanceSlotComponent, index_InstanceTransform as InstanceTransform, index_InstancedMeshComponent as InstancedMeshComponent, index_InstancedMeshKind as InstancedMeshKind, index_LightComponent as LightComponent, index_LightValueState as LightValueState, index_MaterialComponent as MaterialComponent, index_MaterialTypeValue as MaterialTypeValue, index_MaterialValueState as MaterialValueState, index_MeshComponent as MeshComponent, index_MeshGeometryComponent as MeshGeometryComponent, index_MeshGeometryParameters as MeshGeometryParameters, index_MeshGeometryParametersByKind as MeshGeometryParametersByKind, index_ModelComponent as ModelComponent, index_Name as Name, index_Object3DRef as Object3DRef, index_ParentId as ParentId, index_PhysicsComponent as PhysicsComponent, index_PhysicsState as PhysicsState, index_PlaneMeshParameters as PlaneMeshParameters, index_Postprocessing as Postprocessing, index_PostprocessingState as PostprocessingState, index_PrefabInstance as PrefabInstance, index_PrefabNode as PrefabNode, index_RadiusHeightMeshParameters as RadiusHeightMeshParameters, index_RadiusMeshParameters as RadiusMeshParameters, index_RigidbodyState as RigidbodyState, index_RigidbodyType as RigidbodyType, index_ScriptComponent as ScriptComponent, index_ScriptEntry as ScriptEntry, index_ScriptObjectComponent as ScriptObjectComponent, index_ScriptObjectComponentInput as ScriptObjectComponentInput, index_ScriptObjectRuntimeState as ScriptObjectRuntimeState, index_Selectable as Selectable, index_SelectionTransformState as SelectionTransformState, index_SpriteComponent as SpriteComponent, index_TextureFilteringValue as TextureFilteringValue, index_TransformComponent as TransformComponent, index_TransformData as TransformData, index_TransformModeValue as TransformModeValue, index_TransformSpaceValue as TransformSpaceValue, index_VRTeleportAreaComponent as VRTeleportAreaComponent, index_VRTeleportAreaOptions as VRTeleportAreaOptions, index_Vec3 as Vec3, index_VideoComponent as VideoComponent, index_VrTeleportShape as VrTeleportShape, index_XRAnchorComponent as XRAnchorComponent,
|
|
219
|
+
export { index_AnimationComponent as AnimationComponent, index_AnimationComponentOptions as AnimationComponentOptions, index_AudioComponent as AudioComponent, index_CameraComponent as CameraComponent, index_CameraComponentOptions as CameraComponentOptions, index_CameraProjection as CameraProjection, index_CameraRuntimeType as CameraRuntimeType, index_ColliderShape as ColliderShape, index_ColliderState as ColliderState, index_CubeMeshParameters as CubeMeshParameters, index_DEFAULT_COLLIDER_STATE as DEFAULT_COLLIDER_STATE, index_DEFAULT_ENVIRONMENT_STATE as DEFAULT_ENVIRONMENT_STATE, index_DEFAULT_INSTANCED_MESH_PARAMETERS as DEFAULT_INSTANCED_MESH_PARAMETERS, index_DEFAULT_INSTANCE_TRANSFORM as DEFAULT_INSTANCE_TRANSFORM, index_DEFAULT_MESH_GEOMETRY_PARAMETERS as DEFAULT_MESH_GEOMETRY_PARAMETERS, index_DEFAULT_PHYSICS_STATE as DEFAULT_PHYSICS_STATE, index_DEFAULT_POSE_CURLS as DEFAULT_POSE_CURLS, index_DEFAULT_POSE_DIRECTIONS as DEFAULT_POSE_DIRECTIONS, index_DEFAULT_POSTPROCESSING_STATE as DEFAULT_POSTPROCESSING_STATE, index_DEFAULT_RIGIDBODY_STATE as DEFAULT_RIGIDBODY_STATE, index_EditableMeshObjectKind as EditableMeshObjectKind, index_EntityType as EntityType, index_Environment as Environment, index_EnvironmentFogState as EnvironmentFogState, index_EnvironmentFogType as EnvironmentFogType, index_EnvironmentGradientEffect as EnvironmentGradientEffect, index_EnvironmentSkyboxState as EnvironmentSkyboxState, index_EnvironmentSkyboxType as EnvironmentSkyboxType, index_EnvironmentState as EnvironmentState, index_ImageComponent as ImageComponent, index_ImageTarget as ImageTarget, index_ImageTargetAnchor as ImageTargetAnchor, index_ImageTargetAnchorOptions as ImageTargetAnchorOptions, index_ImageTargetReference as ImageTargetReference, index_InstanceSlotComponent as InstanceSlotComponent, index_InstanceTransform as InstanceTransform, index_InstancedMeshComponent as InstancedMeshComponent, index_InstancedMeshKind as InstancedMeshKind, index_LightComponent as LightComponent, index_LightValueState as LightValueState, index_MaterialComponent as MaterialComponent, index_MaterialTypeValue as MaterialTypeValue, index_MaterialValueState as MaterialValueState, index_MeshComponent as MeshComponent, index_MeshGeometryComponent as MeshGeometryComponent, index_MeshGeometryParameters as MeshGeometryParameters, index_MeshGeometryParametersByKind as MeshGeometryParametersByKind, index_ModelComponent as ModelComponent, index_Name as Name, index_Object3DRef as Object3DRef, index_ParentId as ParentId, index_PhysicsComponent as PhysicsComponent, index_PhysicsState as PhysicsState, index_PlaneMeshParameters as PlaneMeshParameters, index_Postprocessing as Postprocessing, index_PostprocessingState as PostprocessingState, index_PrefabInstance as PrefabInstance, index_PrefabNode as PrefabNode, index_RadiusHeightMeshParameters as RadiusHeightMeshParameters, index_RadiusMeshParameters as RadiusMeshParameters, index_RigidbodyState as RigidbodyState, index_RigidbodyType as RigidbodyType, index_ScriptComponent as ScriptComponent, index_ScriptEntry as ScriptEntry, index_ScriptObjectComponent as ScriptObjectComponent, index_ScriptObjectComponentInput as ScriptObjectComponentInput, index_ScriptObjectRuntimeState as ScriptObjectRuntimeState, index_Selectable as Selectable, index_SelectionTransformState as SelectionTransformState, index_SpriteComponent as SpriteComponent, index_TextureFilteringValue as TextureFilteringValue, index_TransformComponent as TransformComponent, index_TransformData as TransformData, index_TransformModeValue as TransformModeValue, index_TransformSpaceValue as TransformSpaceValue, index_VRTeleportAreaComponent as VRTeleportAreaComponent, index_VRTeleportAreaOptions as VRTeleportAreaOptions, index_Vec3 as Vec3, index_VideoComponent as VideoComponent, index_VrTeleportShape as VrTeleportShape, index_XRAnchorComponent as XRAnchorComponent, index_XRAnchorOptions as XRAnchorOptions, index_XREnvironmentComponent as XREnvironmentComponent, index_XRHandPoseComponent as XRHandPoseComponent, index_XRHandPoseOptions as XRHandPoseOptions, index_XRInteractableComponent as XRInteractableComponent, index_XRInteractableOptions as XRInteractableOptions, index_XRInteractorComponent as XRInteractorComponent, index_XRInteractorOptions as XRInteractorOptions, index_XRInteractorSideComponent as XRInteractorSideComponent, index_XRRigComponent as XRRigComponent, index_XRRigOptions as XRRigOptions, index_XrAttachPoint as XrAttachPoint, index_XrDistanceGrabBehavior as XrDistanceGrabBehavior, type index_XrEnvironmentKind as XrEnvironmentKind, type index_XrEnvironmentOrientation as XrEnvironmentOrientation, index_XrEnvironmentPhysics as XrEnvironmentPhysics, index_XrGrabGesture as XrGrabGesture, index_XrGrabHands as XrGrabHands, index_XrGrabReach as XrGrabReach, index_XrHandPoseEntry as XrHandPoseEntry, index_XrHandPreset as XrHandPreset, index_XrInteractorSide as XrInteractorSide, index_XrInteractorType as XrInteractorType, index_XrLocomotionMode as XrLocomotionMode, index_XrTrackingOrigin as XrTrackingOrigin, index_XrTwoHandRotation as XrTwoHandRotation, index_createAttachPoint as createAttachPoint, index_createHandPoseEntry as createHandPoseEntry, index_defaultMaterialValue as defaultMaterialValue, index_handPoseDefinitionFor as handPoseDefinitionFor, index_normalizePhysicsState as normalizePhysicsState, index_setPhysicsLiveRef as setPhysicsLiveRef };
|
|
256
220
|
}
|
|
257
221
|
|
|
258
|
-
export { PrefabInstance as P,
|
|
222
|
+
export { PrefabInstance as P, XREnvironmentComponent as X, PrefabNode as a, type XrEnvironmentKind as b, type XrEnvironmentOrientation as c, index as i };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_POSE_CURLS, n as DEFAULT_POSE_DIRECTIONS, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, I as ImageComponent, q as ImageTarget, r as ImageTargetAnchor, s as ImageTargetAnchorOptions, t as ImageTargetReference, u as InstanceSlotComponent, v as InstanceTransform, w as InstancedMeshComponent, x as InstancedMeshKind, L as LightComponent, y as LightValueState, M as MaterialComponent, z as MaterialTypeValue, B as MaterialValueState, F as MeshComponent, G as MeshGeometryComponent, H as MeshGeometryParameters, J as MeshGeometryParametersByKind, K as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, Q as PhysicsState, R as PlaneMeshParameters, S as RadiusHeightMeshParameters, T as RadiusMeshParameters, U as RigidbodyState, V as RigidbodyType, W as ScriptComponent, X as ScriptEntry, Y as ScriptObjectComponent, Z as ScriptObjectComponentInput, _ as ScriptObjectRuntimeState, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, a2 as TextureFilteringValue, a3 as TransformModeValue, a4 as TransformSpaceValue, a5 as VRTeleportAreaComponent, a6 as VRTeleportAreaOptions, a7 as VideoComponent, a8 as VrTeleportShape, a9 as
|
|
2
|
-
import { C as Component, D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-
|
|
1
|
+
import { A as AnimationComponent, a as AnimationComponentOptions, b as AudioComponent, C as CameraComponent, c as CameraComponentOptions, d as CameraProjection, e as CameraRuntimeType, f as ColliderShape, g as ColliderState, h as CubeMeshParameters, D as DEFAULT_COLLIDER_STATE, i as DEFAULT_INSTANCED_MESH_PARAMETERS, j as DEFAULT_INSTANCE_TRANSFORM, k as DEFAULT_MESH_GEOMETRY_PARAMETERS, l as DEFAULT_PHYSICS_STATE, m as DEFAULT_POSE_CURLS, n as DEFAULT_POSE_DIRECTIONS, o as DEFAULT_RIGIDBODY_STATE, E as EditableMeshObjectKind, p as EntityType, I as ImageComponent, q as ImageTarget, r as ImageTargetAnchor, s as ImageTargetAnchorOptions, t as ImageTargetReference, u as InstanceSlotComponent, v as InstanceTransform, w as InstancedMeshComponent, x as InstancedMeshKind, L as LightComponent, y as LightValueState, M as MaterialComponent, z as MaterialTypeValue, B as MaterialValueState, F as MeshComponent, G as MeshGeometryComponent, H as MeshGeometryParameters, J as MeshGeometryParametersByKind, K as ModelComponent, N as Name, O as Object3DRef, P as PhysicsComponent, Q as PhysicsState, R as PlaneMeshParameters, S as RadiusHeightMeshParameters, T as RadiusMeshParameters, U as RigidbodyState, V as RigidbodyType, W as ScriptComponent, X as ScriptEntry, Y as ScriptObjectComponent, Z as ScriptObjectComponentInput, _ as ScriptObjectRuntimeState, $ as Selectable, a0 as SelectionTransformState, a1 as SpriteComponent, a2 as TextureFilteringValue, a3 as TransformModeValue, a4 as TransformSpaceValue, a5 as VRTeleportAreaComponent, a6 as VRTeleportAreaOptions, a7 as VideoComponent, a8 as VrTeleportShape, a9 as XRAnchorComponent, aa as XRAnchorOptions, ab as XRHandPoseComponent, ac as XRHandPoseOptions, ad as XRInteractableComponent, ae as XRInteractableOptions, af as XRInteractorComponent, ag as XRInteractorOptions, ah as XRInteractorSideComponent, ai as XRRigComponent, aj as XRRigOptions, ak as XrAttachPoint, al as XrDistanceGrabBehavior, am as XrEnvironmentPhysics, an as XrGrabGesture, ao as XrGrabHands, ap as XrGrabReach, aq as XrHandPoseEntry, ar as XrHandPreset, as as XrInteractorSide, at as XrInteractorType, au as XrLocomotionMode, av as XrTrackingOrigin, aw as XrTwoHandRotation, ax as createAttachPoint, ay as createHandPoseEntry, az as defaultMaterialValue, aA as handPoseDefinitionFor, aB as normalizePhysicsState, aC as setPhysicsLiveRef } from './XRHandPose-BImIa4ZS.js';
|
|
2
|
+
import { C as Component, D as DEFAULT_ENVIRONMENT_STATE, a as DEFAULT_POSTPROCESSING_STATE, E as Environment, b as EnvironmentFogState, c as EnvironmentFogType, d as EnvironmentGradientEffect, e as EnvironmentSkyboxState, f as EnvironmentSkyboxType, g as EnvironmentState, P as ParentId, h as Postprocessing, i as PostprocessingState, T as TransformComponent, j as TransformData, V as Vec3 } from './System-ln4Q7Eot.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Marks the ROOT entity of a prefab instance and records its link to the
|
|
@@ -99,41 +99,6 @@ declare class XREnvironmentComponent extends Component {
|
|
|
99
99
|
constructor(kind: XrEnvironmentKind, semanticLabel?: string | null, orientation?: XrEnvironmentOrientation | null);
|
|
100
100
|
}
|
|
101
101
|
|
|
102
|
-
/** Optional initializer for {@link XRAnchorComponent}. */
|
|
103
|
-
type XRAnchorOptions = {
|
|
104
|
-
/** Whether the entity should anchor at all. Defaults to `true`. */
|
|
105
|
-
enabled?: boolean;
|
|
106
|
-
};
|
|
107
|
-
/**
|
|
108
|
-
* Pins an entity to a real-world position.
|
|
109
|
-
*
|
|
110
|
-
* A headset's idea of where the room is keeps being refined while a session
|
|
111
|
-
* runs — it re-recognises the space, corrects drift, and quietly shifts its
|
|
112
|
-
* coordinate system by a few centimetres. Content placed at fixed scene
|
|
113
|
-
* coordinates does not move with those corrections, so a vase carefully set on a
|
|
114
|
-
* real table gradually slides off it.
|
|
115
|
-
*
|
|
116
|
-
* An anchor is the runtime's own handle on a point in the room. Attaching this
|
|
117
|
-
* component hands the entity's pose over to that handle, so the entity moves
|
|
118
|
-
* exactly as the runtime's understanding of the room moves and stays put
|
|
119
|
-
* relative to the real world.
|
|
120
|
-
*
|
|
121
|
-
* Because the anchor OWNS the transform once created, moving the entity by
|
|
122
|
-
* script or by physics has no lasting effect — release it first if you want to
|
|
123
|
-
* move it, then re-anchor.
|
|
124
|
-
*
|
|
125
|
-
* Anchors last only as long as the session. Persisting one across launches
|
|
126
|
-
* needs `requestPersistentHandle`, which is still a draft extension and not
|
|
127
|
-
* supported here.
|
|
128
|
-
*
|
|
129
|
-
* @category Components
|
|
130
|
-
*/
|
|
131
|
-
declare class XRAnchorComponent extends Component {
|
|
132
|
-
/** Whether the entity should anchor. Turning this off releases the anchor. */
|
|
133
|
-
enabled: boolean;
|
|
134
|
-
constructor(options?: XRAnchorOptions);
|
|
135
|
-
}
|
|
136
|
-
|
|
137
102
|
declare const index_AnimationComponent: typeof AnimationComponent;
|
|
138
103
|
declare const index_AnimationComponentOptions: typeof AnimationComponentOptions;
|
|
139
104
|
declare const index_AudioComponent: typeof AudioComponent;
|
|
@@ -216,9 +181,8 @@ declare const index_VRTeleportAreaOptions: typeof VRTeleportAreaOptions;
|
|
|
216
181
|
declare const index_Vec3: typeof Vec3;
|
|
217
182
|
declare const index_VideoComponent: typeof VideoComponent;
|
|
218
183
|
declare const index_VrTeleportShape: typeof VrTeleportShape;
|
|
219
|
-
type index_XRAnchorComponent = XRAnchorComponent;
|
|
220
184
|
declare const index_XRAnchorComponent: typeof XRAnchorComponent;
|
|
221
|
-
|
|
185
|
+
declare const index_XRAnchorOptions: typeof XRAnchorOptions;
|
|
222
186
|
type index_XREnvironmentComponent = XREnvironmentComponent;
|
|
223
187
|
declare const index_XREnvironmentComponent: typeof XREnvironmentComponent;
|
|
224
188
|
declare const index_XRHandPoseComponent: typeof XRHandPoseComponent;
|
|
@@ -252,7 +216,7 @@ declare const index_handPoseDefinitionFor: typeof handPoseDefinitionFor;
|
|
|
252
216
|
declare const index_normalizePhysicsState: typeof normalizePhysicsState;
|
|
253
217
|
declare const index_setPhysicsLiveRef: typeof setPhysicsLiveRef;
|
|
254
218
|
declare namespace index {
|
|
255
|
-
export { index_AnimationComponent as AnimationComponent, index_AnimationComponentOptions as AnimationComponentOptions, index_AudioComponent as AudioComponent, index_CameraComponent as CameraComponent, index_CameraComponentOptions as CameraComponentOptions, index_CameraProjection as CameraProjection, index_CameraRuntimeType as CameraRuntimeType, index_ColliderShape as ColliderShape, index_ColliderState as ColliderState, index_CubeMeshParameters as CubeMeshParameters, index_DEFAULT_COLLIDER_STATE as DEFAULT_COLLIDER_STATE, index_DEFAULT_ENVIRONMENT_STATE as DEFAULT_ENVIRONMENT_STATE, index_DEFAULT_INSTANCED_MESH_PARAMETERS as DEFAULT_INSTANCED_MESH_PARAMETERS, index_DEFAULT_INSTANCE_TRANSFORM as DEFAULT_INSTANCE_TRANSFORM, index_DEFAULT_MESH_GEOMETRY_PARAMETERS as DEFAULT_MESH_GEOMETRY_PARAMETERS, index_DEFAULT_PHYSICS_STATE as DEFAULT_PHYSICS_STATE, index_DEFAULT_POSE_CURLS as DEFAULT_POSE_CURLS, index_DEFAULT_POSE_DIRECTIONS as DEFAULT_POSE_DIRECTIONS, index_DEFAULT_POSTPROCESSING_STATE as DEFAULT_POSTPROCESSING_STATE, index_DEFAULT_RIGIDBODY_STATE as DEFAULT_RIGIDBODY_STATE, index_EditableMeshObjectKind as EditableMeshObjectKind, index_EntityType as EntityType, index_Environment as Environment, index_EnvironmentFogState as EnvironmentFogState, index_EnvironmentFogType as EnvironmentFogType, index_EnvironmentGradientEffect as EnvironmentGradientEffect, index_EnvironmentSkyboxState as EnvironmentSkyboxState, index_EnvironmentSkyboxType as EnvironmentSkyboxType, index_EnvironmentState as EnvironmentState, index_ImageComponent as ImageComponent, index_ImageTarget as ImageTarget, index_ImageTargetAnchor as ImageTargetAnchor, index_ImageTargetAnchorOptions as ImageTargetAnchorOptions, index_ImageTargetReference as ImageTargetReference, index_InstanceSlotComponent as InstanceSlotComponent, index_InstanceTransform as InstanceTransform, index_InstancedMeshComponent as InstancedMeshComponent, index_InstancedMeshKind as InstancedMeshKind, index_LightComponent as LightComponent, index_LightValueState as LightValueState, index_MaterialComponent as MaterialComponent, index_MaterialTypeValue as MaterialTypeValue, index_MaterialValueState as MaterialValueState, index_MeshComponent as MeshComponent, index_MeshGeometryComponent as MeshGeometryComponent, index_MeshGeometryParameters as MeshGeometryParameters, index_MeshGeometryParametersByKind as MeshGeometryParametersByKind, index_ModelComponent as ModelComponent, index_Name as Name, index_Object3DRef as Object3DRef, index_ParentId as ParentId, index_PhysicsComponent as PhysicsComponent, index_PhysicsState as PhysicsState, index_PlaneMeshParameters as PlaneMeshParameters, index_Postprocessing as Postprocessing, index_PostprocessingState as PostprocessingState, index_PrefabInstance as PrefabInstance, index_PrefabNode as PrefabNode, index_RadiusHeightMeshParameters as RadiusHeightMeshParameters, index_RadiusMeshParameters as RadiusMeshParameters, index_RigidbodyState as RigidbodyState, index_RigidbodyType as RigidbodyType, index_ScriptComponent as ScriptComponent, index_ScriptEntry as ScriptEntry, index_ScriptObjectComponent as ScriptObjectComponent, index_ScriptObjectComponentInput as ScriptObjectComponentInput, index_ScriptObjectRuntimeState as ScriptObjectRuntimeState, index_Selectable as Selectable, index_SelectionTransformState as SelectionTransformState, index_SpriteComponent as SpriteComponent, index_TextureFilteringValue as TextureFilteringValue, index_TransformComponent as TransformComponent, index_TransformData as TransformData, index_TransformModeValue as TransformModeValue, index_TransformSpaceValue as TransformSpaceValue, index_VRTeleportAreaComponent as VRTeleportAreaComponent, index_VRTeleportAreaOptions as VRTeleportAreaOptions, index_Vec3 as Vec3, index_VideoComponent as VideoComponent, index_VrTeleportShape as VrTeleportShape, index_XRAnchorComponent as XRAnchorComponent,
|
|
219
|
+
export { index_AnimationComponent as AnimationComponent, index_AnimationComponentOptions as AnimationComponentOptions, index_AudioComponent as AudioComponent, index_CameraComponent as CameraComponent, index_CameraComponentOptions as CameraComponentOptions, index_CameraProjection as CameraProjection, index_CameraRuntimeType as CameraRuntimeType, index_ColliderShape as ColliderShape, index_ColliderState as ColliderState, index_CubeMeshParameters as CubeMeshParameters, index_DEFAULT_COLLIDER_STATE as DEFAULT_COLLIDER_STATE, index_DEFAULT_ENVIRONMENT_STATE as DEFAULT_ENVIRONMENT_STATE, index_DEFAULT_INSTANCED_MESH_PARAMETERS as DEFAULT_INSTANCED_MESH_PARAMETERS, index_DEFAULT_INSTANCE_TRANSFORM as DEFAULT_INSTANCE_TRANSFORM, index_DEFAULT_MESH_GEOMETRY_PARAMETERS as DEFAULT_MESH_GEOMETRY_PARAMETERS, index_DEFAULT_PHYSICS_STATE as DEFAULT_PHYSICS_STATE, index_DEFAULT_POSE_CURLS as DEFAULT_POSE_CURLS, index_DEFAULT_POSE_DIRECTIONS as DEFAULT_POSE_DIRECTIONS, index_DEFAULT_POSTPROCESSING_STATE as DEFAULT_POSTPROCESSING_STATE, index_DEFAULT_RIGIDBODY_STATE as DEFAULT_RIGIDBODY_STATE, index_EditableMeshObjectKind as EditableMeshObjectKind, index_EntityType as EntityType, index_Environment as Environment, index_EnvironmentFogState as EnvironmentFogState, index_EnvironmentFogType as EnvironmentFogType, index_EnvironmentGradientEffect as EnvironmentGradientEffect, index_EnvironmentSkyboxState as EnvironmentSkyboxState, index_EnvironmentSkyboxType as EnvironmentSkyboxType, index_EnvironmentState as EnvironmentState, index_ImageComponent as ImageComponent, index_ImageTarget as ImageTarget, index_ImageTargetAnchor as ImageTargetAnchor, index_ImageTargetAnchorOptions as ImageTargetAnchorOptions, index_ImageTargetReference as ImageTargetReference, index_InstanceSlotComponent as InstanceSlotComponent, index_InstanceTransform as InstanceTransform, index_InstancedMeshComponent as InstancedMeshComponent, index_InstancedMeshKind as InstancedMeshKind, index_LightComponent as LightComponent, index_LightValueState as LightValueState, index_MaterialComponent as MaterialComponent, index_MaterialTypeValue as MaterialTypeValue, index_MaterialValueState as MaterialValueState, index_MeshComponent as MeshComponent, index_MeshGeometryComponent as MeshGeometryComponent, index_MeshGeometryParameters as MeshGeometryParameters, index_MeshGeometryParametersByKind as MeshGeometryParametersByKind, index_ModelComponent as ModelComponent, index_Name as Name, index_Object3DRef as Object3DRef, index_ParentId as ParentId, index_PhysicsComponent as PhysicsComponent, index_PhysicsState as PhysicsState, index_PlaneMeshParameters as PlaneMeshParameters, index_Postprocessing as Postprocessing, index_PostprocessingState as PostprocessingState, index_PrefabInstance as PrefabInstance, index_PrefabNode as PrefabNode, index_RadiusHeightMeshParameters as RadiusHeightMeshParameters, index_RadiusMeshParameters as RadiusMeshParameters, index_RigidbodyState as RigidbodyState, index_RigidbodyType as RigidbodyType, index_ScriptComponent as ScriptComponent, index_ScriptEntry as ScriptEntry, index_ScriptObjectComponent as ScriptObjectComponent, index_ScriptObjectComponentInput as ScriptObjectComponentInput, index_ScriptObjectRuntimeState as ScriptObjectRuntimeState, index_Selectable as Selectable, index_SelectionTransformState as SelectionTransformState, index_SpriteComponent as SpriteComponent, index_TextureFilteringValue as TextureFilteringValue, index_TransformComponent as TransformComponent, index_TransformData as TransformData, index_TransformModeValue as TransformModeValue, index_TransformSpaceValue as TransformSpaceValue, index_VRTeleportAreaComponent as VRTeleportAreaComponent, index_VRTeleportAreaOptions as VRTeleportAreaOptions, index_Vec3 as Vec3, index_VideoComponent as VideoComponent, index_VrTeleportShape as VrTeleportShape, index_XRAnchorComponent as XRAnchorComponent, index_XRAnchorOptions as XRAnchorOptions, index_XREnvironmentComponent as XREnvironmentComponent, index_XRHandPoseComponent as XRHandPoseComponent, index_XRHandPoseOptions as XRHandPoseOptions, index_XRInteractableComponent as XRInteractableComponent, index_XRInteractableOptions as XRInteractableOptions, index_XRInteractorComponent as XRInteractorComponent, index_XRInteractorOptions as XRInteractorOptions, index_XRInteractorSideComponent as XRInteractorSideComponent, index_XRRigComponent as XRRigComponent, index_XRRigOptions as XRRigOptions, index_XrAttachPoint as XrAttachPoint, index_XrDistanceGrabBehavior as XrDistanceGrabBehavior, type index_XrEnvironmentKind as XrEnvironmentKind, type index_XrEnvironmentOrientation as XrEnvironmentOrientation, index_XrEnvironmentPhysics as XrEnvironmentPhysics, index_XrGrabGesture as XrGrabGesture, index_XrGrabHands as XrGrabHands, index_XrGrabReach as XrGrabReach, index_XrHandPoseEntry as XrHandPoseEntry, index_XrHandPreset as XrHandPreset, index_XrInteractorSide as XrInteractorSide, index_XrInteractorType as XrInteractorType, index_XrLocomotionMode as XrLocomotionMode, index_XrTrackingOrigin as XrTrackingOrigin, index_XrTwoHandRotation as XrTwoHandRotation, index_createAttachPoint as createAttachPoint, index_createHandPoseEntry as createHandPoseEntry, index_defaultMaterialValue as defaultMaterialValue, index_handPoseDefinitionFor as handPoseDefinitionFor, index_normalizePhysicsState as normalizePhysicsState, index_setPhysicsLiveRef as setPhysicsLiveRef };
|
|
256
220
|
}
|
|
257
221
|
|
|
258
|
-
export { PrefabInstance as P,
|
|
222
|
+
export { PrefabInstance as P, XREnvironmentComponent as X, PrefabNode as a, type XrEnvironmentKind as b, type XrEnvironmentOrientation as c, index as i };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { k as EcsSystem, l as World, r as EntityId } from './System-
|
|
1
|
+
import { k as EcsSystem, l as World, r as EntityId } from './System-ln4Q7Eot.js';
|
|
2
2
|
import * as THREE from 'three';
|
|
3
3
|
import { m as XrHandJoints, r as XrHandShape } from './handPose-DlcTtqgx.js';
|
|
4
4
|
|
package/dist/index.cjs
CHANGED
|
@@ -2861,6 +2861,24 @@ function createXRHandPoseComponent(world, entityId, ...args) {
|
|
|
2861
2861
|
}
|
|
2862
2862
|
__name(createXRHandPoseComponent, "createXRHandPoseComponent");
|
|
2863
2863
|
|
|
2864
|
+
// core/components/XRAnchor.ts
|
|
2865
|
+
var _XRAnchorComponent = class _XRAnchorComponent extends Component {
|
|
2866
|
+
constructor(options) {
|
|
2867
|
+
super();
|
|
2868
|
+
this.enabled = options?.enabled ?? true;
|
|
2869
|
+
}
|
|
2870
|
+
};
|
|
2871
|
+
__name(_XRAnchorComponent, "XRAnchorComponent");
|
|
2872
|
+
var XRAnchorComponent = _XRAnchorComponent;
|
|
2873
|
+
|
|
2874
|
+
// core/factories/components/XRAnchorFactory.ts
|
|
2875
|
+
function createXRAnchorComponent(world, entityId, ...args) {
|
|
2876
|
+
const component = new XRAnchorComponent(...args);
|
|
2877
|
+
world.addComponent(entityId, component);
|
|
2878
|
+
return component;
|
|
2879
|
+
}
|
|
2880
|
+
__name(createXRAnchorComponent, "createXRAnchorComponent");
|
|
2881
|
+
|
|
2864
2882
|
// core/components/XRInteractable.ts
|
|
2865
2883
|
var _XRInteractableComponent = class _XRInteractableComponent extends Component {
|
|
2866
2884
|
constructor(options) {
|
|
@@ -2972,6 +2990,7 @@ function registerDefaultComponentFactories(objectManagementSystem) {
|
|
|
2972
2990
|
objectManagementSystem.registerComponentFactory("xrRig", createXRRigComponent);
|
|
2973
2991
|
objectManagementSystem.registerComponentFactory("vrTeleportArea", createVRTeleportAreaComponent);
|
|
2974
2992
|
objectManagementSystem.registerComponentFactory("xrHandPose", createXRHandPoseComponent);
|
|
2993
|
+
objectManagementSystem.registerComponentFactory("xrAnchor", createXRAnchorComponent);
|
|
2975
2994
|
objectManagementSystem.registerComponentFactory("xrInteractable", createXRInteractableComponent);
|
|
2976
2995
|
objectManagementSystem.registerComponentFactory("xrInteractor", createXRInteractorComponent);
|
|
2977
2996
|
objectManagementSystem.registerComponentFactory("xrInteractorSide", createXRInteractorSideComponent);
|
|
@@ -4081,16 +4100,6 @@ var _XREnvironmentComponent = class _XREnvironmentComponent extends Component {
|
|
|
4081
4100
|
__name(_XREnvironmentComponent, "XREnvironmentComponent");
|
|
4082
4101
|
var XREnvironmentComponent = _XREnvironmentComponent;
|
|
4083
4102
|
|
|
4084
|
-
// core/components/XRAnchor.ts
|
|
4085
|
-
var _XRAnchorComponent = class _XRAnchorComponent extends Component {
|
|
4086
|
-
constructor(options) {
|
|
4087
|
-
super();
|
|
4088
|
-
this.enabled = options?.enabled ?? true;
|
|
4089
|
-
}
|
|
4090
|
-
};
|
|
4091
|
-
__name(_XRAnchorComponent, "XRAnchorComponent");
|
|
4092
|
-
var XRAnchorComponent = _XRAnchorComponent;
|
|
4093
|
-
|
|
4094
4103
|
// core/factories/objects/ModelFactory.ts
|
|
4095
4104
|
function getModelFileName(path) {
|
|
4096
4105
|
const segments = path.split(/[\\/]/).filter(Boolean);
|
|
@@ -4753,6 +4762,7 @@ function buildComponentValueMaps(snapshot) {
|
|
|
4753
4762
|
snapshot.components,
|
|
4754
4763
|
"XRHandPoseComponent"
|
|
4755
4764
|
),
|
|
4765
|
+
xrAnchorValues: readByComponent(snapshot.components, "XRAnchorComponent"),
|
|
4756
4766
|
xrInteractorSideValues: readByComponent(
|
|
4757
4767
|
snapshot.components,
|
|
4758
4768
|
"XRInteractorSideComponent"
|
|
@@ -5061,6 +5071,19 @@ function restorePostCreateComponents(world, objectManagementSystem, targetEntity
|
|
|
5061
5071
|
}
|
|
5062
5072
|
}
|
|
5063
5073
|
}
|
|
5074
|
+
{
|
|
5075
|
+
const sourceAnchor = asRecord3(values.xrAnchorValues.get(sourceEntityId));
|
|
5076
|
+
let anchor = world.getComponent(targetEntityId, XRAnchorComponent);
|
|
5077
|
+
if (sourceAnchor && !anchor) {
|
|
5078
|
+
anchor = new XRAnchorComponent();
|
|
5079
|
+
world.addComponent(targetEntityId, anchor);
|
|
5080
|
+
}
|
|
5081
|
+
if (sourceAnchor && anchor) {
|
|
5082
|
+
if (typeof sourceAnchor.enabled === "boolean") {
|
|
5083
|
+
anchor.enabled = sourceAnchor.enabled;
|
|
5084
|
+
}
|
|
5085
|
+
}
|
|
5086
|
+
}
|
|
5064
5087
|
{
|
|
5065
5088
|
const sourceInteractor = asRecord3(
|
|
5066
5089
|
values.xrInteractorValues.get(sourceEntityId)
|
|
@@ -15662,6 +15685,7 @@ exports.createSpriteComponent = createSpriteComponent;
|
|
|
15662
15685
|
exports.createTransformComponent = createTransformComponent;
|
|
15663
15686
|
exports.createVRTeleportAreaComponent = createVRTeleportAreaComponent;
|
|
15664
15687
|
exports.createVideoComponent = createVideoComponent;
|
|
15688
|
+
exports.createXRAnchorComponent = createXRAnchorComponent;
|
|
15665
15689
|
exports.createXRHandPoseComponent = createXRHandPoseComponent;
|
|
15666
15690
|
exports.createXRInteractableComponent = createXRInteractableComponent;
|
|
15667
15691
|
exports.createXRInteractorComponent = createXRInteractorComponent;
|