comparison mpeg12.c @ 595:5f7ab2e73bc9 libavcodec

fixing slices which start at mb_x>0
author michaelni
date Sun, 04 Aug 2002 18:19:09 +0000
parents 7e7a7282608c
children df2102629fef
comparison
equal deleted inserted replaced
594:7e26eb37bbbc 595:5f7ab2e73bc9
670 s->mb_incr += code; 670 s->mb_incr += code;
671 break; 671 break;
672 } 672 }
673 } 673 }
674 } 674 }
675 if(s->mb_x==-1 /* first MB in a slice */ && s->mb_incr>1){
676 s->mb_x+= (s->mb_incr - 1) % s->mb_width;
677 s->mb_y+= (s->mb_incr - 1) / s->mb_width;
678 s->mb_incr= 1;
679 }
680
675 if (++s->mb_x >= s->mb_width) { 681 if (++s->mb_x >= s->mb_width) {
676 s->mb_x = 0; 682 s->mb_x = 0;
677 if (s->mb_y >= (s->mb_height - 1)){ 683 if (s->mb_y >= (s->mb_height - 1)){
678 fprintf(stderr, "slice too long\n"); 684 fprintf(stderr, "slice too long\n");
679 return -1; 685 return -1;