Logo Background RSS

Advertisement

Compress PNG Files With PNGCrush

  • Written by luthfi.emka | No Comments Comments
    Last Updated: November 8th, 2009

    pngcrush

    The size to which the PNG image above was compressed may not seem like much, but the original image was already compressed. Besides, if you own a website, compressing ALL the images will most definitely make a difference, especially since – as you can see in the picture above – the quality is basically the same to the naked eye.

    The tool I used is called Pngcrush, a free and open source optimizer for PNG (Portable Network Graphics) files. It can be run from a commandline in an MSDOS window, or from a UNIX or LINUX commandline. Its main purpose is to reduce the size of the PNG IDAT datastream by trying various compression levels an PNG filter methods. It also can be used to remove unwanted ancillary chunks, or to add certain chunks including gAMA, tRNS, iCCP, and textual chunks.

    If you use Linux, Pngcrush should be in your Linux distribution repositories. For Ubuntu, use the following command to install it:
    sudo apt-get install pngcrush

    Using Pngcrush

    Pngcrush can use 114 different filters for optimizing PNG images. To let Pngcrush choose the best one for your images, you can use the -brute option.

    To compress a single image:

    pngcrush -brute -e ".compressed.png" image.png

    “-e” tells Pngcrush to append the “.compressed.png” name to the initial image name.

    To compress all the PNG files in a folder and replace the initial images with the resulted compressed images (that’s what the “-d” option does):

    pngcrush -brute -d "/my/images" *.png

    To see everything that Pngcrush can do, type (in Linux):

    pngcrush --helpor:man pngcrush

    Download PNGCrush for Windows and source files. | via: simplehelp


    © www.webupd8.org 2009. | What’s New on the World Wide Web

    Bookmark : del.icio.us | Reddit | Slashdot | Digg | Facebook | Technorati | Google | StumbleUpon | Window Live | Tailrank | Furl | Netscape | Yahoo | BlinkList | InfoGue | LintasBerita

    Popularity: 1% [?]

    Random Posts


Advertisement

Leave a Comment

Subscribe

Want it delivered? Subscribe to the RSS feed and get site updates immediately.

Ads

Hosting?


Counter

Most Popular Posts

Advertisement

BidVertiser

Archives

Statisticly





Msn bot last visit powered by MyPagerank.Net Yahoo bot last visit powered by MyPagerank.Net