Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 03-22-2011, 02:30 AM   #31
psycholoner
Enthusiast
psycholoner began at the beginning.
 
Posts: 34
Karma: 22
Join Date: Jul 2010
Device: Kindle DXG
I'm having a rough time with this program. I'm converting for a DXG, so I'm using 1200 and 824 (Yes, I have the numbers in the right boxes.). It seems to want to rotate portrait images when It's not supposed to. I tried it on lower resolutions, and it isn't as bad, but I still have a couple of images that get rotated by mistake.

Theres also this weird problem that happens when it does rotate in this way. In the case where it rotates when its not supposed to, the picture gets scaled to 1200 height AFTER its rotated. This means that the width ends up being something around 1700, regardless of the 800 pixel limit.

I'll wait a bit longer for this program.
psycholoner is offline   Reply With Quote
Old 03-22-2011, 03:54 AM   #32
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by glennrp View Post
Could you be more specific about what pngcrush did to the images? It should not have changed their appearance.
Setting the color pallet to 16 make the images look very bad (they open just fine in windows image viewer). Seems like the Kindle has a slight problem with its png decompresser.

Quote:
Originally Posted by psycholoner View Post
I'm having a rough time with this program. I'm converting for a DXG, so I'm using 1200 and 824 (Yes, I have the numbers in the right boxes.). It seems to want to rotate portrait images when It's not supposed to. I tried it on lower resolutions, and it isn't as bad, but I still have a couple of images that get rotated by mistake.

Theres also this weird problem that happens when it does rotate in this way. In the case where it rotates when its not supposed to, the picture gets scaled to 1200 height AFTER its rotated. This means that the width ends up being something around 1700, regardless of the 800 pixel limit.

I'll wait a bit longer for this program.
Already fixed that in the current dev version. Didn't notice it until I converted a shitload of manga

Edit:

Screw it, new version with bugfixes, full multithreading now available in OP. (Custom settings and saving of settings will be in the next release)

psycholoner check it out and if the images are still falsely rotated, could you please PM one of the to me, to see what the problem is?

Last edited by Honf; 03-22-2011 at 04:26 AM.
Honf is offline   Reply With Quote
 
Enthusiast
Old 03-22-2011, 08:53 AM   #33
glennrp
Junior Member
glennrp began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Mar 2011
Device: kindle
Quote:
Originally Posted by Honf View Post
Setting the color pallet to 16 make the images look very bad (they open just fine in windows image viewer). Seems like the Kindle has a slight problem with its png decompresser.
Yeah, if you simply used
Code:
pngcrush -plte_len 16 ...
it could generate an invalid PNG. That dangerous option is only for truncating a palette with unused entries at the top. To actually quantize your image down to 16 colors with pngcrush you also need to set the bit-depth to 4, i.e.,
Code:
pngcrush -bit_depth 4 -plte_len 16 ..
which simply drops the low 4 bits of each color sample, or you could use another application like ImageMagick or pngquant to get a better-looking quantization. I'll look into making pngcrush give a better error return if valid palette entries are being truncated with the -plte_len option. ../glennrp
glennrp is offline   Reply With Quote
Old 03-22-2011, 09:15 AM   #34
Tarr
Member
Tarr began at the beginning.
 
Posts: 20
Karma: 10
Join Date: Feb 2011
Device: Kindle 3 Wifi
Thanks!
Tarr is offline   Reply With Quote
Old 03-22-2011, 09:48 AM   #35
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by glennrp View Post
Yeah, if you simply used
Code:
pngcrush -plte_len 16 ...
it could generate an invalid PNG. That dangerous option is only for truncating a palette with unused entries at the top. To actually quantize your image down to 16 colors with pngcrush you also need to set the bit-depth to 4, i.e.,
Code:
pngcrush -bit_depth 4 -plte_len 16 ..
which simply drops the low 4 bits of each color sample, or you could use another application like ImageMagick or pngquant to get a better-looking quantization. I'll look into making pngcrush give a better error return if valid palette entries are being truncated with the -plte_len option. ../glennrp
-bit_depth 4 -plte_len 16 is the exact setting I used. And it produced horrible images (they opened fine in windows, horrible on kindle). I'll try it out again and I'll open up the commands that pngcrush receives in case anyone will feel adventurous and would like to change them or optimize them.
I'd gladly take better default settings though, if you would find them.
Honf is offline   Reply With Quote
Old 03-22-2011, 10:39 AM   #36
glennrp
Junior Member
glennrp began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Mar 2011
Device: kindle
Quote:
Originally Posted by Honf View Post
-bit_depth 4 -plte_len 16 is the exact setting I used. And it produced horrible images (they opened fine in windows, horrible on kindle). I'll try it out again and I'll open up the commands that pngcrush receives in case anyone will feel adventurous and would like to change them or optimize them.
I'd gladly take better default settings though, if you would find them.
I've just released pngcrush-1.7.15 (source only right now) which will automatically reduce the bit depth to 1, 2, or 4 when the plte_len option is used without the bit_depth option, to avoid generating invalid palette entries (which unfortunately won't help you because you did not omit the -bit_depth option). I don't know why the Kindle images would look different from the Windows ones, unless the Kindle is mis-handling sub-8-bit PNG images. If that is the case you might be able to deal with that by using the current version of ImageMagick (IM-6.6.8-6) to write the images as PNG8 and then pngcrush them with no options.
glennrp is offline   Reply With Quote
Old 03-22-2011, 11:18 AM   #37
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
I am already saving images as PNG8, I think (8 bits per pixel, right?)... Would seems to be a problem in the Kindles handling of sub 8 bit depth images (just retried and the same thing happened, horrible quality on kindle fine on windows). Oh, I hope you don't mind me attaching the pngcrush.exe, didn't ask if I could


Updated OP with new version, found bug that prevented generation of bookkeeping files.

Edit:
My bugfix had a bug in it. version 2 of 0.26 is in OP. Also added the last two versions in case there are more bugs in the latest.

Last edited by Honf; 03-22-2011 at 12:39 PM.
Honf is offline   Reply With Quote
Old 03-22-2011, 02:31 PM   #38
mobad
Enthusiast
mobad began at the beginning.
 
Posts: 27
Karma: 23
Join Date: Jan 2011
Device: Kindle 3 WiFi
You should make the created images only use the the 16 colours that the Kindle supports http://kindlesavers.com/resources/ho...-screensavers/
The Kindle handles 4 bit depth gifs depth much better (Although there may be a problem with 3.1 and gifs, not really sure), they are smaller and have the same quality as pngs.
mobad is offline   Reply With Quote
Old 03-22-2011, 02:45 PM   #39
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by mobad View Post
You should make the created images only use the the 16 colours that the Kindle supports http://kindlesavers.com/resources/ho...-screensavers/
The Kindle handles 4 bit depth gifs depth much better (Although there may be a problem with 3.1 and gifs, not really sure), they are smaller and have the same quality as pngs.
I already do that since the first version Gif support will be added and I'll give an option to chose the output format. Until then it's only pngs

Last edited by Honf; 03-22-2011 at 02:52 PM.
Honf is offline   Reply With Quote
Old 03-22-2011, 02:54 PM   #40
mobad
Enthusiast
mobad began at the beginning.
 
Posts: 27
Karma: 23
Join Date: Jan 2011
Device: Kindle 3 WiFi
I checked when it first came out and and I just rechecked the sample images now with gimp and it isn't using the Kindle colour scheme.

Just want to mention the new version of Canti was just released and it has panel shrinking now and much more.
http://www.bitcake.com/?entry=entry110322-143300

Last edited by mobad; 03-22-2011 at 03:04 PM.
mobad is offline   Reply With Quote
Old 03-22-2011, 03:04 PM   #41
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Check example 2. Example 1 is broken (converted the kindle table you linked a little wrong ).

Edit:
Hm, seems Canti and Mangize are going to be in a feature battle. Good, competition helps drive development Canti for crossplatform, Mangize for speed

Last edited by Honf; 03-22-2011 at 03:12 PM.
Honf is offline   Reply With Quote
Old 03-23-2011, 04:57 PM   #42
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Version 0.3 released. Check OP.

- added progress bar
- updated user interface
- exposed more settings to user, should make it compatible with a lot more devices now
- added ability to save your settings
- fixed landscape rotation bug (caused some images to be falsely rotated, reported by psycholoner)





If the program crashed for anyone when they try to convert, please sent me the image it crashes on and the settings.ini file that gets created by mangize. I had to do a major re haul of the code and I fear some bugs inevitably creped in.
Honf is offline   Reply With Quote
Old 03-26-2011, 11:40 AM   #43
psycholoner
Enthusiast
psycholoner began at the beginning.
 
Posts: 34
Karma: 22
Join Date: Jul 2010
Device: Kindle DXG
tested 0.3 with 1200 by 824 again. pictures don't get limited by the width. I have pictures that are resized to 1200 by 834 etc..
psycholoner is offline   Reply With Quote
Old 03-26-2011, 05:49 PM   #44
Honf
Enthusiast
Honf began at the beginning.
 
Posts: 27
Karma: 18
Join Date: Mar 2011
Device: Kindle
Quote:
Originally Posted by psycholoner View Post
tested 0.3 with 1200 by 824 again. pictures don't get limited by the width. I have pictures that are resized to 1200 by 834 etc..
Ah, by fixing the random landscape rotation bug, I made a bug in the resizing step.

New version in OP, should fix the problem. If it doesn't could you PM me a sample picture? Much easier to track down bugs that way
Honf is offline   Reply With Quote
Old 03-31-2011, 02:54 PM   #45
bearmann
Member
bearmann has a complete set of Star Wars action figures.bearmann has a complete set of Star Wars action figures.bearmann has a complete set of Star Wars action figures.
 
bearmann's Avatar
 
Posts: 14
Karma: 258
Join Date: Feb 2011
Device: none
Hey there Honf,
great little app you wrote, thanks a bunch!

Just some quick questions and suggestions:

1) At this point Mangize doesn't support archives, does it? Because I get an empty XYZ_Processed folder when trying to convert zipped chapters.

2) When opening a file/folder it would be nice to remember the last position.

3) An option to convert pngs to jpegs would be nice - to save some additional space. Or is the output image quality of the jpegs substantially inferior to png?

regards and keep up the good work!
bearmann
bearmann is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Yet Another Kindle Manga converter... talz13 Kindle Developer's Corner 19 11-04-2010 09:08 AM
iRex-Feeder - Yet another stupid Manga-to-Pdf Converter Naratak iRex 0 09-17-2009 08:57 AM


All times are GMT -4. The time now is 05:14 AM.


MobileRead.com is a privately owned, operated and funded community.