GDCM: gdcmIconImageGenerator.h Source File

GDCM 3.2.10

gdcmIconImageGenerator.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: GDCM (Grassroots DICOM). A DICOM library
4
5 Copyright (c) 2006-2011 Mathieu Malaterre
6 All rights reserved.
7 See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8
9 This software is distributed WITHOUT ANY WARRANTY; without even
10 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11 PURPOSE. See the above copyright notice for more information.
12
13=========================================================================*/
14#ifndef GDCMICONIMAGEGENERATOR_H
15#define GDCMICONIMAGEGENERATOR_H
16
17#include "gdcmPixmap.h"
18#include "gdcmIconImage.h"
19
20namespace gdcm
21{
22class IconImageGeneratorInternals;
41 class GDCM_EXPORT IconImageGenerator
42{
43public:
44 IconImageGenerator();
45 ~IconImageGenerator();
46
48 void SetPixmap(const Pixmap& p) { P = p; }
49 Pixmap &GetPixmap() { return *P; }
50 const Pixmap &GetPixmap() const { return *P; }
51
53 void SetOutputDimensions(const unsigned int dims[2]);
54
58 void SetPixelMinMax(double min, double max);
59
63 void AutoPixelMinMax(bool b);
64
69 void ConvertRGBToPaletteColor(bool b);
70
74 void SetOutsideValuePixel(double v);
75
77 bool Generate();
78
80 const IconImage& GetIconImage() const { return *I; }
81
82protected:
83
84private:
85 void BuildLUT( Bitmap & bitmap, unsigned int maxcolor );
86
87 SmartPointer<Pixmap> P;
88 SmartPointer<IconImage> I;
89 IconImageGeneratorInternals *Internals;
90};
91
92} // end namespace gdcm
93
94#endif //GDCMICONIMAGEGENERATOR_H
gdcm::Bitmap
Bitmap class.
Definition gdcmBitmap.h:39
gdcm::IconImageGenerator::GetPixmap
const Pixmap & GetPixmap() const
Definition gdcmIconImageGenerator.h:50
gdcm::IconImageGenerator::GetPixmap
Pixmap & GetPixmap()
Definition gdcmIconImageGenerator.h:49
gdcm::IconImageGenerator::SetPixmap
void SetPixmap(const Pixmap &p)
Set/Get File.
Definition gdcmIconImageGenerator.h:48
gdcm::IconImageGenerator::IconImageGenerator
IconImageGenerator()
gdcm::IconImageGenerator::SetOutputDimensions
void SetOutputDimensions(const unsigned int dims[2])
Set Target dimension of output Icon.
gdcm::IconImageGenerator::Generate
bool Generate()
Generate Icon.
gdcm::IconImageGenerator::ConvertRGBToPaletteColor
void ConvertRGBToPaletteColor(bool b)
gdcm::IconImageGenerator::SetPixelMinMax
void SetPixelMinMax(double min, double max)
gdcm::IconImageGenerator::GetIconImage
const IconImage & GetIconImage() const
Retrieve generated Icon.
Definition gdcmIconImageGenerator.h:80
gdcm::IconImageGenerator::AutoPixelMinMax
void AutoPixelMinMax(bool b)
gdcm::IconImageGenerator::~IconImageGenerator
~IconImageGenerator()
gdcm::IconImageGenerator::SetOutsideValuePixel
void SetOutsideValuePixel(double v)
gdcm::Pixmap
Pixmap class.
Definition gdcmPixmap.h:33
gdcm::SmartPointer
Class for Smart Pointer.
Definition gdcmSmartPointer.h:40
gdcmIconImage.h
gdcmPixmap.h
GDCM_EXPORT
#define GDCM_EXPORT
Definition gdcmWin32.h:34
gdcm
Definition gdcmASN1.h:21
gdcm::IconImage
Bitmap IconImage
Definition gdcmIconImage.h:91