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 #ifndef __domGles_sampler_state_h__
     10 #define __domGles_sampler_state_h__
     11 
     12 #include <dae/daeDocument.h>
     13 #include <dom/domTypes.h>
     14 #include <dom/domElements.h>
     15 
     16 #include <dom/domExtra.h>
     17 class DAE;
     18 
     19 /**
     20  * Two-dimensional texture sampler state for profile_GLES. This is a bundle
     21  * of sampler-specific states that will be referenced by one or more texture_units.
     22  */
     23 class domGles_sampler_state_complexType
     24 {
     25 public:
     26 	class domWrap_s;
     27 
     28 	typedef daeSmartRef<domWrap_s> domWrap_sRef;
     29 	typedef daeTArray<domWrap_sRef> domWrap_s_Array;
     30 
     31 	class domWrap_s : public daeElement
     32 	{
     33 	public:
     34 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::WRAP_S; }
     35 		static daeInt ID() { return 157; }
     36 		virtual daeInt typeID() const { return ID(); }
     37 
     38 	protected:  // Value
     39 		/**
     40 		 * The domGles_sampler_wrap value of the text data of this element.
     41 		 */
     42 		domGles_sampler_wrap _value;
     43 
     44 	public:	//Accessors and Mutators
     45 		/**
     46 		 * Gets the value of this element.
     47 		 * @return a domGles_sampler_wrap of the value.
     48 		 */
     49 		domGles_sampler_wrap getValue() const { return _value; }
     50 		/**
     51 		 * Sets the _value of this element.
     52 		 * @param val The new value for this element.
     53 		 */
     54 		void setValue( domGles_sampler_wrap val ) { _value = val; }
     55 
     56 	protected:
     57 		/**
     58 		 * Constructor
     59 		 */
     60 		domWrap_s(DAE& dae) : daeElement(dae), _value() {}
     61 		/**
     62 		 * Destructor
     63 		 */
     64 		virtual ~domWrap_s() {}
     65 		/**
     66 		 * Overloaded assignment operator
     67 		 */
     68 		virtual domWrap_s &operator=( const domWrap_s &cpy ) { (void)cpy; return *this; }
     69 
     70 	public: // STATIC METHODS
     71 		/**
     72 		 * Creates an instance of this class and returns a daeElementRef referencing it.
     73 		 * @return a daeElementRef referencing an instance of this object.
     74 		 */
     75 		static DLLSPEC daeElementRef create(DAE& dae);
     76 		/**
     77 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
     78 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
     79 		 * @return A daeMetaElement describing this COLLADA element.
     80 		 */
     81 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
     82 	};
     83 
     84 	class domWrap_t;
     85 
     86 	typedef daeSmartRef<domWrap_t> domWrap_tRef;
     87 	typedef daeTArray<domWrap_tRef> domWrap_t_Array;
     88 
     89 	class domWrap_t : public daeElement
     90 	{
     91 	public:
     92 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::WRAP_T; }
     93 		static daeInt ID() { return 158; }
     94 		virtual daeInt typeID() const { return ID(); }
     95 
     96 	protected:  // Value
     97 		/**
     98 		 * The domGles_sampler_wrap value of the text data of this element.
     99 		 */
    100 		domGles_sampler_wrap _value;
    101 
    102 	public:	//Accessors and Mutators
    103 		/**
    104 		 * Gets the value of this element.
    105 		 * @return a domGles_sampler_wrap of the value.
    106 		 */
    107 		domGles_sampler_wrap getValue() const { return _value; }
    108 		/**
    109 		 * Sets the _value of this element.
    110 		 * @param val The new value for this element.
    111 		 */
    112 		void setValue( domGles_sampler_wrap val ) { _value = val; }
    113 
    114 	protected:
    115 		/**
    116 		 * Constructor
    117 		 */
    118 		domWrap_t(DAE& dae) : daeElement(dae), _value() {}
    119 		/**
    120 		 * Destructor
    121 		 */
    122 		virtual ~domWrap_t() {}
    123 		/**
    124 		 * Overloaded assignment operator
    125 		 */
    126 		virtual domWrap_t &operator=( const domWrap_t &cpy ) { (void)cpy; return *this; }
    127 
    128 	public: // STATIC METHODS
    129 		/**
    130 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    131 		 * @return a daeElementRef referencing an instance of this object.
    132 		 */
    133 		static DLLSPEC daeElementRef create(DAE& dae);
    134 		/**
    135 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    136 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    137 		 * @return A daeMetaElement describing this COLLADA element.
    138 		 */
    139 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    140 	};
    141 
    142 	class domMinfilter;
    143 
    144 	typedef daeSmartRef<domMinfilter> domMinfilterRef;
    145 	typedef daeTArray<domMinfilterRef> domMinfilter_Array;
    146 
    147 	class domMinfilter : public daeElement
    148 	{
    149 	public:
    150 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MINFILTER; }
    151 		static daeInt ID() { return 159; }
    152 		virtual daeInt typeID() const { return ID(); }
    153 
    154 	protected:  // Value
    155 		/**
    156 		 * The domFx_sampler_filter_common value of the text data of this element.
    157 		 */
    158 		domFx_sampler_filter_common _value;
    159 
    160 	public:	//Accessors and Mutators
    161 		/**
    162 		 * Gets the value of this element.
    163 		 * @return a domFx_sampler_filter_common of the value.
    164 		 */
    165 		domFx_sampler_filter_common getValue() const { return _value; }
    166 		/**
    167 		 * Sets the _value of this element.
    168 		 * @param val The new value for this element.
    169 		 */
    170 		void setValue( domFx_sampler_filter_common val ) { _value = val; }
    171 
    172 	protected:
    173 		/**
    174 		 * Constructor
    175 		 */
    176 		domMinfilter(DAE& dae) : daeElement(dae), _value() {}
    177 		/**
    178 		 * Destructor
    179 		 */
    180 		virtual ~domMinfilter() {}
    181 		/**
    182 		 * Overloaded assignment operator
    183 		 */
    184 		virtual domMinfilter &operator=( const domMinfilter &cpy ) { (void)cpy; return *this; }
    185 
    186 	public: // STATIC METHODS
    187 		/**
    188 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    189 		 * @return a daeElementRef referencing an instance of this object.
    190 		 */
    191 		static DLLSPEC daeElementRef create(DAE& dae);
    192 		/**
    193 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    194 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    195 		 * @return A daeMetaElement describing this COLLADA element.
    196 		 */
    197 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    198 	};
    199 
    200 	class domMagfilter;
    201 
    202 	typedef daeSmartRef<domMagfilter> domMagfilterRef;
    203 	typedef daeTArray<domMagfilterRef> domMagfilter_Array;
    204 
    205 	class domMagfilter : public daeElement
    206 	{
    207 	public:
    208 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MAGFILTER; }
    209 		static daeInt ID() { return 160; }
    210 		virtual daeInt typeID() const { return ID(); }
    211 
    212 	protected:  // Value
    213 		/**
    214 		 * The domFx_sampler_filter_common value of the text data of this element.
    215 		 */
    216 		domFx_sampler_filter_common _value;
    217 
    218 	public:	//Accessors and Mutators
    219 		/**
    220 		 * Gets the value of this element.
    221 		 * @return a domFx_sampler_filter_common of the value.
    222 		 */
    223 		domFx_sampler_filter_common getValue() const { return _value; }
    224 		/**
    225 		 * Sets the _value of this element.
    226 		 * @param val The new value for this element.
    227 		 */
    228 		void setValue( domFx_sampler_filter_common val ) { _value = val; }
    229 
    230 	protected:
    231 		/**
    232 		 * Constructor
    233 		 */
    234 		domMagfilter(DAE& dae) : daeElement(dae), _value() {}
    235 		/**
    236 		 * Destructor
    237 		 */
    238 		virtual ~domMagfilter() {}
    239 		/**
    240 		 * Overloaded assignment operator
    241 		 */
    242 		virtual domMagfilter &operator=( const domMagfilter &cpy ) { (void)cpy; return *this; }
    243 
    244 	public: // STATIC METHODS
    245 		/**
    246 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    247 		 * @return a daeElementRef referencing an instance of this object.
    248 		 */
    249 		static DLLSPEC daeElementRef create(DAE& dae);
    250 		/**
    251 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    252 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    253 		 * @return A daeMetaElement describing this COLLADA element.
    254 		 */
    255 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    256 	};
    257 
    258 	class domMipfilter;
    259 
    260 	typedef daeSmartRef<domMipfilter> domMipfilterRef;
    261 	typedef daeTArray<domMipfilterRef> domMipfilter_Array;
    262 
    263 	class domMipfilter : public daeElement
    264 	{
    265 	public:
    266 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MIPFILTER; }
    267 		static daeInt ID() { return 161; }
    268 		virtual daeInt typeID() const { return ID(); }
    269 
    270 	protected:  // Value
    271 		/**
    272 		 * The domFx_sampler_filter_common value of the text data of this element.
    273 		 */
    274 		domFx_sampler_filter_common _value;
    275 
    276 	public:	//Accessors and Mutators
    277 		/**
    278 		 * Gets the value of this element.
    279 		 * @return a domFx_sampler_filter_common of the value.
    280 		 */
    281 		domFx_sampler_filter_common getValue() const { return _value; }
    282 		/**
    283 		 * Sets the _value of this element.
    284 		 * @param val The new value for this element.
    285 		 */
    286 		void setValue( domFx_sampler_filter_common val ) { _value = val; }
    287 
    288 	protected:
    289 		/**
    290 		 * Constructor
    291 		 */
    292 		domMipfilter(DAE& dae) : daeElement(dae), _value() {}
    293 		/**
    294 		 * Destructor
    295 		 */
    296 		virtual ~domMipfilter() {}
    297 		/**
    298 		 * Overloaded assignment operator
    299 		 */
    300 		virtual domMipfilter &operator=( const domMipfilter &cpy ) { (void)cpy; return *this; }
    301 
    302 	public: // STATIC METHODS
    303 		/**
    304 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    305 		 * @return a daeElementRef referencing an instance of this object.
    306 		 */
    307 		static DLLSPEC daeElementRef create(DAE& dae);
    308 		/**
    309 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    310 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    311 		 * @return A daeMetaElement describing this COLLADA element.
    312 		 */
    313 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    314 	};
    315 
    316 	class domMipmap_maxlevel;
    317 
    318 	typedef daeSmartRef<domMipmap_maxlevel> domMipmap_maxlevelRef;
    319 	typedef daeTArray<domMipmap_maxlevelRef> domMipmap_maxlevel_Array;
    320 
    321 	class domMipmap_maxlevel : public daeElement
    322 	{
    323 	public:
    324 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MIPMAP_MAXLEVEL; }
    325 		static daeInt ID() { return 162; }
    326 		virtual daeInt typeID() const { return ID(); }
    327 
    328 	protected:  // Value
    329 		/**
    330 		 * The xsUnsignedByte value of the text data of this element.
    331 		 */
    332 		xsUnsignedByte _value;
    333 
    334 	public:	//Accessors and Mutators
    335 		/**
    336 		 * Gets the value of this element.
    337 		 * @return a xsUnsignedByte of the value.
    338 		 */
    339 		xsUnsignedByte getValue() const { return _value; }
    340 		/**
    341 		 * Sets the _value of this element.
    342 		 * @param val The new value for this element.
    343 		 */
    344 		void setValue( xsUnsignedByte val ) { _value = val; }
    345 
    346 	protected:
    347 		/**
    348 		 * Constructor
    349 		 */
    350 		domMipmap_maxlevel(DAE& dae) : daeElement(dae), _value() {}
    351 		/**
    352 		 * Destructor
    353 		 */
    354 		virtual ~domMipmap_maxlevel() {}
    355 		/**
    356 		 * Overloaded assignment operator
    357 		 */
    358 		virtual domMipmap_maxlevel &operator=( const domMipmap_maxlevel &cpy ) { (void)cpy; return *this; }
    359 
    360 	public: // STATIC METHODS
    361 		/**
    362 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    363 		 * @return a daeElementRef referencing an instance of this object.
    364 		 */
    365 		static DLLSPEC daeElementRef create(DAE& dae);
    366 		/**
    367 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    368 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    369 		 * @return A daeMetaElement describing this COLLADA element.
    370 		 */
    371 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    372 	};
    373 
    374 	class domMipmap_bias;
    375 
    376 	typedef daeSmartRef<domMipmap_bias> domMipmap_biasRef;
    377 	typedef daeTArray<domMipmap_biasRef> domMipmap_bias_Array;
    378 
    379 	class domMipmap_bias : public daeElement
    380 	{
    381 	public:
    382 		virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::MIPMAP_BIAS; }
    383 		static daeInt ID() { return 163; }
    384 		virtual daeInt typeID() const { return ID(); }
    385 
    386 	protected:  // Value
    387 		/**
    388 		 * The xsFloat value of the text data of this element.
    389 		 */
    390 		xsFloat _value;
    391 
    392 	public:	//Accessors and Mutators
    393 		/**
    394 		 * Gets the value of this element.
    395 		 * @return a xsFloat of the value.
    396 		 */
    397 		xsFloat getValue() const { return _value; }
    398 		/**
    399 		 * Sets the _value of this element.
    400 		 * @param val The new value for this element.
    401 		 */
    402 		void setValue( xsFloat val ) { _value = val; }
    403 
    404 	protected:
    405 		/**
    406 		 * Constructor
    407 		 */
    408 		domMipmap_bias(DAE& dae) : daeElement(dae), _value() {}
    409 		/**
    410 		 * Destructor
    411 		 */
    412 		virtual ~domMipmap_bias() {}
    413 		/**
    414 		 * Overloaded assignment operator
    415 		 */
    416 		virtual domMipmap_bias &operator=( const domMipmap_bias &cpy ) { (void)cpy; return *this; }
    417 
    418 	public: // STATIC METHODS
    419 		/**
    420 		 * Creates an instance of this class and returns a daeElementRef referencing it.
    421 		 * @return a daeElementRef referencing an instance of this object.
    422 		 */
    423 		static DLLSPEC daeElementRef create(DAE& dae);
    424 		/**
    425 		 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    426 		 * If a daeMetaElement already exists it will return that instead of creating a new one.
    427 		 * @return A daeMetaElement describing this COLLADA element.
    428 		 */
    429 		static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    430 	};
    431 
    432 
    433 protected:  // Attribute
    434 /**
    435  *  The sid attribute is a text string value containing the sub-identifier
    436  * of this element.  This value must be unique within the scope of the parent
    437  * element. Optional attribute.
    438  */
    439 	xsNCName attrSid;
    440 
    441 protected:  // Elements
    442 	domWrap_sRef elemWrap_s;
    443 	domWrap_tRef elemWrap_t;
    444 	domMinfilterRef elemMinfilter;
    445 	domMagfilterRef elemMagfilter;
    446 	domMipfilterRef elemMipfilter;
    447 	domMipmap_maxlevelRef elemMipmap_maxlevel;
    448 	domMipmap_biasRef elemMipmap_bias;
    449 /**
    450  *  The extra element may appear any number of times. OpenGL ES extensions
    451  * may be used here.  @see domExtra
    452  */
    453 	domExtra_Array elemExtra_array;
    454 
    455 public:	//Accessors and Mutators
    456 	/**
    457 	 * Gets the sid attribute.
    458 	 * @return Returns a xsNCName of the sid attribute.
    459 	 */
    460 	xsNCName getSid() const { return attrSid; }
    461 	/**
    462 	 * Sets the sid attribute.
    463 	 * @param atSid The new value for the sid attribute.
    464 	 */
    465 	void setSid( xsNCName atSid ) { *(daeStringRef*)&attrSid = atSid;}
    466 
    467 	/**
    468 	 * Gets the wrap_s element.
    469 	 * @return a daeSmartRef to the wrap_s element.
    470 	 */
    471 	const domWrap_sRef getWrap_s() const { return elemWrap_s; }
    472 	/**
    473 	 * Gets the wrap_t element.
    474 	 * @return a daeSmartRef to the wrap_t element.
    475 	 */
    476 	const domWrap_tRef getWrap_t() const { return elemWrap_t; }
    477 	/**
    478 	 * Gets the minfilter element.
    479 	 * @return a daeSmartRef to the minfilter element.
    480 	 */
    481 	const domMinfilterRef getMinfilter() const { return elemMinfilter; }
    482 	/**
    483 	 * Gets the magfilter element.
    484 	 * @return a daeSmartRef to the magfilter element.
    485 	 */
    486 	const domMagfilterRef getMagfilter() const { return elemMagfilter; }
    487 	/**
    488 	 * Gets the mipfilter element.
    489 	 * @return a daeSmartRef to the mipfilter element.
    490 	 */
    491 	const domMipfilterRef getMipfilter() const { return elemMipfilter; }
    492 	/**
    493 	 * Gets the mipmap_maxlevel element.
    494 	 * @return a daeSmartRef to the mipmap_maxlevel element.
    495 	 */
    496 	const domMipmap_maxlevelRef getMipmap_maxlevel() const { return elemMipmap_maxlevel; }
    497 	/**
    498 	 * Gets the mipmap_bias element.
    499 	 * @return a daeSmartRef to the mipmap_bias element.
    500 	 */
    501 	const domMipmap_biasRef getMipmap_bias() const { return elemMipmap_bias; }
    502 	/**
    503 	 * Gets the extra element array.
    504 	 * @return Returns a reference to the array of extra elements.
    505 	 */
    506 	domExtra_Array &getExtra_array() { return elemExtra_array; }
    507 	/**
    508 	 * Gets the extra element array.
    509 	 * @return Returns a constant reference to the array of extra elements.
    510 	 */
    511 	const domExtra_Array &getExtra_array() const { return elemExtra_array; }
    512 protected:
    513 	/**
    514 	 * Constructor
    515 	 */
    516 	domGles_sampler_state_complexType(DAE& dae, daeElement* elt) : attrSid(), elemWrap_s(), elemWrap_t(), elemMinfilter(), elemMagfilter(), elemMipfilter(), elemMipmap_maxlevel(), elemMipmap_bias(), elemExtra_array() {}
    517 	/**
    518 	 * Destructor
    519 	 */
    520 	virtual ~domGles_sampler_state_complexType() {}
    521 	/**
    522 	 * Overloaded assignment operator
    523 	 */
    524 	virtual domGles_sampler_state_complexType &operator=( const domGles_sampler_state_complexType &cpy ) { (void)cpy; return *this; }
    525 };
    526 
    527 /**
    528  * An element of type domGles_sampler_state_complexType.
    529  */
    530 class domGles_sampler_state : public daeElement, public domGles_sampler_state_complexType
    531 {
    532 public:
    533 	virtual COLLADA_TYPE::TypeEnum getElementType() const { return COLLADA_TYPE::GLES_SAMPLER_STATE; }
    534 	static daeInt ID() { return 164; }
    535 	virtual daeInt typeID() const { return ID(); }
    536 
    537 public:	//Accessors and Mutators
    538 	/**
    539 	 * Gets the sid attribute.
    540 	 * @return Returns a xsNCName of the sid attribute.
    541 	 */
    542 	xsNCName getSid() const { return attrSid; }
    543 	/**
    544 	 * Sets the sid attribute.
    545 	 * @param atSid The new value for the sid attribute.
    546 	 */
    547 	void setSid( xsNCName atSid ) { *(daeStringRef*)&attrSid = atSid; _validAttributeArray[0] = true; }
    548 
    549 protected:
    550 	/**
    551 	 * Constructor
    552 	 */
    553 	domGles_sampler_state(DAE& dae) : daeElement(dae), domGles_sampler_state_complexType(dae, this) {}
    554 	/**
    555 	 * Destructor
    556 	 */
    557 	virtual ~domGles_sampler_state() {}
    558 	/**
    559 	 * Overloaded assignment operator
    560 	 */
    561 	virtual domGles_sampler_state &operator=( const domGles_sampler_state &cpy ) { (void)cpy; return *this; }
    562 
    563 public: // STATIC METHODS
    564 	/**
    565 	 * Creates an instance of this class and returns a daeElementRef referencing it.
    566 	 * @return a daeElementRef referencing an instance of this object.
    567 	 */
    568 	static DLLSPEC daeElementRef create(DAE& dae);
    569 	/**
    570 	 * Creates a daeMetaElement object that describes this element in the meta object reflection framework.
    571 	 * If a daeMetaElement already exists it will return that instead of creating a new one.
    572 	 * @return A daeMetaElement describing this COLLADA element.
    573 	 */
    574 	static DLLSPEC daeMetaElement* registerElement(DAE& dae);
    575 };
    576 
    577 
    578 #endif
    579