- Home /
Mesh looks transperent on one side
Hello all,
I've imported a 3D .fbx model into unity and it seems that one one side the mesh is showing but on the other side it's transparent. Pictures:
SideA:
SideB:
You can see how sideB, "the inner side", is a transparent side of the same mesh.
What's causing it?
Answer by zero_null · Dec 28, 2017 at 07:29 AM
This is completely normal behaviour. It's called backface culling, and it's the most common graphics optimisation used by video cards and the like.
Every face has a 'normal' value, which defines the vector pointing directly out from that face. As well as being used in several shader calculations (lighting etc.), it is also used by the camera to determine whether the face in question is on the side of the object which should be visible. If not, (ie. the normal is facing away from the camera) it simply does not render the face.
There are two solutions to this problem- the first is to find or modify a shader which doesn't remove backfaces. This is probably not the best of plans, since it will probably double the amount of rendering that needs to be done, for no real advantage.
The second option, which I would recommend, is that you model all your meshes to have two sides- one set of faces for the outside shell, and another set of faces pointing the other way for the inside. Another thing- for UV mapping, you probably want a different texture on the inside. If you only have one set of faces, you'll have the same texture on both sides- which would look a little odd, for most buildings.
Originally answered by @syclamoth
https://answers.unity.com/questions/195166/texture-maps-render-on-one-side-only.html
Answer by Eco-Editor · Mar 29, 2018 at 05:58 PM
I've changed the shader to Sprite default. Works like a charm :)