3
$\begingroup$

new to blender, so pardon me if this is a silly question.

I have two geometries and want them to have the same color , yellow. The color of the object needs to be diffusive , means that I do want the color to be there regardless the lights I have in the scene.

The two geometries have the same material, but they are behaving differently , the face one is correct, the moon is not.

What I can see is that the face has a yellow color regardless the light while the moon is grayish and turns out yellow only when the light bounces the surface.

Moon has 1 material only Face has 1 material only I have removed the garbage and you can see just 1 material per object

enter image description here enter image description here

It's not a camera issue as I not using this models within blender but exported as gtlf and while the face behaves well in both blender and gtlf , moon is yellow only when there is light on both blender and gtlf, so issue is not with the camera or the lights, issue is within the model itself.

enter image description here

Below the two materials

enter image description here

enter image description here

$\endgroup$
8
  • $\begingroup$ Hello :). Which of those two objects has the correct behavior? What do you have in mind when saying "I want the color to be there regardless the lights"? Please update the explanation :). $\endgroup$ Commented Feb 17, 2021 at 9:32
  • $\begingroup$ Thanks Michal, updated the question. $\endgroup$
    – czane
    Commented Feb 17, 2021 at 10:21
  • $\begingroup$ Hi czane, My answer is short so why don't you try flipping the moon. I saw a yellow part on the other side. A few materials don't work with one side but work with the other. Try flipping the moon on the Y axis. Please try share some more information though. If flipping the moon doesn't work, I would say change the position of your camera. But honestly, I am not very good at diffuse materials. $\endgroup$ Commented Feb 17, 2021 at 11:04
  • $\begingroup$ @Aster17 thanks updated the question: It's not a camera issue as I not using this models within blender but exported as gtlf and while the face behaves well in both blender and gtlf , moon is yellow only when there is light on both blender and gtlf, so issue is not with the camera or the lights, issue is within the model itself. $\endgroup$
    – czane
    Commented Feb 17, 2021 at 11:42
  • $\begingroup$ czane, I think I found the problem. Decrease your metallicness for a bit. When metallicness is set to 1 on such objects, it causes problems like this, try changing it to something like 0.95. $\endgroup$ Commented Feb 17, 2021 at 12:37

2 Answers 2

1
$\begingroup$

Probably the best way to approach it is to use a flat shader (color shader) without diffuse, the other way is to use the objects' normals in order to create a "fake" light and keep them always consistent regardless the light conditions in your scene (as it is done in most NPR approaches).

this is how a flat shader would look like (just an emission shader in Blender's context)

Emission Shader (flat)

enter image description here

and that's how an NRP would look like

Dot Product (Geometry Position)

Dot Product > Position

or like this

Dot Product (Geometry Normals)

Dot Product > Normals

check the material setup here:

enter image description here

the second vector in the Dot Product node (math vector) will be the source of your fake light.

enter image description here

Keep in mind that Dot Product gives also negative values, so you may need to clamp it for certain occasions

$\endgroup$
2
  • 1
    $\begingroup$ Wow, I never knew dot product exists in node. I know it in calculus. Thanks for this answer and the nodes. $\endgroup$ Commented Feb 17, 2021 at 14:15
  • $\begingroup$ sure, don't look for a Dot Product, it is just a method in Math Vector node (just clarifying that you wont find a Dot Product node by itself). $\endgroup$
    – cnisidis
    Commented Feb 17, 2021 at 14:17
1
$\begingroup$

Solved via Mr Zak solution:

I'd try to apply scale for the moon object (object mode > ctrl+a), then in edit mode recalculate normals. It looks to be the reason for difference in shading in viewport

WHAT DONE:

Changed Scale

Recalculated normals

enter image description here

$\endgroup$

You must log in to answer this question.

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