Sign in to follow this  

GetNextDataObject

This topic is 4480 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 am currently upgrading an app to DX9.0c(August update) from DX8 and the GetNextDataObject was deprecated. I was using this to loop through meshes and now I'm not sure how to replace it. Can anyone help?

Share this post


Link to post
Share on other sites
Hi,

You can use ID3DXFile interface to use x file, although it is quite different than IDirectXFile interface however. A look at the documentation should help you out. You create the ID3DXFile object and an enum object similar to before, and use the following function:

HRESULT GetDataObjectById(
REFGUID rguid,
LPD3DXFILEDATA *ppDataObj
);

You pass a GUID for the object you want and it will get the next object that is that type. Basically, you would loop through all of the objects that you want and get them this way.There is no function to get the next object.

You can also use the following:

HRESULT GetChild(
SIZE_T id,
ID3DXFileData **ppObj
);

This will get the next child object, which may not be the next object.

And last, you can still use the old interface, but you just need to cast when you need a ID3DXFile or similar interface.

Hope this helps,
ProgrammingNerd

Share this post


Link to post
Share on other sites

This topic is 4480 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.

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