My mesh is showing the back side and I cant solve it

Hi everyone!

Below there is a link with my problem.

Every code below from <<<<<>>>>> I add to try a change.
This model I created with 3dsmax and export to Substance and save direct in substance to glft.
But I try another model saved direct from 3dsmax and export with a Babylon Exporter plugin and the same issue.

I found this solution but for me doesnt work.

Or its is my model problem or any code that I did not used…
This is my first contact with Babylon so sorry if a nooby question and sorry my english…

thanks for all.

EDIT1: If I save in .babylon from 3dsmax and NOT works. The same problem. I used a physical material with textures.
BABYLON.SceneLoader.LoadAssetContainer( “”,
“teapotFromMax.babylon”, scene, function (container) {

It seems like your mesh is exported with blend mode on. It works if I turn it off:

Please make sure that your textures are flagged as opaque

(pinging @PatrickRyan for more details if required)

@bisewski, we’re happy to help you get unblocked. You mentioned that your two paths to glTF were Substance, which I see you used Substance Painter 2018.3.2, and 3ds Max. Can you share with me your setup for Painter? Did you set up an opacity channel in your texture set? Also what material mode did you set up your project in (PBR metal-rough, PBR spec-gloss, something else)?

What you have is a simple case of the wrong alphaMode being written to your file like @Deltakosh mentions above. The fastest fix for this is to simply change the glTF material definition in the file. Using the glTF shell extension you can unpack a glb and repack it again. With it unpacked, you will see the glTF json file. Open it in your favorite editor, I use VS Code because it has glTF extensions that give you a viewer as well as intellisense, and change the alphaMode on your material from BLEND to OPAQUE like below:

While that is only a work around, if I can figure out your setup I can help you export without the work around.

One more thing you may want is double sided rendering since there is a chunk of mesh missing next to the lid. That can be added in the same way:

1 Like

Many thanks for your help. I really apreciate your attention.
Here you download my substance file .spp
And here you can download my 3dsmax file

I think like a user from complex industrial projects if is possible import direct from Substance Painter to gltf with this Blend Mode correct, will be perfect. I also will try here any option.


1 Like

Many Thanks for your attention Deltakosh!!! You are right…I will try to export direct from Substance Paint with this option correct…


1 Like

@bisewski, in looking at your Substance Painter file, you have an opacity channel in your material of which, only the metal base has any input and it’s input is 1.0:

When your texture set contains an opacity channel, you will end up with alphaMode set to BLEND in your glTF, even if your opacity channel is set to 1.0 (fully opaque). To get around this, you need to remove the opacity channel from your texture set:


To do this, click the minus icon next to the opacity channel and it will be removed. This will cause Painter to write out alphaMode OPAQUE which is what you want. If you were to need opacity in your asset, say the teapot lid was made of glass, you will want to make a separate texture set for this. You do this by assigning a new material to meshes that need opacity in 3ds Max. That way, when you get the meshes into Painter, they are assigned to the correct texture set and you then add an opacity channel to the appropriate texture set.

A good rule to remember is that you can only have one blend mode per material and if any of your meshes in your asset need to have opacity, any other mesh that shares their material will also end up in the transparent queue in the render. This will cause opaque meshes to render like you saw before because the transparent queue does not take a depth pass into account by default.

So the best practice, divide your mesh into opaque materials and transparent materials (as few as absolutely needed to hit your texel density target) and export that asset to work on in Painter. Then Painter should export your glTF correctly. Let me know if you have any other questions!

Its is perfectly Patrick…I try this solution in a more complex model and work fine…Thanks so much…

This is my first contact with babylon so I will discover many things, but I am very impressed with this Playgroung system and the attention in this support …