# image file types, raw, jpg, bmp, png, tiff



## weltweit (Nov 20, 2012)

Just an idea for a thread discussing image file types. I know there are a lot of you out there that know a lot more than I do on this subject so I hope to learn loads.

From the digital photographers pov there is RAW (how many bits), TIFF ?, JPEG (8bit I think), PNG which seems larger than jpeg, and there is BMP, a windows non lossey format but 8bit.

And there is colour space also... hmmm ..

Makes me wonder if the aim is web display then the final output is usually jpg, so what is the image benefit of shooting raw and then processing in tiff (massive) if your final output is going to be 8bit jpeg?

And what about print. when I print (Boots) I usually take a jpeg, could I get better colour quality if I brought a TIFF (not sure they accept them tbh)...

Anyhow. Image file types. What do you think?


----------



## editor (Nov 20, 2012)

weltweit said:


> Makes me wonder if the aim is web display then the final output is usually jpg, so what is the image benefit of shooting raw and then processing in tiff (massive) if your final output is going to be 8bit jpeg?


When you shoot in JPG with a digital camera, the camera processes the picture the way it thinks is best and its decision is final. 

When you shoot RAW - as the name suggest - you're getting the 'raw' data, so you can control the processing on your desktop. This means that you can sometimes tweak more detail out of an image or correct some exposure elements like white balance etc. Of course, this means that you have to do a lot more work yourself to get to the finished article and you'll need more disk space because RW files are much bigger.

Some photographers will insist that unless you shoot in RAW you're some kind of bumbling idiot, while others will say that JPG is just fine for an awful lot of photographers.

With modern cameras, the quality of JPGs is usually excellent so not everyone bothers with RAW all the time.


----------



## Firky (Nov 20, 2012)

I usually shoot raw because I forget to set the white balance


----------



## weltweit (Nov 20, 2012)

Yes, I understand the opportunity shooting raw gives you, ability to manipulate much more than shooting jpg, ability correct a level of over and or under exposure and change things like white balance. Incidentally it can be pretty quick to change the white balance of a jpg if you have something in the frame that should be white or grey.

But what I am interested in is colour space and colour depth and the like. My understanding is that raw is 16bit wheras jpg is 8bit. So there should be greater colour variation in raw and tiff than jpg. But is it appreciable? on the web (jpg or png) or in a print ...


----------



## weltweit (Nov 20, 2012)

For example, jpg and gif, when I used to make websites with sometimes image heavy headers I sometimes used to split up the header images and whatnot into segments saving some as gifs and some as jpgs, depending mainly on which was smaller. But then along came png. I have never used png for online display, why would I use png?


----------



## cesare (Nov 20, 2012)

http://webdesign.tutsplus.com/articles/general/image-types-and-usage-in-web-design/


----------



## Firky (Nov 20, 2012)

weltweit said:


> For example, jpg and gif, when I used to make websites with sometimes image heavy headers I sometimes used to split up the header images and whatnot into segments saving some as gifs and some as jpgs, depending mainly on which was smaller. But then along came png. I have never used png for online display, why would I use png?


 
What do you mean then along came png? It's always been there! Well, for about 15 years anyway it has been common. I use it:

http://www.atalasoft.com/png


----------



## weltweit (Nov 20, 2012)

cesare said:


> http://webdesign.tutsplus.com/articles/general/image-types-and-usage-in-web-design/


Interesting article thanks cesare. I knew most of the stuff about gif and jpg but none of the stuff about png in its two types.


----------



## weltweit (Nov 20, 2012)

firky said:


> What do you mean then along came png? It's always been there! Well, for about 15 years anyway it has been common. I use it:
> http://www.atalasoft.com/png


In my consciousness it kind of appeared in about 2003  I was quite happy up till then with jpg and gif and then thinking about raw - I think there were arguments about png not being compatible with some browsers back then. Anyhow I never used it - either of them !!

What about Tiff, any fans of tiff?


----------



## Firky (Nov 20, 2012)

weltweit said:


> What about Tiff, any fans of tiff?


----------



## editor (Nov 20, 2012)

PNG likes to strut round like the smart kid in school, but the truth is that everyone still loves JPGs best.

And who would have thought the once laughed-at animated GIF - the scourge of Geocities - would become the coolest kid on the block?


----------



## Firky (Nov 20, 2012)




----------



## RoyReed (Nov 20, 2012)

weltweit said:


> Yes, I understand the opportunity shooting raw gives you, ability to manipulate much more than shooting jpg, ability correct a level of over and or under exposure and change things like white balance. Incidentally it can be pretty quick to change the white balance of a jpg if you have something in the frame that should be white or grey.
> 
> But what I am interested in is colour space and colour depth and the like. My understanding is that raw is 16bit wheras jpg is 8bit. So there should be greater colour variation in raw and tiff than jpg. But is it appreciable? on the web (jpg or png) or in a print ...


RAW files are usually 12 or 14bit in current cameras. Also RAW files aren't limited to any particular colour space such as Adobe RGB or sRGB. They are converted to a particular colour space on saving to JPG, TIF, etc.

In 8bit, each colour channel (RGB) has 256 steps (2^8) between fully saturated colour and black, making a total of 16,777,216 possible colours (256^3). 16bit images have 65,536 steps per channel between fully saturated and black, making many billions of colours possible - more than any current monitor can show. But the reason for using it is that once an image has been converted from RAW to an 8bit JPG those extra colours are gone for good (unless you go back to the RAW file). And having only 256 colours per channel can show stepping in some circumstances. This can sometimes be seen in blue skies where there might only be a few steps in the blue channel to give the shading.

You can change the colour balance of JPGs but in doing so you will lose some data. Every time you change a JPG and re-save it you will lose something and as JPG uses lossy compression the quality of the image will get worse every time you save. This is true even if the JPG compression setting is 100% (or best, or 255, or whatever scale the editing programme uses).

Both PNG and TIF use lossless compression (and TIF can use no compression at all). For web use JPG is typically used for photographic images and PNG for graphic images with flat areas of colour. PNG has largely taken over from GIF for web use.


----------



## editor (Nov 20, 2012)

RoyReed said:


> PNG has largely taken over from GIF for web use.


It hasn't, you know.


----------



## Crispy (Nov 20, 2012)

Thought I'd have a look at my very limited set of bookmarks here at work to see how prevalent PNGs and GIFs are these days.

BBC News front page: 3 GIFs (logo, hilight in a customer survey popover from a 3rd party, 1x1px tracker image for stats). Tons of PNGs.
BBC Weather: 0 GIFs
Arstechnica: 1 GIF. Tons of PNGs.
Eurogamer: 1 transparent padding GIF. Tons of PNGs.
Facebook: GIFs for loading indicators (ie animation) and transparent ones for padding. GIFs for animated ads. All UI elements in PNG.
National rail: GIFs for padding (jeez!). No PNGs. Tons of JPGs, even when the image should totally be a PNG. Sloppy stuff.
Slashdot: 0 GIFs. Tons of PNGs
Wired: Tons of 1x1 GIFs used in some weird image replacement/CDN thing. Tons of PNGs for actual images.

I personally can't think of any reason to use GIF over PNG other than for animated elements.


----------



## editor (Nov 20, 2012)

Crispy said:


> Thought I'd have a look at my very limited set of bookmarks here at work to see how prevalent PNGs and GIFs are these days.


Now look at some smaller sites that haven't the budget or the resources to enjoy regular updates.


----------



## Crispy (Nov 20, 2012)

Yes, naturally there are still loads left hanging around on legacy systems. But nobody should be using it for anything (non-animated) new.


----------



## Hocus Eye. (Nov 20, 2012)

TIFFS are very memory hungry and are usually used when photographing text or documents. I had a digital camera that would take TIFFS years ago but only rarely used that particular capability just to see what it did.


----------



## Crispy (Nov 20, 2012)

Tiff is handy for some specialised uses as it has page and layer support, whilst being easily machine readable. It's used as an intermediary format in all sorts of toolchains.


----------



## Fez909 (Nov 20, 2012)

Gif and png both have their advantages. I believe that gif can produce smaller file sizes when not many different colours are used, and that png is good for resizing.

So pick the best one for the job it is to perform.


----------



## weltweit (Nov 20, 2012)

My first fujifilm 4900z would shoot tiff, it was the highest quality image it would do. They were massive files and the camera took ages to write them. I went back to jpg.

I may shoot my first raw sometime before the end of 2013  but I will have to buy CF cards and a raw converter.

At the moment I shoot 6mp jpeg high quality and if I just want to sharpen or make minor changes I do it to the original jpg and save for the web or for print (there is no visible degradation if you use high quality or 100% and only do it once). If I am likely to want to do a lot of editing and come back to it, which is rare, I save as a photoshop image or a bmp and go back and edit all I like before later outputting as required.

Tiff are 12 bit no?


----------



## Crispy (Nov 20, 2012)

Fez909 said:


> I believe that gif can produce smaller file sizes when not many different colours are used


This myth is perpetuated by Photoshop's historically bad PNG encoding which results in large files (it might have improved recently, I'm not up-to-date) 





> and that png is good for resizing.


In what way?


----------



## editor (Nov 20, 2012)

Crispy said:


> Yes, naturally there are still loads left hanging around on legacy systems. But nobody should be using it for anything (non-animated) new.


PNGs are technically superior but there's nothing _wrong_ with using GIFs.

And yes, some versions of Photoshop make fucking huge PNG files.


----------



## weltweit (Nov 20, 2012)

Not very scientific but I just saved the following image:


As a :
TIF 861 kb
BMP 832 kb
PNG 415 kb
GIF 198 kb
JPG 89.2 kb


----------



## editor (Nov 20, 2012)

GIFs aren't designed to be used for normal photos, unless banding is your thang.


----------



## weltweit (Nov 20, 2012)

editor said:


> GIFs aren't designed to be used for normal photos, unless banding is your thang.


Quite right, the gif does look the worst of them.


----------



## Vintage Paw (Nov 20, 2012)

Since I barely do anything photographimacal that isn't using my iphone these days (or the occasional polaroid), the only time I have to worry about such things is when deciding what format to save fraps screenshots in  (png, incidentally. bmp is way too big and annoying and pointless, jpg is too small and the quality is shit. png is the baby bear porridge of fraps.)

And yeah, I remember way back when, when png enjoyed very limited browser support. And let's not even think about trying to get your transparent images to show up properly across the board.


----------



## weltweit (Nov 20, 2012)

I think today with massive hard disks people are less bothered by filesize hence more people happily using raw. When I started photography my hard disks were always filling up and that was shooting jpg, average size of image 2.5mb.

When I started doing websites most punters were on dial-up so the smaller I could make web graphics the better hence lots of optimised gif and jpg...


----------



## Crispy (Nov 20, 2012)

There's that amazing JPG optimiser that lets you paint areas of the image to selectively allow higher or lower compression rates. Lets you shave off every last kB


----------



## RoyReed (Nov 20, 2012)

editor said:


> PNGs are technically superior but there's nothing _wrong_ with using GIFs.
> 
> And yes, some versions of Photoshop make fucking huge PNG files.


Nothing wrong at all with using GIFs (and I never meant to imply that), but I still say that PNGs have largely replaced them.

And yes, some programmes make awful (and awfully large) PNGs.


----------



## RoyReed (Nov 20, 2012)

Crispy said:


> There's that amazing JPG optimiser that lets you paint areas of the image to selectively allow higher or lower compression rates. Lets you shave off every last kB


Fireworks can do this - not sure about any others.


----------



## editor (Nov 20, 2012)

Crispy said:


> There's that amazing JPG optimiser that lets you paint areas of the image to selectively allow higher or lower compression rates. Lets you shave off every last kB


I used to swear by that program. It certainly helped me get more work back in the day too, because my pages were lightning quick to download.


----------



## ChrisFilter (Nov 20, 2012)

RoyReed said:


> Nothing wrong at all with using GIFs (and I never meant to imply that), but I still say that PNGs have largely replaced them.
> 
> And yes, some programmes make awful (and awfully large) PNGs.



And you'd be right.


----------



## sim667 (Nov 20, 2012)

Shoot raw, edit, export as tiff or jpg depending on where its going. I always embed the adobe 98 colour space too.


----------



## Firky (Nov 20, 2012)

I had to learn the formulae for jpeg compression for an exam at uni - one of the many pointless things academics say you need to know.



editor said:


> GIFs aren't designed to be used for normal photos, unless banding is your thang.


 
And you can adjust the compression on nearly all image formats.


----------



## fogbat (Nov 20, 2012)

editor said:


> Now look at some smaller sites that haven't the budget or the resources to enjoy regular updates.


Moving the goalposts?


----------



## editor (Nov 20, 2012)

fogbat said:


> Moving the goalposts?


Not if you can read properly.


----------



## Crispy (Nov 20, 2012)

fogbat said:


> Moving the goalposts?


Now that would be a GIF.


----------



## starfish2000 (Nov 21, 2012)

I shoot jpegs on holiday amd RAW if its a paid gig, I did a headshot recently and it was a pain in the arse as I forgot to switch it over to RAW and post processing was limited and quite a pain.


----------



## RoyReed (Nov 21, 2012)

starfish2000 said:


> I shoot jpegs on holiday amd RAW if its a paid gig, I did a headshot recently and it was a pain in the arse as I forgot to switch it over to RAW and post processing was limited and quite a pain.


Memory cards are cheap these days - shoot RAW and JPG combined.


----------



## weltweit (Nov 21, 2012)

RoyReed said:


> RAW files are usually 12 or 14bit in current cameras. Also RAW files aren't limited to any particular colour space such as Adobe RGB or sRGB. They are converted to a particular colour space on saving to JPG, TIF, etc.
> 
> In 8bit, each colour channel (RGB) has 256 steps (2^8) between fully saturated colour and black, making a total of 16,777,216 possible colours (256^3). 16bit images have 65,536 steps per channel between fully saturated and black, making many billions of colours possible - more than any current monitor can show. But the reason for using it is that once an image has been converted from RAW to an 8bit JPG those extra colours are gone for good (unless you go back to the RAW file). And having only 256 colours per channel can show stepping in some circumstances. This can sometimes be seen in blue skies where there might only be a few steps in the blue channel to give the shading.


 
Hi Roy, Yes, interesting about 8 bit and 256 steps, does that mean that in a blue sky I have a maximum of 256 steps of colour across the sky and that in practice I am likely to have a lot fewer. It seems to me that I would likely have more visible steps than I usually do then in jpg.

But for web use, whatever people start with raw or jpg, they normally end up with jpg which means everyone has the same problem in the end.



RoyReed said:


> You can change the colour balance of JPGs but in doing so you will lose some data. Every time you change a JPG and re-save it you will lose something and as JPG uses lossy compression the quality of the image will get worse every time you save. This is true even if the JPG compression setting is 100% (or best, or 255, or whatever scale the editing programme uses).


 
This business about losing detail I don't really agree with. I shoot an image in jpg, move it to my hdd and write protect it, that becomes my original or negative if you like. If I want to work on it I open it in pse and do whatever I have to do on it, then if it is for the web I size and save it as jpg fine often on 60% compression, no one has said that they can see degradation in these images. If it is for print then I usually save it as a jpg at 100% / no compression. Nobody I know has been able to notice any degradation of the image / print when I have done this. 

The camera created it once as a high quality jpg, and I have saved it one more time as a jpg for the web or print. That is just one more saving (in the camera) than a raw shooter would have to do.

If I want to do a lot of manipulation (rarely) I open the image in pse and save it as a lossless format, either PSE's own format or Tiff or Bmp, then I can reopen and resave it as often as I like with no loss of quality before in the end outputting it according to whatever I want to use it for.


----------



## Fez909 (Nov 21, 2012)

Crispy said:


> In what way?


 
Seems I was wrong on this.  I thought that all PNGs are vectors.  I take back my claim!


----------



## RoyReed (Nov 21, 2012)

Fez909 said:


> Seems I was wrong on this. I thought that all PNGs are vectors. I take back my claim!


No PNGs are vectors apart from the dubious hijack of the file extension by Macromedia for Fireworks. Fireworks PNGs can contain vectors and bitmaps, but they have very little to do with the original PNG specification other than they can export true PNGs for web use.


----------



## RoyReed (Nov 21, 2012)

weltweit said:


> This business about losing detail I don't really agree with. I shoot an image in jpg, move it to my hdd and write protect it, that becomes my original or negative if you like. If I want to work on it I open it in pse and do whatever I have to do on it, then if it is for the web I size and save it as jpg fine often on 60% compression, no one has said that they can see degradation in these images. If it is for print then I usually save it as a jpg at 100% / no compression. Nobody I know has been able to notice any degradation of the image / print when I have done this.


If you always go back to the original unchanged JPG, then you're correct. My point was for people who make a change, then re-save the file several times. Even at 100% compression you'll start to see degradation after the file has been re-saved several times. This must be true as you'd be adding compression artefacts to compression artefacts.


----------



## weltweit (Nov 21, 2012)

I just thought I would have a little play with jpg compression and what have you.

I took this 89.2kb file (which has already been saved as a 60% jpg: so that is already one compression.



Then I saved it for the web as jpg again with 60% more compression. Then I openned the newly compressed file and saved it for web at 60% again, I did this until the tenth repeat and then went and looked at the loss of quality and any change in filesize in the resulting images.

By iteration 5, that is six times compoundly compressing as jpg at 60% some damage was visible in the blue of the sky at the bottom right corner, this below is image 5 (6 times compressed) interestingly however file size was still 89.3kb



I then checked the final image #10, which had been compoundly compressed at 60% eleven times, the image had degraded over #1 and #5 images as one might expect but it is not a lot worse than the #5 iteration and again fileseize remained 89.2kb. The image #10 is below:



It makes me wonder what degradation one might find if I did these 11 steps with 100% jpg quality i.e. no compression.


----------



## weltweit (Nov 21, 2012)

OK, so, it is established that if one repeatedly saves a jpg with a 60% quality level of compression the image does degrade starting perhaps with the fifth iteration.

What about if one was to save a jpg repeatedly over itself at a 100% level i.e. not with any compression.

I took this image, a 100% jpg so iteration #1 and 237kb



Then I openned it and saved it as #002 again with 100% no compression. Then I openned #2 and saved it as #003 again with 100% jpg and so on until I had cumulatively saved it as a 100% jpg ten times.

The image saved five times looks like this:



And the image cumulatively saved as a 100% jpg ten times, looks like this:



There seems to be surprisingly little degradation of the image and it is now 241kb.


----------



## RoyReed (Nov 21, 2012)

weltweit said:


> What about if one was to save a jpg repeatedly over itself at a 100% level i.e. not with any compression.


100% does not mean no compression. JPG always uses some compression whatever the setting. There has to be. Compare the file size of that original saved as a jpg compared with the same file saved as a TIF or BMP. They don't add in extra data just to bump up the file size.

Your image of the robin is 602x402 pixels. That's 242,004 pixels in total, so for an 8bit per channel RGB image that means 726,012 bytes of data (not including any header, exif or other embedded data). That means the JPG compression has lost about two-thirds of the data to get the file size down to about 240kb. It also shows what a good compression system JPG uses that the image has stayed so good. Nice photo BTW.


----------



## FridgeMagnet (Nov 21, 2012)

I always shoot or scan to JPEG - though obviously with scanning film you always have the "raw" available for reprocessing, it's called a negative  But my digital shots are always to JPEG too. As the ed says on the first page, the quality is high enough these days that there's nothing really gained for me, and I have the advantage of knowing that my original data files are future proofed, in that I don't have to rely on software in 20 years' time understanding how to decode the RAW files from a camera. (For those who aren't aware, RAW is not a format like JPEG or PNG, it is just raw data that comes off the camera and so varies between cameras.)

60% is a really low quality to have a JPEG. Even for crappy web graphics I rarely go below 75%. My standard is 85%.


----------



## Crispy (Nov 21, 2012)

weltweit said:


> There seems to be surprisingly little degradation of the image and it is now 241kb.


If you overlay one image on the other, using the Difference transparency, you should see some interesting patterns


----------



## weltweit (Nov 21, 2012)

Crispy said:


> If you overlay one image on the other, using the Difference transparency, you should see some interesting patterns


Hi Crispy, for some reason I can't get that to work. I have the base image normal as layer 0, then I have image #10 as layer 1 and I set that to difference transparency and then play about with the opacity but for some reason I don't seem to be seeing very much


----------



## RoyReed (Nov 22, 2012)

weltweit said:


> Hi Crispy, for some reason I can't get that to work. I have the base image normal as layer 0, then I have image #10 as layer 1 and I set that to difference transparency and then play about with the opacity but for some reason I don't seem to be seeing very much


Try 'Logical XOR' instead of 'Difference' - if the layers are identical you should just see black. This is what I get with two of your palm trees (first and last).


----------



## Crispy (Nov 22, 2012)

Ah yeah, that's a much better one


----------



## weltweit (Nov 22, 2012)

RoyReed said:


> Try 'Logical XOR' instead of 'Difference' - if the layers are identical you should just see black. This is what I get with two of your palm trees (first and last).


Hi RoyReed,
I don't have Logical XOR as an option in layer types. Perhaps that is because I only have Adobe Photoshop Elements 9 .... But interesting to see the difference between #1 and #10 on the palm tree, I could see the degradation in the bottom right on the image itself but not really the rest of it.


----------



## weltweit (Dec 1, 2012)

Hmm, so ...

People shoot raw which is 12 or 16bit and one of the reasons they do this is because of the additional quality (colour depth) over an 8bit image. Then they process via 12 or 16bit Tiff again so as not to lose this colour depth, but when they come to either displaying an image on the web, or getting it printed out, they lose all that detail because computer screens and printers can't display or output more than 8 bit ...

Obviously that is not the only reason to shoot raw, image recovery being a very significant one.


----------



## Quartz (Dec 1, 2012)

weltweit said:


> I just thought I would have a little play with jpg compression and what have you.


 
I'm not sure that's a good test. I think you actually need to edit the picture to see the effects of recompression. 

Someone mentioned 16 bit colour earlier. You need to be careful there, because sometimes it refers to 16 bits per channel, and sometimes it refers to the total colour output, and is normally 5 bits (32 levels) of red, 6 bits (64 levels) of green, and 5 bits (32 levels) of blue.

Another gotcha is the colour depth of monitors. Your typical computer monitor uses TN and is only 6 bits per channel but uses dithering to fake 8. Next up is the IPS monitor which is usually a full 8 bits per channel. Better IPS monitors can dither those 8 bits to fake 10 bit colour. Then you get full 10+ bit displays.


----------



## weltweit (Dec 1, 2012)

Quartz said:


> Another gotcha is the colour depth of monitors. Your typical computer monitor uses TN and is only 6 bits per channel but uses dithering to fake 8. Next up is the IPS monitor which is usually a full 8 bits per channel. Better IPS monitors can dither those 8 bits to fake 10 bit colour. Then you get full 10+ bit displays.


 
Quartz, my monitor says "colour depth 32bit" the options are 16bit or 32bit ...


----------



## RoyReed (Dec 2, 2012)

weltweit said:


> Quartz, my monitor says "colour depth 32bit" the options are 16bit or 32bit ...


32bit in this instance means 3 channels at 8bits per channel (RGB 24bits - True Colour) plus 8bits for an alpha transparency channel. 16 bits (sometimes called High Colour) usually means 5bits each for the R and B channels and 6bits for the G channel (as Quartz said), making a total of 65,536 possible colours - but there are variations on this.

Read more here:
http://en.wikipedia.org/wiki/Color_depth
http://en.wikipedia.org/wiki/High_color


----------



## weltweit (Dec 2, 2012)

Interesting links RoyReed, thanks ...


----------



## weltweit (Dec 5, 2012)

Saw a professional landscape photographer recently. He used a phase one digital back on a medium format view camera. He shot in raw and then processed as a TIFF. His TIFF files were 400mb each!!


----------



## editor (Jul 26, 2020)

Raw vs JPG explained 



> *JPEG*
> A JPEG file is a completely _finished_ image that your camera fully develops and processes the moment you take the shot. Most cameras have a menu where you can pre-adjust settings like color, sharpness, clarity, and so forth before you take your shot. Once those parameters are set, the camera will apply these settings to the final JPEG before it’s saved to the SD card.
> 
> In order to keep the file size down and to make the file more compatible, your camera throws out some of the extraneous color data and other information _before_ it provides you with the image. Once thrown away, that sensor information is lost forever.
> ...













						RAW vs JPEG: Explaining the Difference with a Box of Cereal
					

In running my photography channel, I get a lot of questions about RAW files vs. JPEG, and some people not fully grasping exactly what RAW files really




					petapixel.com


----------



## weltweit (Jul 26, 2020)

I am shooting raw these days, still, because of one or more other compromises I am not yet getting the full benefit. I keep my raw files so can revisit and reprocess them whenever I wish. 

FastStoneViewer creates jpgs from raws, it doesn't seem to include as many options as Nikon ViewNX 2 but the Nikon software is a pain to use, so I use FastStoneViewer instead.


----------



## weltweit (Aug 12, 2020)

Last week I learnt something, we wanted a background to show through the white areas of a jpeg and I for some reason assumed we would have to make the higher image into a gif. However I learnt you can in fact cut away jpegs to make parts transparent.


----------



## mauvais (Aug 12, 2020)

JPEGs don't have any transparency (alpha) capability so I don't know what you did but it wasn't that.


----------



## fishfinger (Aug 12, 2020)

mauvais said:


> JPEGs don't have any transparency (alpha) capability so I don't know what you did but it wasn't that.


You can use a clipping path to enable transparency in a jpg. Not all apps support this however.

See here:


----------



## weltweit (Aug 12, 2020)

mauvais said:


> JPEGs don't have any transparency (alpha) capability so I don't know what you did but it wasn't that.


Arse .. my mistake, the images with transparency are pngs! Darn it ..


----------



## fishfinger (Aug 12, 2020)

weltweit said:


> We started with an image of a product on a white background. This was displayed on a page which had a coloured swoosh running across it. We then cut out the white background (as I might in a layer in PS) and saved the jpg. Now when displaying the image over the background the background shows through in all the areas that had been cut out.


If you didn't use a clipping path like the example above, then you must have saved the image as a png, or some other format that supports transparency.


----------



## weltweit (Aug 12, 2020)

fishfinger said:


> If you didn't use a clipping path like the example above, then you must have saved the image as a png, or some other format that supports transparency.


Yes, my mistake, it was a png


----------



## mauvais (Aug 12, 2020)

fishfinger said:


> You can use a clipping path to enable transparency in a jpg. Not all apps support this however.
> 
> See here:


You can do this, yes, but it's not meaningfully JPEG. JPEG is a properly defined standard whereas this is proprietary metadata bunged in with it, and applications can choose to interpret that. There might be some standards for extensions but ultimately, as you say, not all JPEG-supporting apps do support it.

I don't know why anyone bothered with this TBH when better image standards exist, namely PNG.


----------

