MeVisLabToolboxReference
MeVisLab/Standard/Sources/ML/MLWEM/WEMBase/WEMQuadPatch.h
Go to the documentation of this file.
00001 // **InsertLicense** code
00002 //----------------------------------------------------------------------------------
00004 
00011 #ifndef __WEMQuadPatch_H
00012 #define __WEMQuadPatch_H
00013 
00014 
00015 #include "WEMPatch.h"
00016 #include "WEMQuad.h"
00017 
00018 ML_START_NAMESPACE
00019 
00021 
00023 class MLWEM_EXPORT WEMQuadPatch : public WEMPatch
00024 {
00025 public:
00026 
00028   WEMQuadPatch(unsigned int bs = 8192);
00031   WEMQuadPatch(WEM* wem, unsigned int bs = 8192);
00033   WEMQuadPatch(const WEMQuadPatch &wemPatch);
00035   virtual ~WEMQuadPatch();
00037   virtual void dispose();
00038 
00040   virtual inline PatchTypes getPatchType() const { return WEM_PATCH_QUADS; }
00041 
00043 
00045   virtual inline unsigned int getNumFaces() const { return _quads->num(); }
00047   inline WEMIndexVector<WEMQuad>* getFaces() { return _quads; }
00049   inline const WEMIndexVector<WEMQuad>* getFaces() const { return const_cast<WEMQuadPatch*>(this)->getFaces(); }
00050 
00052 
00054   virtual inline WEMFace* getFaceAt(unsigned int index) { return _quads->at(index); }
00056   virtual inline const WEMFace* getFaceAt(unsigned int index) const { return const_cast<WEMQuadPatch*>(this)->getFaceAt(index); }
00058   inline WEMQuad* getQuadAt(unsigned int index) { return _quads->at(index); }
00060   inline const WEMQuad* getQuadAt(unsigned int index) const { return const_cast<WEMQuadPatch*>(this)->getQuadAt(index); }
00062   virtual WEMFace* addFace();
00064   WEMQuad* addQuad();
00066   void delQuad(WEMQuad* quad);
00067 
00069 
00070 private:
00071 
00073   void _initMembers(unsigned int bs);
00075   WEMIndexVector<WEMQuad>* _quads;
00076 
00077 };
00078 
00080 
00081 ML_END_NAMESPACE
00082 
00083 #endif // __WEM_H