Inverted x-value of the vertices
I´m working with the DirectX 11 tutorial. I loaded one of my .obj models and added some light. Everything works fine. Now I mentioned, that the model seems to be mirrorerd, so I inverted the x-value of the vertices. This seems to solve the problem, but now the "light an shadow" is completely wrong. Its hard to explain, it is like the outside structure is mapped on the inside. I read a lot about flipping the normals, but until now I did´t find a solution. Thanks for any ideas!
Okay luckily I found an solution by just trying (for me) random things I read on the internet.
First I inverted also the x-value of the nomal.
Secondly I inverted the indices, so if the indices were [0, 1, 2], I changed them to [2, 1, 0]
on Sep 04 `18
gies
Sign in to comment
I see you already found your answer. you have to flip x on everything if you do it. inverting the indices will just flip the triangles "front" direction, which is usually what is used to "cull" triangles that are facing away from the camera (among other things of course too) Thanks for commenting with your solution though!