troosh / openjpeg

Automatically exported from code.google.com/p/openjpeg
Other
0 stars 0 forks source link

dump issue with one conformance file: file9.jp2 #96

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. j2k_dump -i file9.jp2 -o dump-file9.jp2-1.txt
2. j2k_dump -i file9.jp2 -o dump-file9.jp2-2.txt
3. compare the output files

Dump is correctly done but output is variable. More precisely stepsize values 
are different. 

Original issue reported on code.google.com by savmick...@gmail.com on 7 Oct 2011 at 1:45

GoogleCodeExporter commented 9 years ago
valgrind is going nuts on this file:

[INFO] tile 1 of 1
[INFO] - tiers-1 took 7.724482 s
[INFO] - dwt took 0.256016 s
[INFO] - tile decoded in 8.204513 s
==22574== Invalid read of size 4
==22574==    at 0x4042D8: j2k_dump_cp (j2k_dump.c:642)
==22574==    by 0x403C91: main (j2k_dump.c:517)
==22574==  Address 0x5f561f4 is 0 bytes after a block of size 1,076 alloc'd
==22574==    at 0x4C244E8: malloc (vg_replace_malloc.c:236)
==22574==    by 0x402ABA1: j2k_read_siz (j2k.c:602)
==22574==    by 0x402E5B6: j2k_decode (j2k.c:1919)
==22574==    by 0x4031CBE: opj_jp2_decode (jp2.c:749)
==22574==    by 0x4034DCF: opj_decode_with_info (openjpeg.c:168)
==22574==    by 0x4034D41: opj_decode (openjpeg.c:157)
==22574==    by 0x403BC9: main (j2k_dump.c:500)

Original comment by mathieu.malaterre on 29 May 2012 at 4:35

GoogleCodeExporter commented 9 years ago
Breakpoint 3, j2k_read_siz (j2k=0x418300) at 
/home/mathieu/Projects/OpenJPEG/svn/branches/openjpeg-1.5/libopenjpeg/j2k.c:602
602     j2k->default_tcp->tccps = (opj_tccp_t*) opj_calloc(image->numcomps, 
sizeof(opj_tccp_t));
(gdb) p image->numcomps
$3 = 1

and then:

Breakpoint 4, j2k_dump_cp (fd=0x418010, img=0x41a730, cp=0x419970) at 
/home/mathieu/Projects/OpenJPEG/svn/branches/openjpeg-1.5/applications/codec/j2k
_dump.c:642
642             fprintf(fd, "      csty=%x\n", tccp->csty);

(gdb) p img->numcomps
$4 = 3

CQFD

Original comment by mathieu.malaterre on 29 May 2012 at 4:59

GoogleCodeExporter commented 9 years ago

Original comment by mathieu.malaterre on 25 Feb 2014 at 3:27

GoogleCodeExporter commented 9 years ago
I can no longer reproduce this behavior, this has been fixed since then. 
closing.

Original comment by mathieu.malaterre on 27 Feb 2014 at 10:16

GoogleCodeExporter commented 9 years ago

Original comment by anto...@gmail.com on 24 Mar 2014 at 3:57