comparison h264.c @ 3807:6a40092eb9e6 libavcodec

approximate qpel functions: sacrifice some quality for some decoding speed. enabled on B-frames with -lavdopts fast.
author lorenm
date Sun, 01 Oct 2006 21:25:17 +0000
parents 1843a85123b7
children f44a3341bfdf
comparison
equal deleted inserted replaced
3806:e1986d9ddc2d 3807:6a40092eb9e6
3780 } 3780 }
3781 if(h->deblocking_filter && !FRAME_MBAFF) 3781 if(h->deblocking_filter && !FRAME_MBAFF)
3782 xchg_mb_border(h, dest_y, dest_cb, dest_cr, linesize, uvlinesize, 0); 3782 xchg_mb_border(h, dest_y, dest_cb, dest_cr, linesize, uvlinesize, 0);
3783 }else if(s->codec_id == CODEC_ID_H264){ 3783 }else if(s->codec_id == CODEC_ID_H264){
3784 hl_motion(h, dest_y, dest_cb, dest_cr, 3784 hl_motion(h, dest_y, dest_cb, dest_cr,
3785 s->dsp.put_h264_qpel_pixels_tab, s->dsp.put_h264_chroma_pixels_tab, 3785 s->me.qpel_put, s->dsp.put_h264_chroma_pixels_tab,
3786 s->dsp.avg_h264_qpel_pixels_tab, s->dsp.avg_h264_chroma_pixels_tab, 3786 s->me.qpel_avg, s->dsp.avg_h264_chroma_pixels_tab,
3787 s->dsp.weight_h264_pixels_tab, s->dsp.biweight_h264_pixels_tab); 3787 s->dsp.weight_h264_pixels_tab, s->dsp.biweight_h264_pixels_tab);
3788 } 3788 }
3789 3789
3790 3790
3791 if(!IS_INTRA4x4(mb_type)){ 3791 if(!IS_INTRA4x4(mb_type)){
4881 s->qscale, 4881 s->qscale,
4882 h->deblocking_filter, h->slice_alpha_c0_offset/2, h->slice_beta_offset/2, 4882 h->deblocking_filter, h->slice_alpha_c0_offset/2, h->slice_beta_offset/2,
4883 h->use_weight, 4883 h->use_weight,
4884 h->use_weight==1 && h->use_weight_chroma ? "c" : "" 4884 h->use_weight==1 && h->use_weight_chroma ? "c" : ""
4885 ); 4885 );
4886 }
4887
4888 if((s->avctx->flags2 & CODEC_FLAG2_FAST) && !s->current_picture.reference){
4889 s->me.qpel_put= s->dsp.put_2tap_qpel_pixels_tab;
4890 s->me.qpel_avg= s->dsp.avg_2tap_qpel_pixels_tab;
4891 }else{
4892 s->me.qpel_put= s->dsp.put_h264_qpel_pixels_tab;
4893 s->me.qpel_avg= s->dsp.avg_h264_qpel_pixels_tab;
4886 } 4894 }
4887 4895
4888 return 0; 4896 return 0;
4889 } 4897 }
4890 4898