/** * Pure helper for composing a single thumbnail frame: pull a frame at * `atSec` and burn a headline on top with ffmpeg drawtext. * * Extracted from compose-thumbnail.ts so `compose_thumbnail_variants` * can call the same logic three times without duplicating the drawtext * filter construction. */ export interface ComposeThumbnailOpts { /** Source video path (already absolute or pre-resolved). */ input: string; /** Output .jpg/.png absolute path. */ output: string; /** Frame timestamp. */ atSec: number; /** Headline text overlay (raw — escaping is handled internally). */ text: string; /** Path to a TTF font; falls back to common system locations. */ fontFile?: string; fontSize?: number; fontColor?: string; /** Empty string disables outline. Default 'black'. */ outlineColor?: string; position?: "top" | "center" | "bottom"; /** Optional output width (height auto). */ width?: number; signal?: AbortSignal; } export interface ComposeThumbnailResult { ok: true; path: string; fontFile: string; } /** * Burn a headline onto a single frame from the source video and write * it to disk. Returns the resolved font path so callers can surface it * in their output. * * Throws on: * - no system font found (and none provided) * - ffmpeg drawtext exit ≠ 0 */ export declare function composeThumbnailFrame(opts: ComposeThumbnailOpts, cwd?: string): Promise; export declare function pickFont(): string | undefined; /** * Escape a string for ffmpeg drawtext's `text='...'` parameter. * * Rules (verified against real-world implementations): * 1. `\\` first → `\\\\` * 2. `:` → `\\:` * 3. `'` → `\\'` * 4. `%` → `\\%` (because `%{...}` is used for runtime expansions) * 5. newlines → literal `\\n` (drawtext renders as a line break) * * Backslash MUST come first so subsequent escapes don't double-escape. */ export declare function escapeDrawtextValue(text: string): string; //# sourceMappingURL=thumbnail-compose.d.ts.map