aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Garrett-Glaser <darkshikari@gmail.com>2010-12-07 09:51:27 +0000
committerJason Garrett-Glaser <darkshikari@gmail.com>2010-12-07 09:51:27 +0000
commit3cf8db9447a6c77550033acea84e30be2af7ad2c (patch)
tree3d927a496bdff59374d5767579f36dbf1d62dc37
parent407d3d5a3a58971daf67c8fa52a0fc158682235e (diff)
downloadffmpeg-3cf8db9447a6c77550033acea84e30be2af7ad2c.tar.gz
Add fullrange support to libx264.c x264 interface
Originally committed as revision 25904 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r--libavcodec/libx264.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavcodec/libx264.c b/libavcodec/libx264.c
index f550c6a433..0dad5cd567 100644
--- a/libavcodec/libx264.c
+++ b/libavcodec/libx264.c
@@ -297,6 +297,8 @@ static av_cold int X264_init(AVCodecContext *avctx)
x4->params.i_slice_count = avctx->slices;
+ x4->params.vui.b_fullrange = avctx->pix_fmt == PIX_FMT_YUVJ420P;
+
if (avctx->flags & CODEC_FLAG_GLOBAL_HEADER)
x4->params.b_repeat_headers = 0;
@@ -332,6 +334,6 @@ AVCodec libx264_encoder = {
.encode = X264_frame,
.close = X264_close,
.capabilities = CODEC_CAP_DELAY,
- .pix_fmts = (const enum PixelFormat[]) { PIX_FMT_YUV420P, PIX_FMT_NONE },
+ .pix_fmts = (const enum PixelFormat[]) { PIX_FMT_YUV420P, PIX_FMT_YUVJ420P, PIX_FMT_NONE },
.long_name = NULL_IF_CONFIG_SMALL("libx264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10"),
};