Skip to main content
GameDev.net gamedev.net

[TOOL] Batch image compression for Windows

Started by IronTusk Wednesday at 7:28 PM 5 replies 300+ views
Original Post
IronTusk
IronTusk

Hi everyone,

I’ve released PNG Stomp, a Windows desktop tool for batch image compression through TinyPNG.

https://irontuskgames.itch.io/irontusk-png-stomp

I built it for my own game dev workflow. My renders and other art assets, mostly PNGs, were often much larger than I wanted, even after exporting them from Photoshop or other apps. I wanted an easy way to compress a whole folder without processing each image manually.

Just drag in a folder or individual files, choose where to save the compressed copies, and hit Compress.

Features

  • Processes images in folders and their subfolders.

  • Supports PNG, JPG/JPEG, WebP and AVIF.

  • Accepts files and folders through drag and drop.

  • Saves compressed copies without changing your originals.

  • Adds numbered suffixes when output filenames already exist.

  • Reports progress, file-size savings and monthly API usage.

  • Saves your API key in Windows Credential Manager after setup.

An example from my own assets

A 4096 × 4096 PNG render went from 64.1 MB to 3.6 MB, a 94.3% reduction. That's an extreme example. Compression savings vary by image of course.


TinyPNG provides 500 free API compressions per account each month. PNG Stomp makes using their service fast and easy without logins or web interfaces. Drag and drop 100 images at once and be done!

Screenshots, setup instructions and download

https://irontuskgames.itch.io/irontusk-png-stomp

Thanks for taking a look. I’d welcome feedback from developers and artists who regularly work with folders of image assets. There’s also a community page for bug reports and feature requests.

fastcall22
fastcall22

multimedia codecs and compression are a few of my favorite areas of interest. i am also a web developer who happens to have a healthy prejudice against web services that wrap free tools but also have a live backend for some reason. (you know, things like online base64 codec services, exif stripping services, and others. javascript can do that locally, why is this webapp asking a server to do the work? is it storing a copy of this data? what is its terms of services and privacy policy?)

anyway,

how does this tool compare against free tools such as pngquant, pngcrush, imagemagick, and ffmpeg?
does this tool have any added value other than a thin wrapper around the tinify API?
why should one choose to use tinify at all? why risk exposing unpublished and proprietary assets to a third party?
was generative AI used to build png stomp? currently, its presentation strongly gives that impression.

IronTusk wrote:

I built it for my own game dev workflow. My renders and other art assets, mostly PNGs, were often much larger than I wanted, even after exporting them from Photoshop or other apps.

or, you could consider lossy compression at that point; codecs such as AV1, HEVC/H.265, ASTC, or BC7.

IronTusk wrote:

I wanted an easy way to compress a whole folder without processing each image manually.

it would be trivial to write such a script, add it to the toolchain and the asset pipeline. literally 15 minutes of work and would have never considered using a third party service, let alone involve TWO third parties...

fastcall22
fastcall22

man, the more i think about the existence of your png stomp, the more i want to defenestrate my computer lol.

a couple of bucks for the privilege to drag-and-drop files to another paid subscription service?

fucking ridiculous. get fucked.
(sure, they have a free tier, but you sure don't.)

get a better asset pipeline, and keep your slopware to yourself. nobody asked for this.


FAKE EDIT:
upon further review, i have independently reviewed my post and have determined that this is the appropriate level of reaction that one should have in the face of the sloppiest of slopware.

thank you for your attention to this matter, okthxbai

IronTusk
IronTusk

I’m still learning. This started as a way to learn how to make a UI in Python and build something. I also wanted to go through the process of releasing software so I could learn that part too. I wasn’t expecting ANY sales.

Your first post made a fair point about the privacy concerns of uploading assets to TinyPNG. I hadn’t considered that, and I appreciate you bringing it up.

I know this is a simple tool, and an experienced developer could make something similar pretty easily. I’m not claiming otherwise. But there’s a difference between pointing out its limitations and editing my post to call it “slopware” and telling me to “get fucked.”

That feels like an experienced developer picking on someone with far less experience who is trying to learn. I’m open to criticism. I don’t think the personal insults were necessary. I didn't expect to get any attention for this honestly.

You seem pretty knowledgeable with compression and codecs. You listed examples of software that do these things and you clearly know that mine doesn't. It's like to came over to my house just to take a dump on the carpet and leave the front door open.

You know the worst part of all this? Besides your humiliation and editing my post to look the way it does... Is that AI could have made the entire thing in probably 120 seconds. But I spent months trying to figure it out, forgetting eveything i learned everytime I took a break and came back to it. That's the real burn I guess.

So, despite your clear behavior issues, I apologize for infuriating you so much and I apologize to the community for having posted my slopware.

fastcall22
fastcall22

no, that's fair.

i overreacted. nobody deserves to be treated that way, and i have caused great harm to you and our community. for that, i apologize.

i have restored your original post. i'm leaving my post as-is, as a testament to how much of a miserable piece of shit i am. it would it be cowardly to try to hide it. (hiding the post, i mean... though, referring it the other way is pretty funny, too.)

...

hearing you talk about learning to build png stomp has reminded me of when i first started, and of some of my own terrible ideas i thought other developers would want... well, let's just say that it was for the best they never saw the light of day.

generative AI has made entire industries more approachable than ever. there is no place to escape the onslaught of AI generated content. i fear there is huge risk of simply giving in to generative AI-- to skip learning through struggling, to skip building scar tissue from trying and failing.

i don't deserve forgiveness, and hope you continue on your journey.

Sign in to reply to this topic.