Photoshop CC 2015: Confused about Dithering in the Gradient Fill

  • 1
  • Problem
  • Updated 3 years ago
  • Not a Problem
  • (Edited)
Description: There is a bug in the Gradient Fill effect, more specifically in its Dither function

How to reproduce:
1. Create a new image file (100x100px, 72dpi, RGB, 8-bit)
2. Create a Gradient Fill layer. In the gradient fill window, select the blue-yellow-blue gradient from the gradient library. Use the default settings. Do not use the Dither:


3. Merge the layer.
4. Create a new Gradient Fill layer. Use the 2nd preset gradient (color-transparent). Set the color to (109,109,109)! Switch on the Dither:


5. Set the blending mode for the Gradient Fill layer to Hue:

(Zoom 400%)

6. Select both layers (i.e., the Grad. Fill & Background layer) and duplicate them. You will immediately notice that the color noise in the image changed:

(Zoom 400%)

7. Move those duplicated layers into a new group.
8. Set the blending mode for the Group to Difference:

(Zoom 400%)

The final image is obviously colorful and not pure black as it should be. That means that the duplicated layers are different as the original ones. If I disable the Dither in the Gradient Fill layers the difference will be pure black. So I think this issue has something to do with the Dither function of the Gradient Fill.

Could you please look into this problem?

Thank you.
Photo of MilP

MilP

  • 58 Posts
  • 6 Reply Likes

Posted 3 years ago

  • 1
Photo of MilP

MilP

  • 58 Posts
  • 6 Reply Likes
I realized that the problem could be reproduced much easier by following these steps:
1. Create a new image file
2. Create a Gradient Fill layer. In the gradient fill window, select the blue-yellow-blue gradient from the gradient library. Switch ON the Dither!
3. Duplicate this layer.
4. Set the blending mode for the top layer to Difference.
The final image will not be pure black as it should be. There will be pixels with different color like (0,1,1), (1,1,0), (0,0,1), (0,1,0), etc.
Photo of Chris Cox

Chris Cox

  • 20280 Posts
  • 812 Reply Likes
That doesn't sound like a problem.
Dithering is random, so it will give different results in different layers.
If both layers came out identical with dithering enabled - that would be a bug.
Photo of MilP

MilP

  • 58 Posts
  • 6 Reply Likes
It is kind of weird because when I duplicate a layer, I expect it to be identical (pixel to pixel). I was working with many layers in a multilayer document and it took me a while to find out the reason why my duplicated layers are not identical. Maybe you could consider at least to add some warning message when duplicating a gradient fills with dither or groups containing such layers. The dialog window could also provide a choice with an option to rasterize layers with dither so that the duplicate will be the exact copy of the original.