javapng-8

Is there some library in Java to compress Png images like pngout?


Is there some library in Java to compress Png images like pngout, pngcrush, optipng which are written in C/C++?

In continuation to what Phil has commented below, what I meant was reducing the file size of the image generated by the ImageIO class in Java by removing information that is not needed, same as what pngout does. When I ran pngout on the images that were generated by ImageIO class I was able to get about 50% reduction in file size (reduction size will vary based on images). So I wanted to know if there is any tool or library that could be interfaced with Java so that image files produced ImageIO class can have their size reduced.


Solution

  • You could call an executable from Java to do the work, or you could wrap the library using SWIG and call it from Java.