Sign in to follow this  
IceSynth

D3DXLoadMeshHierarchyFromX Problem

Recommended Posts

IceSynth    127
I was working with the MultiAnimation sample from the SDK and I am having a problem when I port it into another application. When I use the D3DXLoadMeshHierarchyFromX (Or similar functions), it fails but does not return a valid error code. I know that my D3DDevice is initialized and working(At least for other functions). Has anyone had a similar problem or know how to fix this?
    hr = D3DXLoadMeshHierarchyFromX( szPath, 0, Graphics->GetDeviceCOM(), pAH, pLUD, (LPD3DXFRAME *) &m_pFrameRoot, &m_pAC );
    if( FAILED( hr ) )
	{
		if(hr == D3DERR_INVALIDCALL)
			goto e_Exit; // Breakpoint One
		if(hr == E_OUTOFMEMORY)
			goto e_Exit; // Breakpoint Two
        goto e_Exit; // Breakpoint Three
	}


The code always ends up at Breakpoint 3 Visual Studio .NET 2003, Windows 2000, Non-Unicode Builds.

Share this post


Link to post
Share on other sites
DXnut    262
Assuming you coded the AllocateHierarchy functions (pAH), did you trace the creation of the frames and meshcontainers through them? I suspect you are getting E_FAIL, which is what happens if you don't code the correctly or intentionally code them to return an error.

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