Sign in to follow this  
nathandelane

Do I have to map all of my .X coordinates to Direct3D world coordinates manually?

Recommended Posts

So I'll state the question at hand, do I have to map all of my .X coordinates to Direct3D world coordinates manually? I haven't gotten this far yet, but I am wondering about it. I'm using Blender 3D to export to .X mesh format, and I am wondering do I need to do the world coordinate mapping myself for each vertex in the file, or does Direct3D know how to do that such that all I need to do is transform the entire mesh to where I want it to be (or the camera)? Nathan

Share this post


Link to post
Share on other sites
You just transform the whole mesh. Basically you say to D3D "I want you to move everything by this amount", I.e. "I want to add this value on to every vertex".

The way D3D works is by applying a transform to every vertex you render (Or rather, every vertex you render until you give it another transform).

Share this post


Link to post
Share on other sites
[quote]Original post by nathandelane
So when I load mesh.x Direct3D knows how to draw it, and I just have to translate it?[/quoteD3D will draw it using the coordinates you have in Blender. If you want to move it, then you can move it - but you don't have to. By default, the object is rendered in the same position as the mesh says (I.e. it's not offset at all).

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this