java - How can we read Lossless compressed JPEG images -



java - How can we read Lossless compressed JPEG images -

i have medical images , compressed lossless images. these images can read in matlab , accusoft java api.

how can load these type of images in java?

my current code is:

image img = null; imageinputstream iis = new fileimageinputstream(file); (iterator<imagereader> = imageio.getimagereaders(iis); img == null && i.hasnext();) { imagereader r = i.next(); seek { r.setinput(iis); img = r.read(0); } grab (ioexception e) { e.printstacktrace(); } } system.out.println("imagee : "+img);

but getting exception :

javax.imageio.iioexception: unsupported jpeg process: sof type 0xc3 @ com.sun.imageio.plugins.jpeg.jpegimagereader.readimageheader(native method) @ com.sun.imageio.plugins.jpeg.jpegimagereader.readnativeheader(jpegimagereader.java:609) @ com.sun.imageio.plugins.jpeg.jpegimagereader.checktablesonly(jpegimagereader.java:347) @ com.sun.imageio.plugins.jpeg.jpegimagereader.gotoimage(jpegimagereader.java:481) @ com.sun.imageio.plugins.jpeg.jpegimagereader.readheader(jpegimagereader.java:602) @ com.sun.imageio.plugins.jpeg.jpegimagereader.readinternal(jpegimagereader.java:1059) @ com.sun.imageio.plugins.jpeg.jpegimagereader.read(jpegimagereader.java:1039) @ javax.imageio.imagereader.read(imagereader.java:939) @ losslessimagereader.losslessimagereader.main(losslessimagereader.java:49)

please help me solve problem.

java image image-processing lossless-compression

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

django - Access session in user model .save() -

php - .htaccess Multiple Rewrite Rules / Prioritizing -