by: Helge, published: Aug 25, 2009, in

Which Image File Format (GIF/PNG/JPG) to Choose – a Consultant's Answer

Which answer does a good consultant give to most general questions? “It depends.” Computer networks are complex systems, and usually there is no single option that fits all scenarios equally well.

I was reminded of this when my wife, who is a professional photographer, told me she stores images in PNG format. At first, I was stumped. PNG? Is that not some kind of successor to GIF? Why use it for photographs?

When I had the time I read up on the topic. And it soon dawned on me that there is no single image file format that is equally well suited for all use cases. Let us have a look at the pros and cons of the most popular formats:

GIF

  • 256 indexed colors only -> no good for photographs
  • Animations (multiple images per file). These are often called “Animated GIF”.
  • One color can be defined as transparent (no alpha channel)
  • Lossless compression -> well suited for screen shots and editing

PNG

  • 24 or 48 bit truecolor (256 indexed colors, too)
  • No animations (only one image per file)
  • Alpha channel for transparency (much more flexible than single color transparency)
  • Lossless compression -> well suited for screen shots and editing, but larger files than JPG

JPG

  • 24 truecolor
  • No animations (only one image per file)
  • No transparency
  • Lossy compression -> small files but not suitable for screen shots or editing

As you can see, each image file format has its unique advantages no other format can offer (GIF has animations, JPG generates small files and PNG stands somewhere in between).

The same is true for most other scenarios (Linux, OS X, or Windows? / VMware ESX, XenServer or Hyper-V?). If you ask a consultant which product to choose, he had better answer: “It depends on your requirements” and propose to perform an analysis before coming up with a recommendation. Analyzing is neither free nor instantaneous, but would you trust someone who does not even ask about you?

Previous Article Moving the Firefox Cache Directory and Profile Separately
Next Article Citrix User Profile Manager (UPM) and the Broken Rootdrive