Closed shssoichiro closed 5 days ago
Your software & so your decision, but not out-of-scope? This is done already by so many software (in so many ways), & needn't bloat oxipng
's codebase.
Your software & so your decision
I created the issue so I wouldn't forget about it.
but not out-of-scope
Possibly. However, I was tired of having to use two programs every time all I really wanted to do was make an image smaller in size. If everyone thinks it's a waste of time though, then it probably is and I'll just make a batch script.
@shssoichiro The only inkling I have toward how this would be apropos for oxipng
is:
a|png
that works hand-in-hand w/ how its compression does (something like losslessly cropping JPG), & so isn't implemented by general algorithms in other softwareoxipng
's code complexity beyond maintenance limitsPerhaps that exists/can be developed? But would take research! 🙇🏾♂️
For what it's worth, as a developer and Oxipng user, I wouldn't naturally think of using Oxipng for standard image resizing tasks, nor expect it to include that feature. Instead, I'd rely on one of the many dedicated image resizing tools out there, then pass the result to Oxipng for optimization.
That said, if there's a smart, lossless way to resize PNGs, or one that interacts more effectively with compression and is overlooked by standard resizing algorithms (similar to the example mentioned by @TPS), I'd be down to experimenting with such a feature in Oxipng!
This is a use case that has arisen as I've frequently found myself taking screenshots on PS5 or Xbox, which are in 4k, and wanting to upload them to Discord. The 4k PNGs coming from the console are still quite large after being run through oxipng. However, if they were downscaled to 1080p, this would significantly reduce the file size.
This is obviously lossy and should be optional, disabled by default.