370 |
|
|
371 |
// interlacing |
// interlacing |
372 |
if (frame->global_flags & XVID_INTERLACING) { |
if (frame->global_flags & XVID_INTERLACING) { |
373 |
|
if (pMB->cbp) { |
374 |
BitstreamPutBit(bs, pMB->field_dct); |
BitstreamPutBit(bs, pMB->field_dct); |
375 |
DEBUG1("codep: field_dct: ", pMB->field_dct); |
DEBUG1("codep: field_dct: ", pMB->field_dct); |
376 |
|
} |
377 |
|
|
378 |
// if inter block, write field ME flag |
// if inter block, write field ME flag |
379 |
if (pMB->mode == MODE_INTER || pMB->mode == MODE_INTER_Q) { |
if (pMB->mode == MODE_INTER || pMB->mode == MODE_INTER_Q) { |
415 |
{ |
{ |
416 |
|
|
417 |
if (frame->coding_type == P_VOP) { |
if (frame->coding_type == P_VOP) { |
|
if (pMB->cbp == 0 && pMB->mode == MODE_INTER && pMB->mvs[0].x == 0 && |
|
|
pMB->mvs[0].y == 0) { |
|
|
|
|
|
#ifdef _DISABLE_SKIP |
|
|
/* disable SKIP when Bframes active until some workaround for the B-SKIP problem is found */ |
|
|
BitstreamPutBit(bs, 0); // always coded! |
|
|
#else |
|
|
BitstreamPutBit(bs, 1); // not_coded |
|
|
|
|
|
return; |
|
|
#endif |
|
|
} else |
|
418 |
BitstreamPutBit(bs, 0); // coded |
BitstreamPutBit(bs, 0); // coded |
419 |
} |
} |
420 |
|
|
425 |
|
|
426 |
} |
} |
427 |
|
|
428 |
|
|
429 |
|
void |
430 |
|
MBSkip(Bitstream * bs) |
431 |
|
{ |
432 |
|
BitstreamPutBit(bs, 1); // not coded |
433 |
|
return; |
434 |
|
} |
435 |
|
|
436 |
|
|
437 |
/*************************************************************** |
/*************************************************************** |
438 |
* bframe encoding start |
* bframe encoding start |
439 |
***************************************************************/ |
***************************************************************/ |