comparison h264.c @ 7897:004f3c69fe7b libavcodec

Move direct_dist_scale_factor() and direct_ref_list_init() after fill_mbaff_ref_list() as future changes will need the mbaff lists inited.
author michael
date Sun, 21 Sep 2008 02:23:51 +0000
parents 3557386b7a97
children a33287a39a55
comparison
equal deleted inserted replaced
7896:3557386b7a97 7897:004f3c69fe7b
2917 h->ref_list[list][index]= s->current_picture; //FIXME this is not a sensible solution 2917 h->ref_list[list][index]= s->current_picture; //FIXME this is not a sensible solution
2918 } 2918 }
2919 } 2919 }
2920 } 2920 }
2921 2921
2922 if(h->slice_type_nos==FF_B_TYPE && !h->direct_spatial_mv_pred)
2923 direct_dist_scale_factor(h);
2924 direct_ref_list_init(h);
2925 return 0; 2922 return 0;
2926 } 2923 }
2927 2924
2928 static void fill_mbaff_ref_list(H264Context *h){ 2925 static void fill_mbaff_ref_list(H264Context *h){
2929 int list, i, j; 2926 int list, i, j;
3910 if(h->nal_ref_idc) 3907 if(h->nal_ref_idc)
3911 decode_ref_pic_marking(h0, &s->gb); 3908 decode_ref_pic_marking(h0, &s->gb);
3912 3909
3913 if(FRAME_MBAFF) 3910 if(FRAME_MBAFF)
3914 fill_mbaff_ref_list(h); 3911 fill_mbaff_ref_list(h);
3912
3913 if(h->slice_type_nos==FF_B_TYPE && !h->direct_spatial_mv_pred)
3914 direct_dist_scale_factor(h);
3915 direct_ref_list_init(h);
3915 3916
3916 if( h->slice_type_nos != FF_I_TYPE && h->pps.cabac ){ 3917 if( h->slice_type_nos != FF_I_TYPE && h->pps.cabac ){
3917 tmp = get_ue_golomb(&s->gb); 3918 tmp = get_ue_golomb(&s->gb);
3918 if(tmp > 2){ 3919 if(tmp > 2){
3919 av_log(s->avctx, AV_LOG_ERROR, "cabac_init_idc overflow\n"); 3920 av_log(s->avctx, AV_LOG_ERROR, "cabac_init_idc overflow\n");