/*
    This file is part of jellything (https://codeberg.org/metamuffin/jellything)
    which is licensed under the GNU Affero General Public License (version 3); see /COPYING.
    Copyright (C) 2026 metamuffin <metamuffin.org>
*/
export type FragmentIndex = TimeRange[]
export interface TimeRange { start: number, end: number }
export interface SubtitleCue extends TimeRange {
    content: string
}
export interface StreamInfo {
    name?: string,
    duration: number,
    tracks: TrackInfo[],
}
export type TrackKind = "video" | "audio" | "subtitle"
export interface TrackInfo {
    name?: string,
    language?: string,
    kind: TrackKind,
    formats: FormatInfo[]
}
export type StreamContainer = "webm" | "matroska" | "mpeg4" | "jvtt" | "webvtt"
export interface FormatInfo {
    codec: string,
    bitrate: number,
    remux: boolean,
    containers: StreamContainer[]

    width?: number,
    height?: number,
    channels?: number,
    samplerate?: number,
    bit_depth?: number,
}
