feat(anki): add media timing review before card creation (#203)

This commit is contained in:
2026-09-04 01:40:56 -07:00
committed by GitHub
parent 99266294b8
commit 84f718043a
78 changed files with 7022 additions and 135 deletions
+10
View File
@@ -11,6 +11,12 @@ export type MediaInput =
source?: string;
inputOptions?: MediaInputOptions;
singleResolvedStream?: boolean;
/**
* The file keeps the original media timestamps instead of starting at zero (a
* stream-copied window of a longer source). Seek with `-ss` against those
* absolute timestamps rather than relative to the file's own start time.
*/
absoluteTimestamps?: boolean;
};
export type NormalizedMediaInput = {
@@ -89,6 +95,10 @@ export function normalizeMediaInput(input: MediaInput): NormalizedMediaInput {
inputArgs.push('-headers', headers);
}
if (input.absoluteTimestamps) {
inputArgs.push('-seek_timestamp', '1');
}
return {
path: input.path,
inputArgs,