Mercurial > libavcodec.hg
comparison mpeg12.c @ 718:16dab8296293 libavcodec
fixing custom quantizer matrix decoding
minor optimizations
author | michaelni |
---|---|
date | Wed, 02 Oct 2002 22:56:58 +0000 |
parents | 6cba3b6196f0 |
children | 585c163c225a |
comparison
equal
deleted
inserted
replaced
717:6cba3b6196f0 | 718:16dab8296293 |
---|---|
1433 dprintf("matrix extension\n"); | 1433 dprintf("matrix extension\n"); |
1434 | 1434 |
1435 if (get_bits1(&s->gb)) { | 1435 if (get_bits1(&s->gb)) { |
1436 for(i=0;i<64;i++) { | 1436 for(i=0;i<64;i++) { |
1437 v = get_bits(&s->gb, 8); | 1437 v = get_bits(&s->gb, 8); |
1438 j = s->intra_scantable.permutated[i]; | 1438 j= s->idct_permutation[ ff_zigzag_direct[i] ]; |
1439 s->intra_matrix[j] = v; | 1439 s->intra_matrix[j] = v; |
1440 s->chroma_intra_matrix[j] = v; | 1440 s->chroma_intra_matrix[j] = v; |
1441 } | 1441 } |
1442 } | 1442 } |
1443 if (get_bits1(&s->gb)) { | 1443 if (get_bits1(&s->gb)) { |
1444 for(i=0;i<64;i++) { | 1444 for(i=0;i<64;i++) { |
1445 v = get_bits(&s->gb, 8); | 1445 v = get_bits(&s->gb, 8); |
1446 j = s->intra_scantable.permutated[i]; | 1446 j= s->idct_permutation[ ff_zigzag_direct[i] ]; |
1447 s->inter_matrix[j] = v; | 1447 s->inter_matrix[j] = v; |
1448 s->chroma_inter_matrix[j] = v; | 1448 s->chroma_inter_matrix[j] = v; |
1449 } | 1449 } |
1450 } | 1450 } |
1451 if (get_bits1(&s->gb)) { | 1451 if (get_bits1(&s->gb)) { |
1452 for(i=0;i<64;i++) { | 1452 for(i=0;i<64;i++) { |
1453 v = get_bits(&s->gb, 8); | 1453 v = get_bits(&s->gb, 8); |
1454 j = s->intra_scantable.permutated[i]; | 1454 j= s->idct_permutation[ ff_zigzag_direct[i] ]; |
1455 s->chroma_intra_matrix[j] = v; | 1455 s->chroma_intra_matrix[j] = v; |
1456 } | 1456 } |
1457 } | 1457 } |
1458 if (get_bits1(&s->gb)) { | 1458 if (get_bits1(&s->gb)) { |
1459 for(i=0;i<64;i++) { | 1459 for(i=0;i<64;i++) { |
1460 v = get_bits(&s->gb, 8); | 1460 v = get_bits(&s->gb, 8); |
1461 j = s->intra_scantable.permutated[i]; | 1461 j= s->idct_permutation[ ff_zigzag_direct[i] ]; |
1462 s->chroma_inter_matrix[j] = v; | 1462 s->chroma_inter_matrix[j] = v; |
1463 } | 1463 } |
1464 } | 1464 } |
1465 } | 1465 } |
1466 | 1466 |