| 503 | } |
| 504 | |
| 505 | __ri static int get_macroblock_address_increment() |
| 506 | { |
| 507 | const MBAtab *mba; |
| 508 | |
| 509 | u16 code = UBITS(16); |
| 510 | |
| 511 | if (code >= 4096) |
| 512 | mba = MBA.mba5 + (UBITS(5) - 2); |
| 513 | else if (code >= 768) |
| 514 | mba = MBA.mba11 + (UBITS(11) - 24); |
| 515 | else switch (UBITS(11)) |
| 516 | { |
| 517 | case 8: /* macroblock_escape */ |
| 518 | DUMPBITS(11); |
| 519 | return 0xb0023; |
| 520 | |
| 521 | case 15: /* macroblock_stuffing (MPEG1 only) */ |
| 522 | if (decoder.mpeg1) |
| 523 | { |
| 524 | DUMPBITS(11); |
| 525 | return 0xb0022; |
| 526 | } |
| 527 | [[fallthrough]]; |
| 528 | |
| 529 | default: |
| 530 | return 0;//error |
| 531 | } |
| 532 | |
| 533 | DUMPBITS(mba->len); |
| 534 | |
| 535 | return ((mba->mba + 1) | (mba->len << 16)); |
| 536 | } |
| 537 | |
| 538 | __fi static int get_luma_dc_dct_diff() |
| 539 | { |