Logo Search packages:      
Sourcecode: gdcm version File versions

gdcm::Image Class Reference

#include <gdcmImage.h>

Inheritance diagram for gdcm::Image:

gdcm::Pixmap gdcm::Object

List of all members.


Detailed Description

Image.

Note:
This is the container for an Image in the general sense. From this container you should be able to request information like:
  • Origin
  • Dimension
  • PixelFormat ... But also to retrieve the image as a raw buffer (char *) Since we have to deal with both RAW data and JPEG stream (which internally encode all the above information) this API might seems redundant. One way to solve that would be to subclass gdcm::Image with gdcm::JPEGImage which would from the stream extract the header info and fill it to please gdcm::Image...well except origin for instance
Basically you can see it as a storage for the PixelData element. However it was also used for MRSpectroscopy object (as proof of concept)

Definition at line 49 of file gdcmImage.h.


Public Member Functions

bool AreOverlaysInPixelData () const
 returns if Overlays are stored in the unused bit of the pixel data:
void Clear ()
bool GetBuffer (char *buffer) const
 Acces the raw data.
unsigned long GetBufferLength () const
unsigned int GetColumns () const
const CurveGetCurve (unsigned int i=0) const
CurveGetCurve (unsigned int i=0)
 Curve: group 50xx.
DataElementGetDataElement ()
const DataElementGetDataElement () const
unsigned int GetDimension (unsigned int idx) const
const unsigned int * GetDimensions () const
 Return the dimension of the pixel data, first dimension (x), then 2nd (y), then 3rd (z)...
double GetDirectionCosines (unsigned int idx) const
const double * GetDirectionCosines () const
IconImageGetIconImage ()
const IconImageGetIconImage () const
 Set/Get Icon Image.
double GetIntercept () const
LookupTableGetLUT ()
const LookupTableGetLUT () const
bool GetNeedByteSwap () const
unsigned int GetNumberOfCurves () const
unsigned int GetNumberOfDimensions () const
 Return the number of dimension of the pixel data bytes; for example 2 for a 2D matrices of values.
unsigned int GetNumberOfOverlays () const
double GetOrigin (unsigned int idx) const
const double * GetOrigin () const
const OverlayGetOverlay (unsigned int i=0) const
OverlayGetOverlay (unsigned int i=0)
 Overlay: group 60xx.
const PhotometricInterpretationGetPhotometricInterpretation () const
 return the photometric interpretation
PixelFormatGetPixelFormat ()
const PixelFormatGetPixelFormat () const
unsigned int GetPlanarConfiguration () const
 return the planar configuration
unsigned int GetRows () const
double GetSlope () const
double GetSpacing (unsigned int idx) const
const double * GetSpacing () const
SwapCode GetSwapCode () const
 DEPRECATED DO NOT USE.
const TransferSyntaxGetTransferSyntax () const
bool IsEmpty () const
void Print (std::ostream &os) const
 print
void SetColumns (unsigned int col)
void SetDataElement (DataElement const &de)
void SetDimension (unsigned int idx, unsigned int dim)
void SetDimensions (const unsigned int *dims)
void SetDirectionCosines (unsigned int idx, double dircos)
void SetDirectionCosines (const double *dircos)
void SetDirectionCosines (const float *dircos)
void SetIntercept (double intercept)
 intercept
void SetLUT (LookupTable const &lut)
 Set/Get LUT.
void SetNeedByteSwap (bool b)
void SetNumberOfCurves (unsigned int n)
void SetNumberOfDimensions (unsigned int dim)
void SetNumberOfOverlays (unsigned int n)
void SetOrigin (unsigned int idx, double ori)
void SetOrigin (const double *ori)
void SetOrigin (const float *ori)
void SetPhotometricInterpretation (PhotometricInterpretation const &pi)
void SetPixelFormat (PixelFormat const &pf)
void SetPlanarConfiguration (unsigned int pc)
void SetRows (unsigned int rows)
void SetSlope (double slope)
 slope
void SetSpacing (unsigned int idx, double spacing)
void SetSpacing (const double *spacing)
void SetSwapCode (SwapCode sc)
void SetTransferSyntax (TransferSyntax const &ts)
 Transfer syntax.

Protected Types

typedef SmartPointer< LookupTableLUTPtr

Protected Member Functions

bool GetBuffer2 (std::ostream &os) const
void Register ()
bool TryJPEG2000Codec (char *buffer) const
bool TryJPEG2000Codec2 (std::ostream &os) const
bool TryJPEGCodec (char *buffer) const
bool TryJPEGCodec2 (std::ostream &os) const
bool TryJPEGLSCodec (char *buffer) const
bool TryPVRGCodec (char *buffer) const
bool TryRAWCodec (char *buffer) const
bool TryRLECodec (char *buffer) const
void UnRegister ()

Protected Attributes

std::vector< unsigned int > Dimensions
LUTPtr LUT
bool NeedByteSwap
unsigned int NumberOfDimensions
PixelFormat PF
PhotometricInterpretation PI
DataElement PixelData
unsigned int PlanarConfiguration
TransferSyntax TS

Private Attributes

std::vector< CurveCurves
std::vector< double > DirectionCosines
IconImage Icon
double Intercept
std::vector< double > Origin
std::vector< OverlayOverlays
SwapCode SC
double Slope
std::vector< double > Spacing

The documentation for this class was generated from the following files:

Generated by  Doxygen 1.6.0   Back to index