Isis Developer Reference
Isis::AdvancedStretchDialog Class Reference

Advanced Stretch Dialog. More...

#include <AdvancedStretchDialog.h>

Inheritance diagram for Isis::AdvancedStretchDialog:
Inheritance graph
Collaboration diagram for Isis::AdvancedStretchDialog:
Collaboration graph

Public Slots

void updateStretch (CubeViewport *)
 This calls setStretch on all applicable advanced stretches.
 

Signals

void stretchChanged ()
 Emitted when an advanced stretch has changed.
 
void visibilityChanged ()
 Emitted when this dialog is shown or hidden.
 
void saveToCube ()
 
void deleteFromCube ()
 
void loadStretch ()
 

Public Member Functions

 AdvancedStretchDialog (QWidget *parent)
 This constructs an advanced stretch.
 
 ~AdvancedStretchDialog ()
 This destroys the advanced stretch dialog.
 
void enableRgbMode (Stretch &redStretch, Histogram &redHist, Stretch &grnStretch, Histogram &grnHist, Stretch &bluStretch, Histogram &bluHist)
 This displays RGB advanced stretches.
 
void updateHistograms (const Histogram &redHist, const Histogram &grnHist, const Histogram &bluHist)
 This calls setHistogram on all of the advanced stretches.
 
void updateForRGBMode (Stretch &redStretch, Histogram &redHist, Stretch &grnStretch, Histogram &grnHist, Stretch &bluStretch, Histogram &bluHist)
 Update the stretch and histogram for all the bands for All BandId option.
 
void enableGrayMode (Stretch &grayStretch, Histogram &grayHist)
 This displays a gray advanced stretch.
 
void updateHistogram (const Histogram &grayHist)
 This calls setHistogram on the gray advanced stretches.
 
bool isRgbMode () const
 Returns true if the dialog is displaying the RGB advanced stretches.
 
void restoreGrayStretch (CubeStretch stretch)
 Restores a saved grayscale stretch from the cube.
 
void restoreRgbStretch (CubeStretch red, CubeStretch green, CubeStretch blue)
 Restores a saved RGB stretch from the cube.
 
CubeStretch getGrayStretch ()
 This returns the advanced stretch's stretch for gray.
 
CubeStretch getRedStretch ()
 This returns the advanced stretch's stretch for red.
 
CubeStretch getGrnStretch ()
 This returns the advanced stretch's stretch for green.
 
CubeStretch getBluStretch ()
 This returns the advanced stretch's stretch for blue.
 
bool enabled ()
 Returns true if the advanced stretch is enabled.
 
void enable (bool enable)
 Sets the enabled state to enable.
 

Protected Slots

void showEvent (QShowEvent *)
 This is implemented to send a signal when visibility changes.
 
void hideEvent (QHideEvent *)
 This is implemented to send a signal when visibility changes.
 

Detailed Description

Advanced Stretch Dialog.

Author
2010-05-20 Steven Lambright

Constructor & Destructor Documentation

◆ AdvancedStretchDialog()

Isis::AdvancedStretchDialog::AdvancedStretchDialog ( QWidget * parent)

This constructs an advanced stretch.

Parameters
parentthe parent widget

◆ ~AdvancedStretchDialog()

Isis::AdvancedStretchDialog::~AdvancedStretchDialog ( )

This destroys the advanced stretch dialog.

Member Function Documentation

◆ deleteFromCube

void Isis::AdvancedStretchDialog::deleteFromCube ( )
signal

Referenced by enableGrayMode(), and enableRgbMode().

◆ enable()

void Isis::AdvancedStretchDialog::enable ( bool enable)
inline

Sets the enabled state to enable.

Parameters
enable

References enable().

Referenced by enable(), and Isis::StretchTool::setCubeViewport().

◆ enabled()

bool Isis::AdvancedStretchDialog::enabled ( )
inline

Returns true if the advanced stretch is enabled.

Returns

Referenced by Isis::StretchTool::updateTool().

◆ enableGrayMode()

void Isis::AdvancedStretchDialog::enableGrayMode ( Stretch & grayStretch,
Histogram & grayHist )

This displays a gray advanced stretch.

Parameters
grayStretch
grayHist

References deleteFromCube(), loadStretch(), saveToCube(), and stretchChanged().

Referenced by Isis::StretchTool::setCubeViewport().

◆ enableRgbMode()

void Isis::AdvancedStretchDialog::enableRgbMode ( Stretch & redStretch,
Histogram & redHist,
Stretch & grnStretch,
Histogram & grnHist,
Stretch & bluStretch,
Histogram & bluHist )

This displays RGB advanced stretches.

Parameters
redStretch
redHist
grnStretch
grnHist
bluStretch
bluHist

References deleteFromCube(), loadStretch(), saveToCube(), and stretchChanged().

Referenced by Isis::StretchTool::setCubeViewport().

◆ getBluStretch()

CubeStretch Isis::AdvancedStretchDialog::getBluStretch ( )

This returns the advanced stretch's stretch for blue.

Returns
Stretch

References _FILEINFO_, Isis::AdvancedStretch::getStretch(), and Isis::IException::Programmer.

Referenced by Isis::StretchTool::saveStretchToCube().

◆ getGrayStretch()

CubeStretch Isis::AdvancedStretchDialog::getGrayStretch ( )

This returns the advanced stretch's stretch for gray.

Returns
Stretch

References _FILEINFO_, Isis::AdvancedStretch::getStretch(), and Isis::IException::Programmer.

Referenced by Isis::StretchTool::saveStretchToCube().

◆ getGrnStretch()

CubeStretch Isis::AdvancedStretchDialog::getGrnStretch ( )

This returns the advanced stretch's stretch for green.

Returns
Stretch

References _FILEINFO_, Isis::AdvancedStretch::getStretch(), and Isis::IException::Programmer.

Referenced by Isis::StretchTool::saveStretchToCube().

◆ getRedStretch()

CubeStretch Isis::AdvancedStretchDialog::getRedStretch ( )

This returns the advanced stretch's stretch for red.

Returns
Stretch

References _FILEINFO_, Isis::AdvancedStretch::getStretch(), and Isis::IException::Programmer.

Referenced by Isis::StretchTool::saveStretchToCube().

◆ hideEvent

void Isis::AdvancedStretchDialog::hideEvent ( QHideEvent * event)
protectedslot

This is implemented to send a signal when visibility changes.

Parameters
event

References visibilityChanged().

◆ isRgbMode()

bool Isis::AdvancedStretchDialog::isRgbMode ( ) const

Returns true if the dialog is displaying the RGB advanced stretches.

Returns
bool

Referenced by restoreRgbStretch(), Isis::StretchTool::updateHistograms(), and Isis::StretchTool::updateTool().

◆ loadStretch

void Isis::AdvancedStretchDialog::loadStretch ( )
signal

Referenced by enableGrayMode(), and enableRgbMode().

◆ restoreGrayStretch()

void Isis::AdvancedStretchDialog::restoreGrayStretch ( CubeStretch stretch)

Restores a saved grayscale stretch from the cube.

Parameters
stretch

References _FILEINFO_, Isis::IException::Programmer, and Isis::AdvancedStretch::restoreSavedStretch().

Referenced by Isis::StretchTool::loadStretchFromCube().

◆ restoreRgbStretch()

void Isis::AdvancedStretchDialog::restoreRgbStretch ( CubeStretch red,
CubeStretch green,
CubeStretch blue )

Restores a saved RGB stretch from the cube.

Parameters
red
green
blue

References _FILEINFO_, isRgbMode(), Isis::IException::Programmer, and Isis::AdvancedStretch::restoreSavedStretch().

Referenced by Isis::StretchTool::loadStretchFromCube().

◆ saveToCube

void Isis::AdvancedStretchDialog::saveToCube ( )
signal

Referenced by enableGrayMode(), and enableRgbMode().

◆ showEvent

void Isis::AdvancedStretchDialog::showEvent ( QShowEvent * event)
protectedslot

This is implemented to send a signal when visibility changes.

Parameters
event

References visibilityChanged().

◆ stretchChanged

void Isis::AdvancedStretchDialog::stretchChanged ( )
signal

Emitted when an advanced stretch has changed.

Referenced by enableGrayMode(), and enableRgbMode().

◆ updateForRGBMode()

void Isis::AdvancedStretchDialog::updateForRGBMode ( Stretch & redStretch,
Histogram & redHist,
Stretch & grnStretch,
Histogram & grnHist,
Stretch & bluStretch,
Histogram & bluHist )

Update the stretch and histogram for all the bands for All BandId option.

Author
Sharmila Prasad (3/14/2011)
Parameters
redStretch- Updated Red Stretch
redHist- Updated Red Histogram
grnStretch- Updated Green Stretch
grnHist- Updated Green Histogram
bluStretch- Updated Blue Stretch
bluHist- Updated Blue Histogram

References Isis::AdvancedStretch::setHistogram(), and Isis::AdvancedStretch::setStretch().

Referenced by Isis::StretchTool::updateAdvStretchDialogforAll().

◆ updateHistogram()

void Isis::AdvancedStretchDialog::updateHistogram ( const Histogram & grayHist)

This calls setHistogram on the gray advanced stretches.

This should be called every time the visible area changes.

Parameters
grayHistHistogram of visible area on gray band

References Isis::AdvancedStretch::setHistogram().

Referenced by Isis::StretchTool::updateHistograms().

◆ updateHistograms()

void Isis::AdvancedStretchDialog::updateHistograms ( const Histogram & redHist,
const Histogram & grnHist,
const Histogram & bluHist )

This calls setHistogram on all of the advanced stretches.

This should be called every time the visible area changes.

Parameters
redHistHistogram of visible area on red band
grnHistHistogram of visible area on green band
bluHistHistogram of visible area on blue band

References Isis::AdvancedStretch::setHistogram().

Referenced by Isis::StretchTool::updateHistograms().

◆ updateStretch

void Isis::AdvancedStretchDialog::updateStretch ( CubeViewport * cvp)
slot

This calls setStretch on all applicable advanced stretches.

This should be called any time the cube viewport changes.

Parameters
cvp

References Isis::AdvancedStretch::setStretch().

◆ visibilityChanged

void Isis::AdvancedStretchDialog::visibilityChanged ( )
signal

Emitted when this dialog is shown or hidden.

Referenced by hideEvent(), and showEvent().


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