Loading an X file on DirectX 10 without DXUT
Hi there,
The tutorial on loading a mesh from an X file on DirectX 10 mention that "(...)concepts covered here can also be applied without (DXUT) it."
I have studied the code on DXUT but still I don't get the picture on how to do it without DXUT, does anyone know a "bare bones" way to load an X file into a ID3DX10Mesh object?
Please, just point me to to right direction, because I have studied how to do it with DirectX 9 but that one uses a DirectX 9 Interface (ID3DXMesh) and some functions (D3DXLoadMeshFromX) that have been depprecated on DirectX 10, also, the documentation does not mention any equivalents on DirectX 10.
Thank you.
You'll probably need to parse and load the .X file yourself manually.
Failing that, you can always use the DX9 functions to load whatever you need (vertices, indices, etc.), the convert them to DX10 formats.
Failing that, you can always use the DX9 functions to load whatever you need (vertices, indices, etc.), the convert them to DX10 formats.
this link can be useful
http://www.gamedev.net/community/forums/mod/journal/journal.asp?jn=316777&reply_id=2747161
http://www.gamedev.net/community/forums/mod/journal/journal.asp?jn=316777&reply_id=2747161
I already know the link.
Anyway, i sent an email to microsoft asking it why they eliminated the functions.
I will post the answer.
Anyway, i sent an email to microsoft asking it why they eliminated the functions.
I will post the answer.
Quote:Anyway, i sent an email to microsoft asking it why they eliminated the functions.Hope you get a reply, but don't hold your breath.
I will post the answer.
The .X format and its related functions have been dying from neglect for years... A lot of customers have their own modelling and content pipelines already so there hasn't been much pressure for MS to create (or extend) yet another file format and yet another library. Creating a unified or standardised mesh and tool library is no small challenge either.
My code (mentioned by Squallc) is probably about the only way you can get this functionality right now...
hth
Jack
You might also want to try our small library called ASSIMP. It reads .x files as well as a dozen other file formats. It does NOT pack the information into a D3DXMesh, though... that's what you'd have to do for yourself anyways.
Thinking about this, the native X file support encouraged me to create a simple .dae file loader, and i learned a lot of new things about index and vertex buffer.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement