Environment has too strong reflection on objects

Strong reflection, for glass mirrors, direct reflection,
The effect is not very good.

This is the effect in Sandbox.PG example:
sandboxExample

image

--------------------------------------------------Divider-------------------------------------------------------------

I placed it in the modelviewer, and the reflection of light is very soft.

image

I want to know how to adjust the bbl to make the reflection softer.

Note: I am using the same environment ball for both of them. The name is neutral. hdr

Hello :slight_smile:

Your sandbox link won’t load on my side.
Did you try to tweek mesh.material.environmentIntensity ?

hi, Sorry, it’s possible that the rich text escaped the link. I adjusted it again and the link address can be previewed now.

Ok, as I said I would advice to tweek environmentIntensity on the glass
Material, (which is LEVELS --> Environment in the Inspector)
Screencast from 09-07-2024 11:28:54

Why do other engine not need to be adjusted? Is it because BJS’s rendering algorithm is different

I would say it’s not exactly a matter of algorithm. Rendering is a thing, lighting is another.

Here in the Sandbox there is an Environment by default. Maybe when you do final usage of your mesh you will add another environment with another lighting intensity, maybe you will add some more lights or whatever. Here comparing the default scene (and its lights) of two viewers (BJS Sandbox, and ModelViewer) does not really make sense to me. At least I would say the difference comes from the lights, more than the rendering pipeline :slight_smile:

In both of the above environments, I used the same HDR. I just want to see the difference in effect. That’s why there are doubts

Ah ok, missed that sorry. I thought you was just pushing the .glb file containing meshes alone

adding @bghgary to check if this is not a problem in our gltf loader not taking in account something

There are multiple reasons why Babylon.js sandbox is different. The primary reason is because we don’t follow the glTF spec for alpha coverage because almost everyone is trying to use it for glass. If it’s glass, Babylon’s rendering is more accurate to what should happen. If you want it to behave completely to spec, then you can use 3dcommerce.babylonjs.com. Newer models should use the KHR_materials_transmission to handle glass which should render consistently across implementations.

It is also brighter in Babylon.js because no tone mapping is applied by default whereas ModelViewer has a tone mapper on by default. You can enable it by clicking on Scene in the inspector and enabling the Khronos PBR Neutral tone mapper which is the same as ModelViewer’s default. We are probably going to enable this tone mapper by default in the 3dcommerce mode.

image

In the screenshot below, I also changed the background to white. This should look much closer to ModelViewer’s settings.

5 Likes

Thank you, buddy. Your answer was fantastic.

Should we need to enable PBR Neutral for PBR realistic rendering?

It depends. Emmett, the driver of the PBR Neutral tone mapper, has an article describing the use cases. This is a complex subject and depends on what you are trying to do.

1 Like

Thanks, I’ll go read and learn