Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Friends

gdcm::Bitmap Class Reference

Bitmap class A bitmap based image. Used as parent for both IconImage and the main Pixel Data Image It does not contains any World Space information (IPP, IOP) More...

#include <gdcmBitmap.h>

Inheritance diagram for gdcm::Bitmap:
Inheritance graph
[legend]
Collaboration diagram for gdcm::Bitmap:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Bitmap ()
 ~Bitmap ()
virtual bool AreOverlaysInPixelData () const
void Clear ()
bool GetBuffer (char *buffer) const
 Acces the raw data.
unsigned long GetBufferLength () const
unsigned int GetColumns () const
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)...
const LookupTableGetLUT () const
LookupTableGetLUT ()
bool GetNeedByteSwap () const
unsigned int GetNumberOfDimensions () const
 Return the number of dimension of the pixel data bytes; for example 2 for a 2D matrices of values.
const PhotometricInterpretationGetPhotometricInterpretation () const
 return the photometric interpretation
PixelFormatGetPixelFormat ()
const PixelFormatGetPixelFormat () const
 Get/Set PixelFormat.
unsigned int GetPlanarConfiguration () const
 return the planar configuration
unsigned int GetRows () const
const TransferSyntaxGetTransferSyntax () const
bool IsEmpty () const
bool IsLossy () const
 Return whether or not the image was compressed using a lossy compressor or not.
bool IsTransferSyntaxCompatible (TransferSyntax const &ts) const
void Print (std::ostream &) const
void SetColumns (unsigned int col)
void SetDataElement (DataElement const &de)
void SetDimension (unsigned int idx, unsigned int dim)
void SetDimensions (const unsigned int dims[3])
void SetLossyFlag (bool f)
 Specifically set that the image was compressed using a lossy compression mechanism.
void SetLUT (LookupTable const &lut)
 Set/Get LUT.
void SetNeedByteSwap (bool b)
void SetNumberOfDimensions (unsigned int dim)
void SetPhotometricInterpretation (PhotometricInterpretation const &pi)
void SetPixelFormat (PixelFormat const &pf)
void SetPlanarConfiguration (unsigned int pc)
void SetRows (unsigned int rows)
void SetTransferSyntax (TransferSyntax const &ts)
 Transfer syntax.

Protected Types

typedef SmartPointer< LookupTableLUTPtr

Protected Member Functions

bool ComputeLossyFlag ()
bool GetBuffer2 (std::ostream &os) const
bool TryJPEG2000Codec (char *buffer, bool &lossyflag) const
bool TryJPEG2000Codec2 (std::ostream &os) const
bool TryJPEGCodec (char *buffer, bool &lossyflag) const
bool TryJPEGCodec2 (std::ostream &os) const
bool TryJPEGLSCodec (char *buffer, bool &lossyflag) const
bool TryKAKADUCodec (char *buffer, bool &lossyflag) const
bool TryPVRGCodec (char *buffer, bool &lossyflag) const
bool TryRAWCodec (char *buffer, bool &lossyflag) const
bool TryRLECodec (char *buffer, bool &lossyflag) const

Protected Attributes

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

Friends

class ImageChangeTransferSyntax
class PixmapReader

Detailed Description

Bitmap class A bitmap based image. Used as parent for both IconImage and the main Pixel Data Image It does not contains any World Space information (IPP, IOP)


Member Typedef Documentation


Constructor & Destructor Documentation

gdcm::Bitmap::Bitmap (  )
gdcm::Bitmap::~Bitmap (  )

Member Function Documentation

virtual bool gdcm::Bitmap::AreOverlaysInPixelData (  ) const [inline, virtual]

Reimplemented in gdcm::Pixmap.

void gdcm::Bitmap::Clear (  )
bool gdcm::Bitmap::ComputeLossyFlag (  ) [protected]
bool gdcm::Bitmap::GetBuffer ( char *  buffer ) const

Acces the raw data.

Examples:
ConvertToQImage.cxx, and threadgdcm.cxx.
bool gdcm::Bitmap::GetBuffer2 ( std::ostream &  os ) const [protected]
unsigned long gdcm::Bitmap::GetBufferLength (  ) const

Return the length of the image after decompression WARNING for palette color: It will NOT take into account the Palette Color thus you need to multiply this length by 3 if computing the size of equivalent RGB image

Examples:
ConvertToQImage.cxx, csa2img.cxx, PatchFile.cxx, and threadgdcm.cxx.
unsigned int gdcm::Bitmap::GetColumns (  ) const [inline]
const DataElement& gdcm::Bitmap::GetDataElement (  ) const [inline]
DataElement& gdcm::Bitmap::GetDataElement (  ) [inline]
unsigned int gdcm::Bitmap::GetDimension ( unsigned int  idx ) const
const unsigned int* gdcm::Bitmap::GetDimensions (  ) const

Return the dimension of the pixel data, first dimension (x), then 2nd (y), then 3rd (z)...

Examples:
ConvertToQImage.cxx, HelloVizWorld.cxx, and threadgdcm.cxx.
const LookupTable& gdcm::Bitmap::GetLUT (  ) const [inline]
LookupTable& gdcm::Bitmap::GetLUT (  ) [inline]
bool gdcm::Bitmap::GetNeedByteSwap (  ) const [inline]
unsigned int gdcm::Bitmap::GetNumberOfDimensions (  ) const

Return the number of dimension of the pixel data bytes; for example 2 for a 2D matrices of values.

Examples:
HelloVizWorld.cxx, and threadgdcm.cxx.
const PhotometricInterpretation& gdcm::Bitmap::GetPhotometricInterpretation (  ) const

return the photometric interpretation

Examples:
ConvertToQImage.cxx, and HelloVizWorld.cxx.
const PixelFormat& gdcm::Bitmap::GetPixelFormat (  ) const [inline]
PixelFormat& gdcm::Bitmap::GetPixelFormat (  ) [inline]
unsigned int gdcm::Bitmap::GetPlanarConfiguration (  ) const

return the planar configuration

unsigned int gdcm::Bitmap::GetRows (  ) const [inline]
const TransferSyntax& gdcm::Bitmap::GetTransferSyntax (  ) const [inline]
bool gdcm::Bitmap::IsEmpty (  ) const [inline]
bool gdcm::Bitmap::IsLossy (  ) const

Return whether or not the image was compressed using a lossy compressor or not.

bool gdcm::Bitmap::IsTransferSyntaxCompatible ( TransferSyntax const &  ts ) const
void gdcm::Bitmap::Print ( std::ostream &   ) const [inline, virtual]

Reimplemented from gdcm::Object.

Reimplemented in gdcm::Image, and gdcm::Pixmap.

void gdcm::Bitmap::SetColumns ( unsigned int  col ) [inline]
void gdcm::Bitmap::SetDataElement ( DataElement const &  de ) [inline]
void gdcm::Bitmap::SetDimension ( unsigned int  idx,
unsigned int  dim 
)
Examples:
csa2img.cxx.
void gdcm::Bitmap::SetDimensions ( const unsigned int  dims[3] )
void gdcm::Bitmap::SetLossyFlag ( bool  f ) [inline]

Specifically set that the image was compressed using a lossy compression mechanism.

void gdcm::Bitmap::SetLUT ( LookupTable const &  lut ) [inline]

Set/Get LUT.

void gdcm::Bitmap::SetNeedByteSwap ( bool  b ) [inline]
void gdcm::Bitmap::SetNumberOfDimensions ( unsigned int  dim )
void gdcm::Bitmap::SetPhotometricInterpretation ( PhotometricInterpretation const &  pi )
void gdcm::Bitmap::SetPixelFormat ( PixelFormat const &  pf ) [inline]
void gdcm::Bitmap::SetPlanarConfiguration ( unsigned int  pc )
Warning:
you need to call SetPixelFormat first (before SetPlanarConfiguration) for consistency checking
void gdcm::Bitmap::SetRows ( unsigned int  rows ) [inline]
void gdcm::Bitmap::SetTransferSyntax ( TransferSyntax const &  ts ) [inline]

Transfer syntax.

Examples:
CreateARGBImage.cxx, and CreateCMYKImage.cxx.
bool gdcm::Bitmap::TryJPEG2000Codec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryJPEG2000Codec2 ( std::ostream &  os ) const [protected]
bool gdcm::Bitmap::TryJPEGCodec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryJPEGCodec2 ( std::ostream &  os ) const [protected]
bool gdcm::Bitmap::TryJPEGLSCodec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryKAKADUCodec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryPVRGCodec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryRAWCodec ( char *  buffer,
bool &  lossyflag 
) const [protected]
bool gdcm::Bitmap::TryRLECodec ( char *  buffer,
bool &  lossyflag 
) const [protected]

Friends And Related Function Documentation

friend class ImageChangeTransferSyntax [friend]
friend class PixmapReader [friend]

Member Data Documentation

std::vector<unsigned int> gdcm::Bitmap::Dimensions [protected]
bool gdcm::Bitmap::LossyFlag [protected]
bool gdcm::Bitmap::NeedByteSwap [protected]
unsigned int gdcm::Bitmap::NumberOfDimensions [protected]
unsigned int gdcm::Bitmap::PlanarConfiguration [protected]

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

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