Options for adding a trackable image marker via WebXRImageTracking.addImage. A convenience shape that also accepts a plain Object3D for object.

interface WebXRImageTrackingOptions {
    asPrimary?: boolean;
    createObjectInstance?: boolean;
    hideWhenTrackingIsLost?: boolean;
    imageDoesNotMove?: boolean;
    object: Object3D<Object3DEventMap> | AssetReference;
    url?: string;
    widthInMeters?: number;
}

Properties

asPrimary?: boolean

Make this the primary marker (used in QuickLook fallback mode).

false
createObjectInstance?: boolean

Create a new instance of the object for each detection.

false
hideWhenTrackingIsLost?: boolean

Hide the object when tracking is lost.

true
imageDoesNotMove?: boolean

Enable for static markers (walls/floor) to improve tracking stability.

false
object: Object3D<Object3DEventMap> | AssetReference

The 3D object (or AssetReference) to display when the marker is detected.

url?: string

URL to the marker image to track. Use high-contrast images with unique features for reliable tracking.

widthInMeters?: number

Physical width of the printed marker in meters. Must match the real marker size.

0.25