summaryrefslogtreecommitdiff
path: root/libavcodec/ljpegenc.c
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2014-03-12 14:31:51 +0100
committerVittorio Giovara <vittorio.giovara@gmail.com>2014-03-16 23:31:30 +0100
commitbf0d7da7cbbf869605086c2a47cdf87f0a533e24 (patch)
tree3cbbccebf5c9488f5495dcf8a6ed704927203564 /libavcodec/ljpegenc.c
parent2183432e6dc8aedf1ef3db63006a2a8195479abd (diff)
ljpeg: check color_range
Diffstat (limited to 'libavcodec/ljpegenc.c')
-rw-r--r--libavcodec/ljpegenc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/ljpegenc.c b/libavcodec/ljpegenc.c
index 7c1b3bc920..e111c8c557 100644
--- a/libavcodec/ljpegenc.c
+++ b/libavcodec/ljpegenc.c
@@ -266,7 +266,8 @@ static av_cold int ljpeg_encode_init(AVCodecContext *avctx)
if ((avctx->pix_fmt == AV_PIX_FMT_YUV420P ||
avctx->pix_fmt == AV_PIX_FMT_YUV422P ||
- avctx->pix_fmt == AV_PIX_FMT_YUV444P) &&
+ avctx->pix_fmt == AV_PIX_FMT_YUV444P ||
+ avctx->color_range == AVCOL_RANGE_MPEG) &&
avctx->strict_std_compliance > FF_COMPLIANCE_UNOFFICIAL) {
av_log(avctx, AV_LOG_ERROR,
"Limited range YUV is non-standard, set strict_std_compliance to "