I have attached a sample EPUB with four sets of images (times all four formulas), each inside of their own grey boxes:
#1. No Transparency (Removed and saved right from GIMP just like the tutorial) (8bpp Grayscale)
#2. Transparent formula (Inkscape -> GIMP -> Mode -> Grayscale -> Saved) (32bpp Grayscale)
#3. Transparent formula (Inkscape) (32bpp Grayscale)
#4. Transparent formula (fed through ScriptPNG to optimize) (Indexed 256)
Sadly, I don't have any physical Kindles to test on (I would not trust Kindle Previewer one iota when dealing with situations such as this).
Quote:
Originally Posted by Hitch
And of course, in Kindle, all PNG's are converted to GIF images for the mobi files.
|
There used to be a KindlGen bug where transparent PNGs turned the transparency into a black background. I just looked up the changelog, and I see this was fixed in KindleGen 2.5:
https://kindlegen.s3.amazonaws.com/d...e%20Notes.html
Quote:
- Improved transparent PNG conversion: Transparent PNG images (now converted to JPEG) will use white background. This originally used black background during conversion causing degraded reading experience.
|
According to the documentation, I always thought that KindleGen:
- All PNG -> GIF.
- Transparent PNG -> GIF with white background.
No clue why they would go from Transparent PNG to JPG!!!
I fed my Transparency Test EPUB into Kindle Previewer, and I found a few things to note:
- 32bpp Grayscale from GIMP turn into big black boxes. (This is the bug?)
- I unpacked the Kindle file with "KindleUnpack", and I see that it converts
- #3 and #4 to JPG with white background (GAH).
- #1 gets converted to GIF.
- #2 is a GIF, but is just a big black box.
The bug:
I believe these images will speak for themselves:
On to the causes of the Bug:
This is all just educated guesses.
I used Imagemagick's "identify -verbose" on all 4 versions of Formula #1 (verbose output attached to this post). After comparing the output closely, I can see that the only major difference between Inkscape's version and GIMP's version is between color type:
https://en.wikipedia.org/wiki/Portab...cs#Color_depth
Inkscape's is set to 6 (RGB + Alpha) while GIMPs is set to the proper 4 (Grayscale + Alpha).
Guess: Perhaps KindleGen can't handle PNG Color Type 4 images?
Request:
Can someone with a lot more image experience create Grayscale + Alpha images and feed them into KindleGen/Previewer? Perhaps try to create them from a different program besides GIMP (maybe Photoshop, or the multitude of others).
Edit:
I just tested this on my Nook + ADE, and it seems like ADE likes to break on the ScriptPNG (Indexed + Transparency), but works fine on the others. The causes of this one? No clue, maybe an Indexing + transparency is EXTREMELY rare.
I would say avoid Transparency PNGs for now.