Game Development Community

Stock 1.8.1 Compile Errors [solved]

by Loubert McGeurkinberger · in Torque Game Engine Advanced · 09/16/2009 (11:41 pm) · 9 replies

I am trying to compile my project (which has no source modifications whatsoever) but I am continually encountering this error:

c:TorqueTGEA_1_8_1enginesourcegfx/D3D9/gfxD3D9Device.h(44) : fatal error C1083: Cannot open include file: 'dxerr9.h': No such file or directory

I have absolutely NO idea what is going on. I have followed the GG compiling guide perfectly; I have installed the August DX SDK and the most recent Windows SDK, have referenced all their paths correctly in my VC++ directory settings (bin, lib and include), and put all their paths to the top of the list, and yet nothing seems to work. I checked the 1.8.1 known issues threads and nothing seems related.

EDIT: I took a look on the Microsoft website and under the August DXSDK Known Issues is the following:

Quote:The DXERR9 library has been removed from the DirectX SDK as of the August 2009 release. The DXERR9 error look-up library has been deprecated for some time in favor of DXERR which supports a broad range of DirectX and related error codes. The DirectX SDK Error Look-up Tool uses DXERR.

This seems to lead me to believe that the August DXSDK has made Torque obsolete. Anyone have a possible fix ? I am really tearing my hair out trying to get this to work

#1
09/17/2009 (2:35 am)
I reverted to the March 2009 DXSDK and, after doing a rebuild, problem dissapeared. Reporting it as a bug in 1.8.1
#2
09/25/2009 (10:54 pm)
To get this working, I replaced the various DXerr9 references with DXerr ones. In the latest SDK, the error reporter for DX9,10, and 11 has been merged into one.
#3
09/29/2009 (9:27 am)
Taylor can you explain your solution in more detail? Which files need to be edited etc. Thanks
#4
10/01/2009 (9:37 am)
I would also be extremely interested in knowing which specific files reference dxerr and if there is another solution other than down-grading
#5
10/01/2009 (11:23 am)
This is what you need to do.

www.garagegames.com/community/forums/viewthread/101387

Just use the search facility as I did. BTW, I have tested this myself on a Stock TGEA 1.8.1 using the August 2009 DirectX SDK ... and it worked.
#6
10/01/2009 (11:49 am)
the link u posted is private for Torque 3D so its not accessible unless u have T3D

please post the solution here if possible
#7
10/01/2009 (12:07 pm)
well that was a bit simple...

its simply rename the header file to DXerr.h which was already mentioned above & remove the "9" from all function names with-in the same file & any calls on those function on other files (refactorer should do it, or find & replace across the project)

Build succeeded :)
#8
10/01/2009 (5:18 pm)
Ok. Here is the solution for those who still need it.

3 things to build with it:

1; in gfxD3D9Device.h replace
#include "dxerr9.h"
to
#include "dxerr.h"

2; in gfxD3D9Shader.cpp replace
DXGetErrorString9A(res), DXGetErrorDescription9A(res), res );
with
DXGetErrorStringA(res), DXGetErrorDescriptionA(res), res );

3; in the dll's properties for linker/input/Additional Dependencies
change dxerr9.lib to dxerr.lib

thats it, full rebuild.

This is thanks to deepscratch. :)
#9
10/22/2009 (5:05 pm)
I am using TGEA 1.7.1 and used the above solution for compatibility with the Aug09 SDK, but after a complete rebuild, there was a fatal assert when I tried to host a game. The error was from the initShader function of gfxD3D9Shader.cpp. Specifically, the line that caused the error was
Con::warnf( ConsoleLogEntry::General, (const char*) errorBuff->GetBufferPointer() );
Apparently when the errorBuff was filled by D3DXCompileShader... it had a bunch of warnings strung together, so many that it was too large for the dVSprintf function.

Reverting to the March 09 SDK eliminated the problem. Incidentally, after going back to the Mar09 version, it still worked with the dxerr.lib library and code references that didn't have the "9". So, it's maybe some difference in the version of dxerr.lib from Mar09 to Aug09.

Just a word to the wise that you should be sure to do a complete rebuild of your entire project after going to Aug09 to be certain it works for you.