Isis Developer Reference
HistogramTool.h
Go to the documentation of this file.
1 #ifndef HistogramTool_h
2 #define HistogramTool_h
3 
4 #include "AbstractPlotTool.h"
5 
6 class QAction;
7 class QWidget;
8 
9 
10 namespace Isis {
11  class Brick;
12  class CubePlotCurve;
13  class HistogramItem;
14  class HistogramToolWindow;
15  class MdiCubeViewport;
16 
41  Q_OBJECT
42 
43  public:
44  HistogramTool(QWidget *parent);
45 
46  protected:
47  QWidget *createToolBarWidget(QStackedWidget *parent);
48  void detachCurves();
50  void enableRubberBandTool();
52  void updateTool();
53 
54  protected slots:
55  void rubberBandComplete();
56 
57  public slots:
58  void refreshPlot();
59 
60  private:
61  void validatePlotCurves();
62 
63  HistogramToolWindow *m_histToolWindow;
64 
66  QPointer<HistogramItem> m_frequencyItem;
68  QPointer<CubePlotCurve> m_percentageCurve;
70  QAction *m_action;
72  QPointer<RubberBandComboBox> m_rubberBandCombo;
73  };
74 };
75 
76 #endif
Isis::Brick::SetBasePosition
void SetBasePosition(const int start_sample, const int start_line, const int start_band)
This method is used to set the base position of the shape buffer.
Definition: Brick.h:120
Isis::AbstractPlotTool::updateTool
virtual void updateTool()
This forwards all update calls to the plot windows.
Definition: AbstractPlotTool.cpp:118
Isis::HistogramTool::HistogramTool
HistogramTool(QWidget *parent)
Constructor creates a new HistogramTool object.
Definition: HistogramTool.cpp:31
CubePlotCurve.h
Isis::MdiCubeViewport
Cube display widget for certain Isis MDI applications.
Definition: MdiCubeViewport.h:39
QWidget
Isis::PlotCurve::CubeDN
@ CubeDN
The data is a Cube DN value.
Definition: PlotCurve.h:67
Isis::RubberBandComboBox
Combo box for choosing a rubber band type.
Definition: RubberBandComboBox.h:26
MdiCubeViewport.h
Isis::ImageHistogram::AddData
virtual void AddData(const double *data, const unsigned int count)
Add an array of doubles to the histogram counters.
Definition: ImageHistogram.cpp:228
Isis::RubberBandTool::setDrawActiveViewportOnly
void setDrawActiveViewportOnly(bool activeOnly=false)
This called to set whether rubber band is drawn on active viewport only rather than all linked viewpo...
Definition: RubberBandTool.cpp:333
Isis::RubberBandTool::RectangleMode
@ RectangleMode
Definition: RubberBandTool.h:62
HistogramTool.h
Isis::AbstractPlotTool::createCurve
static CubePlotCurve * createCurve(QString name, QPen pen, PlotCurve::Units xUnits, PlotCurve::Units yUnits)
This is a helper method for children.
Definition: AbstractPlotTool.cpp:233
QList< QPoint >
Histogram.h
Isis::HistogramPlotWindow::add
void add(HistogramItem *)
Add a HistogramItem to the plot.
Definition: HistogramPlotWindow.cpp:60
Isis::RubberBandTool::CircleMode
@ CircleMode
Definition: RubberBandTool.h:59
Isis::Cube::read
void read(Blob &blob, const std::vector< PvlKeyword > keywords=std::vector< PvlKeyword >()) const
This method will read data from the specified Blob object.
Definition: Cube.cpp:807
Isis::Histogram::BinSize
double BinSize() const
Returns the size of an individual bin.
Definition: Histogram.cpp:470
Isis::Buffer::DoubleBuffer
double * DoubleBuffer() const
Returns the value of the shape buffer.
Definition: Buffer.h:138
Isis::HistogramPlotWindow
Definition: HistogramPlotWindow.h:16
Isis::Tool::toolIconDir
QString toolIconDir() const
returns the path to the icon directory.
Definition: Tool.h:113
Isis::Statistics::Maximum
double Maximum() const
Returns the absolute maximum double found in all data passed through the AddData method.
Definition: Statistics.cpp:403
Isis::Histogram::BinMiddle
double BinMiddle(const int index) const
Returns the value represented by a bin.
Definition: Histogram.cpp:449
Isis::Tool::rubberBandTool
RubberBandTool * rubberBandTool()
Definition: Tool.cpp:57
Isis::Histogram::Skew
double Skew() const
Computes and returns the skew.
Definition: Histogram.cpp:384
Isis::RubberBandTool::currentMode
RubberBandMode currentMode()
Definition: RubberBandTool.cpp:1161
Isis::RubberBandComboBox::Line
@ Line
Line.
Definition: RubberBandComboBox.h:42
Isis::globalFactory
static geos::geom::GeometryFactory::Ptr globalFactory
Definition: PolygonTools.h:51
Isis::RubberBandComboBox::Rectangle
@ Rectangle
Rectangle.
Definition: RubberBandComboBox.h:39
Isis::HistogramTool::toolPadAction
QAction * toolPadAction(ToolPad *pad)
This method adds the histogram tool to the tool pad.
Definition: HistogramTool.cpp:60
Isis::PlotWindow::defaultWindowTitle
static QString defaultWindowTitle()
This is the typical suffix for plot windows, it's here in case we want to update all plot windows to ...
Definition: PlotWindow.cpp:1810
Isis::AbstractPlotTool::selectedWindow
PlotWindow * selectedWindow(bool createIfNeeded=true)
Get the 'active' plot window (the window selected by the user to contain new curves).
Definition: AbstractPlotTool.cpp:256
Isis::Statistics::ValidPixels
BigInt ValidPixels() const
Returns the total number of valid pixels processed.
Definition: Statistics.cpp:433
ToolPad.h
AbstractPlotTool.h
Isis::Brick
Buffer for containing a three dimensional section of an image.
Definition: Brick.h:45
Isis::HistogramTool::updateTool
void updateTool()
This method updates the histogram tool.
Definition: HistogramTool.cpp:118
Isis::HistogramItem
This is the (qwt) plot item for a histogram.
Definition: HistogramItem.h:24
Isis::Histogram::BinCount
BigInt BinCount(const int index) const
Returns the count at a bin position in the histogram.
Definition: Histogram.cpp:403
Isis::Statistics::Variance
double Variance() const
Computes and returns the variance.
Definition: Statistics.cpp:328
HistogramItem.h
Isis::CubeViewport::cubeToViewport
void cubeToViewport(double sample, double line, int &x, int &y) const
Turns a cube into a viewport.
Definition: CubeViewport.cpp:852
Isis::CubeViewport::grayBand
int grayBand() const
Definition: CubeViewport.h:194
Isis::HistogramTool::createToolBarWidget
QWidget * createToolBarWidget(QStackedWidget *parent)
This method creates the widgets for the tool bar.
Definition: HistogramTool.cpp:82
Isis::PlotCurve::Percentage
@ Percentage
The data is a percentage (0-100).
Definition: PlotCurve.h:75
Isis::HistogramTool::rubberBandComplete
void rubberBandComplete()
Called when the user has finished drawing with the rubber band.
Definition: HistogramTool.cpp:141
Isis::Statistics::StandardDeviation
double StandardDeviation() const
Computes and returns the standard deviation.
Definition: Statistics.cpp:312
Isis::Statistics::Minimum
double Minimum() const
Returns the absolute minimum double found in all data passed through the AddData method.
Definition: Statistics.cpp:382
Isis::Histogram::Mode
double Mode() const
Returns the mode.
Definition: Histogram.cpp:328
ImageHistogram.h
Isis::ImageHistogram
Container of a cube histogram.
Definition: ImageHistogram.h:40
Isis::HistogramTool::createWindow
PlotWindow * createWindow()
This method creates the default histogram plot window.
Definition: HistogramTool.cpp:127
Isis::HistogramTool::detachCurves
void detachCurves()
Forget the frequency histogram item and the percentage curve.
Definition: HistogramTool.cpp:108
Isis::Cube
IO Handler for Isis Cubes.
Definition: Cube.h:167
Isis::AbstractPlotTool
Parent class for plotting tools which provides common functionality.
Definition: AbstractPlotTool.h:43
round
#define round(x)
This is free and unencumbered software released into the public domain.
Definition: ViewportBuffer.cpp:29
Isis::HistogramPlotWindow::getDockWidget
QDockWidget * getDockWidget()
Definition: HistogramPlotWindow.h:33
Isis::Statistics::Average
double Average() const
Computes and returns the average.
Definition: Statistics.cpp:300
HistogramPlotWindow.h
Brick.h
Isis::ToolPad
Definition: ToolPad.h:14
Isis::Histogram::Bins
int Bins() const
Returns the number of bins in the histogram.
Definition: Histogram.cpp:483
Isis::Histogram::Median
double Median() const
Returns the median.
Definition: Histogram.cpp:319
Isis::RubberBandTool::geometry
geos::geom::Geometry * geometry()
Definition: RubberBandTool.cpp:823
Isis::HistogramTool
Tool for histograms.
Definition: HistogramTool.h:40
Isis::CubeViewport::viewportToCube
void viewportToCube(int x, int y, double &sample, double &line) const
Turns a viewport into a cube.
Definition: CubeViewport.cpp:815
Isis::RubberBandTool::LineMode
@ LineMode
Definition: RubberBandTool.h:61
PolygonTools.h
QVector
This is free and unencumbered software released into the public domain.
Definition: Calculator.h:18
Isis::PlotWindow::replot
void replot()
Reset the scale of the plot, replot it and emit plot changed.
Definition: PlotWindow.cpp:1797
Isis::HistogramTool::refreshPlot
void refreshPlot()
This method plots the selected data in a histogram window.
Definition: HistogramTool.cpp:167
Isis::PlotWindow
Definition: PlotWindow.h:88
Isis::HistogramTool::enableRubberBandTool
void enableRubberBandTool()
This method is called when the tool is activated by the parent, or when the plot mode is changed.
Definition: HistogramTool.cpp:45
QAction
Isis::CubeViewport::cube
Cube * cube() const
Definition: CubeViewport.h:338
Isis::AbstractPlotTool::createToolBarWidget
QWidget * createToolBarWidget(QStackedWidget *parent)
This provides the standard plot tool options, such as selecting an active plot window.
Definition: AbstractPlotTool.cpp:103
Isis::Tool::cubeViewport
MdiCubeViewport * cubeViewport() const
Return the current cubeviewport.
Definition: Tool.h:197
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
RubberBandComboBox.h
Isis::RubberBandTool::vertices
QList< QPoint > vertices()
This method returns the vertices.
Definition: RubberBandTool.cpp:672