forge
Explore
Log in

Don't you dare go Hollow

🐛 burn_captions works with png_sequence, still and gif exports instead of calling them audio only

Browse files at this commit

6a8d9903e9d6ca7890764a2c5fcfd67ded0cc87dAhmet Kaan GümüşParent: bc73639
crates/engine/src/export.rsmodified+5 -0
@@ -315,6 +315,11 @@ impl Format {
315315 )
316316 }
317317
318+ /// Whether it shows a picture at all: a video format, or the PNG and GIF ones.
319+ pub fn shows_picture(self) -> bool {
320+ self.has_video() || matches!(self, Self::PngSequence | Self::Still | Self::Gif)
321+ }
322+
318323 /// Whether the picture in it is AV1 rather than H.264 -- which encoder runs
319324 /// and which of the two AV1 containers is being written are separate
320325 /// questions, and this is the first.
crates/mcp/src/tools/export.rsmodified+1 -1
@@ -1540,7 +1540,7 @@ fn export_start(srv: &mut Server, args: &Value) -> Reply {
15401540 Ok(v) => v,
15411541 Err(e) => return Reply::err(e),
15421542 };
1543- if burn.is_some() && sound_only {
1543+ if burn.is_some() && (!format.shows_picture() || (!has_picture && format.ext() == "mp4")) {
15441544 return Reply::err(format!(
15451545 "burn_captions draws into the picture, and {} is audio only: drop burn_captions, or export a video format",
15461546 format_name(format)