aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Almer <jamrial@gmail.com>2024-06-17 11:20:57 -0300
committerJames Almer <jamrial@gmail.com>2024-06-19 10:12:50 -0300
commit4e608e90eb9a05e92d7f2ae92065e2898b0fbe0e (patch)
tree5db252bfe21cb97393daf0ff19acbb29e92be72c
parent5191339f74652ce3b72a4bf6f135854bb1b103ae (diff)
downloadffmpeg-4e608e90eb9a05e92d7f2ae92065e2898b0fbe0e.tar.gz
avformat/evc: fix writing reserved bits
They are all zeroes, not ones. Signed-off-by: James Almer <jamrial@gmail.com>
-rw-r--r--libavformat/evc.c6
-rw-r--r--tests/ref/lavf-fate/evc.mp42
2 files changed, 4 insertions, 4 deletions
diff --git a/libavformat/evc.c b/libavformat/evc.c
index 928ae1ff65..6a63630b0c 100644
--- a/libavformat/evc.c
+++ b/libavformat/evc.c
@@ -257,10 +257,10 @@ static int evcc_write(AVIOContext *pb, EVCDecoderConfigurationRecord *evcc)
avio_wb16(pb, evcc->pic_height_in_luma_samples);
/*
- * bit(6) reserved = '111111'b;
- * unsigned int(2) chromaFormat;
+ * unsigned int(6) reserved = '000000'b;
+ * unsigned int(2) lengthSizeMinusOne;
*/
- avio_w8(pb, evcc->lengthSizeMinusOne | 0xfc);
+ avio_w8(pb, evcc->lengthSizeMinusOne & 0x3);
/* unsigned int(8) numOfArrays; */
avio_w8(pb, evcc->num_of_arrays);
diff --git a/tests/ref/lavf-fate/evc.mp4 b/tests/ref/lavf-fate/evc.mp4
index 4b410b84f3..6ef7af4ddc 100644
--- a/tests/ref/lavf-fate/evc.mp4
+++ b/tests/ref/lavf-fate/evc.mp4
@@ -1,3 +1,3 @@
-885fb330b20632b88ef9d7fb03dfa2e9 *tests/data/lavf-fate/lavf.evc.mp4
+bebb66fc3e13ece081d1aa96802e3c1f *tests/data/lavf-fate/lavf.evc.mp4
37386 tests/data/lavf-fate/lavf.evc.mp4
tests/data/lavf-fate/lavf.evc.mp4 CRC=0x48063f85