This extension allows persistence and retrieval of spatial anchors sharing and localization across application sessions on a device. Spatial anchors persisted during an application session on a device will only be able to be retrieved during sessions of that same application on the same device. This extension requires XR_MSFT_spatial_anchor to also be enabled.
| Modifier and Type | Field and Description |
|---|---|
| public static final int | XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT
Extends |
| public static final int | XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT
Extends |
| public static final int | XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT
XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT |
| public static final String | XR_MSFT_SPATIAL_ANCHOR_PERSISTENCE_EXTENSION_NAME
The extension name. |
| public static final int | XR_MSFT_spatial_anchor_persistence_SPEC_VERSION
The extension specification version. |
| public static final int | XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT
Extends |
| public static final int | XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT
Extends |
| public static final int | XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT
Extends |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public static int | nxrCreateSpatialAnchorFromPersistedNameMSFT(XrSession session, long spatialAnchorCreateInfo, long spatialAnchor)
Unsafe version of: |
| public static int | nxrCreateSpatialAnchorStoreConnectionMSFT(XrSession session, long spatialAnchorStore)
Unsafe version of: |
| public static int | nxrEnumeratePersistedSpatialAnchorNamesMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, int
the capacity of the spatialAnchorNamesCapacityInput, long spatialAnchorNamesCountOutput, long persistedAnchorNames)spatialAnchorNames array, or 0 to indicate a request to retrieve the required capacity.Unsafe version of: |
| public static int | nxrPersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, long spatialAnchorPersistenceInfo)
Unsafe version of: |
| public static int | nxrUnpersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, long spatialAnchorPersistenceName)
Unsafe version of: |
| public static int | xrClearSpatialAnchorStoreMSFT(XrSpatialAnchorStoreConnectionMSFT
XrSpatialAnchorStoreConnectionMSFT to perform the clear operation on.Clear all spatial anchors from the spatial anchor store. |
| public static int | xrCreateSpatialAnchorFromPersistedNameMSFT(XrSession
a handle to an session, XrSpatialAnchorFromPersistedAnchorCreateInfoMSFT XrSession previously created with CreateSession.a pointer to the spatialAnchorCreateInfo, PointerBuffer XrSpatialAnchorFromPersistedAnchorCreateInfoMSFT.a pointer to an spatialAnchor)XrSpatialAnchorMSFT handle that will be set by the runtime on successful load.Create a spatial anchor from the spatial anchor store by name. |
| public static int | xrCreateSpatialAnchorStoreConnectionMSFT(XrSession
the session, PointerBuffer XrSession the anchor was created with.a pointer to the spatialAnchorStore)XrSpatialAnchorStoreConnectionMSFT handle.Create a handle to track a connection to the spatial anchor store. |
| public static int | xrDestroySpatialAnchorStoreConnectionMSFT(XrSpatialAnchorStoreConnectionMSFT
the spatialAnchorStore)XrSpatialAnchorStoreConnectionMSFT to be destroyed.Destroys the anchor store handle. |
| public static int | xrEnumeratePersistedSpatialAnchorNamesMSFT(XrSpatialAnchorStoreConnectionMSFT
the spatialAnchorStore, IntBuffer XrSpatialAnchorStoreConnectionMSFT anchor store to perform the enumeration operation on.filled in by the runtime with the count of anchor names written or the required capacity in the case that spatialAnchorNamesCountOutput, XrSpatialAnchorPersistenceNameMSFT.spatialAnchorNamesCapacityInput is insufficient.a pointer to an array of persistedAnchorNamesXrSpatialAnchorPersistenceNameMSFT structures, but can be NULL if propertyCapacityInput is 0.Enumerate the names of currently persisted spatial anchors in the spatial anchor store. |
| public static int | xrPersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT
the spatialAnchorStore, XrSpatialAnchorPersistenceInfoMSFT XrSpatialAnchorStoreConnectionMSFT with which to persist the spatialAnchor.a pointer to spatialAnchorPersistenceInfo)XrSpatialAnchorPersistenceInfoMSFT structure to specify the anchor and its name to persist.Persist the spatial anchor in the spatial anchor store. |
| public static int | xrUnpersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT
an spatialAnchorStore, XrSpatialAnchorPersistenceNameMSFT XrSpatialAnchorStoreConnectionMSFT anchor store to perform the unpersist operation on.a pointer to the spatialAnchorPersistenceName)XrSpatialAnchorPersistenceNameMSFT.Removes an anchor from the store. |
| XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT | back to summary |
|---|---|
| public static final int XR_ERROR_SPATIAL_ANCHOR_NAME_INVALID_MSFT Extends Enum values: | |
| XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT | back to summary |
|---|---|
| public static final int XR_ERROR_SPATIAL_ANCHOR_NAME_NOT_FOUND_MSFT Extends Enum values: | |
| XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT | back to summary |
|---|---|
| public static final int XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT XR_MAX_SPATIAL_ANCHOR_NAME_SIZE_MSFT | |
| XR_MSFT_SPATIAL_ANCHOR_PERSISTENCE_EXTENSION_NAME | back to summary |
|---|---|
| public static final String XR_MSFT_SPATIAL_ANCHOR_PERSISTENCE_EXTENSION_NAME The extension name. | |
| XR_MSFT_spatial_anchor_persistence_SPEC_VERSION | back to summary |
|---|---|
| public static final int XR_MSFT_spatial_anchor_persistence_SPEC_VERSION The extension specification version. | |
| XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT | back to summary |
|---|---|
| public static final int XR_OBJECT_TYPE_SPATIAL_ANCHOR_STORE_CONNECTION_MSFT Extends | |
| XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT | back to summary |
|---|---|
| public static final int XR_TYPE_SPATIAL_ANCHOR_FROM_PERSISTED_ANCHOR_CREATE_INFO_MSFT Extends Enum values: | |
| XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT | back to summary |
|---|---|
| public static final int XR_TYPE_SPATIAL_ANCHOR_PERSISTENCE_INFO_MSFT Extends Enum values: | |
| MSFTSpatialAnchorPersistence | back to summary |
|---|---|
| protected MSFTSpatialAnchorPersistence() | |
| nxrCreateSpatialAnchorFromPersistedNameMSFT | back to summary |
|---|---|
| public static int nxrCreateSpatialAnchorFromPersistedNameMSFT(XrSession session, long spatialAnchorCreateInfo, long spatialAnchor) Unsafe version of: | |
| nxrCreateSpatialAnchorStoreConnectionMSFT | back to summary |
|---|---|
| public static int nxrCreateSpatialAnchorStoreConnectionMSFT(XrSession session, long spatialAnchorStore) Unsafe version of: | |
| nxrEnumeratePersistedSpatialAnchorNamesMSFT | back to summary |
|---|---|
| public static int nxrEnumeratePersistedSpatialAnchorNamesMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, int spatialAnchorNamesCapacityInput, long spatialAnchorNamesCountOutput, long persistedAnchorNames) Unsafe version of:
| |
| nxrPersistSpatialAnchorMSFT | back to summary |
|---|---|
| public static int nxrPersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, long spatialAnchorPersistenceInfo) Unsafe version of: | |
| nxrUnpersistSpatialAnchorMSFT | back to summary |
|---|---|
| public static int nxrUnpersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, long spatialAnchorPersistenceName) Unsafe version of: | |
| xrClearSpatialAnchorStoreMSFT | back to summary |
|---|---|
| public static int xrClearSpatialAnchorStoreMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore) Clear all spatial anchors from the spatial anchor store. C SpecificationThe application can use the
Valid Usage (Implicit)
Return Codes
| |
| xrCreateSpatialAnchorFromPersistedNameMSFT | back to summary |
|---|---|
| public static int xrCreateSpatialAnchorFromPersistedNameMSFT(XrSession session, XrSpatialAnchorFromPersistedAnchorCreateInfoMSFT spatialAnchorCreateInfo, PointerBuffer spatialAnchor) Create a spatial anchor from the spatial anchor store by name. C SpecificationThe application can use the
Valid Usage (Implicit)
Return Codes
See Also
| |
| xrCreateSpatialAnchorStoreConnectionMSFT | back to summary |
|---|---|
| public static int xrCreateSpatialAnchorStoreConnectionMSFT(XrSession session, PointerBuffer spatialAnchorStore) Create a handle to track a connection to the spatial anchor store. C SpecificationThe application can use the The
Valid Usage (Implicit)
Return Codes
| |
| xrDestroySpatialAnchorStoreConnectionMSFT | back to summary |
|---|---|
| public static int xrDestroySpatialAnchorStoreConnectionMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore) Destroys the anchor store handle. C SpecificationThe application can use the
Valid Usage (Implicit)
Thread Safety
Return Codes
| |
| xrEnumeratePersistedSpatialAnchorNamesMSFT | back to summary |
|---|---|
| public static int xrEnumeratePersistedSpatialAnchorNamesMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, IntBuffer spatialAnchorNamesCountOutput, XrSpatialAnchorPersistenceNameMSFT. Enumerate the names of currently persisted spatial anchors in the spatial anchor store. C SpecificationThe application can use the
Valid Usage (Implicit)
Return Codes
See Also
| |
| xrPersistSpatialAnchorMSFT | back to summary |
|---|---|
| public static int xrPersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, XrSpatialAnchorPersistenceInfoMSFT spatialAnchorPersistenceInfo) Persist the spatial anchor in the spatial anchor store. C SpecificationThe application can use the
Valid Usage (Implicit)
Return Codes
See Also
| |
| xrUnpersistSpatialAnchorMSFT | back to summary |
|---|---|
| public static int xrUnpersistSpatialAnchorMSFT(XrSpatialAnchorStoreConnectionMSFT spatialAnchorStore, XrSpatialAnchorPersistenceNameMSFT spatialAnchorPersistenceName) Removes an anchor from the store. C SpecificationThe application can use the
Valid Usage (Implicit)
Return Codes
See Also
| |