Home | History | Annotate | Download | only in dom
      1 /*
      2 * Copyright 2006 Sony Computer Entertainment Inc.
      3 *
      4 * Licensed under the MIT Open Source License, for details please see license.txt or the website
      5 * http://www.opensource.org/licenses/mit-license.php
      6 *
      7 */
      8 
      9 #include <dae.h>
     10 #include <dae/daeDom.h>
     11 #include <dom/domProfile_CG.h>
     12 #include <dae/daeMetaCMPolicy.h>
     13 #include <dae/daeMetaSequence.h>
     14 #include <dae/daeMetaChoice.h>
     15 #include <dae/daeMetaGroup.h>
     16 #include <dae/daeMetaAny.h>
     17 #include <dae/daeMetaElementAttribute.h>
     18 
     19 daeElementRef
     20 domProfile_CG::create(DAE& dae)
     21 {
     22 	domProfile_CGRef ref = new domProfile_CG(dae);
     23 	return ref;
     24 }
     25 
     26 
     27 daeMetaElement *
     28 domProfile_CG::registerElement(DAE& dae)
     29 {
     30 	daeMetaElement* meta = dae.getMeta(ID());
     31 	if ( meta != NULL ) return meta;
     32 
     33 	meta = new daeMetaElement(dae);
     34 	dae.setMeta(ID(), *meta);
     35 	meta->setName( "profile_CG" );
     36 	meta->registerClass(domProfile_CG::create);
     37 
     38 	daeMetaCMPolicy *cm = NULL;
     39 	daeMetaElementAttribute *mea = NULL;
     40 	cm = new daeMetaSequence( meta, cm, 0, 1, 1 );
     41 
     42 	mea = new daeMetaElementAttribute( meta, cm, 0, 0, 1 );
     43 	mea->setName( "asset" );
     44 	mea->setOffset( daeOffsetOf(domProfile_CG,elemAsset) );
     45 	mea->setElementType( domAsset::registerElement(dae) );
     46 	cm->appendChild( mea );
     47 
     48 	cm = new daeMetaChoice( meta, cm, 0, 1, 0, -1 );
     49 
     50 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
     51 	mea->setName( "code" );
     52 	mea->setOffset( daeOffsetOf(domProfile_CG,elemCode_array) );
     53 	mea->setElementType( domFx_code_profile::registerElement(dae) );
     54 	cm->appendChild( mea );
     55 
     56 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
     57 	mea->setName( "include" );
     58 	mea->setOffset( daeOffsetOf(domProfile_CG,elemInclude_array) );
     59 	mea->setElementType( domFx_include_common::registerElement(dae) );
     60 	cm->appendChild( mea );
     61 
     62 	cm->setMaxOrdinal( 0 );
     63 	cm->getParent()->appendChild( cm );
     64 	cm = cm->getParent();
     65 
     66 	cm = new daeMetaChoice( meta, cm, 1, 3002, 0, -1 );
     67 
     68 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
     69 	mea->setName( "image" );
     70 	mea->setOffset( daeOffsetOf(domProfile_CG,elemImage_array) );
     71 	mea->setElementType( domImage::registerElement(dae) );
     72 	cm->appendChild( mea );
     73 
     74 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
     75 	mea->setName( "newparam" );
     76 	mea->setOffset( daeOffsetOf(domProfile_CG,elemNewparam_array) );
     77 	mea->setElementType( domCg_newparam::registerElement(dae) );
     78 	cm->appendChild( mea );
     79 
     80 	cm->setMaxOrdinal( 0 );
     81 	cm->getParent()->appendChild( cm );
     82 	cm = cm->getParent();
     83 
     84 	mea = new daeMetaElementArrayAttribute( meta, cm, 6003, 1, -1 );
     85 	mea->setName( "technique" );
     86 	mea->setOffset( daeOffsetOf(domProfile_CG,elemTechnique_array) );
     87 	mea->setElementType( domProfile_CG::domTechnique::registerElement(dae) );
     88 	cm->appendChild( mea );
     89 
     90 	mea = new daeMetaElementArrayAttribute( meta, cm, 6004, 0, -1 );
     91 	mea->setName( "extra" );
     92 	mea->setOffset( daeOffsetOf(domProfile_CG,elemExtra_array) );
     93 	mea->setElementType( domExtra::registerElement(dae) );
     94 	cm->appendChild( mea );
     95 
     96 	cm->setMaxOrdinal( 6004 );
     97 	meta->setCMRoot( cm );
     98 	// Ordered list of sub-elements
     99 	meta->addContents(daeOffsetOf(domProfile_CG,_contents));
    100 	meta->addContentsOrder(daeOffsetOf(domProfile_CG,_contentsOrder));
    101 
    102 	meta->addCMDataArray(daeOffsetOf(domProfile_CG,_CMData), 2);
    103 	//	Add attribute: id
    104 	{
    105 		daeMetaAttribute *ma = new daeMetaAttribute;
    106 		ma->setName( "id" );
    107 		ma->setType( dae.getAtomicTypes().get("xsID"));
    108 		ma->setOffset( daeOffsetOf( domProfile_CG , attrId ));
    109 		ma->setContainer( meta );
    110 		ma->setIsRequired( false );
    111 
    112 		meta->appendAttribute(ma);
    113 	}
    114 
    115 	//	Add attribute: platform
    116 	{
    117 		daeMetaAttribute *ma = new daeMetaAttribute;
    118 		ma->setName( "platform" );
    119 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    120 		ma->setOffset( daeOffsetOf( domProfile_CG , attrPlatform ));
    121 		ma->setContainer( meta );
    122 		ma->setDefaultString( "PC");
    123 		ma->setIsRequired( false );
    124 
    125 		meta->appendAttribute(ma);
    126 	}
    127 
    128 	meta->setElementSize(sizeof(domProfile_CG));
    129 	meta->validate();
    130 
    131 	return meta;
    132 }
    133 
    134 daeElementRef
    135 domProfile_CG::domTechnique::create(DAE& dae)
    136 {
    137 	domProfile_CG::domTechniqueRef ref = new domProfile_CG::domTechnique(dae);
    138 	return ref;
    139 }
    140 
    141 
    142 daeMetaElement *
    143 domProfile_CG::domTechnique::registerElement(DAE& dae)
    144 {
    145 	daeMetaElement* meta = dae.getMeta(ID());
    146 	if ( meta != NULL ) return meta;
    147 
    148 	meta = new daeMetaElement(dae);
    149 	dae.setMeta(ID(), *meta);
    150 	meta->setName( "technique" );
    151 	meta->registerClass(domProfile_CG::domTechnique::create);
    152 
    153 	meta->setIsInnerClass( true );
    154 	daeMetaCMPolicy *cm = NULL;
    155 	daeMetaElementAttribute *mea = NULL;
    156 	cm = new daeMetaSequence( meta, cm, 0, 1, 1 );
    157 
    158 	mea = new daeMetaElementAttribute( meta, cm, 0, 0, 1 );
    159 	mea->setName( "asset" );
    160 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemAsset) );
    161 	mea->setElementType( domAsset::registerElement(dae) );
    162 	cm->appendChild( mea );
    163 
    164 	mea = new daeMetaElementArrayAttribute( meta, cm, 1, 0, -1 );
    165 	mea->setName( "annotate" );
    166 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemAnnotate_array) );
    167 	mea->setElementType( domFx_annotate_common::registerElement(dae) );
    168 	cm->appendChild( mea );
    169 
    170 	cm = new daeMetaChoice( meta, cm, 0, 2, 0, -1 );
    171 
    172 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    173 	mea->setName( "code" );
    174 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemCode_array) );
    175 	mea->setElementType( domFx_code_profile::registerElement(dae) );
    176 	cm->appendChild( mea );
    177 
    178 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    179 	mea->setName( "include" );
    180 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemInclude_array) );
    181 	mea->setElementType( domFx_include_common::registerElement(dae) );
    182 	cm->appendChild( mea );
    183 
    184 	cm->setMaxOrdinal( 0 );
    185 	cm->getParent()->appendChild( cm );
    186 	cm = cm->getParent();
    187 
    188 	cm = new daeMetaChoice( meta, cm, 1, 3003, 0, -1 );
    189 
    190 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    191 	mea->setName( "image" );
    192 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemImage_array) );
    193 	mea->setElementType( domImage::registerElement(dae) );
    194 	cm->appendChild( mea );
    195 
    196 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    197 	mea->setName( "newparam" );
    198 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemNewparam_array) );
    199 	mea->setElementType( domCg_newparam::registerElement(dae) );
    200 	cm->appendChild( mea );
    201 
    202 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    203 	mea->setName( "setparam" );
    204 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemSetparam_array) );
    205 	mea->setElementType( domCg_setparam::registerElement(dae) );
    206 	cm->appendChild( mea );
    207 
    208 	cm->setMaxOrdinal( 0 );
    209 	cm->getParent()->appendChild( cm );
    210 	cm = cm->getParent();
    211 
    212 	mea = new daeMetaElementArrayAttribute( meta, cm, 6004, 1, -1 );
    213 	mea->setName( "pass" );
    214 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemPass_array) );
    215 	mea->setElementType( domProfile_CG::domTechnique::domPass::registerElement(dae) );
    216 	cm->appendChild( mea );
    217 
    218 	mea = new daeMetaElementArrayAttribute( meta, cm, 6005, 0, -1 );
    219 	mea->setName( "extra" );
    220 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique,elemExtra_array) );
    221 	mea->setElementType( domExtra::registerElement(dae) );
    222 	cm->appendChild( mea );
    223 
    224 	cm->setMaxOrdinal( 6005 );
    225 	meta->setCMRoot( cm );
    226 	// Ordered list of sub-elements
    227 	meta->addContents(daeOffsetOf(domProfile_CG::domTechnique,_contents));
    228 	meta->addContentsOrder(daeOffsetOf(domProfile_CG::domTechnique,_contentsOrder));
    229 
    230 	meta->addCMDataArray(daeOffsetOf(domProfile_CG::domTechnique,_CMData), 2);
    231 	//	Add attribute: id
    232 	{
    233 		daeMetaAttribute *ma = new daeMetaAttribute;
    234 		ma->setName( "id" );
    235 		ma->setType( dae.getAtomicTypes().get("xsID"));
    236 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique , attrId ));
    237 		ma->setContainer( meta );
    238 
    239 		meta->appendAttribute(ma);
    240 	}
    241 
    242 	//	Add attribute: sid
    243 	{
    244 		daeMetaAttribute *ma = new daeMetaAttribute;
    245 		ma->setName( "sid" );
    246 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    247 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique , attrSid ));
    248 		ma->setContainer( meta );
    249 		ma->setIsRequired( true );
    250 
    251 		meta->appendAttribute(ma);
    252 	}
    253 
    254 	meta->setElementSize(sizeof(domProfile_CG::domTechnique));
    255 	meta->validate();
    256 
    257 	return meta;
    258 }
    259 
    260 daeElementRef
    261 domProfile_CG::domTechnique::domPass::create(DAE& dae)
    262 {
    263 	domProfile_CG::domTechnique::domPassRef ref = new domProfile_CG::domTechnique::domPass(dae);
    264 	return ref;
    265 }
    266 
    267 
    268 daeMetaElement *
    269 domProfile_CG::domTechnique::domPass::registerElement(DAE& dae)
    270 {
    271 	daeMetaElement* meta = dae.getMeta(ID());
    272 	if ( meta != NULL ) return meta;
    273 
    274 	meta = new daeMetaElement(dae);
    275 	dae.setMeta(ID(), *meta);
    276 	meta->setName( "pass" );
    277 	meta->registerClass(domProfile_CG::domTechnique::domPass::create);
    278 
    279 	meta->setIsInnerClass( true );
    280 	daeMetaCMPolicy *cm = NULL;
    281 	daeMetaElementAttribute *mea = NULL;
    282 	cm = new daeMetaSequence( meta, cm, 0, 1, 1 );
    283 
    284 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 0, -1 );
    285 	mea->setName( "annotate" );
    286 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemAnnotate_array) );
    287 	mea->setElementType( domFx_annotate_common::registerElement(dae) );
    288 	cm->appendChild( mea );
    289 
    290 	mea = new daeMetaElementArrayAttribute( meta, cm, 1, 0, -1 );
    291 	mea->setName( "color_target" );
    292 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemColor_target_array) );
    293 	mea->setElementType( domFx_colortarget_common::registerElement(dae) );
    294 	cm->appendChild( mea );
    295 
    296 	mea = new daeMetaElementArrayAttribute( meta, cm, 2, 0, -1 );
    297 	mea->setName( "depth_target" );
    298 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemDepth_target_array) );
    299 	mea->setElementType( domFx_depthtarget_common::registerElement(dae) );
    300 	cm->appendChild( mea );
    301 
    302 	mea = new daeMetaElementArrayAttribute( meta, cm, 3, 0, -1 );
    303 	mea->setName( "stencil_target" );
    304 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemStencil_target_array) );
    305 	mea->setElementType( domFx_stenciltarget_common::registerElement(dae) );
    306 	cm->appendChild( mea );
    307 
    308 	mea = new daeMetaElementArrayAttribute( meta, cm, 4, 0, -1 );
    309 	mea->setName( "color_clear" );
    310 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemColor_clear_array) );
    311 	mea->setElementType( domFx_clearcolor_common::registerElement(dae) );
    312 	cm->appendChild( mea );
    313 
    314 	mea = new daeMetaElementArrayAttribute( meta, cm, 5, 0, -1 );
    315 	mea->setName( "depth_clear" );
    316 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemDepth_clear_array) );
    317 	mea->setElementType( domFx_cleardepth_common::registerElement(dae) );
    318 	cm->appendChild( mea );
    319 
    320 	mea = new daeMetaElementArrayAttribute( meta, cm, 6, 0, -1 );
    321 	mea->setName( "stencil_clear" );
    322 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemStencil_clear_array) );
    323 	mea->setElementType( domFx_clearstencil_common::registerElement(dae) );
    324 	cm->appendChild( mea );
    325 
    326 	mea = new daeMetaElementAttribute( meta, cm, 7, 0, 1 );
    327 	mea->setName( "draw" );
    328 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemDraw) );
    329 	mea->setElementType( domProfile_CG::domTechnique::domPass::domDraw::registerElement(dae) );
    330 	cm->appendChild( mea );
    331 
    332 	cm = new daeMetaChoice( meta, cm, 0, 8, 1, -1 );
    333 
    334 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    335 	mea->setName( "gl_pipeline_settings" );
    336 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemGl_pipeline_settings_array) );
    337 	mea->setElementType( domGl_pipeline_settings::registerElement(dae) );
    338 	cm->appendChild( new daeMetaGroup( mea, meta, cm, 0, 1, 1 ) );
    339 
    340 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 1, 1 );
    341 	mea->setName( "shader" );
    342 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemShader_array) );
    343 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::registerElement(dae) );
    344 	cm->appendChild( mea );
    345 
    346 	cm->setMaxOrdinal( 0 );
    347 	cm->getParent()->appendChild( cm );
    348 	cm = cm->getParent();
    349 
    350 	mea = new daeMetaElementArrayAttribute( meta, cm, 3009, 0, -1 );
    351 	mea->setName( "extra" );
    352 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass,elemExtra_array) );
    353 	mea->setElementType( domExtra::registerElement(dae) );
    354 	cm->appendChild( mea );
    355 
    356 	cm->setMaxOrdinal( 3009 );
    357 	meta->setCMRoot( cm );
    358 	// Ordered list of sub-elements
    359 	meta->addContents(daeOffsetOf(domProfile_CG::domTechnique::domPass,_contents));
    360 	meta->addContentsOrder(daeOffsetOf(domProfile_CG::domTechnique::domPass,_contentsOrder));
    361 
    362 	meta->addCMDataArray(daeOffsetOf(domProfile_CG::domTechnique::domPass,_CMData), 1);
    363 	//	Add attribute: sid
    364 	{
    365 		daeMetaAttribute *ma = new daeMetaAttribute;
    366 		ma->setName( "sid" );
    367 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    368 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass , attrSid ));
    369 		ma->setContainer( meta );
    370 		ma->setIsRequired( false );
    371 
    372 		meta->appendAttribute(ma);
    373 	}
    374 
    375 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass));
    376 	meta->validate();
    377 
    378 	return meta;
    379 }
    380 
    381 daeElementRef
    382 domProfile_CG::domTechnique::domPass::domDraw::create(DAE& dae)
    383 {
    384 	domProfile_CG::domTechnique::domPass::domDrawRef ref = new domProfile_CG::domTechnique::domPass::domDraw(dae);
    385 	return ref;
    386 }
    387 
    388 
    389 daeMetaElement *
    390 domProfile_CG::domTechnique::domPass::domDraw::registerElement(DAE& dae)
    391 {
    392 	daeMetaElement* meta = dae.getMeta(ID());
    393 	if ( meta != NULL ) return meta;
    394 
    395 	meta = new daeMetaElement(dae);
    396 	dae.setMeta(ID(), *meta);
    397 	meta->setName( "draw" );
    398 	meta->registerClass(domProfile_CG::domTechnique::domPass::domDraw::create);
    399 
    400 	meta->setIsInnerClass( true );
    401 	//	Add attribute: _value
    402 	{
    403 		daeMetaAttribute *ma = new daeMetaAttribute;
    404 		ma->setName( "_value" );
    405 		ma->setType( dae.getAtomicTypes().get("Fx_draw_common"));
    406 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domDraw , _value ));
    407 		ma->setContainer( meta );
    408 		meta->appendAttribute(ma);
    409 	}
    410 
    411 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domDraw));
    412 	meta->validate();
    413 
    414 	return meta;
    415 }
    416 
    417 daeElementRef
    418 domProfile_CG::domTechnique::domPass::domShader::create(DAE& dae)
    419 {
    420 	domProfile_CG::domTechnique::domPass::domShaderRef ref = new domProfile_CG::domTechnique::domPass::domShader(dae);
    421 	return ref;
    422 }
    423 
    424 
    425 daeMetaElement *
    426 domProfile_CG::domTechnique::domPass::domShader::registerElement(DAE& dae)
    427 {
    428 	daeMetaElement* meta = dae.getMeta(ID());
    429 	if ( meta != NULL ) return meta;
    430 
    431 	meta = new daeMetaElement(dae);
    432 	dae.setMeta(ID(), *meta);
    433 	meta->setName( "shader" );
    434 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::create);
    435 
    436 	meta->setIsInnerClass( true );
    437 	daeMetaCMPolicy *cm = NULL;
    438 	daeMetaElementAttribute *mea = NULL;
    439 	cm = new daeMetaSequence( meta, cm, 0, 1, 1 );
    440 
    441 	mea = new daeMetaElementArrayAttribute( meta, cm, 0, 0, -1 );
    442 	mea->setName( "annotate" );
    443 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader,elemAnnotate_array) );
    444 	mea->setElementType( domFx_annotate_common::registerElement(dae) );
    445 	cm->appendChild( mea );
    446 
    447 	cm = new daeMetaSequence( meta, cm, 1, 0, 1 );
    448 
    449 	mea = new daeMetaElementAttribute( meta, cm, 0, 1, 1 );
    450 	mea->setName( "compiler_target" );
    451 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader,elemCompiler_target) );
    452 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::domCompiler_target::registerElement(dae) );
    453 	cm->appendChild( mea );
    454 
    455 	mea = new daeMetaElementAttribute( meta, cm, 1, 0, 1 );
    456 	mea->setName( "compiler_options" );
    457 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader,elemCompiler_options) );
    458 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::domCompiler_options::registerElement(dae) );
    459 	cm->appendChild( mea );
    460 
    461 	cm->setMaxOrdinal( 1 );
    462 	cm->getParent()->appendChild( cm );
    463 	cm = cm->getParent();
    464 
    465 	mea = new daeMetaElementAttribute( meta, cm, 3, 1, 1 );
    466 	mea->setName( "name" );
    467 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader,elemName) );
    468 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::domName::registerElement(dae) );
    469 	cm->appendChild( mea );
    470 
    471 	mea = new daeMetaElementArrayAttribute( meta, cm, 4, 0, -1 );
    472 	mea->setName( "bind" );
    473 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader,elemBind_array) );
    474 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::domBind::registerElement(dae) );
    475 	cm->appendChild( mea );
    476 
    477 	cm->setMaxOrdinal( 4 );
    478 	meta->setCMRoot( cm );
    479 
    480 	//	Add attribute: stage
    481 	{
    482 		daeMetaAttribute *ma = new daeMetaAttribute;
    483 		ma->setName( "stage" );
    484 		ma->setType( dae.getAtomicTypes().get("Cg_pipeline_stage"));
    485 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader , attrStage ));
    486 		ma->setContainer( meta );
    487 
    488 		meta->appendAttribute(ma);
    489 	}
    490 
    491 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader));
    492 	meta->validate();
    493 
    494 	return meta;
    495 }
    496 
    497 daeElementRef
    498 domProfile_CG::domTechnique::domPass::domShader::domCompiler_target::create(DAE& dae)
    499 {
    500 	domProfile_CG::domTechnique::domPass::domShader::domCompiler_targetRef ref = new domProfile_CG::domTechnique::domPass::domShader::domCompiler_target(dae);
    501 	return ref;
    502 }
    503 
    504 
    505 daeMetaElement *
    506 domProfile_CG::domTechnique::domPass::domShader::domCompiler_target::registerElement(DAE& dae)
    507 {
    508 	daeMetaElement* meta = dae.getMeta(ID());
    509 	if ( meta != NULL ) return meta;
    510 
    511 	meta = new daeMetaElement(dae);
    512 	dae.setMeta(ID(), *meta);
    513 	meta->setName( "compiler_target" );
    514 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::domCompiler_target::create);
    515 
    516 	meta->setIsInnerClass( true );
    517 	//	Add attribute: _value
    518 	{
    519 		daeMetaAttribute *ma = new daeMetaAttribute;
    520 		ma->setName( "_value" );
    521 		ma->setType( dae.getAtomicTypes().get("xsNMTOKEN"));
    522 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domCompiler_target , _value ));
    523 		ma->setContainer( meta );
    524 		meta->appendAttribute(ma);
    525 	}
    526 
    527 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader::domCompiler_target));
    528 	meta->validate();
    529 
    530 	return meta;
    531 }
    532 
    533 daeElementRef
    534 domProfile_CG::domTechnique::domPass::domShader::domCompiler_options::create(DAE& dae)
    535 {
    536 	domProfile_CG::domTechnique::domPass::domShader::domCompiler_optionsRef ref = new domProfile_CG::domTechnique::domPass::domShader::domCompiler_options(dae);
    537 	return ref;
    538 }
    539 
    540 
    541 daeMetaElement *
    542 domProfile_CG::domTechnique::domPass::domShader::domCompiler_options::registerElement(DAE& dae)
    543 {
    544 	daeMetaElement* meta = dae.getMeta(ID());
    545 	if ( meta != NULL ) return meta;
    546 
    547 	meta = new daeMetaElement(dae);
    548 	dae.setMeta(ID(), *meta);
    549 	meta->setName( "compiler_options" );
    550 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::domCompiler_options::create);
    551 
    552 	meta->setIsInnerClass( true );
    553 	//	Add attribute: _value
    554 	{
    555 		daeMetaAttribute *ma = new daeMetaAttribute;
    556 		ma->setName( "_value" );
    557 		ma->setType( dae.getAtomicTypes().get("xsString"));
    558 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domCompiler_options , _value ));
    559 		ma->setContainer( meta );
    560 		meta->appendAttribute(ma);
    561 	}
    562 
    563 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader::domCompiler_options));
    564 	meta->validate();
    565 
    566 	return meta;
    567 }
    568 
    569 daeElementRef
    570 domProfile_CG::domTechnique::domPass::domShader::domName::create(DAE& dae)
    571 {
    572 	domProfile_CG::domTechnique::domPass::domShader::domNameRef ref = new domProfile_CG::domTechnique::domPass::domShader::domName(dae);
    573 	return ref;
    574 }
    575 
    576 
    577 daeMetaElement *
    578 domProfile_CG::domTechnique::domPass::domShader::domName::registerElement(DAE& dae)
    579 {
    580 	daeMetaElement* meta = dae.getMeta(ID());
    581 	if ( meta != NULL ) return meta;
    582 
    583 	meta = new daeMetaElement(dae);
    584 	dae.setMeta(ID(), *meta);
    585 	meta->setName( "name" );
    586 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::domName::create);
    587 
    588 	meta->setIsInnerClass( true );
    589 	//	Add attribute: _value
    590 	{
    591 		daeMetaAttribute *ma = new daeMetaAttribute;
    592 		ma->setName( "_value" );
    593 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    594 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domName , _value ));
    595 		ma->setContainer( meta );
    596 		meta->appendAttribute(ma);
    597 	}
    598 
    599 	//	Add attribute: source
    600 	{
    601 		daeMetaAttribute *ma = new daeMetaAttribute;
    602 		ma->setName( "source" );
    603 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    604 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domName , attrSource ));
    605 		ma->setContainer( meta );
    606 		ma->setIsRequired( false );
    607 
    608 		meta->appendAttribute(ma);
    609 	}
    610 
    611 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader::domName));
    612 	meta->validate();
    613 
    614 	return meta;
    615 }
    616 
    617 daeElementRef
    618 domProfile_CG::domTechnique::domPass::domShader::domBind::create(DAE& dae)
    619 {
    620 	domProfile_CG::domTechnique::domPass::domShader::domBindRef ref = new domProfile_CG::domTechnique::domPass::domShader::domBind(dae);
    621 	return ref;
    622 }
    623 
    624 
    625 daeMetaElement *
    626 domProfile_CG::domTechnique::domPass::domShader::domBind::registerElement(DAE& dae)
    627 {
    628 	daeMetaElement* meta = dae.getMeta(ID());
    629 	if ( meta != NULL ) return meta;
    630 
    631 	meta = new daeMetaElement(dae);
    632 	dae.setMeta(ID(), *meta);
    633 	meta->setName( "bind" );
    634 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::domBind::create);
    635 
    636 	meta->setIsInnerClass( true );
    637 	daeMetaCMPolicy *cm = NULL;
    638 	daeMetaElementAttribute *mea = NULL;
    639 	cm = new daeMetaChoice( meta, cm, 0, 0, 1, 1 );
    640 
    641 	mea = new daeMetaElementAttribute( meta, cm, 0, 1, 1 );
    642 	mea->setName( "cg_param_type" );
    643 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader::domBind,elemCg_param_type) );
    644 	mea->setElementType( domCg_param_type::registerElement(dae) );
    645 	cm->appendChild( new daeMetaGroup( mea, meta, cm, 0, 1, 1 ) );
    646 
    647 	mea = new daeMetaElementAttribute( meta, cm, 0, 1, 1 );
    648 	mea->setName( "param" );
    649 	mea->setOffset( daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader::domBind,elemParam) );
    650 	mea->setElementType( domProfile_CG::domTechnique::domPass::domShader::domBind::domParam::registerElement(dae) );
    651 	cm->appendChild( mea );
    652 
    653 	cm->setMaxOrdinal( 0 );
    654 	meta->setCMRoot( cm );
    655 	// Ordered list of sub-elements
    656 	meta->addContents(daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader::domBind,_contents));
    657 	meta->addContentsOrder(daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader::domBind,_contentsOrder));
    658 
    659 	meta->addCMDataArray(daeOffsetOf(domProfile_CG::domTechnique::domPass::domShader::domBind,_CMData), 1);
    660 	//	Add attribute: symbol
    661 	{
    662 		daeMetaAttribute *ma = new daeMetaAttribute;
    663 		ma->setName( "symbol" );
    664 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    665 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domBind , attrSymbol ));
    666 		ma->setContainer( meta );
    667 		ma->setIsRequired( true );
    668 
    669 		meta->appendAttribute(ma);
    670 	}
    671 
    672 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader::domBind));
    673 	meta->validate();
    674 
    675 	return meta;
    676 }
    677 
    678 daeElementRef
    679 domProfile_CG::domTechnique::domPass::domShader::domBind::domParam::create(DAE& dae)
    680 {
    681 	domProfile_CG::domTechnique::domPass::domShader::domBind::domParamRef ref = new domProfile_CG::domTechnique::domPass::domShader::domBind::domParam(dae);
    682 	return ref;
    683 }
    684 
    685 
    686 daeMetaElement *
    687 domProfile_CG::domTechnique::domPass::domShader::domBind::domParam::registerElement(DAE& dae)
    688 {
    689 	daeMetaElement* meta = dae.getMeta(ID());
    690 	if ( meta != NULL ) return meta;
    691 
    692 	meta = new daeMetaElement(dae);
    693 	dae.setMeta(ID(), *meta);
    694 	meta->setName( "param" );
    695 	meta->registerClass(domProfile_CG::domTechnique::domPass::domShader::domBind::domParam::create);
    696 
    697 	meta->setIsInnerClass( true );
    698 
    699 	//	Add attribute: ref
    700 	{
    701 		daeMetaAttribute *ma = new daeMetaAttribute;
    702 		ma->setName( "ref" );
    703 		ma->setType( dae.getAtomicTypes().get("xsNCName"));
    704 		ma->setOffset( daeOffsetOf( domProfile_CG::domTechnique::domPass::domShader::domBind::domParam , attrRef ));
    705 		ma->setContainer( meta );
    706 		ma->setIsRequired( true );
    707 
    708 		meta->appendAttribute(ma);
    709 	}
    710 
    711 	meta->setElementSize(sizeof(domProfile_CG::domTechnique::domPass::domShader::domBind::domParam));
    712 	meta->validate();
    713 
    714 	return meta;
    715 }
    716 
    717