Computer Assited Medical Intervention Tool Kit  version 5.0
VolumeRenderingWidget Class Reference

The widget allows the user to select the desired parameter for the transfer function. More...

#include <VolumeRenderingWidget.h>

+ Inheritance diagram for VolumeRenderingWidget:
+ Collaboration diagram for VolumeRenderingWidget:

Public Slots

virtual void addColor ()
 Color. More...
 
virtual void addGradientOpacity ()
 Gradient Opacity. More...
 
virtual void addTransparency ()
 Transparency. More...
 
virtual void ambientLightSliderChanged (int)
 ambient Light Value Editing More...
 
virtual void ambientLightSpinBoxChanged (double)
 
virtual void diffuseLightSliderChanged (int)
 Diffuse Light Value Editing. More...
 
virtual void diffuseLightSpinBoxChanged (double)
 
virtual void loadColorMap ()
 Load / Save / Reset colormaps. More...
 
virtual void refreshVolumeRendering ()
 When to change volume rendering. More...
 
virtual void resetColorMap ()
 
virtual void saveColorMap ()
 
virtual void specularLightSliderChanged (int)
 Specular Light Value Editing. More...
 
virtual void specularLightSpinBoxChanged (double)
 
virtual void visibilityToggled (bool)
 

Signals

void refresh ()
 emitted when the user clicked on the Refresh button More...
 

Public Member Functions

void addColor (int grayLevel, QColor color)
 
void addGradientOpacity (int grayLevel, double opacity)
 
void addTransparency (int grayLevel, double transparency)
 
double getAmbient ()
 
QMap< int, QColor > getColorPoints ()
 
double getDiffuse ()
 
QMap< int, double > getOpacityPoints ()
 
double getSpecular ()
 
QMap< int, double > getTransparencyPoints ()
 
void load (QString filename)
 
void removeColorPoint (ColorPointWidget *point)
 
void removeOpacityPoint (GradientOpacityWidget *point)
 
void removeTransparencyPoint (TransparencyPointWidget *point)
 
void setAmbient (double ambient)
 
void setDefaultColors (QMap< int, QColor > defaultColors)
 
void setDefaultOpacities (QMap< int, double > defaultOpacities)
 
void setDefaultTransparencies (QMap< int, double > defaultTransparencies)
 
void setDiffuse (double diffuse)
 
void setSpecular (double specular)
 
void updateUI (QString name, bool existVR)
 update the UI using the given name (current image name) and its visibility existVR should be true if the volume rendering component of the image was alread created using a colormap visibility is given by the action's proprety More...
 
bool visibility ()
 get the current visibility value More...
 
 VolumeRenderingWidget (VolumeRenderingAction *myAction, QWidget *parent=nullptr)
 Default construtor. More...
 
 ~VolumeRenderingWidget () override
 

Private Attributes

QList< ColorPointWidget * > colorPoints
 
QList< GradientOpacityWidget * > gradientOpacities
 
VolumeRenderingActionmyAction
 
QList< TransparencyPointWidget * > transparencies
 
Ui_VolumeRenderingWidget ui
 

Detailed Description

The widget allows the user to select the desired parameter for the transfer function.

The transfer function allows one to select the desired (R,G,B,alpha) values of the rendered 3D image.

The transfer function widget.

Constructor & Destructor Documentation

◆ VolumeRenderingWidget()

VolumeRenderingWidget::VolumeRenderingWidget ( VolumeRenderingAction myAction,
QWidget *  parent = nullptr 
)

Default construtor.

References myAction, and ui.

◆ ~VolumeRenderingWidget()

VolumeRenderingWidget::~VolumeRenderingWidget ( )
override

Member Function Documentation

◆ addColor [1/2]

void VolumeRenderingWidget::addColor ( )
virtualslot

Color.

References colorPoints, and ui.

Referenced by setDefaultColors().

+ Here is the caller graph for this function:

◆ addColor() [2/2]

void VolumeRenderingWidget::addColor ( int  grayLevel,
QColor  color 
)

References colorPoints, and ui.

◆ addGradientOpacity [1/2]

void VolumeRenderingWidget::addGradientOpacity ( )
virtualslot

Gradient Opacity.

References gradientOpacities, and ui.

Referenced by setDefaultOpacities().

+ Here is the caller graph for this function:

◆ addGradientOpacity() [2/2]

void VolumeRenderingWidget::addGradientOpacity ( int  grayLevel,
double  opacity 
)

References gradientOpacities, and ui.

◆ addTransparency [1/2]

void VolumeRenderingWidget::addTransparency ( )
virtualslot

Transparency.

References transparencies, and ui.

Referenced by setDefaultTransparencies().

+ Here is the caller graph for this function:

◆ addTransparency() [2/2]

void VolumeRenderingWidget::addTransparency ( int  grayLevel,
double  transparency 
)

References transparencies, and ui.

◆ ambientLightSliderChanged

void VolumeRenderingWidget::ambientLightSliderChanged ( int  value)
virtualslot

ambient Light Value Editing

References ui.

◆ ambientLightSpinBoxChanged

void VolumeRenderingWidget::ambientLightSpinBoxChanged ( double  value)
virtualslot

References ui.

◆ diffuseLightSliderChanged

void VolumeRenderingWidget::diffuseLightSliderChanged ( int  value)
virtualslot

Diffuse Light Value Editing.

References ui.

◆ diffuseLightSpinBoxChanged

void VolumeRenderingWidget::diffuseLightSpinBoxChanged ( double  value)
virtualslot

References ui.

◆ getAmbient()

double VolumeRenderingWidget::getAmbient ( )

References ui.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ getColorPoints()

QMap< int, QColor > VolumeRenderingWidget::getColorPoints ( )

References colorPoints.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ getDiffuse()

double VolumeRenderingWidget::getDiffuse ( )

References ui.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ getOpacityPoints()

QMap< int, double > VolumeRenderingWidget::getOpacityPoints ( )

References gradientOpacities.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ getSpecular()

double VolumeRenderingWidget::getSpecular ( )

References ui.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ getTransparencyPoints()

QMap< int, double > VolumeRenderingWidget::getTransparencyPoints ( )

References transparencies.

Referenced by VolumeRenderingAction::createVolumeRendering().

+ Here is the caller graph for this function:

◆ load()

void VolumeRenderingWidget::load ( QString  filename)

References CAMITK_ERROR, myAction, setDefaultColors(), setDefaultOpacities(), setDefaultTransparencies(), and ui.

Referenced by loadColorMap(), and resetColorMap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ loadColorMap

void VolumeRenderingWidget::loadColorMap ( )
virtualslot

Load / Save / Reset colormaps.

References load().

+ Here is the call graph for this function:

◆ refresh

void VolumeRenderingWidget::refresh ( )
signal

emitted when the user clicked on the Refresh button

Referenced by refreshVolumeRendering().

+ Here is the caller graph for this function:

◆ refreshVolumeRendering

void VolumeRenderingWidget::refreshVolumeRendering ( )
virtualslot

When to change volume rendering.

References refresh().

◆ removeColorPoint()

void VolumeRenderingWidget::removeColorPoint ( ColorPointWidget point)

References colorPoints, and ui.

Referenced by ColorPointWidget::remove().

+ Here is the caller graph for this function:

◆ removeOpacityPoint()

void VolumeRenderingWidget::removeOpacityPoint ( GradientOpacityWidget point)

References gradientOpacities, and ui.

Referenced by GradientOpacityWidget::remove().

+ Here is the caller graph for this function:

◆ removeTransparencyPoint()

void VolumeRenderingWidget::removeTransparencyPoint ( TransparencyPointWidget point)

References transparencies, and ui.

Referenced by TransparencyPointWidget::remove().

+ Here is the caller graph for this function:

◆ resetColorMap

void VolumeRenderingWidget::resetColorMap ( )
virtualslot

References load(), and myAction.

Referenced by updateUI().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ saveColorMap

void VolumeRenderingWidget::saveColorMap ( )
virtualslot

◆ setAmbient()

void VolumeRenderingWidget::setAmbient ( double  ambient)

References ui.

◆ setDefaultColors()

void VolumeRenderingWidget::setDefaultColors ( QMap< int, QColor >  defaultColors)

References addColor(), colorPoints, and ui.

Referenced by load().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setDefaultOpacities()

void VolumeRenderingWidget::setDefaultOpacities ( QMap< int, double >  defaultOpacities)

References addGradientOpacity(), gradientOpacities, and ui.

Referenced by load().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setDefaultTransparencies()

void VolumeRenderingWidget::setDefaultTransparencies ( QMap< int, double >  defaultTransparencies)

References addTransparency(), transparencies, and ui.

Referenced by load().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setDiffuse()

void VolumeRenderingWidget::setDiffuse ( double  diffuse)

References ui.

◆ setSpecular()

void VolumeRenderingWidget::setSpecular ( double  specular)

References ui.

◆ specularLightSliderChanged

void VolumeRenderingWidget::specularLightSliderChanged ( int  value)
virtualslot

Specular Light Value Editing.

References ui.

◆ specularLightSpinBoxChanged

void VolumeRenderingWidget::specularLightSpinBoxChanged ( double  value)
virtualslot

References ui.

◆ updateUI()

void VolumeRenderingWidget::updateUI ( QString  name,
bool  existVR 
)

update the UI using the given name (current image name) and its visibility existVR should be true if the volume rendering component of the image was alread created using a colormap visibility is given by the action's proprety

References myAction, resetColorMap(), and ui.

Referenced by VolumeRenderingAction::getWidget().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ visibility()

bool VolumeRenderingWidget::visibility ( )

get the current visibility value

Referenced by visibilityToggled().

+ Here is the caller graph for this function:

◆ visibilityToggled

void VolumeRenderingWidget::visibilityToggled ( bool  visibility)
virtualslot

References myAction, and visibility().

+ Here is the call graph for this function:

Member Data Documentation

◆ colorPoints

QList<ColorPointWidget*> VolumeRenderingWidget::colorPoints
private

◆ gradientOpacities

◆ myAction

VolumeRenderingAction* VolumeRenderingWidget::myAction
private

◆ transparencies

◆ ui


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