Well yes but no, you’re getting the right results but for all the wrong reasons.
It never ceases always amaze me how some artists are able to create the results that they want through sheer coincidence, with the math behind it just happening to work for that very specific scenario, but that’s also what I like about working with them.
Let me explain:
You might have noticed that besides the new Detail and Lacunarity inputs I also added a Normalize
checkbox to Fractal Voronoi Distance to Edge.
As your posts made me notice this checkbox is rather misleading because the for Distance to Edge the output is getting normalized by default but only takes the scale input into account. When you tick the Normalize
checkbox it additionally takes the Detail and Lacunarity inputs into account when normalizing.
I’ll probably change it such that it either no normalization happens at all or all inputs are taken into account. But for this discussion only the fact that the output is always normalized according to the value of the scale input is important.
Now I’d like you to have a look at this picture:
On the right side you’re seeing the output of your node setup, while on the left side you’re seeing the output of my Fractal Voronoi Distance to Edge using the same input values.
You might notice that apart from the border thickness the borders are at exactly the same locations.
This is where the part about normalization comes into play.
Your node setup normalizes each layer separately before applying the Darken function on the already normalized layers.
This is why the the borders in your setup has varying border thickness depending on the scale of each layer as the scale input normalizes differently according to the scale value.
My code normalizes the output after applying the Darken function on the not yet normalized layers.
Thus normalization only occurs once for all layers combined with the same scale value which is why the border thickness is the same irrespective of the layer.
At the end the only difference is the order of operations and no this still leaves no need for an additional Roughness input, as the behavior you want could be implemented using just a single checkbox, which reverses the order of operations.
However this is easier said than done, the Voronoi Texture
code is already pretty complex and I’ll have to see if there is an elegant way to do that.
And to clear things up:
I think that’s what I (and @Lumpengnom ? ) have been trying to say
The proposal Lumpengnom came up with actually isn’t the same as yours, with one of the differences being that his proposal would actually need a Roughness input, as opposed to just a checkbox.
Is that what you meant you’d do when you said
. . . I’ll add it to the things to rework.
I meant that I will rework the Edge to Distance output to take a Roughness input to act like the Factor input of the MixRGB node.