@vestra-player/sdk - v1.11.3
    Preparing search index...

    Interface SourceReference

    A remembered local file, from MediaSources: its token and what the player knows of it. Never its path or its content.

    1.7.8

    interface SourceReference {
        token: string;
        name: string;
        duration: number;
        status: "ok" | "missing" | "changed";
        video:
            | {
                codec: string;
                width: number;
                height: number;
                fps: number;
                pixelFormat: string
                | null;
            }
            | null;
        audio: { codec: string; sampleRate: number; channels: number }
        | null;
    }
    Index
    token: string

    The opaque token: this plugin's key for the file. Store it.

    name: string

    The file's name, for display.

    duration: number

    Its duration in seconds.

    status: "ok" | "missing" | "changed"

    ok; missing when no file is at its path any more (moved, renamed, deleted, a drive not connected); changed when the file there has another size or modification time than when it was remembered.

    video:
        | {
            codec: string;
            width: number;
            height: number;
            fps: number;
            pixelFormat: string
            | null;
        }
        | null

    Its video stream (the default one), null for none.

    Type Declaration

    • {
          codec: string;
          width: number;
          height: number;
          fps: number;
          pixelFormat: string | null;
      }
      • codec: string

        FFmpeg's codec name (h264, hevc, vp9, …).

      • width: number

        Width in pixels as stored (before the sample aspect ratio).

      • height: number

        Height in pixels.

      • fps: number

        Frames per second.

      • pixelFormat: string | null

        FFmpeg's pixel format (yuv420p, …), null when unknown.

    • null
    audio: { codec: string; sampleRate: number; channels: number } | null

    Its audio stream (the default one), null for none.

    Type Declaration

    • { codec: string; sampleRate: number; channels: number }
      • codec: string

        FFmpeg's codec name (aac, opus, …).

      • sampleRate: number

        Samples per second.

      • channels: number

        Channel count.

    • null