Image Optimization (PNG) Tools

You’re making a game, and you know what platform you are aiming to release the game on. You wipe out all the audio for the other platform…. And your game is still too big? Whaa? How does that happen? You’ve even emptied out the unused animations from the database! I know I’ve asked myself, “just what is in this game anyway?”


Well, your game, my game, and those folks over there too are in the same boat. Use overlays? Plugins? Parallax? It simply doesn’t matter, all of us have a collection of PNG images. Go ahead, right click on your “IMG” folder in one of your projects, and select properties. Check out the size of that thing! Obviously, getting rid of unused images will help, but what if there was something more you could do?

Spoiler: Non Optimized Image, 4.8 KB.
Image_NonOptimized.png

I wouldn’t have started writing this if there wasn’t. It’s time to optimize those images. The PNG format stores a variety of data, from headers and metadata to pallets that can all be tweaked. All of them can get some level of compression on them, and some can see as much as a 70% size reduction. So, the trick comes down to the tools.


Google for PNG optimization, and you’ll get results for all the webmasters out there who use PNGs on their websites. There’s TinyPNG, OPtimizePNG, ezgif, and a host of others. Most of them have a daily and/or a monthly limit; then, they charge for it. (They then pay Google for a higher position on results pages to catch more hapless victims!) Not terribly useful for a game that has 400M of sprite-sheets, face images, and busts. We need a tool.

Spoiler: Same Image Optimized, 2.5 KB.
Image_Optimized.png

Luckily, there are several, and they’re free. I’ll list them below, but I use Psydk’s PngOPtimizer (actually the PortableApps version of it). All you have to do is get one, and then use the chosen app to reduce your filesizes. You will have to test your game before distributing it, because sometimes any of the optimization software can misinterpret data and introduce an error. However, most of the tools available will create a backup of the original (PngOptimizer creates a duplicate file with a leading underscore in the same directory).


Once you’ve tested your game, delete the extra files. You will usually find about a 25 % - 33% total reduction in the size of your IMG directory. This is before any RAR or ZIP compression. Make sure to read the instructions for whichever optimizer you choose!


Small List of PNG Optimizing Software





NOTE: I will NOT link to any online optimizer services, as they are basically rip-offs.
you miss Tinypng which is awesome tool, up to 20 images, max 5mb each and reduce to 70%, simply F5 and you can do it again
over and overand i have it as well for photoshop to save time when saving the image, so a clean project really starts around 200-225MB
instead of 300-350mb 😀
quickest cheapest way to lighten a PNG, is to make it 8-bit palette.
you can do that with whatever program.
A good call @gstv87! Still, that would involve loading every tile set, character sheet, and system image into GiMP (or paint.net, or photoshop), and re-saving. With PngOptimiser, we can simply drag a folder into the app-window, check if everything works, and then delete "_*.*" from the image directory.

@ShadowDragon While I've used tinypng before, I feel that the limitation and F5 trick was not worth discussing since there are free apps that do the job nearly as well. With that said, I cannot fault the quality from tinypng, I don't think I've ever gotten a bad image from that site.
I've done 50 or more at a time on tiny.ping and I've never been charged. I tend to do mine in batches as I go along, not save them up for a mammoth session at the end.
i love to use tiny png, but if you want to bulk the images over 20, than a small fee is paid, otherwise its free,
the only cons i know of tiny png are gradiant colors than dont make it not nice as the view you made,
even when using tinypng in photoshop when saving, same result, everything besides any gradient = topquality.

but that is my opinion though. I dont know any other app as well and didn't know its name.
Definitely nothing wrong with TinyPNG, but having a local app has other benefits too. The main point though, is to remember to optimize the images. 😀
A good call @gstv87! Still, that would involve loading every tile set, character sheet, and system image into GiMP (or paint.net, or photoshop), and re-saving. With PngOptimiser, we can simply drag a folder into the app-window, check if everything works, and then delete "_*.*" from the image directory.

yeah, but if you're a graphic artist, you already do that while designing your tileset.
these tools are the last step, in case you want to compress them even more.
you can already cut a big chunk of the load directly at design time.
@gstv87 Very true. I just didn't see any threads on the subject, and we do get new people here every day. I thought it would be nice to have the subject mentioned.
PNGGauntlet (newer software, requires .NET): https://pnggauntlet.com/
As a heads-up, this has ceased being developed. Just FYI.
I wish posts like this one could be meshed into some sort of tutorial. There's a lot of compression opportunities, but new designers don't know what to trust or if they will lose quality. For a lot of us, Ogg files are big consumers too. https://github.com/OptiVorbis/OptiVorbis
I wish posts like this one could be meshed into some sort of tutorial. There's a lot of compression opportunities, but new designers don't know what to trust or if they will lose quality. For a lot of us, Ogg files are big consumers too. https://github.com/OptiVorbis/OptiVorbis
did you test it, does it break ogg metadata?
did you test it, does it break ogg metadata?
I did not test, but posted since it was on open source, which is always a plus.
I did not test, but posted since it was on open source, which is always a plus.
I did - only on two files, and they seem ok. It didn't wipe the metadata out so thats a start.

Original thread: https://forums.rpgmakerweb.com/threads/image-optimization-png-tools.110142/