From fe100fb49038b246888fde40878c92ae4878f673 Mon Sep 17 00:00:00 2001 From: Mathieu Malaterre Date: Thu, 13 Mar 2014 10:35:41 +0000 Subject: [PATCH] [trunk] Add debug code to extract decompressed image right before PCLR handling Update issue 235 --- src/lib/openjp2/j2k.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/lib/openjp2/j2k.c b/src/lib/openjp2/j2k.c index ce5ef77f..e446dab0 100644 --- a/src/lib/openjp2/j2k.c +++ b/src/lib/openjp2/j2k.c @@ -9322,6 +9322,13 @@ OPJ_BOOL opj_j2k_decode(opj_j2k_t * p_j2k, for (compno = 0; compno < p_image->numcomps; compno++) { p_image->comps[compno].resno_decoded = p_j2k->m_output_image->comps[compno].resno_decoded; p_image->comps[compno].data = p_j2k->m_output_image->comps[compno].data; +#if 0 + char fn[256]; + sprintf( fn, "/tmp/%d.raw", compno ); + FILE *debug = fopen( fn, "wb" ); + fwrite( p_image->comps[compno].data, sizeof(OPJ_INT32), p_image->comps[compno].w * p_image->comps[compno].h, debug ); + fclose( debug ); +#endif p_j2k->m_output_image->comps[compno].data = NULL; }