comparison h264.c @ 7404:f76bbe133ddd libavcodec

Remove another 2 incorrect checks. These would ignore fields of different parity.
author michael
date Fri, 25 Jul 2008 23:49:01 +0000
parents aff96834b8cd
children dfe1d1d104eb
comparison
equal deleted inserted replaced
7403:aff96834b8cd 7404:f76bbe133ddd
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)
2959 ) 2958 )
2960 break; 2959 break;
2961 } 2960 }
2962 if(i>=0) 2961 if(i>=0)
2963 ref->pic_id= pred; 2962 ref->pic_id= pred;
2971 av_log(h->s.avctx, AV_LOG_ERROR, "long_term_pic_idx overflow\n"); 2970 av_log(h->s.avctx, AV_LOG_ERROR, "long_term_pic_idx overflow\n");
2972 return -1; 2971 return -1;
2973 } 2972 }
2974 ref = h->long_ref[long_idx]; 2973 ref = h->long_ref[long_idx];
2975 assert(!(ref && !ref->reference)); 2974 assert(!(ref && !ref->reference));
2976 if(ref && (ref->reference & pic_structure)){ 2975 if(ref){
2977 ref->pic_id= pic_id; 2976 ref->pic_id= pic_id;
2978 assert(ref->long_ref); 2977 assert(ref->long_ref);
2979 i=0; 2978 i=0;
2980 }else{ 2979 }else{
2981 i=-1; 2980 i=-1;