fix: few bugs with image sequences

This commit is contained in:
Maya 2026-05-25 21:27:01 +03:00
parent 2d12ab42c0
commit 35949a6d04
No known key found for this signature in database
3 changed files with 3 additions and 7 deletions

View File

@ -614,6 +614,7 @@
type="checkbox"
class="!w-fit"
bind:checked={imageSequenceTransparency}
disabled={!imageSequence}
/>
<label for="extract-sequence" class="text-sm">
{m["convert.image_sequence.transparency"]()}

View File

@ -22,7 +22,7 @@ export function buildImageSequenceCommand(
const isAnimatedImage = animatedImageFormats.includes(outputFormat);
const enableTransparency = settings.imageSequenceTransparency ?? false;
if (videoFormats.includes(outputFormat)) {
if (videoFormats.includes(outputFormat) && !isAnimatedImage) {
const fpsFilter = `fps=${settings.imageSequenceFPS || 15}`;
const blackCompositeFilter =
`color=c=black,format=rgb24[bg];` +
@ -61,7 +61,7 @@ export function buildImageSequenceCommand(
baseArgs.push("-plays", "0");
if (enableTransparency) baseArgs.push("-pix_fmt", "rgba");
} else if (outputFormat === "webp") {
if (enableTransparency) baseArgs.push("-pix_fmt", "rgba");
if (enableTransparency) baseArgs.push("-pix_fmt", "bgra");
}
} else {
const pixFmt = enableTransparency ? "yuva420p" : "yuv420p";

View File

@ -112,11 +112,6 @@ export const toArgs = (ext: string, isAlac: boolean = false): string[] => {
break;
}
case "libvpx": {
args.push("-c:v", "libvpx-vp9");
break;
}
case "mpeg2video": {
// for mpeg, mpg, vob, mxf
if (ext === ".mxf") args.push("-ar", "48000"); // force 48kHz sample rate