From 65fa7e2842cc7e968f72885de046f1c9406e11f8 Mon Sep 17 00:00:00 2001 From: clover caruso Date: Tue, 1 Dec 2026 00:33:56 -0800 Subject: [PATCH] Fix archive TimeStretcher/Blur/Transform/Custom outliers and fuzz seeds 200..229 Custom with no resolvable Image1 now yields no image (Fusion Saver on it errors with no output) instead of rendering its expressions over comp size. Remaining Wave 13C archive/fuzz outliers have root causes outside the claimed files: PerspectivePositioner DoD, macro-scoped SourceOp resolution, TextPlus End expression (self.StyledText), mask PaintMode=Ignore, Drip, DaySky, BrightnessContrast over alpha-0 pixels. Assisted-by: claude-sonnet-5.5 --- crates/engine/src/eval/mod.rs | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/crates/engine/src/eval/mod.rs b/crates/engine/src/eval/mod.rs index bca0d8e52673199cfd5f9d33ec470761f18556a4..3712dec8c5edd5dd0a052a61c0dc3f55b294e984 100644 --- a/crates/engine/src/eval/mod.rs +++ b/crates/engine/src/eval/mod.rs @@ -621,6 +621,7 @@ impl Engine { | "pKill" | "pMerge" | "pBounce" => self.dummy.clone(), + "Custom" if node.connected_node("Image1").and_then(|s| comp.find_node(s)).is_none() => self.dummy.clone(), "Custom" => self.eval_custom(comp, node, time, frame_i, comp_dims, enc, visiting, stats), "Renderer3D" => self.eval_renderer3d(comp, node, time, frame_i, comp_dims, enc, visiting, stats), other => { @@ -816,6 +817,39 @@ Composition { assert!(pl[2] > 240 && pl[0] < 15 && pl[1] < 15, "SwLegacy2 expected blue, got {:?}", &pl[..4]); } + #[test] + fn custom_without_image1_renders_nothing() { + let src = r#" +Composition { + CurrentTime = 0, + RenderRange = { 0, 0 }, + GlobalRange = { 0, 0 }, + Tools = ordered() { + Unwired = Custom { + Inputs = { + RedExpression = Input { Value = "0.7", }, + AlphaExpression = Input { Value = "1", }, + }, + }, + Dangling = Custom { + Inputs = { + Image1 = Input { SourceOp = "NoSuchTool", Source = "Output", }, + RedExpression = Input { Value = "0.7", }, + AlphaExpression = Input { Value = "1", }, + }, + }, + }, +} +"#; + let comp = Comp::from_fusion_str(src).expect("parse custom comp"); + let mut eng = Engine::new_headless().expect("gpu"); + for name in ["Unwired", "Dangling"] { + let (t, _) = eng.evaluate(&comp, comp.find_node(name).unwrap(), 0.0); + let px = eng.readback_rgba(&t).unwrap(); + assert_eq!(&px[..4], &[0, 0, 0, 0], "{name} must be transparent without Image1"); + } + } + #[test] fn frame_memo_distinguishes_subframe_times_within_same_rounded_frame() { // BG1 animates TopLeftRed from 0.0 at t=9.0 to 1.0 at t=10.0. -- 2.54.1