Open GoogleCodeExporter opened 9 years ago
Attaching as patch directly
Original comment by mathieu.malaterre
on 29 Aug 2012 at 7:00
Attachments:
Original comment by mathieu.malaterre
on 10 Sep 2012 at 9:30
The code is not using C90 convention, which makes it hard to apply as-is:
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c: In
function 't1_enc_updateflags':
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:400:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:402:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:410:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:412:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:428:4:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:441:4:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c: In
function 't1_enc_sigpass_step':
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:493:2:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c: In
function 't1_enc_refpass_step':
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:745:2:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c: In
function 't1_enc_clnpass_step':
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:983:2:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:996:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c: In
function 'allocate_buffers':
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1330:2:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1346:11:
error: pointer targets in initialization differ in signedness
[-Werror=pointer-sign]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1346:2:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1352:4:
error: pointer targets in assignment differ in signedness [-Werror=pointer-sign]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1359:5:
error: pointer targets in assignment differ in signedness [-Werror=pointer-sign]
/home/mathieu/Projects/openjpeg/branches/openjpeg-1.5/libopenjpeg/t1.c:1360:3:
error: ISO C90 forbids mixed declarations and code [-Werror=edantic]
cc1: all warnings being treated as errors
make[2]: ***
[applications/mj2/CMakeFiles/frames_to_mj2.dir/__/__/libopenjpeg/t1.c.o] Error 1
Original comment by mathieu.malaterre
on 10 Sep 2012 at 9:31
Attached a new version of the patch with a few tweaks and also C90
compatibility.
Original comment by c...@carlh.net
on 10 Sep 2012 at 10:56
Attachments:
Also, I just noticed that I didn't put back support for the J2K_CCP_CBLKSTY_VSC
flag. Although this doesn't seem to be set anywhere within libopenjpeg; could
it be removed?
Original comment by c...@carlh.net
on 10 Sep 2012 at 10:58
Original comment by mathieu.malaterre
on 14 Mar 2014 at 3:14
Hi,
I updated the patch for tag 2.1.0, thought I'll share it with everyone.
Still no support J2K_CCP_CBLKSTY_VSC & limited non regression tests (I use a
custom set of images as I do not have access to external svn proxy at work -
proxy issues)
Please find some time ratios below (using also updated patch from Issue 220).
The whole encoding time is taken into account, not only t1 enc. Input images
are 8bit grayscale images encoded using 9/7 wavelet. Timings include
8bit->32bit conversion.
0,878843317 (linux x86 gcc4.4)
0,878999168 (linux x64 gcc4.4)
0,906621081 (linux armv7 gcc4.6)
0,924342459 (linux armv5 gcc4.6)
0,878114055 (windows x86 vc7)
0,832016242 (windows x86 vc8)
0,880686491 (windows x64 vc8)
0,829962365 (windows x86 vc10)
0,884205368 (windows x64 vc10)
Regards,
Matthieu
Original comment by m.darb...@gmail.com
on 28 May 2014 at 7:07
Attachments:
Hi Matthieu,
Thanks for the patch. Is there a way to put back support for
J2K_CCP_CBLKSTY_VSC in the patch ?
J2K_CCP_CBLKSTY_VSC is actually set through the "parameters->mode" field
Antonin
Original comment by antonin
on 2 Jun 2014 at 9:15
Hi Antonin,
I do not feel very comfortable doing this. For now, this work has not required
much understanding of the algorithm, it was only a port from Carl's patch to
2.1.0 release.
Maybe Carl can lend a hand on this one ?
I'll see what I can do but no promises (& I probably won't have time to start
digging into this before august)
Original comment by m.darb...@gmail.com
on 4 Jun 2014 at 5:48
+1 for getting this patch into the mainline
Original comment by boxe...@gmail.com
on 18 Jul 2014 at 3:44
Regarding VSC, is this feature used very much? I understand that it leads to
poorer
compression ratios than default t1 encoding.
Original comment by boxe...@gmail.com
on 18 Jul 2014 at 3:45
Original comment by antonin
on 18 Jul 2014 at 11:07
For those who may find it useful, I have taken Matthieu's version of the patch
and created a branch for it in my OpenJPEG mirror:
https://github.com/OpenJPEG/openjpeg/tree/carls-t1-patch
Original comment by boxe...@gmail.com
on 15 Sep 2014 at 8:52
Original issue reported on code.google.com by
mathieu.malaterre
on 29 Aug 2012 at 6:59