D3DXMESH and LOD / multiple sub-meshes
Simple question:
I have an X file with the following meshes in it:
H -> High level of detail
L -> Low level of detail
HLIGHT -> Head light
TLIGHT -> Tail light
WHL0 -> front-left wheel
WHL1 -> front-right wheel
WHL2 -> back-left wheel
WHL3 -> back-right wheel
BOUND -> this should only be used for collision detection
How do I display ONLY the H, and WHL# meshes using D3DXMESH? The normal Xfile loading code displays all of those meshes.
NOTE: Each mesh is stored in a x3ds_(mesh-name) frame.
Your help is greatly appreciated.
Since no one else has replied yet, I will at least
try. Sorry, I just started looking at X-Files.
I did not know they could support LOD, but there is a
DrawSubset function.
Sorry, but I wanted to at least get in on the conversation.
try. Sorry, I just started looking at X-Files.
I did not know they could support LOD, but there is a
DrawSubset function.
Sorry, but I wanted to at least get in on the conversation.
A little more info, and bad news.
I have been doing research on loading and
displaying animation from an XFile (I started another
thread about this also). But basing all my knowledge
so far on the one example that came with the SDK
(since nothing else exists that I have found, yet),
it looks like you must make all the custom code to handle
it. This leaves me only to believe you must do the same
for LOD also. You can enumerate through the objects in
the file, and based on their ID, you will know what they
are. And from there you should be able to load the indivdual
objects from the xfile like normal, and calculate which
LOD to draw as normally done.
I am sad to say that there is not an easier solution.
I am starting think (as I did before) Xfile is not an easy solution, just a file type. Well, at least it is becoming a semi-standard though.
I have been doing research on loading and
displaying animation from an XFile (I started another
thread about this also). But basing all my knowledge
so far on the one example that came with the SDK
(since nothing else exists that I have found, yet),
it looks like you must make all the custom code to handle
it. This leaves me only to believe you must do the same
for LOD also. You can enumerate through the objects in
the file, and based on their ID, you will know what they
are. And from there you should be able to load the indivdual
objects from the xfile like normal, and calculate which
LOD to draw as normally done.
I am sad to say that there is not an easier solution.
I am starting think (as I did before) Xfile is not an easy solution, just a file type. Well, at least it is becoming a semi-standard though.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement