@bitmovin/player-integration-webxr - v1.2.0
    Preparing search index...

    Interface VideoSampling

    Where a world-space direction lands in the video: what an effect drawn from the video needs to sample the frame the viewer sees, without uploading the video a second time. See BitmovinWebXR.getVideoSampling.

    The surface is a three.js SphereGeometry segment, so a point p on it, in the surface's own frame, sits at

    phi = atan2(p.z, -p.x), taken from phiStart theta = acos(p.y / radius) u = (phi - phiStart) / phiLength v = 1 - (theta - thetaStart) / thetaLength

    and (u, v) scaled by eye.repeat and moved by eye.offset is its texture coordinate. Outside 0..1, the direction misses the arc and shows the background.

    interface VideoSampling {
        texture: any;
        worldToSurface: any;
        radius: number;
        phiStart: number;
        phiLength: number;
        thetaStart: number;
        thetaLength: number;
        eye: { offset: { u: number; v: number }; repeat: { u: number; v: number } };
    }
    Index
    texture: any

    The texture the surfaces sample: the video's current frame. Shared with them; read it, never change or dispose it.

    worldToSurface: any

    From world space into the surface's own frame.

    radius: number

    The surface's radius, in meters.

    phiStart: number

    Where the arc starts around the vertical axis, in radians, as SphereGeometry takes it.

    phiLength: number

    How far the arc runs around the vertical axis, in radians.

    thetaStart: number

    Where the arc starts down from the upper pole, in radians.

    thetaLength: number

    How far the arc runs down from thetaStart, in radians.

    eye: { offset: { u: number; v: number }; repeat: { u: number; v: number } }

    The part of the frame one eye's picture fills. The whole frame for mono; the left eye's half for stereo.

    Type Declaration

    • offset: { u: number; v: number }

      Its lower left corner, in texture coordinates.

      • u: number

        Across, 0..1.

      • v: number

        Up, 0..1.

    • repeat: { u: number; v: number }

      Its size, in texture coordinates.

      • u: number

        Across, 0..1.

      • v: number

        Up, 0..1.