ALBA
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
albaGUIHistogramWidget Class Reference

#include <albaGUIHistogramWidget.h>

Inheritance diagram for albaGUIHistogramWidget:
Inheritance graph
[legend]
Collaboration diagram for albaGUIHistogramWidget:
Collaboration graph
[legend]

Public Types

enum  HISTOGRAM_WIDGET_ID {
  ID_LOGSCALE = MINID , ID_NUMBER_OF_BIN , ID_RANGE_SLICER , ID_SLIDER_THRESHOLD ,
  ID_EXPORT_DATA , ID_EXPORT_STATS
}
 

Public Member Functions

 albaGUIHistogramWidget (wxWindow *parent, wxWindowID id=-1, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(400, 300), long style=wxTAB_TRAVERSAL, bool showThresholds=false)
 
virtual ~albaGUIHistogramWidget ()
 
virtual void SetListener (albaObserver *Listener)
 
void OnEvent (albaEventBase *event)
 
 ALBA_ID_DEC (RANGE_MODIFIED)
 
void SetHistogramData (vtkImageData *histogram)
 
void SetData (vtkDataArray *data, albaVME *vme=NULL)
 
void LogarithmicScale (int enable=1)
 
void LogarithmicScaleOn ()
 
void LogarithmicScaleOff ()
 
bool IsLogarithmicScale ()
 
void ShowLines (int value=1)
 
void ShowText (int value=1)
 
void SetLut (vtkLookupTable *lut)
 
albaGUIGetGui ()
 
void GetThresholds (double *lower, double *upper)
 
long int GetHistogramValue (int x, int y)
 
double GetHistogramScalarValue (int x, int y)
 
void UpdateLines (int min, int max)
 
- Public Member Functions inherited from albaGUIPanel
 albaGUIPanel (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name="panel")
 
- Public Member Functions inherited from albaObserver
 albaObserver ()
 
virtual ~albaObserver ()
 
virtual void OnEvent (albaEventBase *e)=0
 

Protected Member Functions

void CreateGui ()
 
void UpdateGui ()
 
void EnableWidgets (bool enable=true)
 

Protected Attributes

albaObserverm_Listener
 
int m_HisctogramValue
 
int m_NumberOfBins
 
int m_LogHistogramFlag
 
double m_Threshold [2]
 
int m_ShowText
 
albaGUIm_Gui
 
albaGUIRangeSliderm_Slider
 
albaGUILutSliderm_SliderThresholds
 
double m_SelectedRange [2]
 
vtkLookupTable * m_Lut
 
vtkDataArray * m_Data
 
albaVMEm_VME
 
albaRWIm_HistogramRWI
 
vtkALBAHistogram * m_Histogram
 
vtkImageData * m_HistogramData
 

Additional Inherited Members

- Public Attributes inherited from albaGUIPanel
albaGUIPanelm_NextPanel
 

Detailed Description

albaGUIHistogramWidget : widget that encapsulate render window into a gui

Definition at line 44 of file albaGUIHistogramWidget.h.

Member Enumeration Documentation

◆ HISTOGRAM_WIDGET_ID

Enumerator
ID_LOGSCALE 
ID_NUMBER_OF_BIN 
ID_RANGE_SLICER 
ID_SLIDER_THRESHOLD 
ID_EXPORT_DATA 
ID_EXPORT_STATS 

Definition at line 61 of file albaGUIHistogramWidget.h.

Constructor & Destructor Documentation

◆ albaGUIHistogramWidget()

albaGUIHistogramWidget::albaGUIHistogramWidget ( wxWindow *  parent,
wxWindowID  id = -1,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxSize(400, 300),
long  style = wxTAB_TRAVERSAL,
bool  showThresholds = false 
)

Constructor.

◆ ~albaGUIHistogramWidget()

virtual albaGUIHistogramWidget::~albaGUIHistogramWidget ( )
virtual

Destructor.

Member Function Documentation

◆ SetListener()

virtual void albaGUIHistogramWidget::SetListener ( albaObserver Listener)
inlinevirtual

Set the listener for the widget.

Definition at line 54 of file albaGUIHistogramWidget.h.

◆ OnEvent()

void albaGUIHistogramWidget::OnEvent ( albaEventBase event)
virtual

Main Event handler.

Implements albaObserver.

◆ ALBA_ID_DEC()

albaGUIHistogramWidget::ALBA_ID_DEC ( RANGE_MODIFIED  )

◆ SetHistogramData()

void albaGUIHistogramWidget::SetHistogramData ( vtkImageData *  histogram)

Set a pre-calculated histogram, just visualize it instead calculate.

It is used like a cache.

◆ SetData()

void albaGUIHistogramWidget::SetData ( vtkDataArray *  data,
albaVME vme = NULL 
)

Input data from which generate histogram.

◆ LogarithmicScale()

void albaGUIHistogramWidget::LogarithmicScale ( int  enable = 1)

Enable/disable logarithmic scale for histogram.

◆ LogarithmicScaleOn()

void albaGUIHistogramWidget::LogarithmicScaleOn ( )
inline

Turn On log scale.

Definition at line 81 of file albaGUIHistogramWidget.h.

◆ LogarithmicScaleOff()

void albaGUIHistogramWidget::LogarithmicScaleOff ( )
inline

Turn Off log scale.

Definition at line 84 of file albaGUIHistogramWidget.h.

◆ IsLogarithmicScale()

bool albaGUIHistogramWidget::IsLogarithmicScale ( )
inline

Return the status of log scale flag.

Definition at line 87 of file albaGUIHistogramWidget.h.

◆ ShowLines()

void albaGUIHistogramWidget::ShowLines ( int  value = 1)

Enable/Disable threshold lines visualization.

◆ ShowText()

void albaGUIHistogramWidget::ShowText ( int  value = 1)
inline

Enable/Disable the visualization of the number of samples in the bin under the mouse cursor.

Definition at line 94 of file albaGUIHistogramWidget.h.

◆ SetLut()

void albaGUIHistogramWidget::SetLut ( vtkLookupTable *  lut)

Set the reference to the lut which range will be adjusted by the slider.

The reference to the Lookup Table should be set before asking for the Histogram's Gui, so the slider to change the lookup table's range will appear on the UI.

◆ GetGui()

albaGUI * albaGUIHistogramWidget::GetGui ( )

Return a reference to the UI.

◆ GetThresholds()

void albaGUIHistogramWidget::GetThresholds ( double *  lower,
double *  upper 
)

Get the threshold of the histogram if setted.

◆ GetHistogramValue()

long int albaGUIHistogramWidget::GetHistogramValue ( int  x,
int  y 
)

◆ GetHistogramScalarValue()

double albaGUIHistogramWidget::GetHistogramScalarValue ( int  x,
int  y 
)

◆ UpdateLines()

void albaGUIHistogramWidget::UpdateLines ( int  min,
int  max 
)

Update position of the gizmo lines.

◆ CreateGui()

void albaGUIHistogramWidget::CreateGui ( )
protected

Create GUI for histogram widget.

◆ UpdateGui()

void albaGUIHistogramWidget::UpdateGui ( )
protected

Update UI parameters according to the vtkALBAHistogram.

◆ EnableWidgets()

void albaGUIHistogramWidget::EnableWidgets ( bool  enable = true)
protected

Enable/disable view widgets.

Member Data Documentation

◆ m_Listener

albaObserver* albaGUIHistogramWidget::m_Listener
protected

Definition at line 126 of file albaGUIHistogramWidget.h.

◆ m_HisctogramValue

int albaGUIHistogramWidget::m_HisctogramValue
protected

Definition at line 127 of file albaGUIHistogramWidget.h.

◆ m_NumberOfBins

int albaGUIHistogramWidget::m_NumberOfBins
protected

Definition at line 128 of file albaGUIHistogramWidget.h.

◆ m_LogHistogramFlag

int albaGUIHistogramWidget::m_LogHistogramFlag
protected

Definition at line 129 of file albaGUIHistogramWidget.h.

◆ m_Threshold

double albaGUIHistogramWidget::m_Threshold[2]
protected

Definition at line 130 of file albaGUIHistogramWidget.h.

◆ m_ShowText

int albaGUIHistogramWidget::m_ShowText
protected

Definition at line 131 of file albaGUIHistogramWidget.h.

◆ m_Gui

albaGUI* albaGUIHistogramWidget::m_Gui
protected

Definition at line 133 of file albaGUIHistogramWidget.h.

◆ m_Slider

albaGUIRangeSlider* albaGUIHistogramWidget::m_Slider
protected

Definition at line 135 of file albaGUIHistogramWidget.h.

◆ m_SliderThresholds

albaGUILutSlider* albaGUIHistogramWidget::m_SliderThresholds
protected

Definition at line 136 of file albaGUIHistogramWidget.h.

◆ m_SelectedRange

double albaGUIHistogramWidget::m_SelectedRange[2]
protected

Definition at line 137 of file albaGUIHistogramWidget.h.

◆ m_Lut

vtkLookupTable* albaGUIHistogramWidget::m_Lut
protected

Definition at line 139 of file albaGUIHistogramWidget.h.

◆ m_Data

vtkDataArray* albaGUIHistogramWidget::m_Data
protected

Definition at line 140 of file albaGUIHistogramWidget.h.

◆ m_VME

albaVME* albaGUIHistogramWidget::m_VME
protected

Definition at line 141 of file albaGUIHistogramWidget.h.

◆ m_HistogramRWI

albaRWI* albaGUIHistogramWidget::m_HistogramRWI
protected

Definition at line 142 of file albaGUIHistogramWidget.h.

◆ m_Histogram

vtkALBAHistogram* albaGUIHistogramWidget::m_Histogram
protected

Definition at line 143 of file albaGUIHistogramWidget.h.

◆ m_HistogramData

vtkImageData* albaGUIHistogramWidget::m_HistogramData
protected

Definition at line 144 of file albaGUIHistogramWidget.h.


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