• Advertisement
Sign in to follow this  

D3DXMatrixDecompose and D3DERR_INVALIDCALL

This topic is 4590 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

hi, I've been stuck with an error that I really can't get rid of. Here is a bit of code i'm using :
   D3DXVECTOR3     scaling(0.0f, 0.0f, 0.0f), translation(0.0f, 0.0f, 0.0f);
   D3DXQUATERNION  rotation(0.0f, 0.0f, 0.0f, 0.0f);

   HRESULT hr;
   if (FAILED(hr = D3DXMatrixDecompose(&scale, &rotation, &translation, m_pMatrix)))
      return(hr);

And sometimes, the D3DXMatrixDecompose function fails with a D3DERR_INVALIDCALL, and sometimes works perfectly :/ I've read the DirectX help, but apparently, the only reason why it would fail is when a parameter is invalid. But I double checked the "m_pMatrix" parameter, it's valid, pointing to a valid matrix (I checked that in the debugger) and the 3 other parameters are just declared and initialized before. I really don't understand, so any help is welcomed ^^

Share this post


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

  • Advertisement