Sign in to follow this  
Tiege

Simple Load Animated DirectX File?

Recommended Posts

Tiege    102
So I've been gradually learning and apply directx to load models from blender and render them etc. I'm onto loading animated .x files but its way more complicated than just loading the static model. The hierarchy function requires a lot more additions from the programmer that arent really given well in any tutorial I've found. Only the psuedocode is offered and all the samples are too complicated to pull any info out of for learning. Is there a simple tutorial out there that can help me JUST load and render a simple animated model in a .x format? I dont care about skinning or texture right now. Also why is the functions for this from the directx sdk abstracts and unfilled for us? Like ID3DXAllocateHierarchy has to be filled out by us? Are there functions that just do everything with maybe limited custombility?

Share this post


Link to post
Share on other sites
yckx    1298
[quote name='Tiege' timestamp='1313535200' post='4850072']
Like ID3DXAllocateHierarchy has to be filled out by us? Are there functions that just do everything with maybe limited custombility?
[/quote]
The DirectX interfaces, structures and functions typically are complicated when they need to be complicated, and are designed for general use. Each game has unique needs, so even if they did provide restricted solutions they would have little use, and the general one would remain necessary. It's up to the game developer to wrap the API in something simpler if desired—that's essentially what a game engine does (among other things).

If you could provide a link to the tutorial you are trying to follow, and tell us specifically where you're getting stuck, typically you'll be more likely to get responses, and they'll tend to be more helpful, since they'll be addressing a more focused problem.

Share this post


Link to post
Share on other sites
Tiege    102
Well I was following the one on this site [url="http://www.gamedev.net/page/resources/_/reference/programming/sweet-snippets/working-with-the-directx-x-file-format-and-animation-in-directx-90-r2079"]http://www.gamedev.net/page/resources/_/reference/programming/sweet-snippets/working-with-the-directx-x-file-format-and-animation-in-directx-90-r2079[/url] or even the one from toymaker.com

I understand the set up a bit but when I get to the psuedocode where I need to turn it into my own code I'm kind of at a loss. It seems the tutorials have a lot of other things added for their uses which I'm not looking for right now. I just want a simple animated model from blender to render.

Share this post


Link to post
Share on other sites
yckx    1298
The article on GD.net to which you linked has actual example code in a ZIP file linked near the bottom of the article, just above the subheading "Animating with DirectX .X Files." Also, if you want to go straight to the source, look at the sample browser that comes with the DirectX SDK. Look for the SkinnedMesh example in the DirectX 9 category. The example code and accompanying documentation page should prove helpful.

Share this post


Link to post
Share on other sites
Tiege    102
[quote name='yckx' timestamp='1313637714' post='4850587']
The article on GD.net to which you linked has actual example code in a ZIP file linked near the bottom of the article, just above the subheading "Animating with DirectX .X Files." Also, if you want to go straight to the source, look at the sample browser that comes with the DirectX SDK. Look for the SkinnedMesh example in the DirectX 9 category. The example code and accompanying documentation page should prove helpful.
[/quote]

Ya I've looked at both of those and tried to pick them apart but they're too developed for me to grasp exactly what I need. I just want to be able to do the bare minimum and work my way up from there.

Share this post


Link to post
Share on other sites
yckx    1298
Ah, then I misunderstood you; I thought you were getting stuck on the pseudocode and wanted to se some actual code. The thing is that it doesn't get much simpled than that. Those tutorials don't put much else in the example specifically to keep from overcomplicating things. If you can understand it to a point but there are specific parts you don't quite get, then by all means post those specific questions and we can help you understand them. But if you're having this much trouble with large parts of it, then you probably need to better familiarize yourself with the underlying concepts and work up to this point.

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