Object appears partly transparent when rotated

Started by
22 comments, last by gchris6810 10 years, 4 months ago


Do you have any ideas of how I could solve this in DirectX 11 that extend on the ideas above?

You still haven't posted your projection matrix, along with the code that generates your projection matrix (as Spiro said, the thing that you posted was probably not your projection matrix, or if it was, then there's something seriously wrong with it and it's probably where it all goes wrong). Posting the view matrix too might be a good idea.

Advertisement

Okay, now i'm sure it has something to do with the depth. When I rotate the object before I do the first render pass 90 degrees the render appears completely 2D with all the triangles drawn on top of each other! It seems the closer to 90 degrees it is drawn the more of a 2D view you seem to get. I hope this helps.

Could someone please tell me what I have to do to solve this as it has been bugging me for a while now. As for the matrices you asked for, the matrix I posted previously is the only one I am using which is the models transform matrix (The bottom right element should be a 1 rather than a 0).

Okay, now i'm sure it has something to do with the depth. When I rotate the object before I do the first render pass 90 degrees the render appears completely 2D with all the triangles drawn on top of each other! It seems the closer to 90 degrees it is drawn the more of a 2D view you seem to get. I hope this helps.

Could someone please tell me what I have to do to solve this as it has been bugging me for a while now. As for the matrices you asked for, the matrix I posted previously is the only one I am using which is the models transform matrix (The bottom right element should be a 1 rather than a 0).

So this is your model transform matrix then?

0.035, 0, 0, 0,

0, 0, 0.045, 0,

0, 0, 0.045, 0,

0, 0, 0, 1

If so, then that is probably the problem, because that matrix is doing some sort of weird skew that would flatten the model completely along one axis. I'd expect something more like:

0.035, 0, 0, 0,

0, 0.045, 0, 0,

0, 0, 0.045, 0,

0, 0, 0, 1

No sorry my matrix is the second one you posted.

0.035, 0, 0, 0,

0, 0.045, 0, 0,

0, 0, 0.045, 0,

0, 0, 0, 1

This topic is closed to new replies.

Advertisement