From d2541edc544b66365eb57f81d25777975ba6f8cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?William=20B=C3=A9rub=C3=A9?= Date: Mon, 12 Aug 2024 14:15:17 -0400 Subject: [PATCH] (Continued) --- src/mp4/moov.c | 2 +- src/mp4/mp4.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mp4/moov.c b/src/mp4/moov.c index c442315..bca9f15 100644 --- a/src/mp4/moov.c +++ b/src/mp4/moov.c @@ -193,7 +193,7 @@ enum BufError write_mvhd(struct BitBuf *ptr, const struct MoovInfo *moov_info) { chk_err; // 4 Selection duration err = put_u32_be(ptr, 0); chk_err; // 4 Current time - err = put_u32_be(ptr, 2); + err = put_u32_be(ptr, 3); chk_err; // 4 Next track ID err = put_u32_be_to_offset(ptr, start_atom, ptr->offset - start_atom); diff --git a/src/mp4/mp4.c b/src/mp4/mp4.c index e3668ca..33dc3d9 100644 --- a/src/mp4/mp4.c +++ b/src/mp4/mp4.c @@ -106,7 +106,7 @@ enum BufError mp4_set_slice(const char *nal_data, const uint32_t nal_len, samples_info[0].duration = default_sample_size; samples_info[0].flags = is_iframe ? 0 : 65536; samples_info[1].size = buf_aud.offset; - samples_info[1].duration = buf_aud.offset / aud_framesize * aud_samplerate; + samples_info[1].duration = default_sample_size; buf_moof.offset = 0; err = write_moof(