diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-01-24 14:44:34 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-01-24 15:47:47 +0100 |
commit | fc13a89654b5878050ac07e36254c5e712aa8820 (patch) | |
tree | 73e35d94880aae72b785ef9d1079c442a552777b /libavcodec/h264.c | |
parent | 70b0aeba001c61d52965debda4875e610bb2435e (diff) | |
parent | e9d817351b28e62868528476971afe4cde1fa280 (diff) | |
download | ffmpeg-fc13a89654b5878050ac07e36254c5e712aa8820.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
dsputil: Separate h264 qpel
Conflicts:
libavcodec/dsputil_template.c
libavcodec/h264.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 89d2a6b540..624c407f97 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -986,10 +986,9 @@ static av_cold void common_init(H264Context *h) s->avctx->bits_per_raw_sample = 8; h->cur_chroma_format_idc = 1; - ff_h264dsp_init(&h->h264dsp, - s->avctx->bits_per_raw_sample, h->cur_chroma_format_idc); - ff_h264_pred_init(&h->hpc, s->codec_id, - s->avctx->bits_per_raw_sample, h->cur_chroma_format_idc); + ff_h264dsp_init(&h->h264dsp, 8, 1); + ff_h264qpel_init(&h->h264qpel, 8); + ff_h264_pred_init(&h->hpc, s->codec_id, 8, 1); h->dequant_coeff_pps = -1; s->unrestricted_mv = 1; @@ -2469,6 +2468,7 @@ static int h264_set_parameter_from_sps(H264Context *h) ff_h264dsp_init(&h->h264dsp, h->sps.bit_depth_luma, h->sps.chroma_format_idc); + ff_h264qpel_init(&h->h264qpel, h->sps.bit_depth_luma); ff_h264_pred_init(&h->hpc, s->codec_id, h->sps.bit_depth_luma, h->sps.chroma_format_idc); s->dsp.dct_bits = h->sps.bit_depth_luma > 8 ? 32 : 16; @@ -2625,6 +2625,7 @@ static int h264_slice_header_init(H264Context *h, int reinit) memcpy(c, h->s.thread_context[i], sizeof(MpegEncContext)); memset(&c->s + 1, 0, sizeof(H264Context) - sizeof(MpegEncContext)); c->h264dsp = h->h264dsp; + c->h264qpel = h->h264qpel; c->sps = h->sps; c->pps = h->pps; c->pixel_shift = h->pixel_shift; @@ -2666,8 +2667,8 @@ static int decode_slice_header(H264Context *h, H264Context *h0) int must_reinit; int needs_reinit = 0; - s->me.qpel_put = s->dsp.put_h264_qpel_pixels_tab; - s->me.qpel_avg = s->dsp.avg_h264_qpel_pixels_tab; + s->me.qpel_put = h->h264qpel.put_h264_qpel_pixels_tab; + s->me.qpel_avg = h->h264qpel.avg_h264_qpel_pixels_tab; first_mb_in_slice = get_ue_golomb_long(&s->gb); |