51 #define H263_MBTYPE_B_VLC_BITS 6
52 #define CBPC_B_VLC_BITS 3
156 unsigned int val, gob_number;
168 for(;left>13; left--){
219 if (!p[-1] && p[1])
return p - 1;
220 else if(!p[ 1] && p[2])
return p;
252 for(;left>16+1+5+5; left-=8){
274 int code, val, sign, shift;
286 val = (val - 1) << shift;
299 if (pred < -31 && val < -63)
301 if (pred > 32 && val > 63)
327 code = (sign) ? (pred - code) : (pred + code);
339 int cbpc, i, pred_x, pred_y, mx, my;
356 mot_val[0 ]= mot_val[2 ]=
358 mot_val[1 ]= mot_val[3 ]=
379 if ((cbpc & 16) == 0) {
393 mot_val[0 ]= mot_val[2 ]=
395 mot_val[1 ]= mot_val[3 ]=
410 if (s->
umvplus && (mx - pred_x) == 1 && (my - pred_y) == 1)
429 static const int8_t quant_tab[4] = { -1, -2, 1, 2 };
446 const uint8_t *scan_table;
462 #if CONFIG_RV10_DECODER
465 component = (n <= 3 ? 0 : n - 4 + 1);
472 level = level & 0xff;
485 if((level&0x7F) == 0){
532 last = code >= rl->
last;
574 for (i = 0; i < 6; i++) {
589 if (pb_frame == 2 && c)
604 int cbpc, cbpy, i, cbp, pred_x, pred_y, mx, my, dquant;
607 int cbpb = 0, pb_mv_count = 0;
646 cbp = (cbpc & 3) | (cbpy << 2);
652 if ((cbpc & 16) == 0) {
675 if (s->
umvplus && (mx - pred_x) == 1 && (my - pred_y) == 1)
697 if (s->
umvplus && (mx - pred_x) == 1 && (my - pred_y) == 1)
711 mot_val0[0 ]= mot_val0[2 ]= mot_val0[0+2*
stride]= mot_val0[2+2*
stride]=
712 mot_val0[1 ]= mot_val0[3 ]= mot_val0[1+2*
stride]= mot_val0[3+2*
stride]=
713 mot_val1[0 ]= mot_val1[2 ]= mot_val1[0+2*
stride]= mot_val1[2+2*
stride]=
714 mot_val1[1 ]= mot_val1[3 ]= mot_val1[1+2*
stride]= mot_val1[3+2*
stride]= 0;
745 cbp = (cbpc & 3) | (cbpy << 2);
774 mot_val[0 ]= mot_val[2 ]= mot_val[0+2*
stride]= mot_val[2+2*
stride]= mx;
775 mot_val[1 ]= mot_val[3 ]= mot_val[1+2*
stride]= mot_val[3+2*
stride]= my;
787 mot_val[0 ]= mot_val[2 ]= mot_val[0+2*
stride]= mot_val[2+2*
stride]= mx;
788 mot_val[1 ]= mot_val[3 ]= mot_val[1+2*
stride]= mot_val[3+2*
stride]= my;
825 cbp = (cbpc & 3) | (cbpy << 2);
833 while(pb_mv_count--){
839 for (i = 0; i < 6; i++) {
879 startcode = ((startcode << 8) |
get_bits(&s->
gb, 8)) & 0x003FFFFF;
881 if(startcode == 0x20)
885 if (startcode != 0x20) {
918 if (format != 7 && format != 6) {
982 }
else if (ufep != 0) {
1020 av_dlog(s->
avctx,
"\nH.263+ Custom picture: %dx%d\n",width,height);
1033 if ((width == 0) || (height == 0))
1121 for(i=0; i<13; i++){