DIY Photography

Your one stop shop for everything photo-video

  • News
  • Inspiration
  • Reviews
  • Tutorials
  • DIY
  • Gear
Search

Submit A Story

Everything you wanted to know about Banding and were afraid to ask

Dec 9, 2017 by Stefan Kohler 2 Comments

  • Share
  • Tweet
  • Flipboard
  • WhatsApp

We’ve all been there: you sit on a picture forever, bored of retouching, and then when you do get around to it strange things start to show up in it. Like odd rings of graduated color.

These rings of color are called banding. They are nothing more than tonal breaks but before I explain where these obvious changes in tone come from–and how to avoid them–let me show you an example:

If you look at the background on the right-hand side of the image you can see what resembles a staircase of brightness, getting darker as it moves away from the model. That’s banding.

How is banding created?

Banding is easy to explain: if there are more pixels than there are brightness levels, you get banding.

Let’s take a look at how a picture is put together. We have three channels: red, green and blue. Each of these channels, which makes up a color image, has up to 256 levels. Multiply 256 * 256 * 256 and you have your total number of possible different pixel values. By different pixel values we mean that they differ in luminance, hue, or color saturation.

In our example, we have the same value for all three channels because it is a black and white picture. That means there are only 256 values available.

The first dot (the bright one in the middle of the picture) has an RGB value of 78; the second dot has an RGB value of 28. The distance between them is 452px. If you were to assess it in purely mathematical terms there are 50 steps to 450px, which means that every 9px the value should change by one step. In theory that should be a clean process with invisible levels. But it isn’t.

During the editing process, information was pushed back and forth, making the image appear a bit darker here and a little lighter there. This creates holes in the histogram and changes the background’s appearance.

With a tonal correction, I enlarged the area in question and marked the holes. This makes it more visible:

These holes are breaks in the tonal values and they show up as uneven progressions in colour (or lightness and darkness) in the photo.

Banding as a result of compression

To understand why banding can happen when uploading to the web, you have to take a brief look at the JPEG algorithm. How are pictures compressed?

  1. Compression by conversion to the YCbCr color model

The image is not saved as RGB channels (red-green-blue) but as Y-Cb-Cr (luminance, blue-yellow, red-green). While the luminance channel is stored in full resolution, the other two aren’t. They are smaller.

This series of images illustrates it:

The RGB image is broken down into a 100% version of the luminance (Y), and a scaled version for each of the red-green color information (Cb) and the blue-yellow information (Cr). This process saves a lot of data and at the same time still looks very good–except for the banding, that is.

* Note: The process is much more complex. If you would like to examine it in more detail here is some more detailed information [PDF]. Otherwise, we’d rather not bore you with issues of subsampling and the like.

Next, these three channels are split into blocks–typically 8×8 pixels at first. These blocks are then smoothed a bit, which means that the tonal differences within the blocks are reduced further. When the image is saved, it won’t be the absolute values that are saved, but the differences between present and previous values. It’s all very neat and saves on data.

This saved image will be much smaller. If you want to see the efficiency of the process, just compare an uncompressed TIF against a JPG and look at the file size.

However, this block formation and smoothing creates yet more holes in our color gradient–and this makes the banding stronger. The higher the compression, the more banding.

I could go on writing for hours, but when it comes to toning, the strongest factors that affect it are: the decomposition and different scaling, blocking, and pixel-to-tone ratio.

All of this means that we can make an interesting observation about cameras: The higher the resolution and the better the noise performance, the greater the tendency for banding.

What can you do to prevent banding?

When you start to edit a picture you will be able to see during the Raw conversion process if the image might be prone to banding. If large, smooth gradients appear this is your cue to edit in 16-bit.

If you opt for 16-bit, instead of the 256 values per channel, a whopping 65,536 possible values are available to you. During editing, therefore, no holes should make their way into the histogram.

If it interests you there’s a detailed article about 8-bit vs 16-bit here.

Before saving your image as a JPG, you can prevent the appearance of blooming by introducing a little noise. By ‘noise’ I mean bigger difference between the pixels.

Here, we compare an 8 × 8 pixel area before and after adding noise:

As you can see, the individual pixels are now different which means that smoothing will be less successful here – the JPG algorithm has been outsmarted.

The best way to create enough noise is to create a new layer and fill it with 50% gray using “Edit -> Fill”. Now by going to “Filter -> Noise -> Add Noise” you will generate some noise. Next set the new layer to the “soft light” layer mode and vary the thickness via the layer transparency. It is important, of course, to create this sort of noise at the very end of your workflow–first zoom out, then sharpen, then add noise. If you change the order, you either sharpen (and amplify) the noise or you prevent the noise by reducing it. So do it at the very end, just before saving.

How to remove banding?

If you want to remove the banding in an already saved picture it is a relatively simple process.

First, convert the image into 16-bit to give yourself more latitude in the tonal values.

Then, remove the appearance of banding using Gaussian Blur. This will help to close the holes in the histogram.

Finally, you will save the image, as described above. But it’s definitely better to pay attention during the Raw conversion process to the color depth and make use of some large, soft brushes!

This article was also published here and shared with permission

FIND THIS INTERESTING? SHARE IT WITH YOUR FRIENDS!

  • Share
  • Tweet
  • Flipboard
  • WhatsApp

Related posts:

Default ThumbnailEverything You Wanted To Know About Light Painting Everything You Wanted To Know About Codecs And Why They Matter This is everything you wanted to know about dynamic range This deep dive video into stabilisation is everything you ever wanted to know about OIS or IBIS

Filed Under: Tutorials Tagged With: Adobe Photoshop, banding, editing software, JPG, resizing

Stefan Kohler: from diyphotography.net

About Stefan Kohler

Stefan Kohler is a full-time retoucher. He's from Germany and likes bacon. In the last years, he built up a broad community around his retouching classes at the Infinite tool's website. You can follow his work oninstagram.

« Samsung’s next generation of smartphones will see a massive 512GB internal storage
Take extreme macro photos by adapting a microscope »

Submit A Story

Get our FREE Lighting Book

DIYP lighting book cover

* download requires newsletter signup

Recent Comments

Free Resources

Advanced lighting book

Learn photography

Recent Posts

  • NASA’s remarkable new photo sheds light on the lunar south pole
  • Hands-on with Colbor’s colourful 220W RGB COB LED
  • Everything you need to know before you rent a photography studio
  • Nikon Zf: Nikon’s full frame retro camera
  • AI-Mazing! ACDSee Photo Studio Ultimate 2024 adds new AI-powered tools

Udi Tirosh: from diyphotography.netUdi Tirosh is an entrepreneur, photography inventor, journalist, educator, and writer based in Israel. With over 25 years of experience in the photo-video industry, Udi has built and sold several photography-related brands. Udi has a double degree in mass media communications and computer science.

Alex Baker: from diyphotography.netAlex Baker is a portrait and lifestyle driven photographer based in Valencia, Spain. She works on a range of projects from commercial to fine art and has had work featured in publications such as The Daily Mail, Conde Nast Traveller and El Mundo, and has exhibited work across Europe

David Williams: from diyphotography.netDave Williams is an accomplished travel photographer, writer, and best-selling author from the UK. He is also a photography educator and published Aurora expert. Dave has traveled extensively in recent years, capturing stunning images from around the world in a modified van. His work has been featured in various publications and he has worked with notable brands such as Skoda, EE, Boeing, Huawei, Microsoft, BMW, Conde Nast, Electronic Arts, Discovery, BBC, The Guardian, ESPN, NBC, and many others.

John Aldred: from diyphotography.netJohn Aldred is a photographer with over 20 years of experience in the portrait and commercial worlds. He is based in Scotland and has been an early adopter - and occasional beta tester - of almost every digital imaging technology in that time. As well as his creative visual work, John uses 3D printing, electronics and programming to create his own photography and filmmaking tools and consults for a number of brands across the industry.

Dunja Djudjic: from diyphotography.netDunja Djudjic is a multi-talented artist based in Novi Sad, Serbia. With 15 years of experience as a photographer, she specializes in capturing the beauty of nature, travel, and fine art. In addition to her photography, Dunja also expresses her creativity through writing, embroidery, and jewelry making.

Copyright © DIYPhotography 2006 - 2023 | About | Contact | Advertise | Write for DIYP | Full Disclosure | Privacy Policy