Tag Info

Hot answers tagged

2

COLOR0 is DX9. Since you're dealing with DX11 (ps_5_0) you need to replace COLOR0 with SV_Target.


2

The quaternion you find using your method is indeed correct. However, it’s also pretty unlikely that DirectX::XMQuaternionSlerp would behave incorrectly with such trivial input. Thus, I suspect that the thing you are doing wrong is: trusting what you see in the debugger while running potentially optimised code assuming the layout of a __mm128 would be ...


2

By design, DirectXMath returns for XMQuaternionSlerp the same result as you'd get from the following (inefficient used only for testing) scalar code: XMVECTOR ScalarQuatSlerp(XMVECTOR q1, XMVECTOR q2, float t) { // Extract the components float q1x = XMVectorGetX(q1); float q1y = XMVectorGetY(q1); float q1z = XMVectorGetZ(q1); float q1w = ...


2

The official Visual Studio "DirectX" templates are only for Windows Store apps for Windows 8.x and Windows phone 8.x. They do not support Win32 desktop apps. In order to develop Windows Store apps for Windows 8.1 or Windows phone 8.1 apps, you need: VS 2013 (any edition except Express for Web and Express for Windows Desktop) A Windows 8.1 system In ...


1

The issue seem to be that you don't copy data over, you're overwriting the idata pointer with the address of mIV: idata = mIV; // this changes idata to point to mIV, not copy data Should be something like: for(size_t i=0; i < (sizeof(mIV) / sizeof(mIV[0])); ++i){ idata[i] = mIV[i]; } Or memcpy(idata, mIV, sizeof(mIV)); Or some other copy ...


1

It basically doesn't matter. #define uses token-pasting to insert the specified value into the shader code whereever it occurs; the shader itself will see the token as if you simply hard-coded it at every occurrence instead. A static const variable in, in actuality, a variable. Specifically, it is a variable that is initialized once, whose value persists ...



Only top voted, non community-wiki answers of a minimum length are eligible