I am making a very complex material.
I keep running into an odd problem.
In material viewer, the black and white appear, as well as when viewed in the Diffuse shader node’s color.
But when I plug it into displace… no displace happens.
It happens sometimes, but it feels like when I add or multiply a complex node set in, suddenly no displace, although as I said, when viewed in material viewer or diffuse node, it still shows black and white details, indicating it should be displacing when plugged into displace.
So is there possibly a number of nodes limit, or a limit to how many nodes can be chained together in progression for displace output?
What could cause crystal clear black white contrast in material viewer, but no displace when plugged into displace.
As far as the displace goes I am not sure. But I do know that I have seen some crazy node setups that would make you go crosseyed looking at them. Looks like a plate of spaghetti that has been dropped on the floor. So not sure how many nodes you are talking here but I have seen some that seem quite overkill for their results…
There is an upper limit in which you will get an SVM stack error and the material will render black.
If you’re just getting artifacts in the viewport, try rendering and see how it looks. Some overly complex setups might look wrong in material shading mode. If the material still looks wrong when rendered, its time to make sure your spaghetti is al dente.
I think for some reason the displace is rendering black, hence no displace.
As I said, it comes out black and white when viewed in color (as a displace map would), but the displace fails.
And I say fails because the displace does work, it seems, until the material gets too complex.
However, the color always works.
Also, I read there is a uv limit of 8, but I am not using UV. All are generated or position texture coordinates.
@NeOmega You need to provide more information to this thread…
-Stripped file with the object and the material that produces the error;
-The version number of your Blender.
-Your hardware specs (OS, CPU, RAM, GPU, etc)
Without those, we can spend the whole week talking things totally unrelated.
To keep guessing though… have you tried to use full global illumination?
Properties panel -> Render tab -> Light Paths section -> Full Global Illumination.
The only time I got black artefacts was when using a lot of nodes and (transparent/translucent) objects and this was my solution.
I think I already got my answer.
I knew what I was doing, is not really how a material was intended to be used.
It’s got to be at least 400 nodes.
It is a material that uses gradient textures to map different materials on a human form. A skinning/clothing material
It is set up so you can say adjust the sleeve length or pants length with sliders on node groups, and assign different materials(displace)/colors to the different articles of clothing.
I just discovered that if I say adjust the sleeve length, the displace disappears. When I put the sleeve length back, the displace was still gone.
So that definitely sounds like a stack error.
I think for now, I’ll wait for official 2.8, file a bug report then, if it is still an issue, and move on to other tasks for my game. I have lost an entire two full days over this.
I don’t think the number 400 is the cause, but rather how they’re linked up. I once did a Mandelbrot setup, and since we can’t have iterative processes, I had to chain up the iterations by hand in a “not so long string of node groups”. I couldn’t do too many of them until Blender hung on me “Building Shaders” forever. Deleting one group in the chain, and it worked fine. And totally, it was a lot less than 400 nodes in total.
“Maybe” is a big gamble considering 400+ nodes. If you have a bunch of math equations in there, do you know if the math checks out with only values between 0 and 1? If clamping every math node fixes the issue, then the math is wrong somewhere. Otherwise there’s no need to clamp everything. Just use a min/max or floor/ceiling where necessary
So I was trying to move on, but more craziness happened.
I had a bunch of nodes selected, and the displacement was working.
I made them into a group, and the displacement failed.
Ctrl+Z, displacement remained gone!
So I saved, restarted Blender… …and the displacement came back.
I’ve had something as simple as a single noise node go corrupt on me; once I replaced it with the same settings and connections all became good.
This weekend I had three bump nodes that simply wouldn’t mix:
1 - Bump map1 covers all material.
2 - Bump map2 covering 1/3 is masked out with a 0/1 map with RGB mix. All good.
3 - Bump map3 covering last 1/3 is masked out with a 0/1 map with RBG mix - complete fail.
Setting mix manually 0 or 1 was ok, anything in between failed (all black). Fac was checked and had only 0 or 1, yet it failed as if it wasn’t. CM was not the issue here. Never had this issue before.
yes. i checked with the mix rgb nodes, by pulling the factor mask, and just using the slider. the bump mapping was either all one, or all the other. there was no fading between one or the other.