Jump to content
  • Advertisement
Sign in to follow this  
Rryk

Blender DirectX .x material export

This topic is 4059 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've created a mesh in a Blender. Then I've exported it into .obj file and UV-mapped in UVMapper. Got a new mapped .obj file which I've imported into blender. Now I need to export that mesh into .x file so I could render it in DirectX with texture. I've tryed to export with standart .x exporter and DirectX8 exporter found in this article: http://www.gamedev.net/reference/articles/article2255.asp. But it didn't helped me. Every time I execute this code: D3DXLoadMeshFromX(L"dragon.x", D3DXMESH_SYSTEMMEM, d3ddev, NULL, &bufShipMaterial, NULL, &numMaterials, &meshSpaceship) it returns numMaterials=0. So I cannot load any material. What is wrong with this? Why do I get 0 materials (whereas in plain text of .x file there 3 materials)? How do I fix that? PS: I think this question to be at the beginners level, but i think it is more DirectX-related, so I posted it here. Sorry if i was wrong.

Share this post


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

  • Advertisement
×

Important Information

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

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!