ataylor Posted October 16, 2015 Share Posted October 16, 2015 Trying to upgrade project to new Unigine 2.0 release, building engine from source. UnigineScript complained about Xml not being a valid token. Turns out HAVE_XML was not defined and XML support was being omitted during engine compilation. I looked at the PreprocessorDefinitions sections of unigine_vs2013.vcxproj and found this: <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;USE_HALF_TEXCOORDSHAVE_JSONHAVE_NVAPIHAVE_AMDADLHAVE_IMEUSE_XAUDIO2USE_XA2_WRAPPERHAVE_XML;HAVE_PATH;HAVE_MESH;HAVE_IMAGE;HAVE_BOUNDS;HAVE_REGEXP;HAVE_SOCKET;HAVE_BLOB;HAVE_VORBIS;HAVE_THEORA;HAVE_NVCPL;USE_ASSERT;USE_MEMORY;USE_SHADER_CACHE;USE_SSE;USE_SSE2;USE_OPENGL;USE_OPENGL_43;USE_OPENGL_44;USE_GL_WRAPPER;USE_DIRECT3D11;USE_D3D11_WRAPPER;USE_OPENAL;USE_AL_WRAPPER;USE_XPAD360;USE_JOYSTICK;USE_FLASH;USE_FLASH_ENGINE;USE_EDITOR;NDEBUG;ARCH_X64;%(PreprocessorDefinitions)</PreprocessorDefinitions> Note the lack of semicolons separating what I assume are supposed to be separate #defines. Link to comment
anna Posted October 19, 2015 Share Posted October 19, 2015 Hi, thank you for your report. You're right, some semicolons are missed. We will fix it. Please change PreprocessorDefinitions as follows: <PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE;USE_HALF_TEXCOORDS;HAVE_JSON;HAVE_NVAPI;HAVE_AMDADL;HAVE_IME;USE_XAUDIO2;USE_XA2_WRAPPER;HAVE_XML;HAVE_PATH;HAVE_MESH;HAVE_IMAGE;HAVE_BOUNDS;HAVE_REGEXP;HAVE_SOCKET;HAVE_BLOB;HAVE_VORBIS;HAVE_THEORA;HAVE_NVCPL;USE_ASSERT;USE_MEMORY;USE_SHADER_CACHE;USE_SSE;USE_SSE2;USE_OPENGL;USE_OPENGL_43;USE_OPENGL_44;USE_GL_WRAPPER;USE_DIRECT3D11;USE_D3D11_WRAPPER;USE_OPENAL;USE_AL_WRAPPER;USE_XPAD360;USE_JOYSTICK;USE_FLASH;USE_FLASH_ENGINE;USE_EDITOR;NDEBUG;ARCH_X64;%(PreprocessorDefinitions)</PreprocessorDefinitions> Link to comment
dred Posted October 22, 2015 Share Posted October 22, 2015 I am trying to include the Unigine project in our solution and ran into a couple more errors, The build fails complaining that it can't find "XA2Ext.h" in the path. "sound/xaudio2" appears to be missing from the additional include directory, after adding that I get a few linker errors that are based in XA2Wrapper and XA2SoundManager. I haven't figured out how to fix the linker errors yet. Link to comment
anna Posted October 23, 2015 Share Posted October 23, 2015 Hi Dred, Sorry about this bug. You're right about include path sound/xaudio2. But some source files are accidentally missed in the project. Please do the following: In VS Solution Explorer go to Unigine/Sources/sound -> Add -> Existing Item -> choose all .cpp files from {UNIGINE_SDK}\source\engine\sound\xaudio2 directory. Do the same for .h files in Unigine/Headers/sound. You can also organize them in Unigine/Headers(Sources)/sound/xaudio2 tree as they are in SDK structure. Hope this would help. Link to comment
Recommended Posts