diff --git a/src/mp4box/trun.rs b/src/mp4box/trun.rs index efbb2b0..3ca2989 100644 --- a/src/mp4box/trun.rs +++ b/src/mp4box/trun.rs @@ -55,6 +55,11 @@ impl TrunBox { if TrunBox::FLAG_SAMPLE_CTS & self.flags > 0 { sum += 4 * self.sample_count as u64; } + + sum += (4 * self.sample_durations.len()) as u64; + sum += (4 * self.sample_sizes.len()) as u64; + sum += (4 * self.sample_flags.len()) as u64; + sum += (4 * self.sample_cts.len()) as u64; sum } }