diff mbox series

[FFmpeg-devel,11/11] avformat/movenc: add s210 4:2:2 10-bit packed

Message ID 1636712536-13114-11-git-send-email-lance.lmwang@gmail.com
State New
Headers show
Series [FFmpeg-devel,01/11] avformat/rtpdec_rfc4175: use rawvideo for uyvy422 | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished
andriy/make_ppc success Make finished
andriy/make_fate_ppc success Make fate finished

Commit Message

Lance Wang Nov. 12, 2021, 10:22 a.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

S210 is not regiestered by official registration authority yet, so the
patch is just to help testing s210 encoder/decode locally.

Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
---
 libavformat/isom_tags.c | 1 +
 libavformat/movenc.c    | 1 +
 2 files changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/libavformat/isom_tags.c b/libavformat/isom_tags.c
index 62e6047..fccf140 100644
--- a/libavformat/isom_tags.c
+++ b/libavformat/isom_tags.c
@@ -58,6 +58,7 @@  const AVCodecTag ff_codec_movvideo_tags[] = {
     { AV_CODEC_ID_AVUI,   MKTAG('A', 'V', 'U', 'I') }, /* AVID Uncompressed deinterleaved UYVY422 */
     { AV_CODEC_ID_AVRP,   MKTAG('A', 'V', 'r', 'p') }, /* Avid 1:1 10-bit RGB Packer */
     { AV_CODEC_ID_AVRP,   MKTAG('S', 'U', 'D', 'S') }, /* Avid DS Uncompressed */
+    { AV_CODEC_ID_S210,   MKTAG('S', '2', '1', '0') }, /* 10-bit 4:2:2 packed */
     { AV_CODEC_ID_V210,   MKTAG('v', '2', '1', '0') }, /* uncompressed 10-bit 4:2:2 */
     { AV_CODEC_ID_V210,   MKTAG('b', 'x', 'y', '2') }, /* BOXX 10-bit 4:2:2 */
     { AV_CODEC_ID_V308,   MKTAG('v', '3', '0', '8') }, /* uncompressed  8-bit 4:4:4 */
diff --git a/libavformat/movenc.c b/libavformat/movenc.c
index 37d4403..e0c46cb 100644
--- a/libavformat/movenc.c
+++ b/libavformat/movenc.c
@@ -2125,6 +2125,7 @@  static int mov_write_video_tag(AVFormatContext *s, AVIOContext *pb, MOVMuxContex
 
     int uncompressed_ycbcr = ((track->par->codec_id == AV_CODEC_ID_RAWVIDEO && track->par->format == AV_PIX_FMT_UYVY422)
                            || (track->par->codec_id == AV_CODEC_ID_RAWVIDEO && track->par->format == AV_PIX_FMT_YUYV422)
+                           ||  track->par->codec_id == AV_CODEC_ID_S210
                            ||  track->par->codec_id == AV_CODEC_ID_V308
                            ||  track->par->codec_id == AV_CODEC_ID_V408
                            ||  track->par->codec_id == AV_CODEC_ID_V410