Trouble compiling DOM in Visual Studion 9

I am trying to write an importer using the Collada DOM in an existing application. I am getting errors when I try to compile the c++ file. There is as yet no Collada code in the file, just the include files as below:
#include <dae.h>
#include <dom/domCOLLADA.h>
using namespace std;

I have also included the recommend lines for the Precompiled header.

I max out the errors with erros such as these:
c:\hummer\colladadom\include\dom\domasset.h(30) : error C2039: ‘ASSET’ : is not a member of ‘COLLADA_TYPE’
c:\hummer\colladadom\include\dom\domasset.h(30) : error C2065: ‘ASSET’ : undeclared identifier
c:\hummer\colladadom\include\dom\domasset.h(45) : error C2039: ‘CONTRIBUTOR’ : is not a member of ‘COLLADA_TYPE’
c:\hummer\colladadom\include\dom\domasset.h(45) : error C2065: ‘CONTRIBUTOR’ : undeclared identifier

and so on…

Any help would be appreciated.

Philip

I think the COLLADA DOM uses a header include policy sometimes called “explicit”. This means that each cpp file must include the headers in the required order. The hpp files do not (always) include files they depend on. This forces users to understand the structure of things when writing code (can be a good thing).

I personally prefer the “implicit” policy where each header file includes every file it depends on and is self-contained. It takes more time to do this well (forwards declares, forward only headers, etc.) but it is more user friendly and less error prone.

Thanks for the help.

I would have thought this application was implicit as there are 9 files included at the top of the dae.h file and domCOLLADA.h has 20 some odd include files at the top.

I do not know how to proceed with this. Tried various combinations of include files with no luck. The on-line doc. has nothing that might be useful. I am doing work for two universities. I will tell tham to look for another file format that might work for them.

Thanks anyway.

Philip

I think you can proceed with OpenCOLLADA actually. Visit http://www.opencollada.org for the software libraries.