Solved

PNG compared to JPEG and GIF

Posted on 2006-11-08
1
755 Views
Last Modified: 2013-12-25
I've used GIF and JPEG for ages now, and begin to discover PNG. I hear from many people it's better, and I know that transparancy is better in PNG - if supported by the browser of course.

Normally I use JPEG for photo's. If I use PNG (24 bits), the image size is much bigger, and I cannot specify a compression rate (using Photoshop 6). As an example I took a photo of 800 x 600 pixels. Saved as PNG it was 800kb, and the JPEG version varied between 100kb (for high quality or 60%) and 500kb (100% quality). So the best JPEG quality is half the size of the PNG. Why is PNG better?

If I save to PNG (version 1), then reopen the saved PNG (800 kb big), save that again as PNG (version 2), the size grows to 950kb. If I reopen the last PNG (v2) and save it again as PNG (version 3), it seems to keep the last size. Is this always the case? Is PNG 24-bits lossless? Or at least not incremental on losing information?

What do you prefer? JPEG or PNG?

How about GIF? I think I won't use it anymore. I've noticed PNG-8 has comparable file sizes. I never use animated GIFs, so I don't need that (and don't know if PNG supports animation). Do you have reasons to prefer GIF over PNG?
0
Comment
Question by:grexx
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 38

Accepted Solution

by:
lherrou earned 250 total points
ID: 17898617
Grexx,

First of all, remember that PNG was intended as a replacement for the GIF file format when Unisys said they would enforce the LZW compression patent, which was used in GIF. JPEG is still the primary lossy compression method for photographic or photographic-style images. PNG is not going to be the smallest format for photographic-type images in most cases. On the other hand, for a simple image, the GIF format, while called loss-less, in fact discards color information to achieve some of it's compression, and is limited to 256 colors or less (as set by user/software). PNG often, but not always, outperforms GIF on image quality and compression in images of these types.

The following article shows some excellent comparisons, and discusses when each should be used:
http://www.websitetemplatedesign.com/oscommerce_tutorials/printer_136.shtml

Cheers,
LHerrou
0

Featured Post

Are You Using the Best Web Development Editor?

The worlds of web hosting and web development are constantly evolving. Every year we see design trends change, coding standards adapt and new frameworks/CMS created. With such a quick pace of change it’s easy to get lost trying to keep up.

See if your editor made the list.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developer portfolios can be a bit of an enigma—how do you present yourself to employers without burying them in lines of code?  A modern portfolio is more than just work samples, it’s also a statement of how you work.
Dramatic changes are revolutionizing how we build and use technology. Every company is automating, digitizing, and modernizing operations. We need a better, more connected way to work together as teams so we can harness the insights from our system…
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question