|
|
@ -1416,7 +1416,7 @@ static int vc1_decode_p_mb(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (v->rangeredfrm) |
|
|
|
if (v->rangeredfrm) |
|
|
@ -1437,7 +1437,7 @@ static int vc1_decode_p_mb(VC1Context *v) |
|
|
|
} else if (val) { |
|
|
|
} else if (val) { |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, first_block, |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, first_block, |
|
|
|
s->dest[dst_idx] + off, (i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
s->dest[dst_idx] + off, (i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
ttmb = -1; |
|
|
|
ttmb = -1; |
|
|
@ -1527,7 +1527,7 @@ static int vc1_decode_p_mb(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, is_coded[i], mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, is_coded[i], mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (v->rangeredfrm) |
|
|
|
if (v->rangeredfrm) |
|
|
@ -1549,7 +1549,7 @@ static int vc1_decode_p_mb(VC1Context *v) |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), |
|
|
|
&block_tt); |
|
|
|
&block_tt); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
@ -1675,7 +1675,8 @@ static int vc1_decode_p_mb_intfr(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) continue; |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
|
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (i < 4) { |
|
|
|
if (i < 4) { |
|
|
|
stride_y = s->linesize << fieldtx; |
|
|
|
stride_y = s->linesize << fieldtx; |
|
|
@ -1766,7 +1767,7 @@ static int vc1_decode_p_mb_intfr(VC1Context *v) |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : (s->linesize << fieldtx), |
|
|
|
(i & 4) ? s->uvlinesize : (s->linesize << fieldtx), |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
ttmb = -1; |
|
|
|
ttmb = -1; |
|
|
@ -1845,7 +1846,7 @@ static int vc1_decode_p_mb_intfi(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
off = (i & 4) ? 0 : ((i & 1) * 8 + (i & 2) * 4 * s->linesize); |
|
|
|
off = (i & 4) ? 0 : ((i & 1) * 8 + (i & 2) * 4 * s->linesize); |
|
|
@ -1902,7 +1903,7 @@ static int vc1_decode_p_mb_intfi(VC1Context *v) |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), |
|
|
|
&block_tt); |
|
|
|
&block_tt); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
if (!v->ttmbf && ttmb < 8) ttmb = -1; |
|
|
|
if (!v->ttmbf && ttmb < 8) ttmb = -1; |
|
|
@ -2048,7 +2049,7 @@ static void vc1_decode_b_mb(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (v->rangeredfrm) |
|
|
|
if (v->rangeredfrm) |
|
|
@ -2062,7 +2063,7 @@ static void vc1_decode_b_mb(VC1Context *v) |
|
|
|
vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), NULL); |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), NULL); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
ttmb = -1; |
|
|
|
ttmb = -1; |
|
|
|
first_block = 0; |
|
|
|
first_block = 0; |
|
|
@ -2123,7 +2124,7 @@ static void vc1_decode_b_mb_intfi(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if ((i>3) && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if ((i > 3) && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (v->rangeredfrm) |
|
|
|
if (v->rangeredfrm) |
|
|
@ -2218,7 +2219,7 @@ static void vc1_decode_b_mb_intfi(VC1Context *v) |
|
|
|
vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) ? s->uvlinesize : s->linesize, |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), NULL); |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), NULL); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
ttmb = -1; |
|
|
|
ttmb = -1; |
|
|
|
first_block = 0; |
|
|
|
first_block = 0; |
|
|
@ -2341,7 +2342,7 @@ static int vc1_decode_b_mb_intfr(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
vc1_decode_intra_block(v, s->block[i], i, val, mquant, |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
(i & 4) ? v->codingset2 : v->codingset); |
|
|
|
if (i > 3 && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if (i > 3 && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[i]); |
|
|
|
if (i < 4) { |
|
|
|
if (i < 4) { |
|
|
@ -2507,7 +2508,7 @@ static int vc1_decode_b_mb_intfr(VC1Context *v) |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
pat = vc1_decode_p_block(v, s->block[i], i, mquant, ttmb, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
first_block, s->dest[dst_idx] + off, |
|
|
|
(i & 4) ? s->uvlinesize : (s->linesize << fieldtx), |
|
|
|
(i & 4) ? s->uvlinesize : (s->linesize << fieldtx), |
|
|
|
(i & 4) && (s->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
(i & 4) && (s->avctx->flags & CODEC_FLAG_GRAY), &block_tt); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
block_cbp |= pat << (i << 2); |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
if (!v->ttmbf && ttmb < 8) |
|
|
|
ttmb = -1; |
|
|
|
ttmb = -1; |
|
|
@ -2650,7 +2651,7 @@ static void vc1_decode_i_blocks(VC1Context *v) |
|
|
|
|
|
|
|
|
|
|
|
vc1_decode_i_block(v, s->block[k], k, val, (k < 4) ? v->codingset : v->codingset2); |
|
|
|
vc1_decode_i_block(v, s->block[k], k, val, (k < 4) ? v->codingset : v->codingset2); |
|
|
|
|
|
|
|
|
|
|
|
if (k > 3 && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if (k > 3 && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[k]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(s->block[k]); |
|
|
|
if (v->pq >= 9 && v->overlap) { |
|
|
|
if (v->pq >= 9 && v->overlap) { |
|
|
@ -2674,7 +2675,7 @@ static void vc1_decode_i_blocks(VC1Context *v) |
|
|
|
if (s->mb_x) { |
|
|
|
if (s->mb_x) { |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[0], s->linesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[0], s->linesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[0] + 8 * s->linesize, s->linesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[0] + 8 * s->linesize, s->linesize); |
|
|
|
if (!(s->flags & CODEC_FLAG_GRAY)) { |
|
|
|
if (!(s->avctx->flags & CODEC_FLAG_GRAY)) { |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[1], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[1], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[2], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_h_overlap(s->dest[2], s->uvlinesize); |
|
|
|
} |
|
|
|
} |
|
|
@ -2684,7 +2685,7 @@ static void vc1_decode_i_blocks(VC1Context *v) |
|
|
|
if (!s->first_slice_line) { |
|
|
|
if (!s->first_slice_line) { |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[0], s->linesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[0], s->linesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[0] + 8, s->linesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[0] + 8, s->linesize); |
|
|
|
if (!(s->flags & CODEC_FLAG_GRAY)) { |
|
|
|
if (!(s->avctx->flags & CODEC_FLAG_GRAY)) { |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[1], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[1], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[2], s->uvlinesize); |
|
|
|
v->vc1dsp.vc1_v_overlap(s->dest[2], s->uvlinesize); |
|
|
|
} |
|
|
|
} |
|
|
@ -2813,7 +2814,7 @@ static void vc1_decode_i_blocks_adv(VC1Context *v) |
|
|
|
vc1_decode_i_block_adv(v, block[k], k, val, |
|
|
|
vc1_decode_i_block_adv(v, block[k], k, val, |
|
|
|
(k < 4) ? v->codingset : v->codingset2, mquant); |
|
|
|
(k < 4) ? v->codingset : v->codingset2, mquant); |
|
|
|
|
|
|
|
|
|
|
|
if (k > 3 && (s->flags & CODEC_FLAG_GRAY)) |
|
|
|
if (k > 3 && (s->avctx->flags & CODEC_FLAG_GRAY)) |
|
|
|
continue; |
|
|
|
continue; |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(block[k]); |
|
|
|
v->vc1dsp.vc1_inv_trans_8x8(block[k]); |
|
|
|
} |
|
|
|
} |
|
|
|