diff --git a/crates/automation/src/confine.rs b/crates/automation/src/confine.rs index 6d8ce2819..c24f62acb 100644 --- a/crates/automation/src/confine.rs +++ b/crates/automation/src/confine.rs @@ -401,6 +401,11 @@ impl FootageSource for ConfinedFootage { fn called_off(&self) -> bool { self.inner.called_off() } + /// The files read inside the roots, as the inner source notes them (footage outside reads + /// nothing). + fn recording(&self, reads: &effectcraft_engine::render::reads::ReadLog, f: &mut dyn FnMut()) { + self.inner.recording(reads, f) + } } /// The session's file reads, only inside the read roots: what a project or an imported file diff --git a/crates/media/src/reads/tests.rs b/crates/media/src/reads/tests.rs index f9079820f..8fee7d211 100644 --- a/crates/media/src/reads/tests.rs +++ b/crates/media/src/reads/tests.rs @@ -112,9 +112,16 @@ fn a_sequence_frame_reports_only_its_own_file() { assert_stamps_match_disk(&files); assert_eq!(crate::opens_under(&dir) - opened, 1, "one file opened: the frame's"); assert_eq!(crate::opens_under(&unused_dir), 0, "the unused sequence was not looked at"); - // Another frame reads its own file. - let (_, files) = render(&p, &pool, &cache, cid, 4); + // Another frame reads its own file, also through the viewer's wrapper of the pool. + let viewer = effectcraft_render::CancellableFootage { inner: &pool, cancel: Default::default() }; + let log = ReadLog::new(); + let mut r = Renderer::new(&p, &viewer, RenderOpts::default()); + r.cache = Some(&cache); + r.reads = Some(&log); + r.comp_frame(cid, RATE.tick_of(4)); + let files = log.into_files(); assert_eq!(paths(&files), [frame_4]); + assert!(files.is_complete()); let _ = std::fs::remove_dir_all(&dir); }