import { type ProcessCommand } from "./process.js";
import type { SlideImage } from "./types.js";
export type FfmpegVfrArgs = ["-fps_mode" | "-vsync", "vfr"];
export type SceneSegment = {
    start: number;
    end: number | null;
};
export declare function clamp(value: number, min: number, max: number): number;
export declare function parseShowinfoTimestamp(line: string): number | null;
export declare function resolveFfmpegVfrArgs({ ffmpegPath, timeoutMs, }: {
    ffmpegPath: ProcessCommand;
    timeoutMs: number;
}): Promise<FfmpegVfrArgs>;
export declare function resolveExtractedTimestamp({ requested, actual, seekBase, }: {
    requested: number;
    actual: number | null;
    seekBase?: number | null;
}): number;
export declare function roundThreshold(value: number): number;
export declare function calibrateSceneThreshold({ ffmpegPath, inputPath, durationSeconds, sampleCount, timeoutMs, logSlides, }: {
    ffmpegPath: ProcessCommand;
    inputPath: string;
    durationSeconds: number | null;
    sampleCount: number;
    timeoutMs: number;
    logSlides?: ((message: string) => void) | null;
}): Promise<{
    threshold: number;
    confidence: number;
}>;
export declare function buildSegments(durationSeconds: number | null, workers: number): Array<{
    start: number;
    duration: number;
}>;
export declare function detectSceneTimestamps({ ffmpegPath, inputPath, threshold, timeoutMs, vfrArgs, segments, workers, onSegmentProgress, runWithConcurrency, }: {
    ffmpegPath: ProcessCommand;
    inputPath: string;
    threshold: number;
    timeoutMs: number;
    vfrArgs: FfmpegVfrArgs;
    segments?: Array<{
        start: number;
        duration: number;
    }>;
    workers?: number;
    onSegmentProgress?: ((completed: number, total: number) => void) | null;
    runWithConcurrency: <T>(tasks: Array<() => Promise<T>>, workers: number, onProgress?: ((completed: number, total: number) => void) | null) => Promise<T[]>;
}): Promise<number[]>;
export declare function applyMinDurationFilter(slides: SlideImage[], minDurationSeconds: number, warnings: string[], removeFile: (path: string) => void): SlideImage[];
export declare function mergeTimestamps(sceneTimestamps: number[], intervalTimestamps: number[], minDurationSeconds: number): number[];
export declare function filterTimestampsByMinDuration(timestamps: number[], minDurationSeconds: number): number[];
export declare function buildSceneSegments(sceneTimestamps: number[], durationSeconds: number | null): SceneSegment[];
export declare function findSceneSegment(segments: SceneSegment[], timestamp: number): SceneSegment | null;
export declare function adjustTimestampWithinSegment(timestamp: number, segment: SceneSegment | null): number;
export declare function selectTimestampTargets({ targets, sceneTimestamps, minDurationSeconds, intervalSeconds, }: {
    targets: number[];
    sceneTimestamps: number[];
    minDurationSeconds: number;
    intervalSeconds: number;
}): number[];
export declare function buildIntervalTimestamps({ durationSeconds, minDurationSeconds, maxSlides, }: {
    durationSeconds: number | null;
    minDurationSeconds: number;
    maxSlides: number;
}): {
    timestamps: number[];
    intervalSeconds: number;
} | null;
export declare function probeVideoInfo({ ffprobePath, inputPath, timeoutMs, }: {
    ffprobePath: ProcessCommand;
    inputPath: string;
    timeoutMs: number;
}): Promise<{
    durationSeconds: number | null;
    width: number | null;
    height: number | null;
}>;
export declare function applyMaxSlidesFilter<T extends {
    index: number;
    timestamp: number;
    imagePath: string;
}>(slides: T[], maxSlides: number, warnings: string[], removeFile: (path: string) => void): T[];
