#include <vuHistogram.h>
Collaboration diagram for vuHistogram:
Public Types | |
enum | HistType { TYPE_INTENSITY = 0, TYPE_LAPWEIGHTED, TYPE_NUMTYPES } |
Public Member Functions | |
vuHistogram (HistType type=TYPE_INTENSITY) | |
Specialized constructor. | |
virtual | ~vuHistogram () |
Destructor. | |
void | setType (HistType type) |
Sets a histogram type. | |
HistType | getType () |
void | reset () |
Resets the statistics. | |
void | setSize (dword size) |
set the initial size of the histogram (256) | |
void | recordIntensity (word intensity) |
This is just a try to implement an intensity histogram creation. | |
const vuDVector< dword > | getHistogram () const |
Interface to the recorded histogram information. | |
const char * | getTypeName () const |
Return name of type set. | |
Protected Attributes | |
vuDVector< dword > | m_Histogram |
Histogram data. | |
HistType | m_Type |
Type of the Histogram. | |
Friends | |
ostream & | operator<< (ostream &os, const vuHistogram &hist) |
Write contents of histogram to a stream. |
The current implementation just calculates intensity histograms in a very unflexible way...
We need a concept for histograms. This is just a quick creation of an initial class, but is has to be rewritten. The following lines are just a collection of ideas.
A central histogram class is useful for creation of transfer functions and for basic image processing (e.g. histogram equalization).
A histogram class should be
That means a histogram for intensity distibutions is basically the same for all kinds of data. Only the way it is created will differ. To create specific histograms should be the task of the histogram class. That means if a Laplacian weighted histogram is requested the histogram class will ask the volume for intensities and derivatives and create the according statistics. The question is how to apply this to different kinds of geometry (BCC, Rectilinear, ...).
To get started we can assume that all data is unimodal of type 'word'.
Histograms for multimodal data are a different problem. Maybe each type of data (byte, float, vector data) should have an own histogram class, which could maybe derived from a base class.
interface to all volumes
Definition at line 54 of file vuHistogram.h.
|
Definition at line 56 of file vuHistogram.h. |
|
Specialized constructor.
Definition at line 3 of file vuHistogram.cpp. |
Here is the call graph for this function:
|
Destructor.
Definition at line 9 of file vuHistogram.cpp. |
|
Interface to the recorded histogram information.
Definition at line 79 of file vuHistogram.h. |
|
Definition at line 69 of file vuHistogram.h. Referenced by vu11122::createHistogram(), and vu11121::createHistogram(). |
|
Return name of type set.
Definition at line 19 of file vuHistogram.cpp. |
|
This is just a try to implement an intensity histogram creation.
Definition at line 46 of file vuHistogram.cpp. References vuDVector< T >::getLength(), and m_Histogram. Referenced by vu11122::createHistogram(), and vu11121::createHistogram(). |
Here is the call graph for this function:
|
Resets the statistics.
Definition at line 27 of file vuHistogram.cpp. References vuDVector< T >::getLength(), and m_Histogram. Referenced by vu11122::createHistogram(), vu11121::createHistogram(), setType(), and vuHistogram(). |
Here is the call graph for this function:
|
set the initial size of the histogram (256)
Definition at line 34 of file vuHistogram.cpp. References dword, vuDVector< T >::getLength(), m_Histogram, vuDVector< T >::setSize(), and size. |
Here is the call graph for this function:
|
Sets a histogram type.
Definition at line 13 of file vuHistogram.cpp. References m_Type, and reset(). Referenced by vuHistogram(). |
Here is the call graph for this function:
|
Write contents of histogram to a stream.
Definition at line 58 of file vuHistogram.cpp. |
|
Histogram data.
Definition at line 90 of file vuHistogram.h. Referenced by operator<<(), recordIntensity(), reset(), and setSize(). |
|
Type of the Histogram.
Definition at line 92 of file vuHistogram.h. Referenced by setType(). |