Fix JOC passthrough layout and no-previous-state interpolation

Interpolate the second half of a two-data-point frame from dp0 to dp1 when
the object has no previous matrix; a single data point keeps the hard cut.

Rebuild the passthrough frame as the 8-plane core order L, R, C, LFE, Ls,
Rs, (Lrs, Rrs) written to output slots 0..7, all delayed by 1217 samples,
and keep that 8-plane history updated on every frame. Frames without JOC
metadata always take this passthrough path, and a core channel count
change clears the LFE ring while keeping the clipgain ramp state.

Reject unsupported downmix configurations with a structured variant error
in the metadata scan, and score ID14 payloads by the frame status instead
of accepting any lenient parse.

Update the math notes and README for the two-data-point interpolation
without a previous state and the 8-plane passthrough output.
This commit is contained in:
TheM14 committed 2026-11-06 11:53:05 +08:00
1 parent 0820444f45
commit 17e52a531c
7 files changed
+68 -34

No files matched your search

+5 -5
View File
@@ -191,11 +191,9 @@ $$
### 3.2 单数据点插值
令上一帧末值为 $P_{o,c,b}$,当前目标值为 $D_{o,c,p(b)}$。对象没有 previous 状态时
(整条流第一帧或对象首次出现),24 个时槽直接取当前目标(硬切,不从零淡入):
$$
M_{o,c,b,t}=D_{o,c,p(b)},\qquad t=0\ldots23.
$$
(整条流第一帧或对象首次出现):单数据点情形 24 个时槽恒为 $D_{o,c,p(b)}$(硬切,
不从零淡入);双数据点情形前 12 个时槽为 $D_0$,后 12 个时槽按 §3.3 的第二段公式
从 $D_0$ 插值到 $D_1$(把该节的 $P$ 取为 $D_0$)。
有 previous 状态时,对时槽 $t=0\ldots23$:
@@ -232,6 +230,8 @@ D_{0}, & t=11,\\[1mm]
\end{cases}
$$
没有 previous 状态时同样使用上面的公式,只是把 $P_{o,c,b}$ 取为 $D_0$。
阶跃模式(`slope_idx=1`)在指定时槽直接切换目标:$t<o_0$ 保持上一帧末值 $P_{o,c,b}$
(没有 previous 时取 $D_0$),$o_0\le t<o_1$ 取 $D_0$,$t\ge o_1$ 取 $D_1$;
单数据点时 $t<o_0$ 保持 $P$、$t\ge o_0$ 取 $D_0$。