Skip to content

Commit 1d88b1b

Browse files
committed
reader: debug2: print more info about dqt
print parsed info about Pq and Tq
1 parent 685152a commit 1d88b1b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/gpujpeg_reader.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -609,9 +609,9 @@ gpujpeg_reader_read_com(uint8_t** image, const uint8_t* image_end, bool ff_cs_it
609609
}
610610

611611
static void
612-
quant_table_dump(unsigned index, const struct gpujpeg_table_quantization* table)
612+
quant_table_dump(int Pq, int Tq, const struct gpujpeg_table_quantization* table)
613613
{
614-
printf("quantization table 0x%02x:", index);
614+
printf("quantization table 0x%02x (%d-bit, dst: %d):", Pq << 4 | Tq, Pq == 0 ? 8 : 10, Tq);
615615
for ( int i = 0; i < 64; ++i ) {
616616
if ( i % 8 == 0 ) {
617617
printf("\n");
@@ -673,7 +673,7 @@ gpujpeg_reader_read_dqt(struct gpujpeg_decoder* decoder, uint8_t** image, const
673673
gpujpeg_table_quantization_decoder_compute(table);
674674

675675
if (decoder->coder.param.verbose >= LL_DEBUG2) {
676-
quant_table_dump(index, table);
676+
quant_table_dump(Pq, Tq, table);
677677
}
678678
}
679679
return 0;

0 commit comments

Comments
 (0)