1
$\begingroup$

I've a shading node setup to create a scratched surface, to show wear of paint. I'm using Blender 2.80. See the image below.

enter image description here

I would like to export the model to SteamVR, and for that I need a single diffuse texture (normal map can be set separately in the SteamVR model). I was hoping I could bake the result. The baked result should not contain shadows or light gradients or anything, only the base color from the BSDF shader, combined with the image from the mix shader so show the scratches. So I expect no gradients, but a homogenous surface color, with scratches here and there, (showing through the other picture of wood). See the shader node setup below.

Shader nodes:

enter image description here

Bake setup:

I tried combining different options. But none give me the result I am looking for.

enter image description here

Result:

This is the best result I got so far. It shows the base color (white) with the colors of the wood texture (to show the scracthes). But the base color has gradients, which I do not want. I do not want the darker color on the left, but a homogenous color. How can I achieve this?

enter image description here

$\endgroup$
7
  • $\begingroup$ Bake margin? or blender.stackexchange.com/questions/60285/… ? $\endgroup$
    – lemon
    Commented Jul 20, 2019 at 12:14
  • $\begingroup$ @lemon Thanks for the help. I found a way to get what I want, by setting the emission of the Principled BSDF shader node. I've added it as an answer to this question. $\endgroup$ Commented Jul 20, 2019 at 12:28
  • $\begingroup$ ok... I see the point: the object to bake to made shadows. Another approach (I think) should be to use directly the color as output (with no shader) $\endgroup$
    – lemon
    Commented Jul 20, 2019 at 12:33
  • $\begingroup$ Would that replace the Principled BSDF shader entirely? That would make it a bit more difficult I think to include a normal map. But for the baking that is not a point of course. $\endgroup$ Commented Jul 20, 2019 at 12:43
  • 1
    $\begingroup$ Mike, thanks, but the principal is you have a solution (and this solution is also accessible in the comments). $\endgroup$
    – lemon
    Commented Jul 20, 2019 at 20:52

2 Answers 2

2
$\begingroup$

I found a way to do it. The only thing that I changed is setting the Emission parameter of the Principled BSDF shader to complete white (it was completely black).

enter image description here

Bake settings:

enter image description here

Result:

enter image description here

Downside:

The color of the texture created is no longer determined by the "Base Color", but by "Emission". So probably any other thing going into the base color parameter wouldn't end up on the texture I am affraid. But for my use case, this setup is giving me what I want.

$\endgroup$
1
  • $\begingroup$ Give a try plugin directly the color to the surface output.Should use a mix rgb instead of mix shader to do that.So that will stay a diffuse (but not shaded). $\endgroup$
    – lemon
    Commented Jul 20, 2019 at 12:39
1
$\begingroup$

Although I do not know how to do this in vanilla blender, I highly recommend the Principled Baker add-on.

With this add-on you can bake (almost) any complex material into multiple texture maps (color, metallic, roughness, normal, etc.) to feed into one single principled shader, and the render result should be identical to your original node setup. The color map is unaffected by lighting, and works on both metallic and non-metallic surfaces (unlike the vanilla diffuse baking), which should meet your need.

When you have the add-on installed, select the object(s) which you want to bake, go to the node editor view, and press N to bring up the Principled Baker panel. Either use the auto detection mode or manually choose whichever maps you want. It will automatically export all the maps you have selected at once.

$\endgroup$
1
  • $\begingroup$ Unfortunately I am using blender 2.80. Blender 2.79b is not able to open the file. But thanks for the tip anyway, of course! $\endgroup$ Commented Jul 20, 2019 at 12:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .