Static Lighting and Reflection

I’m doing a scene with Static Lighting that relies only on emissive textures, Lightmaps and an HDRi for the general lighting.
I have some reflective materials in the scene, like a glass material, but I don’t want to get the reflection of the HDRi on those, I want to use another texture. For that I baked in Blender a Panorama Equirectangular texture and tried to put it in the Reflection and in the Refraction channel (I use the sandbox and a PBR material) but I can’t get the result I want (I tried all the mapping mode in the general texture settings).

I want the reflection to be like the HDRi one, but when I use those channels with my texture I get a static flat image that change the UV offset when I change my view, and not rotate around the object like an HDRi does.

Here the file for a test scene:

Glass Test .Babylon

What should I do to make it work as intended?
I use Blender and the Sandbox in my workflow (exporting in .GLB from blender and then in .Babylon from the Sandbox), I don’t use the Playground.

Playground is always helpful for answering your question, even if you don’t use PG yourself.
So I created one with your model -
From the first sight it seems that your reflection texture should be defined as Cube texture, otherwise it will be flat.

1 Like

So, for fixing it using the Sandbox what should I do? I tried setting the mode to “Cubic” in the texture properties but it still has problems.

The texture is not displayed as flat anymore but has an incorrect visualizzation, probably because that mode doesn’t work with classic panoramic texture but need a Cubemap. What kind of Cubemap standard babylon needs for that option?

This converter shows some cubemap layouts but none of them work in this case.

Here is the Documentation - Reflections and Refractions | Babylon.js Documentation
Here is the new PG - - seems that it works now as it should to.
As you may see, I added the box with correct settings below the model and after that passed the reflectionTexture and its coordinatesMode to the vetro material.

I get the logic you used to do that, you generate a CubeTexture and use it for the reflection channel.
The problem is that I need to do it only with Blender+Sandbox, and using the Sandbox editor you can’t import a CubeTexture in the input for the Reflection, it only accepts an single rgba texture:

But I need to get this:

So I need a way to export (using .glb) a CubeTexture from blender to Sandbox, or enable the import for CubeTextures directly from the Sandbox editor.

Do you think it’s possible?

“load texture from file” button below the preview doesn’t work?

Sandbox is not really a editor, it’s to preview 3d models
Inspector too, preview file contents and debug models :slight_smile:

Because in your material properties it is not defined as a Cube texture.