0

so far I've been succesfully changing from the deprecated D3DX libraries to the new ones, but with the function D3DX11CompileFromFile I'm supposed to use the new D3DCompileFromFile. MSDN says the header file is D3DCompiler.h and the lib file is D3DCompiler.lib. Intellisense picks up two, one from

C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Lib\x64

and the other from

C:\Program Files (x86)\Windows Kits\8.1\Lib\winv6.3\um\x64

enter image description here

If anyone knows why this is happening I'd appreciate the help. I've also tried switching the orders of a few of them. Thanks.

Zebrafish
  • 11,682
  • 3
  • 43
  • 119
  • 1
    you probably need to change your project include/library paths, and remove references to the June 2010 DXSDK. The one from the June 2010 header doesn't contain D3DCompileFromFile, only D3DCompile. – MuertoExcobito Apr 27 '16 at 00:01
  • Bingo, removing all references to the June 2010 SDK worked, now I just gotta change everything. So EVERYTHING in the June SDK is deprecated and I should use includes and libraries form the Windows Kit folder? – Zebrafish Apr 27 '16 at 01:34

1 Answers1

1

Ideally you remove the DirectX SDK (June 2010) paths entirely and just use the D3DCompile header in the Windows 8.1 SDK.

If you have to use the legacy DirectX SDK (June 2010), you put those include & lib paths after the Windows 8.1 SDK. This mostly works, but there are complications with respect to down-level XAudio 2.7. See The Zombie DirectX SDK for all the details.

The legacy DirectX SDK copy of d3dcompiler.h doesn't have the FromFile flavor which was added for the Windows 8.x SDK version. On Windows 8.1 or Windows 10, D3DCompiler_47.DLL is part of the OS, but if you want to run on Windows 7 you need to deploy the DLL with your application which you can just copy out of $(WindowsSdkDir)redist\d3d\<arch>\D3DCompile*.DLL. See HLSL, FXC, and D3DCompile.

Chuck Walbourn
  • 38,259
  • 2
  • 58
  • 81