Mercurial > libavcodec.hg
comparison h263.c @ 1896:ef87d53ca87a libavcodec
h.263 ssm + aic fix by (Maarten Daniels <maarten dot daniels at student dot luc dot ac dot be>)
author | michael |
---|---|
date | Thu, 18 Mar 2004 22:45:37 +0000 |
parents | 779bdf5063ce |
children | 5c21b165abf6 |
comparison
equal
deleted
inserted
replaced
1895:e5687117cc7f | 1896:ef87d53ca87a |
---|---|
1454 */ | 1454 */ |
1455 a = dc_val[(x - 1) + (y) * wrap]; | 1455 a = dc_val[(x - 1) + (y) * wrap]; |
1456 c = dc_val[(x) + (y - 1) * wrap]; | 1456 c = dc_val[(x) + (y - 1) * wrap]; |
1457 | 1457 |
1458 /* No prediction outside GOB boundary */ | 1458 /* No prediction outside GOB boundary */ |
1459 if (s->first_slice_line && ((n < 2) || (n > 3))) | 1459 if(s->first_slice_line && n!=3){ |
1460 c = 1024; | 1460 if(n!=2) c= 1024; |
1461 if(n!=1 && s->mb_x == s->resync_mb_x) a= 1024; | |
1462 } | |
1461 pred_dc = 1024; | 1463 pred_dc = 1024; |
1462 /* just DC prediction */ | 1464 /* just DC prediction */ |
1463 if (a != 1024 && c != 1024) | 1465 if (a != 1024 && c != 1024) |
1464 pred_dc = (a + c) >> 1; | 1466 pred_dc = (a + c) >> 1; |
1465 else if (a != 1024) | 1467 else if (a != 1024) |
5115 } | 5117 } |
5116 | 5118 |
5117 s->qscale = get_bits(&s->gb, 5); | 5119 s->qscale = get_bits(&s->gb, 5); |
5118 } | 5120 } |
5119 | 5121 |
5122 s->mb_width = (s->width + 15) / 16; | |
5123 s->mb_height = (s->height + 15) / 16; | |
5124 s->mb_num = s->mb_width * s->mb_height; | |
5125 | |
5120 /* PEI */ | 5126 /* PEI */ |
5121 while (get_bits1(&s->gb) != 0) { | 5127 while (get_bits1(&s->gb) != 0) { |
5122 skip_bits(&s->gb, 8); | 5128 skip_bits(&s->gb, 8); |
5123 } | 5129 } |
5124 | 5130 |
5125 if(s->h263_slice_structured){ | 5131 if(s->h263_slice_structured){ |
5126 if (get_bits1(&s->gb) != 1) { | 5132 if (get_bits1(&s->gb) != 1) { |
5127 av_log(s->avctx, AV_LOG_ERROR, "SEPB1 marker missing\n"); | 5133 av_log(s->avctx, AV_LOG_ERROR, "SEPB1 marker missing\n"); |
5128 return -1; | 5134 return -1; |
5129 } | 5135 } |