-
Notifications
You must be signed in to change notification settings - Fork 12
Allow preserving aspect ratio #19
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
Comments
Hi. I tested it and it appears to work as intended. However, I don't really understand the use case for this. Resizing, whether called explicitly or by --profile, implies modifying the aspect ratio. Perhaps it's not clear by the comment, but what I mean by "preserve aspect ratio", is try to preserve the orientation of landscape images. The fixed layout specification for ebooks says that content should fill the entire screen, so the current implementation is intentional. See this. Having images not be resized to the size the user specified seems counterintuitive to me, and the whole point a fixed layout ebook is that it should behave consistently regardless of what the input image was. Most manga and comics don't follow exactly a 3:4 format, and will be stretched to some degree, but this is usually pretty minor. Tankobon published in the West typically follow a 130x190 aspect ratio, which appears to be very similar to western comics. |
Though I can see why an option to preserve aspect ratio would be useful. The default method could be a problem when dealing with webcomics, cause there isn't really a standard size, and stretching a perfectly square image into a (generally) 3:4 screen would probably look really bad, so I might implement the thumbnail method there. Thanks for the suggestion. I will try to add this in the next week. |
For the time being, if you wanna preserve the aspect ratio, you can use --size 0x0 ( |
it should fill as much of the viewport as possible, not distort images to fill every last pixel of it. no one does that, not the publishers, not online scanlations, not kindle comic converter. |
Okay, you're right and I apologise, it seems I really misunderstood the spec. I'll be at least a few weeks before I can work on this, I'm in the middle of moving. In the meantime, you can make it your patch into a full pull request if you want. |
I tried to add this: #20 |
I added this PR to my project: BelardoA/reCBZ2#1 I decided to create a new project since this one has been abandoned. |
Uh oh!
There was an error while loading. Please reload this page.
images are resized to the exact output resolution without keeping their correct aspect ratio. ive attempted to fix this. ive tested with both up- and downscaling and it worked perfectly for me, but please test it for yourself first too. (i commented out the old method)
archive.py starting at line 131:
The text was updated successfully, but these errors were encountered: