From 83388aede27c36f82525c83b5d131143259c5ae2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ahmet=20Kaan=20G=C3=BCm=C3=BC=C5=9F?= Date: Wed, 2 Dec 2026 13:18:19 +0300 Subject: [PATCH] ec-aac test full_chain_low_band: downsampled SBR outputs at the core rate, so the core is compared as is, not 2x upsampled (fsaac48 now corr 1.000000 at lag -481) --- crates/ec-aac/tests/sbr_real_library/chunk_a.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/crates/ec-aac/tests/sbr_real_library/chunk_a.rs b/crates/ec-aac/tests/sbr_real_library/chunk_a.rs index 8f8978af..578dcaed 100644 --- a/crates/ec-aac/tests/sbr_real_library/chunk_a.rs +++ b/crates/ec-aac/tests/sbr_real_library/chunk_a.rs @@ -164,7 +164,11 @@ pub(super) fn full_chain_low_band_matches_own_core() { // sample-for-sample with the full-chain output's rate -- // crude, but a low-pass well below the core Nyquist erases the // stairstep artifacts this introduces. - let up = upsample_2x(&core[ch]); + let up = if full_rate == core_rate { + core[ch].clone() + } else { + upsample_2x(&core[ch]) + }; let cutoff = f64::from(core_rate) * 0.4; let keep = if full.len() > core.len() { mono_prefix(&full)