Home ยป Forum ยป Author Hangout

Forum: Author Hangout

HEIF

Switch Blayde ๐Ÿšซ

Since there's so little activity on the Forum and there are so many IT technical people here, I'd like to ask what you think of HEIF.

I have a new iPhone 13 Pro Max that, when I take a photo, creates it as an HEIF (not JPEG). From what I read, Android will soon be doing it as well. It seems HEIF has a better compression so it takes up half the space, plus the quality is better.

Do you think HEIF will replace JPEG down the road?

Michael Loucks ๐Ÿšซ

@Switch Blayde

Do you think HEIF will replace JPEG down the road?

Given pretty much everyone except pros uses phones as their default camera, it wouldn't surprise me. But you never know. I'd have to look up whether or not there are patents involved, because that can slow adoption.

Replies:   Switch Blayde  palamedes
Switch Blayde ๐Ÿšซ
Updated:

@Michael Loucks

I'd have to look up whether or not there are patents involved

HEIF files are a special case of the ISO Base Media File Format (ISOBMFF, ISO/IEC 14496-12), first defined in 2001 as a shared part of MP4 and JPEG 2000. Introduced in 2015, it was developed by the Moving Picture Experts Group (MPEG) and is defined as Part 12 within the MPEG-H media suite (ISO/IEC 23008-12).

HEIF was adopted by Apple in 2017 with the introduction of iOS 11.

palamedes ๐Ÿšซ

@Michael Loucks

Given pretty much everyone except pros uses phones as their default camera, it wouldn't surprise me. But you never know. I'd have to look up whether or not there are patents involved, because that can slow adoption.

Canon 1D X Mark III camera can use HEIF and at $5,000+ I can see why people stick with their phone. And yes in know for PRO's that is still a cheap camera.

Dominions Son ๐Ÿšซ

@Switch Blayde

It seems HEIF has a better compression so it takes up half the space, plus the quality is better.

Count me skeptical of claims it can offer both stronger compression and higher image quality.

There are image formats that use lossless compression algorithms, but the compression is almost always weaker than lossy compression methods used in formats like JPEG.

https://www.howtogeek.com/345314/what-is-the-heif-or-heic-image-format/

What it does offer that JPEG doesn't is 16bit color. (JPEG only supports 8 bit color). But there is more to overall image quality than just 16 bit vs 8 bit color.

John Demille ๐Ÿšซ

@Dominions Son

Count me skeptical of claims it can offer both stronger compression and higher image quality.

Different compression algorithms differ greatly in the quality produced and filesize.

Take for example video compression:

x264 the standard since around 2004 produces roughly the same quality picture as the MPEG2 standard at less than half the bit rate (file size) of MPEG2.

Now x265 gives you roughly the same image quality as x264 at roughly 55% the file size.

HEIC has better compression algorithm than JPEG (and way more features). Even JPEG2000 has better algorithm than JPEG, but wasn't better enough to go through the transition successfully.

Replies:   Dominions Son
Dominions Son ๐Ÿšซ

@John Demille

Different compression algorithms differ greatly in the quality produced and filesize.

True, but image quality and compression ratio are generally antagonistic goals. It is close to impossible to maximize both.

Switch Blayde ๐Ÿšซ

@Dominions Son

Count me skeptical of claims it can offer both stronger compression and higher image quality.

From https://www.digitaltrends.com/photography/what-is-the-difference-jpeg-vs-heif/

It's the "high-efficiency" in the name that's the key differentiator in this newer photo format. A HEIF file takes up roughly half the space of a JPEG without reducing the quality of the actual image. While the image uses smarter, more modern compression algorithms, it's only small on space, keeping just as many megapixels and details intact. If you choose to shoot in HEIF, your photos will take up less space on your camera roll, your hard drive, and your cloud storage.

In some cases, a HEIF file may actually have better image quality than a JPEG. That's because these new files support 16-bit color. 16-bit refers to how many different colors the image can store. While the human eye can't even differentiate between the trillions of colors available in 16-bit, more colors create more flexibility when editing the photo. An 8-bit photo could be over-edited to the point where the colors appear to have bands in them โ€” a phenomenon photographers call, you guessed it, banding โ€” while a 16-bit photo has more wiggle room. (Not every camera can capture 16 bit, and the HEIF will only capture the maximum bit depth that the camera allows.)

helmut_meukel ๐Ÿšซ

@Switch Blayde

That's because these new files support 16-bit color. 16-bit refers to how many different colors the image can store.

This 8-bit/16-bit is misleading. Historically it startet with 16 fixed colors, then came 16 color palettes, where the pictures had only 16 colors, but they could be selected from a greater palette. finally we got to TrueColor with 24 (or 32) bit. This is still the standard, RGB is 8-bit each giving color values from 0 to 255 for each component (red, green, blue) resulting in 16,777,216 different colors. Due to the limitation of the human eye, it will not distinguish between colors when the RGB values are decreased or increased by 1 (there are color areas where increasing one value by 1 and decreasing another by 1 will be recognized by some humans).
Add to this the limitations of the hardware to display all 16 million colors (on screen or in print) and you'll find very few cases (if any) where using 16 bits per channel will be necessary.

HM.

Dominions Son ๐Ÿšซ

@Switch Blayde

A HEIF file takes up roughly half the space of a JPEG without reducing the quality of the actual image.

That's a more believable claim.

In some cases, a HEIF file may actually have better image quality than a JPEG. That's because these new files support 16-bit color.

I am well aware of the difference between 16 bit and 8 bit color.

However, switching from 8 bit to 16 bit color also doubles the size of the raw uncompressed image.

And with lossy compression algorithms, the higher the compression ratio, the more gets lost.

Higher color resolution doesn't necessarily help image quality if entire clusters of pixels that had unique values in the raw image end up with the same value due to lossy compression.

LOAnnie ๐Ÿšซ

@Dominions Son

The piece that's missing is the decoding of compression. Court reporting vs typing verbatim is a form of compression that really depends on the speed to encode/decode.

MPEG back 20 years ago shrunk file sizes but could be decided on the fly with the technology of the time. Formats listed below like x264 and x265 can deliver the same quality at smaller file sizes because the computing power of the decoding hardware has made it that it can decode the compressed video fast enough to be real time. Like the court reporter analogy, do you have to stop and think about what every bit of shorthand means, or can you read it naturally

Replies:   Dominions Son
Dominions Son ๐Ÿšซ

@LOAnnie

Decompression speed is not relevant to the issues I am talking about.

1. Not relevant to still images.
2. Not relevant to the data loss from lossy compression. The data loss happens when the file is compressed, not when it's uncompressed.

Keet ๐Ÿšซ

@Switch Blayde

HEIF has several advantages over JPEG. The most important are smaller file size and support for transparency. Transparency is also supported by PNG but the smaller file size is important for storage and transmission over the net. What it lacks is a overall adoption. Until most systems support it by default it's safer to stick to JPEG/PNG. Currently you can't send a HEIF compressed image to friends and be sure they can view it. Time will tell if it succeeds in getting that level of adoption, personally I think it will but I can't predict how long it will take.

Dominions Son ๐Ÿšซ
Updated:

@Keet

Transparency is also supported by PNG but the smaller file size is important for storage and transmission over the net.

But a lot of photographers who do a lot of image editing actually prefer to work with their camera's raw format (uncompressed).

PNG is weaker compression, but it's lossless.

With lossy compression, every time you edit and re-save the image, the editing software has to re-compress the image, and this means that every time you edit and save, more data is lost*.

*Here data loss does does not mean you are losing pixels, rather adjacent pixels that had unique values end up set the same value.

Enough generations of loss and the image starts to appear to pixelate, take on the appearance of losing resolution by having large blocks of pixels all the same, making it appear to have larger pixels.

Replies:   John Demille
John Demille ๐Ÿšซ

@Dominions Son

But a lot of photographers who do a lot of image editing actually prefer to work with their camera's raw format (uncompressed).

Originals and files not meant for transmission should never be compressed with a lossy algorithm. But since everything is a compromise, you never know all the conditions that led to the choice of compression. Disk space may be at a premium or ignorance of the user could be the cause.

PNG is weaker compression, but it's lossless.

Not always. 24bit PNG (8bits per colour) supports lossy compression too. But the default is lossless compression and lossless is the only option for indexed colour PNG (8bit).

With lossy compression, every time you edit and re-save the image, the editing software has to re-compress the image, and this means that every time you edit and save, more data is lost*.

True. That's why no originals should be saved in a lossy format. Lossy compression should be applied only to final images that are meant to be viewed and not manipulated. But again, compromises may be necessary.

Switch Blayde ๐Ÿšซ
Updated:

@Keet

Currently you can't send a HEIF compressed image to friends and be sure they can view it.

That's how I learned about HEIF.

My wife is a glass artist. She has photos of her art in the cloud so that she can show it to people from her iPhone or iPad. She also sometimes emails photos to people.

She emailed (Hotmail) a photo from her new iPhone and it worked fine. But when she emailed it from her Mac, the person couldn't view it. I looked into it and discovered the photo was stored in the cloud as HEIF but the iPhone converted it to JPEG when emailing it (the Mac of course didn't).

An article I read said that Android was soon going to do what the iPhone does. That's why I asked if HEIF would eventually be as common as JPEG (i.e., the iPhone wouldn't have to convert it to JPEG when emailing it).

I'm not saying it's in the short-term. For example, I don't expect Bookapy to accept an HEIF book cover. For that matter, I don't expect GIMP to be able to save it as HEIF. I was just curious.

What I told my wife to do was create a folder on her Mac and do an "export" from Preview to convert it to JPEG and email that file when emailing from the Mac.

Replies:   Keet
Keet ๐Ÿšซ

@Switch Blayde

What I told my wife to do was create a folder on her Mac and do an "export" from Preview to convert it to JPEG and email that file when emailing from the Mac.

Nothing wrong with export to JPEG but you should consider the purpose of the export result and decide which format works best for that purpose. There's a big difference between high res photo's and a cartoon drawing. It also depends what the receiver is going to use the image for: just a quick view, manipulate it, print in a large size?
Here https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Image_types most of the generic formats are listed with descriptions when best to use. HEIF is noticeably absent from that list, just like it's still missing from most other sites that list and describe image formats.

Back to Top

Close
 

WARNING! ADULT CONTENT...

Storiesonline is for adult entertainment only. By accessing this site you declare that you are of legal age and that you agree with our Terms of Service and Privacy Policy.