Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualMedo3337

Posted 05 July 2013 - 10:12 AM

Okay, trying to open and save .x file and the following code fail, getting D3DERR_INVALIDCALL when I call D3DXSaveMeshHierarchyToFile():
LPD3DXANIMATIONCONTROLLER animController;
hr = D3DXLoadMeshHierarchyFromX(filePath, D3DXMESH_MANAGED, device, 
memoryAllocator, NULL, &frameRoot, &animController);
assert(SUCCEEDED(hr)); // OK

hr = D3DXSaveMeshHierarchyToFile("character_with_all_animations.x", D3DXF_FILEFORMAT_TEXT, frameRoot, animController, NULL);
assert(SUCCEEDED(hr)); // <---- ERROR: Getting D3DERR_INVALIDCALL here

#1Medo3337

Posted 05 July 2013 - 10:00 AM

Okay, trying to open and save .x file and the following code fail, getting D3DERR_INVALIDCALL when I call D3DXSaveMeshHierarchyToFile():
LPD3DXANIMATIONCONTROLLER animController;
hr = D3DXLoadMeshHierarchyFromX(filePath, D3DXMESH_MANAGED, device, 
memoryAllocator, NULL, &frameRoot, &animController);
assert(SUCCEEDED(hr)); // OK

hr = D3DXSaveMeshHierarchyToFile("G:\\character_with_all_animations.x", D3DXF_FILEFORMAT_TEXT, frameRoot, animController, NULL);
assert(SUCCEEDED(hr)); // <---- ERROR: Getting D3DERR_INVALIDCALL here

PARTNERS