OpenXRMarkerTracker
Detected-marker type, size, ID and payload.
Spatial tracker for a detected marker. MarkerType determines interpretation: QR/Micro QR use string/bytes, ArUco/AprilTag use type, dictionary and MarkerId. BoundsSize/payload establish no valid pose; check inherited tracking state and default pose.
Setters change metadata only; they neither recognize images nor enable cameras. Map payloads to allowed application identifiers. Runtime support for every code type is not guaranteed.
Executed example and setup. Windows headless XR-off covered synthetic metadata/client logic: 23 API cases and an earlier 20 helper checks. Real discovery, entity/context RIDs, persistence, headsets and imagery remain untested. Do not dispose provider-owned trackers/poses/cached wrappers; dispose a newly owned tracker after use.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
OpenXRMarkerTrackerConstructor
public OpenXRMarkerTracker();Creates a caller-owned RefCounted tracker without starting OpenXR, registering with XRServer or detecting anything. Base state is Paused, category Anchor, entity/context RIDs empty. Real applications normally use the borrowed provider-registered tracker rather than a synthetic resource. Release your own instance after removing owned references/registration.
Properties3
BoundsSizeProperty
public Vector2 BoundsSize { get; set; }Stored marker size, initially Vector2.Zero. The setter only stores Vector2; it starts no camera, changes no tracker pose and creates no mesh/collider. Real size comes from the runtime; synthetic tracker metadata proves no detection.
MarkerIdProperty
public uint MarkerId { get; set; }Numeric uint marker ID, initially 0. Match ArUco/AprilTag with type and dictionary; neither a persistence UUID nor QR text. The setter only stores metadata; zero alone is not an error.
MarkerTypeProperty
public OpenXRSpatialComponentMarkerList.MarkerType MarkerType { get; set; }Marker type, initially Unknown. Runtime data can represent QR, Micro QR, ArUco or AprilTag; check support for each type. The setter changes metadata only; it starts no detector and selects no dictionary.
Methods8
GetBoundsSizeVector2
public Vector2 GetBoundsSize();Stored marker size, initially Vector2.Zero. The setter only stores Vector2; it starts no camera, changes no tracker pose and creates no mesh/collider. Real size comes from the runtime; synthetic tracker metadata proves no detection.
Vector2Stored marker size, initially Vector2.Zero. The setter only stores Vector2; it starts no camera, changes no tracker pose and creates no mesh/collider. Real size comes from the runtime; synthetic tracker metadata proves no detection.
GetMarkerDataVariant
public Variant GetMarkerData();Variant payload, initially Nil. QR/Micro QR provider data can be String or PackedByteArray; C# SetMarkerData can store other Variants too, so check VariantType before reading. Map allowed identifiers rather than treating arbitrary text as a path/code. The setter decodes no marker and resets the internal buffer ID.
VariantVariant payload, initially Nil. QR/Micro QR provider data can be String or PackedByteArray; C# SetMarkerData can store other Variants too, so check VariantType before reading. Map allowed identifiers rather than treating arbitrary text as a path/code. The setter decodes no marker and resets the internal buffer ID.
GetMarkerIduint
public uint GetMarkerId();Numeric uint marker ID, initially 0. Match ArUco/AprilTag with type and dictionary; neither a persistence UUID nor QR text. The setter only stores metadata; zero alone is not an error.
uintNumeric uint marker ID, initially 0. Match ArUco/AprilTag with type and dictionary; neither a persistence UUID nor QR text. The setter only stores metadata; zero alone is not an error.
GetMarkerTypeOpenXRSpatialComponentMarkerList.MarkerType
public OpenXRSpatialComponentMarkerList.MarkerType GetMarkerType();Marker type, initially Unknown. Runtime data can represent QR, Micro QR, ArUco or AprilTag; check support for each type. The setter changes metadata only; it starts no detector and selects no dictionary.
OpenXRSpatialComponentMarkerList.MarkerTypeMarker type, initially Unknown. Runtime data can represent QR, Micro QR, ArUco or AprilTag; check support for each type. The setter changes metadata only; it starts no detector and selects no dictionary.
SetBoundsSizevoid
public void SetBoundsSize(Vector2 boundsSize);Stored marker size, initially Vector2.Zero. The setter only stores Vector2; it starts no camera, changes no tracker pose and creates no mesh/collider. Real size comes from the runtime; synthetic tracker metadata proves no detection.
| Name | Type | Default |
|---|---|---|
boundsSize | Vector2 | — |
boundsSizeStored marker size, initially Vector2.Zero. The setter only stores Vector2; it starts no camera, changes no tracker pose and creates no mesh/collider. Real size comes from the runtime; synthetic tracker metadata proves no detection.
SetMarkerDatavoid
public void SetMarkerData(Variant markerData);Variant payload, initially Nil. QR/Micro QR provider data can be String or PackedByteArray; C# SetMarkerData can store other Variants too, so check VariantType before reading. Map allowed identifiers rather than treating arbitrary text as a path/code. The setter decodes no marker and resets the internal buffer ID.
| Name | Type | Default |
|---|---|---|
markerData | Variant | — |
markerDataVariant payload, initially Nil. QR/Micro QR provider data can be String or PackedByteArray; C# SetMarkerData can store other Variants too, so check VariantType before reading. Map allowed identifiers rather than treating arbitrary text as a path/code. The setter decodes no marker and resets the internal buffer ID.
SetMarkerIdvoid
public void SetMarkerId(uint markerId);Numeric uint marker ID, initially 0. Match ArUco/AprilTag with type and dictionary; neither a persistence UUID nor QR text. The setter only stores metadata; zero alone is not an error.
| Name | Type | Default |
|---|---|---|
markerId | uint | — |
markerIdNumeric uint marker ID, initially 0. Match ArUco/AprilTag with type and dictionary; neither a persistence UUID nor QR text. The setter only stores metadata; zero alone is not an error.
SetMarkerTypevoid
public void SetMarkerType(OpenXRSpatialComponentMarkerList.MarkerType markerType);Marker type, initially Unknown. Runtime data can represent QR, Micro QR, ArUco or AprilTag; check support for each type. The setter changes metadata only; it starts no detector and selects no dictionary.
| Name | Type | Default |
|---|---|---|
markerType | OpenXRSpatialComponentMarkerList.MarkerType | — |
markerTypeMarker type, initially Unknown. Runtime data can represent QR, Micro QR, ArUco or AprilTag; check support for each type. The setter changes metadata only; it starts no detector and selects no dictionary.