Hi I’m trying to use the free xml code generator provided at
to aid me in my creation of a collada to binary PSP converter. When I use it with the following properties:
C:\Development\COLLADA>xsd cxx-tree --output-dir output --generate-polymorphic --morph-anonymous --root-element-first CO
I get a C++ file of 4879KB and a H file of 2299KB which seem rather large to say the least! Is this to be expected? Has anybody else tried to autogenerate code from the schema and if so how did they go about doing it?
Also the author of the above xml code generator has a thread on his forum about compiling the collada schema but sadly the thread came to an abrupt end:
http://codesynthesis.com/pipermail/xsd- … 00259.html
Is anyone developing the schema paying any notice to these concerns? Using this code generator on collada seems to be coming to a dead end for me until it can be chopped up better.
I did using JAXB. It did fine with COLLADA 1.3 but it coughed a hairball on COLLADA 1.4. I had to delete some of the less common schema elements down toward the bottom to get it to work. I have not tried it with JAXB 2 yet, though.
So the COLLADA DOM is generated from the schema.
We have a custom schema parser/c++ generator written in PHP that does that.
I have looked into other code generators but wasn’t very happy with the results.
There is the --parts option that allows you to split the generated C++ source files into a number of parts for large monolithic schemas. Details are here:
Hi, I am new to COLLADA and I have a rather big question.
I am currently writing a study memoire about data binding from XML to C++ and reflection, and I was wondering if the metaparser used for the conversion of the COLLADA Schema to the C++ library would be available, even partially, for academic research.
If not, are there some details about it available (eg. the language the parser is written in) ?
The parser is written in PHP !
Please contact us at firstname.lastname@example.org so we can discuss the possibility of providing it to you for your research.
Is there any possibility that your custom parser be made publically available. I could imagine a lot of collada developers would be interested in that, particularly with the bugs ms xsd.exe has (both 2003 and 2005 versions) - it fails to handle circular references in schemas (this issue came up with the 1.41 collada schema).
I don’t see why anybody would find the parser useful (minus a student who was writing a term paper on code generators). If you want the output of the parser you use the COLLADA DOM. The COLLADA DOM is auto generated from the Schema and it’s publicly available.
Since nobody is going to modify the COLLADA schema and then regenerate the DOM (why would you want non standard COLLADA? thats what <extra> is used for) there is no use for the parser in the public domain. It would just be one more project we have to support and we don’t have the resources for that.