Commit 99086073 authored by Michael Niedermayer's avatar Michael Niedermayer

Merge remote-tracking branch 'qatar/master'

* qatar/master:
  utvideodec: Set colorspace by codec_tag.
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 42b8296f 252ee3d3
...@@ -507,22 +507,24 @@ static av_cold int decode_init(AVCodecContext *avctx) ...@@ -507,22 +507,24 @@ static av_cold int decode_init(AVCodecContext *avctx)
case MKTAG('U', 'L', 'Y', '0'): case MKTAG('U', 'L', 'Y', '0'):
c->planes = 3; c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV420P; avctx->pix_fmt = AV_PIX_FMT_YUV420P;
avctx->colorspace = AVCOL_SPC_BT470BG;
break; break;
case MKTAG('U', 'L', 'Y', '2'): case MKTAG('U', 'L', 'Y', '2'):
c->planes = 3; c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV422P; avctx->pix_fmt = AV_PIX_FMT_YUV422P;
avctx->colorspace = AVCOL_SPC_BT470BG;
break; break;
case MKTAG('U', 'L', 'H', '0'): case MKTAG('U', 'L', 'H', '0'):
c->planes = 3; c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV420P;
avctx->color_primaries = AVCOL_PRI_BT709; avctx->color_primaries = AVCOL_PRI_BT709;
avctx->colorspace = AVCOL_SPC_BT709; avctx->colorspace = AVCOL_SPC_BT709;
avctx->pix_fmt = AV_PIX_FMT_YUV420P;
break; break;
case MKTAG('U', 'L', 'H', '2'): case MKTAG('U', 'L', 'H', '2'):
c->planes = 3; c->planes = 3;
avctx->pix_fmt = AV_PIX_FMT_YUV422P;
avctx->color_primaries = AVCOL_PRI_BT709; avctx->color_primaries = AVCOL_PRI_BT709;
avctx->colorspace = AVCOL_SPC_BT709; avctx->colorspace = AVCOL_SPC_BT709;
avctx->pix_fmt = AV_PIX_FMT_YUV422P;
break; break;
default: default:
av_log(avctx, AV_LOG_ERROR, "Unknown Ut Video FOURCC provided (%08X)\n", av_log(avctx, AV_LOG_ERROR, "Unknown Ut Video FOURCC provided (%08X)\n",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment