I ran into this problem using Visual Studio 2012 Express on Windows 8; however, my errors were almost exactly the same, and the fix is centered around the Windows SDK. This was in MSDN (see #5):
D3DX is not considered the canonical API for using Direct3D in Windows 8 and therefore isn't included with the corresponding Windows SDK. Investigate alternate solutions for working with the Direct3D API.
For legacy projects, such as the Windows 7 (and earlier) DirectX SDK samples, the following steps are necessary to build applications with D3DX using the DirectX SDK:
a. Modify the project’s VC++ directories as follows to use the right order for SDK headers and libraries.
Open Properties for the project and select the VC++ Directories page.
Select All Configurations and All Platforms.
Set these directories as follows:
- Include Directories: $(IncludePath);$(DXSDK_DIR)Include
- Library Directories: $(LibraryPath);$(DXSDK_DIR)Lib\x86
Click Apply.
Choose the x64 Platform.
Set the Library Directory as follows:
- Library Directories: $(LibraryPath);$(DXSDK_DIR)Lib\x64
b. Wherever "d3dx9.h", "d3dx10.h", or "d3dx11.h" are included in your project, be sure to explicitly include "d3d9.h", "d3d10.h" and "dxgi.h", or "d3d11.h" and "dxgi.h" first to ensure you are picking up the newer version. You can disable warning C4005 if needed; however, this warning indicates you are using the older version of these headers.
c. Remove all references to DXGIType.h in your project. This header doesn't exist in the Windows SDK, and the DirectX SDK version conflicts with the new winerror.h.
d. All D3DX DLLs are installed onto your development computer by the DirectX SDK installation. Ensure that the necessary D3DX dependencies are redistributed with any sample or with your application if it is moved to another machine.
e. Be aware that replacement technologies for current uses of D3DX11 include DirectXTex and DirectXTK. D3DXMath is replaced by DirectXMath.
I can't say for sure, but I think the Windows 8 SDK might be your problem. It may be a bit of a pain, but using the fix above will help make your code require less dependencies as well as making it compatible with both Windows 7 and Windows 8.