Jump to content
  • Advertisement
Sign in to follow this  
fkhan

Slimdx Direct3d9 Model skewing

This topic is 3072 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am writing a collada model viewer and have been using the BasicEffect.fx from XNA. The model I am trying to render is of a dice(cube) which renders fine only that it is skewed and looks like a trapezium. It renders fine if I use a different effect file.

Share this post


Link to post
Share on other sites
Advertisement
Here is the screenshot of the model
https://docs.google.com/leaf?id=0BwVB_dthrIq6MTYxMDU3MDgtYmY4YS00MzM5LWI4NDMtZjc3YTQ5Y2E5ZjBk&hl=en

Share this post


Link to post
Share on other sites
Its not skewed.

Your triangle winding order is opposite of your back-face culling mode.

Have a look at renderstates and d3drs_cullmode in particular.

You are seeing the inside of the cube as if the outside faces were see-through.

Share this post


Link to post
Share on other sites
Right on steve! How could you ever tell that was from culling?
Just had to set cullmode in render loop.

To save debugging time for others, here's the code
device.SetRenderState(RenderState.CullMode, true);

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!