How can .png files utilize transparency, whereas all .jpegs are all opaque rectangles?

223 views

What about the “design” of a .png allows it to be transparent for logos and such? Whereas when I export a .jpeg it’s always an opaque square.

In: 0

3 Answers

Anonymous 0 Comments

The way that PNGs do transparency is that they have 4 “color layers” – one for red, green, blue and “alpha”

Red green and blue channels are enough to be combined to make the color for each pixel. The alpha channel indicates for each pixel, “how transparent” it should be

JPG only has the red/green/blue channels, so it doesn’t support transparency

An older format, GIF, supports transparency but only as a binary on/off value, i.e. the pixel is either fully opaque or full transparent

You are viewing 1 out of 3 answers, click here to view all answers.