-
-
Notifications
You must be signed in to change notification settings - Fork 312
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for TIFF compression types 3 and 4 (CCITT Group 3/4 Fax encoding) #61
Comments
Hi Hazem, Thanks for reporting! My TIFFImageReader does not yet support "CCITT Group 3 fax encoding" aka T4 or "CCITT Group 4 fax encoding" aka T6 (TIFF compression tag constants 3 and 4) as these are not "Baseline" TIFF Class B compression types. Your TIFF file uses the former compression. I'd like to support these compression types in the future, as they are very common. Feel free to submit a patch, if you have some time! :-) If not, I'll look into it when I find the time. Best regards, Harald K |
I am very interested in this, and although a side-request, a 'best usage' of Twelvemonkeys for taking a TIFF, split out some pages, and create a new TIFF with those selected pages (something we did with the old JAI library). Reference thread around this common challenge: http://stackoverflow.com/questions/17770071/splitting-a-multipage-tiff-image-into-individual-images-java |
+1 CCITT 4 |
Hi guys, I'd really like to implement it, it's on the list but didn't make it to 3.1. If anyone has some spare time to implement the T4 and T6 decompression algorithms, I'd be very happy to integrate that (bilevel reading is already fully done). :-) Otherwise, stay tuned. Harald K |
Maybe a possible idea for the Google Summer of Code? Github has been accepted as organization. It is still a lot of work mentoring the student (in my case: 5-10 hours a week), but less than coding it yourself :-) |
@THausherr That is an interesting idea! Not sure I have 5-10 hours/week available, though. And if I had, I might as well just do it myself. :-) But will definitively consider it! Harald K |
I'm currently trying to implement Group 3 / 4 decoding. As soon as i'm satisfied with the results i will make a pull request. However, i'm currently having problems with determining the correct reference row changing elements in Group 4 images. |
Is there any hope for a pure Java implementation of Group 4 en/decoding performing on par with JAI native libs? |
@Schmidor This is great news! I was planning to have a stab at this some time soon, but if you can make it work, that leaves me with more time for JPEG-Lossless. :-) Let me know if I can help in any way (feel free to contact me by direct email)! I'd need to read up on the specs, and possibly need to see some code to be able to help with the exact problem you are referring to... But at least good to see that someone is working on this! Best regards, Harald K |
@rlauck Not sure. But I also don't see why not. :-) In any case, if you need the native performance (and don't have a problem installing native libs and JNI stuff), using either JAI or even creating a separate plugin backed by LibTIFF shouldn't be a problem. The goal of this project is to have everything written in Java, for easy deployment and predictable behaviour. Harald K |
I think i've got it, just a wrong start index in 2d encoding. One thing left is wheter the decoder should know about PhotometricInterpretation and output accordingly or whether it always should output WhiteIsZero and the Tiff Reader should invert it at a later stage. |
Cool! I'll have a look (I'm currently on holiday, so it may take some time). The idea so far has been to keep the Otherwise, this looks like a very valuable addition to the TIFF reader! Thanks, Harald K |
I am trying to read the following image https://www.dropbox.com/s/zpjfppfjcz0emb8/image.tiff?dl=0
The imageio plugins are loaded and I can read other tiff images, but when I try reading this specific one ImageIO.read(new FileInputStream("image path")) returns null
The text was updated successfully, but these errors were encountered: