comparison h264.c @ 7405:dfe1d1d104eb libavcodec

Revert r14404 Remove another 2 incorrect checks. These would ignore fields of different parity. I was wrong, i thought pic_stricture is the current pic structure. But it does not make a difference either way on the reference bitstreams.
author michael
date Fri, 25 Jul 2008 23:55:31 +0000
parents f76bbe133ddd
children 6288bc103b9f
comparison
equal deleted inserted replaced
7404:f76bbe133ddd 7405:dfe1d1d104eb
2952 for(i= h->short_ref_count-1; i>=0; i--){ 2952 for(i= h->short_ref_count-1; i>=0; i--){
2953 ref = h->short_ref[i]; 2953 ref = h->short_ref[i];
2954 assert(ref->reference); 2954 assert(ref->reference);
2955 assert(!ref->long_ref); 2955 assert(!ref->long_ref);
2956 if( 2956 if(
2957 ref->frame_num == frame_num 2957 ref->frame_num == frame_num &&
2958 (ref->reference & pic_structure)
2958 ) 2959 )
2959 break; 2960 break;
2960 } 2961 }
2961 if(i>=0) 2962 if(i>=0)
2962 ref->pic_id= pred; 2963 ref->pic_id= pred;
2970 av_log(h->s.avctx, AV_LOG_ERROR, "long_term_pic_idx overflow\n"); 2971 av_log(h->s.avctx, AV_LOG_ERROR, "long_term_pic_idx overflow\n");
2971 return -1; 2972 return -1;
2972 } 2973 }
2973 ref = h->long_ref[long_idx]; 2974 ref = h->long_ref[long_idx];
2974 assert(!(ref && !ref->reference)); 2975 assert(!(ref && !ref->reference));
2975 if(ref){ 2976 if(ref && (ref->reference & pic_structure)){
2976 ref->pic_id= pic_id; 2977 ref->pic_id= pic_id;
2977 assert(ref->long_ref); 2978 assert(ref->long_ref);
2978 i=0; 2979 i=0;
2979 }else{ 2980 }else{
2980 i=-1; 2981 i=-1;