C Specification

The XrSpatialComponentDataQueryResultEXT structure is defined as:

// Provided by XR_EXT_spatial_entity
typedef struct XrSpatialComponentDataQueryResultEXT {
    XrStructureType                     type;
    void*                               next;
    uint32_t                            entityIdCapacityInput;
    uint32_t                            entityIdCountOutput;
    XrSpatialEntityIdEXT*               entityIds;
    uint32_t                            entityStateCapacityInput;
    uint32_t                            entityStateCountOutput;
    XrSpatialEntityTrackingStateEXT*    entityStates;
} XrSpatialComponentDataQueryResultEXT;

Members

Member Descriptions
  • type is the XrStructureType of this structure.

  • next is NULL or a pointer to the next structure in a structure chain.

  • entityIdCapacityInput is the capacity of the entityIds array, or 0 to indicate a request to retrieve the required capacity.

  • entityIdCountOutput is the number of XrSpatialEntityIdEXT in entityIds, or the required capacity in the case that entityIdCapacityInput is insufficient.

  • entityIds is an array of XrSpatialEntityIdEXT. It can be NULL if entityIdCapacityInput is 0.

  • entityStateCapacityInput is the capacity of the entityStates array, or 0 to indicate a request to retrieve the required capacity.

  • entityStateCountOutput is the number of XrSpatialEntityTrackingStateEXT in entityStates, or the required capacity in the case that entityStateCapacityInput is insufficient. This must always be the same as entityIdCountOutput.

  • entityStates is an array of XrSpatialEntityTrackingStateEXT. It can be NULL if entityStateCapacityInput is 0.

  • See the https://registry.khronos.org/OpenXR/specs/1.1/html/xrspec.html#fundamentals-buffer-size-parameters section for a detailed description of retrieving the required entityIds size.

Description

An application can use the entityIds with xrCreateSpatialEntityFromIdEXT to create XrSpatialEntityEXT handles for the entities it is interested in getting regular updates for. The application can then use these XrSpatialEntityEXT handles with xrCreateSpatialUpdateSnapshotEXT to create an update snapshot that has the runtime’s latest known data of the components for the provided entities.

Valid Usage (Implicit)

See Also

Document Notes

For more information, see the OpenXR Specification

This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.

Copyright 2014-2025 The Khronos Group Inc.