Lens Scripting API
    Preparing search index...

    Holds a reference to the world camera.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    cameraComponent: Camera
    cameraTransform: Transform
    getInstance: () => WorldCameraFinderProvider

    Methods

    • Returns the back vector of the camera. This is actually the front vector because the camera is reversed in Lens Studio.

      Returns vec3

    • Returns the forward vector of the camera. This is actually the back vector because the camera is reversed in Lens Studio.

      Returns vec3

    • Parameters

      • x: number

        the magnitude to multiply the camera's forward direction by

      • parallelToGround: boolean = false

        if the camera's forward direction should be projected to be parallel to ground

      Returns vec3

      a position in world space in front of the camera by x units

    • Parameters

      • worldPosition: vec3

        vec3 representing the position in world space

      Returns boolean

      whether a position is in camera FoV or not

    • Returns the camera's world position projected from screen space coordinates at a given z depth

      Parameters

      • x: number
      • y: number
      • absoluteDepth: number

      Returns vec3