A QGLWidget that displays a Transfer Function Editor, or an Iso Selection Window.
More...
#include <mappingframe.h>
A QGLWidget that displays a Transfer Function Editor, or an Iso Selection Window.
- Author
- Alan Norton
- Version
- 3.0
- Date
- May 2015 The MappingFrame is a QGLWidget that can be used to map colors and/or opacity from a 1D interval. The MappingFrame can be inserted in the VAPOR tabs using QDesigner. Several Signal/Slot connections must be implemented to support editing functionality.
Definition at line 76 of file mappingframe.h.
MappingFrame::MappingFrame |
( |
QWidget * |
parent, |
|
|
const char * |
name = 0 |
|
) |
| |
virtual MappingFrame::~MappingFrame |
( |
| ) |
|
|
virtual |
void MappingFrame::endChange |
( |
| ) |
|
|
signal |
Signal that is invoked when user ends modifying the transfer function. This should be connected to a slot in the EventRouter that completes and saves the Command that is used for saving the edit changes in the Command queue.
void MappingFrame::hookup |
( |
EventRouter * |
evrouter, |
|
|
QPushButton * |
editButton, |
|
|
QPushButton * |
ZoomPan, |
|
|
QPushButton * |
fitToView, |
|
|
QPushButton * |
histoButton, |
|
|
QPushButton * |
fitData, |
|
|
QPushButton * |
bindColorToOpac, |
|
|
QPushButton * |
bindOpacToColor, |
|
|
QSlider * |
opacityScaleSlider |
|
) |
| |
Method required to establish a connection between the EventRouter that contains a transfer function editor, (or an IsoControl) and the MappingFrame that provides the editing functionality. This method should be invoked in the method EventRouter::hookupTab()
- Parameters
-
[in] | evrouter | The EventRouter associated with this MappingFrame |
[in] | editButton | The QPushButton that enables Edit mode |
[in] | ZoomPan | QPushButton that enables zoom/pan (navigate) mode. |
[in] | histoButton | QPushButton that refreshes the histogram. |
[in] | fitData | QPushButton that fits the bounds to the data |
[in] | bindColorToOpac | QPushButton that binds the selected color control point to selected opacity control point. |
[in] | bindOpacToColor | QPushButton that binds the selected opacity control point to the selected color control point. |
[in] | opacityScaleSlider | QSlider that controls the opacity scale |
MapperFunction* MappingFrame::mapperFunction |
( |
| ) |
|
|
inline |
void MappingFrame::mappingChanged |
( |
| ) |
|
|
signal |
Signal indicates that the mapping function has changed, update the visualizer on this signal if you want transfer function edits visualized in real-time
float MappingFrame::maxDataValue |
( |
| ) |
|
|
inline |
float MappingFrame::minDataValue |
( |
| ) |
|
|
inline |
void MappingFrame::setColorMapping |
( |
bool |
flag | ) |
|
Enable or disable the color mapping in the Transfer Function. Should be specified in the EventRouter constructor
- Parameters
-
[in] | flag | set true if color mapping will be enabled. |
void MappingFrame::setIsolineSliders |
( |
bool |
flag | ) |
|
|
inline |
Enable or disable the use of multiple iso sliders in an IsoControl editor Should be specified in the EventRouter constructor
- Parameters
-
[in] | flag | set true if multiple iso Sliders will be enabled. |
Definition at line 141 of file mappingframe.h.
void MappingFrame::setIsolineSliders |
( |
const vector< double > & |
slidervals | ) |
|
Specify the set of values that will be associated with multiple Iso Sliders Should be specified whenever the Isovalues are changed.
- Parameters
-
[in] | slidervals | is a vector of iso values |
void MappingFrame::setIsoSlider |
( |
bool |
flag | ) |
|
|
inline |
Enable or disable the use of a single iso slider in an IsoControl editor Should be specified in the EventRouter constructor
- Parameters
-
[in] | flag | set true if one iso Slider will be enabled. |
Definition at line 136 of file mappingframe.h.
void MappingFrame::setMapperFunction |
( |
MapperFunction * |
mapper | ) |
|
Specify the MapperFunction that is associated with this MappingFrame. This is invoked in EventRouter::setEditorDirty()
- Parameters
-
[in] | mapper | MapperFunction to be associated with this MappingFrame |
void MappingFrame::setOpacityMapping |
( |
bool |
flag | ) |
|
Enable or disable the opacity mapping in the Transfer Function. Should be specified in the EventRouter constructor
- Parameters
-
[in] | flag | set true if opacity mapping will be enabled. |
void MappingFrame::setVariableName |
( |
std::string |
name | ) |
|
Specify the variable associated with the MappingFrame. Invoked in EventRouter::setEditorDirty()
void MappingFrame::startChange |
( |
QString |
description | ) |
|
|
signal |
Signal that is invoked when user starts to modify the transfer function. This should be connected to a slot in the EventRouter that creates a Command that will be used for putting the edit changes into the Command queue.
- Parameters
-
[in] | description | of the change that is occurring |
void MappingFrame::update |
( |
| ) |
|
|
inline |
void MappingFrame::updateParams |
( |
| ) |
|
Synchronize the MappingFrame with the underlying RenderParams. Invoked in EventRouter::setEditorDirty().
Update the display of the Transfer Function or IsoControl based on the current RenderParams that contains the MapperFunction being used. This should be invoked in EventRouter::updateTab()
- Parameters
-
[in] | rp | RenderParams* that contains the Transfer Function or IsoControl |
bool MappingFrame::colorMapping |
|
readwrite |
bool MappingFrame::opacityMapping |
|
readwrite |
The documentation for this class was generated from the following file: