1199 |
|
|
1200 |
/* ---- update vol flags at IVOP ----------- */ |
/* ---- update vol flags at IVOP ----------- */ |
1201 |
pEnc->current->vol_flags = pEnc->mbParam.vol_flags = frame->vol_flags; |
pEnc->current->vol_flags = pEnc->mbParam.vol_flags = frame->vol_flags; |
1202 |
|
switch(frame->par) { |
1203 |
|
case XVID_PAR_11_VGA: |
1204 |
|
case XVID_PAR_43_PAL: |
1205 |
|
case XVID_PAR_43_NTSC: |
1206 |
|
case XVID_PAR_169_PAL: |
1207 |
|
case XVID_PAR_169_NTSC: |
1208 |
|
case XVID_PAR_EXT: |
1209 |
|
pEnc->mbParam.par = frame->par; |
1210 |
|
break; |
1211 |
|
default: |
1212 |
|
pEnc->mbParam.par = XVID_PAR_EXT; |
1213 |
|
break; |
1214 |
|
} |
1215 |
|
pEnc->mbParam.par_width = (frame->par_width)?frame->par_width:1; |
1216 |
|
pEnc->mbParam.par_height = (frame->par_height)?frame->par_height:1; |
1217 |
|
|
1218 |
if ((pEnc->mbParam.vol_flags & XVID_VOL_MPEGQUANT)) { |
if ((pEnc->mbParam.vol_flags & XVID_VOL_MPEGQUANT)) { |
1219 |
if (frame->quant_intra_matrix != NULL) |
if (frame->quant_intra_matrix != NULL) |
1583 |
|
|
1584 |
current->sStat.kblks++; |
current->sStat.kblks++; |
1585 |
|
|
1586 |
|
if (pEnc->current->vop_flags & XVID_VOP_GREYSCALE) |
1587 |
|
{ pMB->cbp &= 0x3C; /* keep only bits 5-2 */ |
1588 |
|
qcoeff[4*64+0]=0; /* zero, because for INTRA MBs DC value is saved */ |
1589 |
|
qcoeff[5*64+0]=0; |
1590 |
|
} |
1591 |
MBCoding(current, pMB, qcoeff, bs, ¤t->sStat); |
MBCoding(current, pMB, qcoeff, bs, ¤t->sStat); |
1592 |
stop_coding_timer(); |
stop_coding_timer(); |
1593 |
continue; |
continue; |
1914 |
} |
} |
1915 |
} |
} |
1916 |
|
|
1917 |
#ifdef BFRAMES_DEC_DEBUG |
/* keep only bits 5-2 -- Chroma blocks will just be skipped by the |
1918 |
BFRAME_DEBUG |
* coding function for BFrames, that's why we don't zero teh DC |
1919 |
#endif |
* coeffs */ |
1920 |
|
if ((frame->vop_flags & XVID_VOP_GREYSCALE)) |
1921 |
|
mb->cbp &= 0x3C; |
1922 |
|
|
1923 |
start_timer(); |
start_timer(); |
1924 |
MBCodingBVOP(mb, qcoeff, frame->fcode, frame->bcode, bs, |
MBCodingBVOP(mb, qcoeff, frame->fcode, frame->bcode, bs, |
1925 |
&frame->sStat, direction); |
&frame->sStat, direction); |