I tried tinkering with color ramps and layer weights, but no avail, these spread out the specular’s colors too much, and the whole model end up looking brown instead. A reference for what I’d like is the pearlescent paint option in GTA V, where you can have your car in one color, but the reflections in another, and I have yet to find any tutorial on achieving this effect for Blender, even though it doesn’t sound complicated at all…
You are trying to do something that’s not physically plausible. This means it won’t really be possible to do in Cycles, unless you do some compositing or maybe do weird stuff with specular intensity and tint.
But, it is possible in Eevee, thanks to the “shader to rgb” node. However, it involves breaking the rules of a standard material and doing some weird, non-physical stuff. Here is an exemple, file included.
Oh wow okay, I didn’t know it couldn’t be physically possible, thanks for the example. But yes I want to render in Cycles so this won’t do. Wouldn’t it be possible to get a similar result by changing the clearcoat color maybe? For instance, white Tesla cars have a slight hue in their highlights that is more colorful than the base paint, that’s what I’d like the get close to. Then if the black/beige color combination doesn’t work it’s fine, but I’d like to at least know how to get that single color pearlescent effect on metallic materials.
Well, there is a way to do something similar in Cycles, but not exactly the same. Instead of having the highlight be colored, it’s the part of the material facing the camera that is.
Cool thanks! That’s the closest to what I had in mind, still too spread out of my tastes but I’ll tinker with it. If you don’t mind, can you explain what was your logic in this, and how to use the “For better control than clearcoat” area? I’m pretty new on Fresnel and Layer weight, so I’d like to understand how it works.
Car paint materials are made of 2 layers: a rough metallic base with a transparent varnish on top (clearcoat).
I used the color ramp to affect the color of the metallic part. You can change the colors on the ramp or move them around to control the exact look. The clearcoat doesn’t change color, it’s a non-metallic effect and mostly affects the reflection at the edges of the material, but it’s presence is necessary for a convincing car paint.
I did the clearcoat as a separate group rather than using the one that comes with the principled shader, because the latter has some well know problems: it is added to the material rather than mixed, which is not physically correct, and it doesn’t let you control the color of the clearcoat if you wish to.
I mixed in the clearcoat with a fresnel node, because that’s how it works in real life: non-metals are more reflective at an angle and the fresnel represents this effect with the correct maths (you don’t have to touch the fresnel node).
However, I used the “facing” attribute for the color rather than fresnel, because it’s more artistically intuitive. The “facing” is a simple linear gradient that represents how much a polygon is facing the camera. The fresnel has a fancier exponential curve, which is harder to work with when paired with a color ramp. So, the facing is better for manual control and the fresnel is for accurate reflections.
Thanks for the explanations! So, I used your shader as a base, and with the help of a friend we ended up with this which is closer to what I had in mind. I like this better because it really filters the highlights, making it possible to have the reflections in any color I want, have control of the intensity with the color ramp and stay somewhat subtle. I’m posting it hoping it can be useful to other users. Anyways thanks a lot for the help! That basically led me to what I wanted.
Edit: Wait, something I don’t like about this shader: there’s some kind of reverse Fresnel happening where the sharper the view angle, the darker it gets? It gets really unnatural at some points, where the whole top of the model is black, even though it’s the part that receives the most light. The further to 1 the Fresnel node is, the worse it gets.
Do you have a scene or HDRI background around the object that can be seen in the reflection? If not, you are only reflecting a void and this can make reflective objects look bad.
If I replicate your setup, I get this, which colors the angled faces most:
I have made a further refined version of my setup. I have separated the colored specular from the main shader so it can have its own roughness and have made it narrower. I think this is the closest I can get it without using compositing.