Neith Posted February 18, 2017 Share Posted February 18, 2017 How do you make a smooth gradient? I want to make a bar that is 964x45, background color is 33,33,33,255 and I just want simple linear white gradient to radiate from center towards the edges at maybe 5% opacity so it makes a shine effect. But whatever I do, it ALWAYS has some banding or noise. Tried doing it in both Af photo and Designer, but photo is def worse. I use all default settings, dithering is ON. Quote Link to comment Share on other sites More sharing options...
gdenby Posted February 18, 2017 Share Posted February 18, 2017 I'm not quite understanding what you are doing. The last time I made anything w. dithering was for 8 bit .gifs. By definition, those were noisy and usually banded. Quote iMac 27" Retina, c. 2015: OS X 10.11.5: 3.3 GHz I c-5: 32 Gb, AMD Radeon R9 M290 2048 Mb iPad 12.9" Retina, iOS 10, 512 Gb, Apple pencil Huion WH1409 tablet Link to comment Share on other sites More sharing options...
v_kyr Posted February 18, 2017 Share Posted February 18, 2017 A bar like this? Quote ☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan ☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2 Link to comment Share on other sites More sharing options...
Neith Posted February 19, 2017 Author Share Posted February 19, 2017 Yeah something like that, but here is exactly what im trying as you can see in the png there is no banding on the left but on the right banding is noticable. Quote Link to comment Share on other sites More sharing options...
anon1 Posted February 19, 2017 Share Posted February 19, 2017 Yeah something like that, but here is exactly what im trying as you can see in the png there is no banding on the left but on the right banding is noticable. I see what you mean I don´t have a solution but I admire the problem :D do you have the affinity file (probably a simple file but anyhow :P )? Quote Link to comment Share on other sites More sharing options...
Neith Posted February 19, 2017 Author Share Posted February 19, 2017 here's the af file bar.afdesign Quote Link to comment Share on other sites More sharing options...
anon1 Posted February 19, 2017 Share Posted February 19, 2017 so where did these pixel layers originate from? Ultimately it does not matter though, so anyway use a vector shape and fill it with a gradient and then export and all looks perfectly fine (at least when I tried it, so please try on your side) I attached the file cheers Quote Link to comment Share on other sites More sharing options...
Neith Posted February 19, 2017 Author Share Posted February 19, 2017 yeah that looks much better thanks. i was adding the gradient on a blank layer :S anon1 1 Quote Link to comment Share on other sites More sharing options...
Guest Posted February 19, 2017 Share Posted February 19, 2017 Hi neithque, It seems that the lines appear whatever the drawing method used to make the bar.I tried the rectangle, the pen and the pencil and the result is always the same. Quote Link to comment Share on other sites More sharing options...
gdenby Posted February 19, 2017 Share Posted February 19, 2017 I know what is going on, but know if I can quite describe it. Human vision can perceive intensity variations that are around .005 different. That is why 256 grey scale images are perceived as having continuous tones. At 200 shades, one will inevitably see slight differences. Dithering helps, but only if the dots are small enough to mix in the eye. That's why printed documents need to be at least 150 dots per inch, preferably 300. The sample image is at screen resolution, 72. The tonal range is slightly too small, and a smooth interpolation will have pixels that are more than .005 different. I haven't used AD's pixel features much, so I wasn't able to improve the file. I don't had AP. I do have Photoshop elements, and when I put the sample .png, the dither artifacts can be suppressed by doing a Gaussian blur of no more than 1 pixel. .5 is almost as good to my eye. Quote iMac 27" Retina, c. 2015: OS X 10.11.5: 3.3 GHz I c-5: 32 Gb, AMD Radeon R9 M290 2048 Mb iPad 12.9" Retina, iOS 10, 512 Gb, Apple pencil Huion WH1409 tablet Link to comment Share on other sites More sharing options...
anon1 Posted February 19, 2017 Share Posted February 19, 2017 yeah that looks much better thanks. i was adding the gradient on a blank layer :S ah you used a pixel layer well that is kind of bad practise in this case (because vector is resolution independent and seems like affinity can thus optimise it in a better way) @gdenby, does my file not look good on your side? did you choose a very high export compression? cheers Quote Link to comment Share on other sites More sharing options...
gdenby Posted February 19, 2017 Share Posted February 19, 2017 ah you used a pixel layer well that is kind of bad practise in this case (because vector is resolution independent and seems like affinity can thus optimise it in a better way) @gdenby, does my file not look good on your side? did you choose a very high export compression? cheers When I open it in AD, I can see some slight variations. When I zoom to about 1200% the dithering is obvious. I edited my post. I had written that the tonal range was to large, but should have written too small for the size of the area. I am viewing on a retina display. It takes about a 400% zoom to view things at about the same grain as 72 dpi. I've just started reading about .svg. Only scratched the surface, but I wonder if a fix to the problem would be outputting the bar to that format rather than .png. If I'm understanding the spec correctly, it is rather like postscript, in that the files can be rendered to the best quality of the viewing/printing device. Quote iMac 27" Retina, c. 2015: OS X 10.11.5: 3.3 GHz I c-5: 32 Gb, AMD Radeon R9 M290 2048 Mb iPad 12.9" Retina, iOS 10, 512 Gb, Apple pencil Huion WH1409 tablet Link to comment Share on other sites More sharing options...
Medical Officer Bones Posted February 19, 2017 Share Posted February 19, 2017 A gradient will always cause banding if the two values are too close and the width of the element is too wide to accommodate a smooth transition. The OP's gradient example must transition from [33,33,33] to [56,56,56] - a value shift of 23 over a width of about 480px---> each value shift takes up 21px. And that results in visible banding. Gdenby mentions that our eyes will notice the banding (more than a 0.05 value/intensity shift occurs). Working in 16bpc often prevents this from occurring, but the end result generally must be converted to 8bit per channel. The only solution that works to mitigate these banding issues is to apply some dithering between steps or apply noise to the overall gradient in the 8bit version. Here is an example of how dithering applied between each step considerably visually reduces the banding. Zoom in to make out the dithering. (do not attempt to view this file within the context of a white background - our eyes adjust to the white, and it is difficult to compare the two! Open in Photo instead) And exacerbating the matter is banding caused by low-quality screens with a limited colour gamut. When working with SVG (Scalable Vector Graphics) the banding ought to be prevented by the browser's built-in dithering/anti-aliasing algorithms. Unfortunately, it depends on the browser and the operating system whether this actually is applied or not. For example, the above gradient displays with bands in Firefox Developer for me, while it looks fine in both Opera and Chrome. (I am on Windows, btw.) I read that OSX may introduce bands in Chrome. In a nutshell, SVG may not be the solution you are looking for if banding is to be avoided altogether - it depends on the OS and browser in my experience. anon1, R C-R and mykee 2 1 Quote Link to comment Share on other sites More sharing options...
rschaub Posted July 6, 2017 Share Posted July 6, 2017 Sorry to open an old topic, but I ran into the exact same problem as OP in Affinity Photo. I'm creating a new pixel layer (256x256) and place a rectangle across the whole layer, which I fill with a gradient (linear, black to white, 256 greyscales, which should theoretically result in one step up in lightness per row). I too noticed considerable noise instead of a smooth gradient. Then I found the slider 'noise' in the gradient color picker. It is set all the way to the left, which should disable any noise. Moving it to the far right will increase the amount of noise in the gradient which is to be expected. However, moving the slider only slightly to the right from its leftmost position will decrease the noise to a barely visible level (it will not disappear completely!). I'm pretty sure that's not the intended behavior... One could argue that if it's barely visible, it's no big deal, but I need a perfectly smooth gradient because I'm using it as a lookup table of sorts for a program I'm writing. Having discontinuities appear in the image will render it useless. left: default settings (magnified gradient) right: noise slider moved slightly. Noise is reduced but still visible. Is there a known workaround to this? Thanks! Quote Link to comment Share on other sites More sharing options...
rschaub Posted July 7, 2017 Share Posted July 7, 2017 To answer my own question: The problem with visible dithering in theoretically smooth gradients lie with the application's performance settings. Edit -> Performance -> Dither gradients Unchecking this option will make gradients perfectly smooth :D . Having the option checked will result in the above mentioned behavior. Madame 1 Quote Link to comment Share on other sites More sharing options...
mykee Posted August 23, 2018 Share Posted August 23, 2018 I has problem with gradient too. I made a book cover, and I see gradient lines on exported PNG. What I tried: turned off Dither gradients option used Fill layer or Rectangle - no helped My project was in CMYK mode, and I set gradient from white to black. I used 1.6.5 version of Affinity Photo. I added Nose Live Filter, and set to 10%. This is enough for smoother. Quote Link to comment Share on other sites More sharing options...
Fixx Posted August 24, 2018 Share Posted August 24, 2018 ? John Rostron, firstdefence and Alfred 2 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.