With PBRMaterial and HemisphericLight BJS causes strong reflections. Anything looks like it is wetty.
With PBRMaterial.metallic = 0; I get only a 50/50 mix of albedoTexture and Metallness.
Am I missing something?
(I will try to do a PG)
A PG will definitely help.
Also, you should use an env map (if not already using one), as a PBR scene really requires one for good results.
Yes, I do use a reflectionTexture, but only for reflecting PBRs like glass or metal.
Otherwise it gets ugly effects even on lawn:
The odd thing is, if I drop my model as gltf in https://sandbox.babylonjs.com, it looks good. But I can’t see how it is done. Does it have a HemisphericLight as I need for shadows? Why is there reflection of the reflectionTexture only on windows?
It is almost impossible to give a reliable answer without the gltf file itself.
There it is:
But that’s only a static view. My real code does it by BJS calls
PG will come …
May be, the RoughnessFromMetallicTexture I got is inverted? Dark is 0 and Light is 1, I assume.
How it should look? - https://playground.babylonjs.com/#UKNERM#360
Hi. Looks like material rough value is too low. Open bjs inspector in your app and look to material rough value. For non metallic surfaces like asphalt and lawn metallic factor always = 0
Thank you for your motivating replays.
Mostly I did not understand the whole concept. And I am not sure if I do now.
@kvasss, you were right:
Because the reflections where that strong, I set metallic=0. This does NOT disable reflections but only to 50%! What?
To get rid of the remaining 50% (only for not mirroring textures) I set roughness to 1.
Stupid; this way I disabled RoughnessFromMetallicTexture and MetallnessFromMetallicTextureBlue.
An BJS PG showed me: “set to 1 to only use it from the metallicRoughnessTexture”
The textures I use seem to be korrekt:
- For lawn etc. the metallnessBlue is black/0 and the roughnessGreen is white/1 except for some wet spots.
- For metall and solar panel i.e. metallness is 1 and roughness 0 except for some scratches
But metallness=1 gives really strong reflections, the albedoTexture is almost invisible.
So I set .metallic = 0.2 to get a realistic surface. Is that meant this way by BJS?
The .reflectionTexture works fine for metallic surfaces. But at roof etc. with a hight roughness,
the average color value of the texture get added. As I use a blue sky, the whole scene gets a wrong blueness.
Does using .reflectionTexture take render time? If I use it only for reflecting materials,
the scene gets to dark, even with light.intensity = 1.0. I can set it to 2.0 or even 5.0
to get the needed daylight view. But why do I need this. Is that meant this way by BJS?
One more thing: I set the HemisphericLight direction.y opposite to the DirectionalLight shadows. %-)
@labris, your PG is clever. The external link, light.position = camera.position. It uses a PointLight causing a special atmosphere, good for dawn scenes.