[FFmpeg-cvslog] utvideodec: Set colorspace by codec_tag.
Yusuke Nakamura
git at videolan.org
Mon Jun 10 10:47:56 CEST 2013
ffmpeg | branch: master | Yusuke Nakamura <muken.the.vfrmaniac at gmail.com> | Sun Jun 9 00:16:27 2013 +0900| [252ee3d39b899f5bf11af4b5d6d7f117f622a9d7] | committer: Kostya Shishkov
utvideodec: Set colorspace by codec_tag.
Signed-off-by: Kostya Shishkov <kostya.shishkov at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=252ee3d39b899f5bf11af4b5d6d7f117f622a9d7
---
libavcodec/utvideodec.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/libavcodec/utvideodec.c b/libavcodec/utvideodec.c
index 129034b..bd67f9e 100644
--- a/libavcodec/utvideodec.c
+++ b/libavcodec/utvideodec.c
@@ -511,18 +511,22 @@ static av_cold int decode_init(AVCodecContext *avctx)
case MKTAG('U', 'L', 'Y', '0'):
c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV420P;
+ avctx->colorspace = AVCOL_SPC_BT470BG;
break;
case MKTAG('U', 'L', 'Y', '2'):
c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV422P;
+ avctx->colorspace = AVCOL_SPC_BT470BG;
break;
case MKTAG('U', 'L', 'H', '0'):
c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV420P;
+ avctx->colorspace = AVCOL_SPC_BT709;
break;
case MKTAG('U', 'L', 'H', '2'):
c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV422P;
+ avctx->colorspace = AVCOL_SPC_BT709;
break;
default:
av_log(avctx, AV_LOG_ERROR, "Unknown Ut Video FOURCC provided (%08X)\n",
More information about the ffmpeg-cvslog
mailing list