gdcmOverlay.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program: GDCM (Grassroots DICOM). A DICOM library
00004   Module:  $URL$
00005 
00006   Copyright (c) 2006-2010 Mathieu Malaterre
00007   All rights reserved.
00008   See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00015 #ifndef GDCMOVERLAY_H
00016 #define GDCMOVERLAY_H
00017 
00018 #include "gdcmTypes.h"
00019 #include "gdcmObject.h"
00020 
00021 namespace gdcm
00022 {
00023   
00024 class OverlayInternal;
00025 class ByteValue;
00026 class DataSet;
00027 class DataElement;
00039 class GDCM_EXPORT Overlay : public Object
00040 {
00041 public:
00042   Overlay();
00043   ~Overlay();
00045   void Print(std::ostream &) const;
00046 
00049   static unsigned int GetNumberOfOverlays(DataSet const & ds);
00050 
00052   void Update(const DataElement & de);
00053 
00055   void SetGroup(unsigned short group);
00057   unsigned short GetGroup() const;
00059   void SetRows(unsigned short rows);
00061   unsigned short GetRows() const;
00063   void SetColumns(unsigned short columns);
00065   unsigned short GetColumns() const;
00067   void SetNumberOfFrames(unsigned int numberofframes);
00069   void SetDescription(const char* description);
00071   const char *GetDescription() const;
00073   void SetType(const char* type);
00075   const char *GetType() const;
00077   void SetOrigin(const signed short *origin);
00079   const signed short * GetOrigin() const;
00081   void SetFrameOrigin(unsigned short frameorigin);
00083   void SetBitsAllocated(unsigned short bitsallocated);
00085   unsigned short GetBitsAllocated() const;
00087   void SetBitPosition(unsigned short bitposition);
00089   unsigned short GetBitPosition() const;
00091   void SetOverlay(const char *array, unsigned int length);
00093   bool GrabOverlayFromPixelData(DataSet const &ds);
00094 
00095   const ByteValue &GetOverlayData() const;
00096 
00097   bool IsEmpty() const;
00098 
00100   bool IsZero() const;
00101 
00102   // return if the Overlay is stored in the pixel data or not
00103   bool IsInPixelData() const;
00104   void IsInPixelData(bool b);
00105 
00106   void Decode(std::istream &is, std::ostream &os);
00107 
00108   void Decompress(std::ostream &os) const;
00109 
00110   bool GetBuffer(char *buffer) const;
00111   bool GetUnpackBuffer(unsigned char *buffer) const;
00112 
00113   Overlay(Overlay const &ov);
00114 
00115 private:
00116   OverlayInternal *Internal;
00117 };
00118 
00119 } // end namespace gdcm
00120 
00121 #endif //GDCMOVERLAY_H

Generated on Sat Dec 4 2010 08:58:44 for GDCM by doxygen 1.7.2
SourceForge.net Logo