Moving CMV shader from 2.7 to 2.8 - color problems?

So, I am trying to move a material from Reynante Martinez’s Cycles Material Vault from Blender 2.79 to Blender 2.81.

The material is entirely procedural, and looks fine in 2.79. But, when I load it into 2.81, what are gray voronoi cells in the 2.79 version immediately turn into a pastel rainbow colors in 2.8. On immediate view, I can’t see any obvious place that things are broken, but I also am not sure what procedurals were updated in 2.8?

The voronoi cells are fine and of the proper scale, it is just the colors that are wrong. I am going to attach a .blend file that I will save as a 2.79 file. Opening this in 2.8 will preserve the node tree, but rendering it will reveal the issue.

If anyone has any suggestions or could take a peek, I would very much appreciate that.FlatMetal279.blend (2.4 MB)

The voronoi (and others) have been updated. Where fac and color produced the same thing before just in color or black and white, the fac has been removed and replaced with distance and position outputs which are not the same thing as a grayscale fac. To get closer to the original, drop in some RGB to BW nodes on the voronoi color outputs.

1 Like

Thank you so much! I’ll open up a window for 2.8 and 2.79 and make sure I keep it consistent, and adjust according to the changes you mentioned!

Much much appreciated!

Was anything changed with the Noise textures? I must not have looked close enough, but its actually a combination of the noise and voronoi that is getting the miscoloration.

The RGB>BW nodes did fix it by the way! I am just curious if the Noise procedural was also updated? Or… where to read about on my own what all were changed and what that means?

Marked you post as solution! Thank!

Yes, noise was updated too. It’s doing noise slightly differently now in order to support 4D noise. So the generated pattern doesn’t look identical to before I believe, but it still has the same “feel” to it. Unless you’re matching previously rendered frames with a particular look to the pattern, there should be nothing to worry about. Fac still contains the R channel.

If you want to work with the F1 voronoi color output in BW, use a white noise node to automatically scale the output from 0 to 1. It makes the signal easier to handle in further calculations.
If you want to work with the Smooth F1 voronoi color output in BW, you have to use a map range node and tweak its input settings.

The “math” used in the setup could be improved for signal readability and driveability. I’m not a fan of using color ramps for doing simple greater than checks, and I also usually prefer map range instead for smoother transitions. Diffuse is used on a metal, it’s even O-N diffuse for unknown reasons. I’m guessing the glossy roughness produce wrong results (now squared), and they don’t change for the scratches. And for the Normal/Bump map, hard clipping is used. Bump modulates strength instead of distance. Unnecessary use of detail in the noise nodes. No variation inside the flakes. Material is called “FlatMetal”? What does that even mean? Although given the pattern, I’m guessing it’s hot dip galvanized zinc.

But in the end, if it works, it works.

Yeah, it’s been quite a while since I have made any effort to really work with materials, so I’m still pretty basic as far as the details. For this, I just needed something on hand that was close enough to something that would look like solder from a distance, but yeah I’m pretty sure it was supposed to be galvanized something, like a zinc washer.

But your commentary is pretty interesting (I had wondered about the color ramp that you mentioned). But your critique has enough detail that I can probably learn some necessary things looking at this, even though the material itself isn’t that important.

What do you mean “now squared” on the glossy/roughness? I’m probably thinking the wrong direction with how I’m interpreting that.

Are you aware of any good resources on intermediate/advanced material creation? I can understand a lot of the documentation well enough, but obviously there’s not a lot of commentary in there on “intent” and the the usage cases of some of these things.

Previously all the “important action” of roughness happened in the 0-0.1 region. Now we use the square root. In order to have a roughness value slider that “worked well”, we used to have to square the number.
Square root of 0.04 = 0.2. Square root of 0.09 = 0.3. So in order to get roughness in the (now) 0.2 - 0.3 ranges, we had to use those very impractically low numbers.
Still, a roughness is just a roughness. Gold will still be gold no matter the roughness, and you should adjust its base to match what you think it should look like in your current project. A roughness map doesn’t dictate how rough a material will always be - don’t go into the trap thinking maps are absolute. If you search for galvanized hot dip images, results will vary from very matte to almost polished looking. When I have such a map, I always use the new map range node, possibly in combination with some custom bias and gain nodes if I want to change the interpolation.

No, not really. I’ve been meaning to do some tutorials myself aimed mostly at tutorial creators (because there is a lot of garbage info out there and a lot of tutorial creators that doesn’t know the details of what they are teaching about), but I never got around to do it. The worst are those copying nodes from the extra screen, then hooking them up - and we never get to see what happens to the signal between steps. But I’m glad I waited, because now I can pretty much scrap my whole math library functions because most of them are now built in. I would recommend watching tuts for other software, photography and cinematography, even painting and color theory.

1 Like

Thanks, I will do that. I had already started looking at tutorials for Maya/Arnold and trying to pick up on the principles etc.

But, I think your idea for tutorials would be really something exceptional. While I appreciate tutorials that are to the point about some specific effect or another, that’s not really “learning”. One of my favorites recently was a relatively simple one about a “planet from space” shader, but what was important was that even though it was so simple, it was heavily focused on how the signal was altered at each node along the way. And since at the end of the day, with materials it is two things (1. understanding what real world materials are and why, and 2. signal processing), I feel like many people would benefit far more from tutorials that, say, pick 2 or 3 interesting (if mundane) materials to reproduce, but then focus heavily on the theory and how each individual node specifically effects the signal (and why). So then, for those like me that aren’t professionals, we can see our end goal and it’s not pure theory, but that we learn important parts of the theory along the way.

If you ever do make any of those, I hope I am around to see where you post them.

And honestly, even though many of the math functions that were missing are built in now, I honestly would still really appreciate if you had pictures of any node setups with explanations, or just general descriptions. Because for me, personally, I learn best once I see a number of set-ups and start to see how things are combined. Even just the math elements, being able to visualize the connections and transforms are very helpful to me since I am predominately a visual learner.

Thanks so much for entertaining this discussion, Carl.

Not really except in some threads I’ve posted to, but I have for own reference a picture of my library here:


Many of those will be deprecated by now, some has been updated, and some new ones are in. Just added a node experiment for seamless loopable generator usage. I’ve done it before, like 25 years ago, so I know it can be done using 4D generators in 2D space. But I never got around to actually doing it until today. Haven’t tested it fully, but looks promising.

2 Likes

Thank you! You’ve been incredibly helpful. I wish I could do more than just “Like” your comments. I sincerely appreciate it.