Lens Scripting API

    Class MarkerAsset

    Represents a texture to be tracked with MarkerTrackingComponent.

    Marker Tracking guide.

    // Set the MarkerAsset on a MarkerTracking component

    //@input Component.MarkerTrackingComponent markerTracker
    //@input Asset.MarkerAsset marker

    script.markerTracker.marker = script.marker;

    Hierarchy (View Summary, Expand)

    Index

    Constructors

    Properties

    height: number

    The height of the marker asset in real-life centimeters. Used to provide accurate transformation. A MarkerTrackingComponent using this MarkerAsset will be scaled so that one unit in the SceneObject's local space is equal to one centimeter in real life.

    name: string

    The name of the Asset in Lens Studio.

    uniqueIdentifier: string

    Methods

    • Returns the aspect ratio (width / height) of the texture used by the marker asset.

      Returns number

    • Returns the name of this object's type.

      Returns string

    • Returns true if the object matches or derives from the passed in type.

      Parameters

      • type: string

      Returns boolean

    • Returns true if this object is the same as other. Useful for checking if two references point to the same thing.

      Parameters

      Returns boolean

    MMNEPVFCICPMFPCPTTAAATR