diff options
author | Justin Ruggles <justin.ruggles@gmail.com> | 2014-04-28 16:08:33 -0400 |
---|---|---|
committer | Justin Ruggles <justin.ruggles@gmail.com> | 2014-06-20 10:39:33 -0400 |
commit | 9e500efdbe0deeff1602500ebc229a0a6b6bb1a2 (patch) | |
tree | ab9fefcc3d3bab4d2a75f427e96587fd61ec2770 /libavcodec/hevc.c | |
parent | d349afb07bacccb62eb5369c38d6406d2909d792 (diff) | |
download | ffmpeg-9e500efdbe0deeff1602500ebc229a0a6b6bb1a2.tar.gz |
Add av_image_check_sar() and use it to validate SAR
Diffstat (limited to 'libavcodec/hevc.c')
-rw-r--r-- | libavcodec/hevc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/hevc.c b/libavcodec/hevc.c index a4c495d1d0..f66a49f803 100644 --- a/libavcodec/hevc.c +++ b/libavcodec/hevc.c @@ -400,9 +400,10 @@ static int set_sps(HEVCContext *s, const HEVCSPS *sps) s->avctx->width = sps->output_width; s->avctx->height = sps->output_height; s->avctx->pix_fmt = sps->pix_fmt; - s->avctx->sample_aspect_ratio = sps->vui.sar; s->avctx->has_b_frames = sps->temporal_layer[sps->max_sub_layers - 1].num_reorder_pics; + ff_set_sar(s->avctx, sps->vui.sar); + if (sps->vui.video_signal_type_present_flag) s->avctx->color_range = sps->vui.video_full_range_flag ? AVCOL_RANGE_JPEG : AVCOL_RANGE_MPEG; |