diff mbox series

[FFmpeg-devel,v2,4/4] avformat/rtpdec_rfc4175: add support for RANGE

Message ID 1633969392-17937-4-git-send-email-lance.lmwang@gmail.com
State Accepted
Commit fb4f9a204399e48d1567164ff7e7b348095cc37a
Headers show
Series [FFmpeg-devel,v2,1/4] avformat/rtpdec_rfc4175: add support for exactframerate
Related show

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

Limin Wang Oct. 11, 2021, 4:23 p.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

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

Patch

diff --git a/libavformat/rtpdec_rfc4175.c b/libavformat/rtpdec_rfc4175.c
index 93607d7..f50cad7 100644
--- a/libavformat/rtpdec_rfc4175.c
+++ b/libavformat/rtpdec_rfc4175.c
@@ -118,6 +118,11 @@  static int rfc4175_parse_fmtp(AVFormatContext *s, AVStream *stream,
             stream->codecpar->color_primaries = AVCOL_PRI_BT2020;
             stream->codecpar->color_space     = AVCOL_SPC_BT2020_NCL;
         }
+    } else if (!strncmp(attr, "RANGE", 5)) {
+        if (!strncmp(value, "NARROW", 6))
+            stream->codecpar->color_range = AVCOL_RANGE_MPEG;
+        else if (!strncmp(value, "FULL", 4))
+            stream->codecpar->color_range = AVCOL_RANGE_JPEG;
     }
 
     return 0;