00001 /* 00002 * Copyright 2006 Sony Computer Entertainment Inc. 00003 * 00004 * Licensed under the MIT Open Source License, for details please see license.txt or the website 00005 * http://www.opensource.org/licenses/mit-license.php 00006 * 00007 */ 00008 00009 #ifndef __domSkin_h__ 00010 #define __domSkin_h__ 00011 00012 #include <dae/daeDocument.h> 00013 #include <dom/domTypes.h> 00014 #include <dom/domElements.h> 00015 00016 #include <dom/domSource.h> 00017 #include <dom/domExtra.h> 00018 #include <dom/domInputLocal.h> 00019 #include <dom/domInputLocalOffset.h> 00020 class DAE; 00021 00026 class domSkin : public daeElement 00027 { 00028 public: 00029 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::SKIN; } 00030 static daeInt ID() { return 656; } 00031 virtual daeInt typeID() const { return ID(); } 00032 public: 00033 class domBind_shape_matrix; 00034 00035 typedef daeSmartRef<domBind_shape_matrix> domBind_shape_matrixRef; 00036 typedef daeTArray<domBind_shape_matrixRef> domBind_shape_matrix_Array; 00037 00044 class domBind_shape_matrix : public daeElement 00045 { 00046 public: 00047 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::BIND_SHAPE_MATRIX; } 00048 static daeInt ID() { return 657; } 00049 virtual daeInt typeID() const { return ID(); } 00050 00051 protected: // Value 00055 domFloat4x4 _value; 00056 00057 public: //Accessors and Mutators 00062 domFloat4x4 &getValue() { return _value; } 00067 const domFloat4x4 &getValue() const { return _value; } 00072 void setValue( const domFloat4x4 &val ) { _value = val; } 00073 00074 protected: 00078 domBind_shape_matrix(DAE& dae) : daeElement(dae), _value() {} 00082 virtual ~domBind_shape_matrix() {} 00086 virtual domBind_shape_matrix &operator=( const domBind_shape_matrix &cpy ) { (void)cpy; return *this; } 00087 00088 public: // STATIC METHODS 00093 static DLLSPEC daeElementRef create(DAE& dae); 00099 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00100 }; 00101 00102 class domJoints; 00103 00104 typedef daeSmartRef<domJoints> domJointsRef; 00105 typedef daeTArray<domJointsRef> domJoints_Array; 00106 00112 class domJoints : public daeElement 00113 { 00114 public: 00115 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::JOINTS; } 00116 static daeInt ID() { return 658; } 00117 virtual daeInt typeID() const { return ID(); } 00118 00119 protected: // Elements 00124 domInputLocal_Array elemInput_array; 00128 domExtra_Array elemExtra_array; 00129 00130 public: //Accessors and Mutators 00135 domInputLocal_Array &getInput_array() { return elemInput_array; } 00140 const domInputLocal_Array &getInput_array() const { return elemInput_array; } 00145 domExtra_Array &getExtra_array() { return elemExtra_array; } 00150 const domExtra_Array &getExtra_array() const { return elemExtra_array; } 00151 protected: 00155 domJoints(DAE& dae) : daeElement(dae), elemInput_array(), elemExtra_array() {} 00159 virtual ~domJoints() {} 00163 virtual domJoints &operator=( const domJoints &cpy ) { (void)cpy; return *this; } 00164 00165 public: // STATIC METHODS 00170 static DLLSPEC daeElementRef create(DAE& dae); 00176 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00177 }; 00178 00179 class domVertex_weights; 00180 00181 typedef daeSmartRef<domVertex_weights> domVertex_weightsRef; 00182 typedef daeTArray<domVertex_weightsRef> domVertex_weights_Array; 00183 00188 class domVertex_weights : public daeElement 00189 { 00190 public: 00191 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::VERTEX_WEIGHTS; } 00192 static daeInt ID() { return 659; } 00193 virtual daeInt typeID() const { return ID(); } 00194 public: 00195 class domVcount; 00196 00197 typedef daeSmartRef<domVcount> domVcountRef; 00198 typedef daeTArray<domVcountRef> domVcount_Array; 00199 00204 class domVcount : public daeElement 00205 { 00206 public: 00207 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::VCOUNT; } 00208 static daeInt ID() { return 660; } 00209 virtual daeInt typeID() const { return ID(); } 00210 00211 protected: // Value 00215 domListOfUInts _value; 00216 00217 public: //Accessors and Mutators 00222 domListOfUInts &getValue() { return _value; } 00227 const domListOfUInts &getValue() const { return _value; } 00232 void setValue( const domListOfUInts &val ) { _value = val; } 00233 00234 protected: 00238 domVcount(DAE& dae) : daeElement(dae), _value() {} 00242 virtual ~domVcount() {} 00246 virtual domVcount &operator=( const domVcount &cpy ) { (void)cpy; return *this; } 00247 00248 public: // STATIC METHODS 00253 static DLLSPEC daeElementRef create(DAE& dae); 00259 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00260 }; 00261 00262 class domV; 00263 00264 typedef daeSmartRef<domV> domVRef; 00265 typedef daeTArray<domVRef> domV_Array; 00266 00273 class domV : public daeElement 00274 { 00275 public: 00276 virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::V; } 00277 static daeInt ID() { return 661; } 00278 virtual daeInt typeID() const { return ID(); } 00279 00280 protected: // Value 00284 domListOfInts _value; 00285 00286 public: //Accessors and Mutators 00291 domListOfInts &getValue() { return _value; } 00296 const domListOfInts &getValue() const { return _value; } 00301 void setValue( const domListOfInts &val ) { _value = val; } 00302 00303 protected: 00307 domV(DAE& dae) : daeElement(dae), _value() {} 00311 virtual ~domV() {} 00315 virtual domV &operator=( const domV &cpy ) { (void)cpy; return *this; } 00316 00317 public: // STATIC METHODS 00322 static DLLSPEC daeElementRef create(DAE& dae); 00328 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00329 }; 00330 00331 00332 protected: // Attribute 00337 domUint attrCount; 00338 00339 protected: // Elements 00343 domInputLocalOffset_Array elemInput_array; 00348 domVcountRef elemVcount; 00355 domVRef elemV; 00359 domExtra_Array elemExtra_array; 00360 00361 public: //Accessors and Mutators 00366 domUint getCount() const { return attrCount; } 00371 void setCount( domUint atCount ) { attrCount = atCount; _validAttributeArray[0] = true; } 00372 00377 domInputLocalOffset_Array &getInput_array() { return elemInput_array; } 00382 const domInputLocalOffset_Array &getInput_array() const { return elemInput_array; } 00387 const domVcountRef getVcount() const { return elemVcount; } 00392 const domVRef getV() const { return elemV; } 00397 domExtra_Array &getExtra_array() { return elemExtra_array; } 00402 const domExtra_Array &getExtra_array() const { return elemExtra_array; } 00403 protected: 00407 domVertex_weights(DAE& dae) : daeElement(dae), attrCount(), elemInput_array(), elemVcount(), elemV(), elemExtra_array() {} 00411 virtual ~domVertex_weights() {} 00415 virtual domVertex_weights &operator=( const domVertex_weights &cpy ) { (void)cpy; return *this; } 00416 00417 public: // STATIC METHODS 00422 static DLLSPEC daeElementRef create(DAE& dae); 00428 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00429 }; 00430 00431 00432 protected: // Attribute 00438 xsAnyURI attrSource; 00439 00440 protected: // Elements 00447 domBind_shape_matrixRef elemBind_shape_matrix; 00451 domSource_Array elemSource_array; 00457 domJointsRef elemJoints; 00462 domVertex_weightsRef elemVertex_weights; 00466 domExtra_Array elemExtra_array; 00467 00468 public: //Accessors and Mutators 00473 xsAnyURI &getSource() { return attrSource; } 00478 const xsAnyURI &getSource() const { return attrSource; } 00483 void setSource( const xsAnyURI &atSource ) { attrSource = atSource; _validAttributeArray[0] = true; } 00488 void setSource( xsString atSource ) { attrSource = atSource; _validAttributeArray[0] = true; } 00489 00494 const domBind_shape_matrixRef getBind_shape_matrix() const { return elemBind_shape_matrix; } 00499 domSource_Array &getSource_array() { return elemSource_array; } 00504 const domSource_Array &getSource_array() const { return elemSource_array; } 00509 const domJointsRef getJoints() const { return elemJoints; } 00514 const domVertex_weightsRef getVertex_weights() const { return elemVertex_weights; } 00519 domExtra_Array &getExtra_array() { return elemExtra_array; } 00524 const domExtra_Array &getExtra_array() const { return elemExtra_array; } 00525 protected: 00529 domSkin(DAE& dae) : daeElement(dae), attrSource(dae, *this), elemBind_shape_matrix(), elemSource_array(), elemJoints(), elemVertex_weights(), elemExtra_array() {} 00533 virtual ~domSkin() {} 00537 virtual domSkin &operator=( const domSkin &cpy ) { (void)cpy; return *this; } 00538 00539 public: // STATIC METHODS 00544 static DLLSPEC daeElementRef create(DAE& dae); 00550 static DLLSPEC daeMetaElement* registerElement(DAE& dae); 00551 }; 00552 00553 00554 #endif