678 |
|
|
679 |
if (dec->interlacing) { |
if (dec->interlacing) { |
680 |
mb->field_dct = BitstreamGetBit(bs); |
mb->field_dct = BitstreamGetBit(bs); |
681 |
DEBUG1("deci: field_dct: ", mb->field_dct); |
DPRINTF(DPRINTF_MB,"deci: field_dct: %i", mb->field_dct); |
682 |
} |
} |
683 |
|
|
684 |
decoder_mbintra(dec, mb, x, y, acpred_flag, cbp, bs, quant, |
decoder_mbintra(dec, mb, x, y, acpred_flag, cbp, bs, quant, |
856 |
if (dec->interlacing) { |
if (dec->interlacing) { |
857 |
if (cbp || intra) { |
if (cbp || intra) { |
858 |
mb->field_dct = BitstreamGetBit(bs); |
mb->field_dct = BitstreamGetBit(bs); |
859 |
DEBUG1("decp: field_dct: ", mb->field_dct); |
DPRINTF(DPRINTF_MB,"decp: field_dct: %i", mb->field_dct); |
860 |
} |
} |
861 |
|
|
862 |
if (mb->mode == MODE_INTER || mb->mode == MODE_INTER_Q) { |
if (mb->mode == MODE_INTER || mb->mode == MODE_INTER_Q) { |
863 |
mb->field_pred = BitstreamGetBit(bs); |
mb->field_pred = BitstreamGetBit(bs); |
864 |
DEBUG1("decp: field_pred: ", mb->field_pred); |
DPRINTF(DPRINTF_MB, "decp: field_pred: %i", mb->field_pred); |
865 |
|
|
866 |
if (mb->field_pred) { |
if (mb->field_pred) { |
867 |
mb->field_for_top = BitstreamGetBit(bs); |
mb->field_for_top = BitstreamGetBit(bs); |
868 |
DEBUG1("decp: field_for_top: ", mb->field_for_top); |
DPRINTF(DPRINTF_MB,"decp: field_for_top: %i", mb->field_for_top); |
869 |
mb->field_for_bot = BitstreamGetBit(bs); |
mb->field_for_bot = BitstreamGetBit(bs); |
870 |
DEBUG1("decp: field_for_bot: ", mb->field_for_bot); |
DPRINTF(DPRINTF_MB,"decp: field_for_bot: %i", mb->field_for_bot); |
871 |
} |
} |
872 |
} |
} |
873 |
} |
} |
1581 |
break; |
break; |
1582 |
|
|
1583 |
default: |
default: |
1584 |
DEBUG1("Not support B-frame mb_type =", mb->mb_type); |
DPRINTF(DPRINTF_ERROR,"Not support B-frame mb_type = %i", mb->mb_type); |
1585 |
} |
} |
1586 |
|
|
1587 |
} // end of FOR |
} // end of FOR |
1651 |
dec->low_delay_default = (frame->general & XVID_DEC_LOWDELAY); |
dec->low_delay_default = (frame->general & XVID_DEC_LOWDELAY); |
1652 |
dec->out_frm = (frame->colorspace == XVID_CSP_EXTERN) ? frame->image : NULL; |
dec->out_frm = (frame->colorspace == XVID_CSP_EXTERN) ? frame->image : NULL; |
1653 |
|
|
1654 |
|
if ((frame->general & XVID_DEC_DISCONTINUITY)) |
1655 |
|
dec->frames = 0; |
1656 |
|
|
1657 |
if (frame->length < 0) /* decoder flush */ |
if (frame->length < 0) /* decoder flush */ |
1658 |
{ |
{ |
1659 |
/* if not decoding "low_delay/packed", and this isn't low_delay and |
/* if not decoding "low_delay/packed", and this isn't low_delay and |
1838 |
{ |
{ |
1839 |
/* output the recently decoded frame */ |
/* output the recently decoded frame */ |
1840 |
decoder_output(dec, &dec->refn[0], dec->last_mbs, frame, dec->last_reduced_resolution); |
decoder_output(dec, &dec->refn[0], dec->last_mbs, frame, dec->last_reduced_resolution); |
1841 |
|
output = 1; |
1842 |
} |
} |
1843 |
else |
else |
1844 |
{ |
{ |
1850 |
|
|
1851 |
decoder_output(dec, &dec->cur, NULL, frame, 1 /*disable pp*/); |
decoder_output(dec, &dec->cur, NULL, frame, 1 /*disable pp*/); |
1852 |
} |
} |
|
output = 1; |
|
1853 |
} |
} |
1854 |
|
|
1855 |
frame->length = BitstreamPos(&bs) / 8; |
frame->length = BitstreamPos(&bs) / 8; |