API reference
API reference
Select your platform
No SDKs available
No versions available

OVRAnchorContainer Struct

Extends IOVRAnchorComponent< OVRAnchorContainer >, IEquatable< OVRAnchorContainer >
Represents a container for other OVRAnchors.
This component can be accessed from an OVRAnchor that supports it by calling OVRAnchor.GetComponent<T> from the anchor.
The anchor container is part of the Meta Quest Scene Model. Read more at Scene Overview.

Public Statics

A null representation of an OVRAnchorContainer.
Use this to compare with another component to determine whether it is null.

Properties

Whether this object represents a valid anchor component.
True if this component is enabled and no change to its enabled status is pending.
SpaceComponentType Type[Get]
ulong Handle[Get]
Uuids of the anchors contained by this Anchor Container.
The UUIDs can be passed to OVRAnchor.FetchAnchorsAsync(List<OVRAnchor>,OVRAnchor.FetchOptions,Action<List<OVRAnchor>,int>) to obtain runtime instances of those anchors. Alternatively, you can use FetchAnchorsAsync to combine this call with OVRAnchor.FetchAnchorsAsync(List<OVRAnchor>,OVRAnchor.FetchOptions,Action<List<OVRAnchor>,int>).
Exceptions
InvalidOperationException
If it fails to retrieve the Uuids, which could happen if the component is not supported or enabled.

Member Functions

Compares this component for equality with other .
Parameters
other
The other component to compare with.
Returns
True if both components belong to the same OVRAnchor, otherwise false.
Compares this component for equality with obj .
Parameters
obj
The object to compare with.
Returns
True if obj is an OVRAnchorContainer and Equals(OVRAnchorContainer) is true, otherwise false.
Gets a hashcode suitable for use in a Dictionary or HashSet.
Returns
A hashcode for this component.
Gets a string representation of this component.
Returns
A string representation of this component.
(Obsolete) Asynchronous method that fetches anchors contained by this Anchor Container.
Dispose of the returned OVRTask<bool> if you don't use the results
Parameters
anchors
List that will get cleared and populated with the requested anchors.
Deprecated
This method is obsolete. Use FetchAnchorsAsync instead.
Returns
Returns an OVRTask<bool> that will eventually let you test if the fetch was successful or not. If the result is true, then the anchors parameter has been populated with the requested anchors.
Exceptions
InvalidOperationException
If it fails to retrieve the Uuids
ArgumentNullException
If parameter anchors is null
Fetches anchors contained by this Anchor Container.
Dispose of the returned OVRTask if you don't use the results
Parameters
anchors
List that will get cleared and populated with the requested anchors.
Returns
Returns an OVRTask that will eventually let you test if the fetch was successful or not. If the result is true, then the anchors parameter has been populated with the requested anchors.
Exceptions
InvalidOperationException
If it fails to retrieve the Uuids
ArgumentNullException
If parameter anchors is null

Static Member Functions

Compares two components for equality.
Parameters
lhs
The component to compare with rhs .
rhs
The component to compare with lhs .
Returns
True if both components belong to the same OVRAnchor, otherwise false.
Compares two components for inequality.
Parameters
lhs
The component to compare with rhs .
rhs
The component to compare with lhs .
Returns
True if the components do not belong to the same OVRAnchor, otherwise false.
Did you find this page helpful?
Thumbs up icon
Thumbs down icon