Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
qMRMLThreeDView Class Reference

3D view for view nodes. For performance reasons, the view block refreshes when the scene is in batch process state. More...

#include <Libs/MRML/Widgets/qMRMLThreeDView.h>

Inheritance diagram for qMRMLThreeDView:
Collaboration diagram for qMRMLThreeDView:

Public Types

typedef ctkVTKRenderView Superclass
 Superclass typedef.
 

Properties

double ambientShadowsIntensityScale
 
double ambientShadowsIntensityShift
 
double ambientShadowsSizeScale
 
double ambientShadowsVolumeOpacityThreshold
 Volume rendering opacity above this value will cast shadows.
 
bool shadowsVisibility
 

Public Slots

void lookFromViewAxis (const ctkAxesWidget::Axis &axis)
 
void setMRMLScene (vtkMRMLScene *newScene)
 
void setMRMLViewNode (vtkMRMLViewNode *newViewNode)
 Set the current viewNode to observe.
 

Public Member Functions

void addDisplayableManager (const QString &displayableManager)
 
double ambientShadowsIntensityScale () const
 
double ambientShadowsIntensityShift () const
 
double ambientShadowsSizeScale () const
 
double ambientShadowsVolumeOpacityThreshold () const
 
Q_INVOKABLE vtkMRMLCameraNodecameraNode ()
 Returns camera node of the 3D view.
 
Q_INVOKABLE vtkMRMLAbstractDisplayableManagerdisplayableManagerByClassName (const char *className)
 Return a DisplayableManager given its class name.
 
void dragEnterEvent (QDragEnterEvent *event) override
 
void dropEvent (QDropEvent *event) override
 
Q_INVOKABLE void getDisplayableManagers (vtkCollection *displayableManagers)
 
Q_INVOKABLE vtkMRMLThreeDViewInteractorStyleinteractorObserver () const
 Returns the interactor observer of the view.
 
Q_INVOKABLE vtkMRMLViewNodemrmlViewNode () const
 Get the 3D View node observed by view.
 
 qMRMLThreeDView (QWidget *parent=nullptr)
 Constructors.
 
Q_INVOKABLE void resetCamera (bool resetRotation=true, bool resetTranslation=true, bool resetDistance=true)
 
virtual void resetFocalPoint ()
 
Q_INVOKABLE void rotateToViewAxis (const std::string &axisLabel)
 
Q_INVOKABLE void rotateToViewAxis (unsigned int axisId)
 
void setAmbientShadowsIntensityScale (double)
 
void setAmbientShadowsIntensityShift (double)
 
void setAmbientShadowsSizeScale (double)
 
void setAmbientShadowsVolumeOpacityThreshold (double)
 
Q_INVOKABLE void setDefaultViewCursor (const QCursor &cursor)
 Set default cursor in the view area.
 
void setInteractor (vtkRenderWindowInteractor *interactor) override
 Sets the interactor of the view.
 
void setShadowsVisibility (bool)
 
Q_INVOKABLE void setViewCursor (const QCursor &)
 Set cursor in the view area.
 
bool shadowsVisibility () const
 
Q_INVOKABLE vtkSSAOPass * ssaoPass () const
 
Q_INVOKABLE void unsetViewCursor ()
 Restore default cursor in the view area.
 
 ~qMRMLThreeDView () override
 

Detailed Description

3D view for view nodes. For performance reasons, the view block refreshes when the scene is in batch process state.

See also
qMRMLThreeDWidget, qMRMLThreeDViewControllerWidget, qMRMLSliceView

Definition at line 44 of file qMRMLThreeDView.h.

Member Typedef Documentation

◆ Superclass

typedef ctkVTKRenderView qMRMLThreeDView::Superclass

Superclass typedef.

Definition at line 66 of file qMRMLThreeDView.h.

Property Documentation

◆ ambientShadowsIntensityScale

double qMRMLThreeDView::ambientShadowsIntensityScale
readwrite

Ambient shadows intensity scale. Default is 1.0, larger value means stronger darkening.

Definition at line 59 of file qMRMLThreeDView.h.

◆ ambientShadowsIntensityShift

double qMRMLThreeDView::ambientShadowsIntensityShift
readwrite

Ambient shadows intensity shift. Default is 0.0, larger value means darkening is only visible where occlusion is stronger.

Definition at line 62 of file qMRMLThreeDView.h.

◆ ambientShadowsSizeScale

double qMRMLThreeDView::ambientShadowsSizeScale
readwrite

Ambient shadows size scale. Specifies size of features to be emphasized by shadows.The scale is logarithmic, default (0.0) corresponds to object size of about 100 (in scene physical units).

Definition at line 54 of file qMRMLThreeDView.h.

◆ ambientShadowsVolumeOpacityThreshold

double qMRMLThreeDView::ambientShadowsVolumeOpacityThreshold
readwrite

Volume rendering opacity above this value will cast shadows.

Definition at line 56 of file qMRMLThreeDView.h.

◆ shadowsVisibility

bool qMRMLThreeDView::shadowsVisibility
readwrite

Show shadows to improve depth perception. Currently, only ambient shadows (screen-space ambient occlusion) method is supported and AmbientShadowsSizeScale and AmbientShadowsVolumeOpacityThreshold parameters control its appearance.

Definition at line 50 of file qMRMLThreeDView.h.

Constructor & Destructor Documentation

◆ qMRMLThreeDView()

qMRMLThreeDView::qMRMLThreeDView ( QWidget * parent = nullptr)
explicit

Constructors.

◆ ~qMRMLThreeDView()

qMRMLThreeDView::~qMRMLThreeDView ( )
override

Member Function Documentation

◆ addDisplayableManager()

void qMRMLThreeDView::addDisplayableManager ( const QString & displayableManager)

Add a displayable manager to the view, the displayable manager is proper to the 3D view and is not shared with other views. If you want to register a displayable manager with all the 3D views (existing or future), you need to do it via vtkMRMLThreeDViewDisplayableManagerFactory::RegisterDisplayableManager() By default: vtkMRMLCameraDisplayableManager, vtkMRMLViewDisplayableManager and vtkMRMLModelDisplayableManager are already registered.

◆ ambientShadowsIntensityScale()

double qMRMLThreeDView::ambientShadowsIntensityScale ( ) const

◆ ambientShadowsIntensityShift()

double qMRMLThreeDView::ambientShadowsIntensityShift ( ) const

◆ ambientShadowsSizeScale()

double qMRMLThreeDView::ambientShadowsSizeScale ( ) const

◆ ambientShadowsVolumeOpacityThreshold()

double qMRMLThreeDView::ambientShadowsVolumeOpacityThreshold ( ) const

◆ cameraNode()

Q_INVOKABLE vtkMRMLCameraNode * qMRMLThreeDView::cameraNode ( )

Returns camera node of the 3D view.

◆ displayableManagerByClassName()

Q_INVOKABLE vtkMRMLAbstractDisplayableManager * qMRMLThreeDView::displayableManagerByClassName ( const char * className)

Return a DisplayableManager given its class name.

◆ dragEnterEvent()

void qMRMLThreeDView::dragEnterEvent ( QDragEnterEvent * event)
override

◆ dropEvent()

void qMRMLThreeDView::dropEvent ( QDropEvent * event)
override

◆ getDisplayableManagers()

Q_INVOKABLE void qMRMLThreeDView::getDisplayableManagers ( vtkCollection * displayableManagers)

◆ interactorObserver()

Q_INVOKABLE vtkMRMLThreeDViewInteractorStyle * qMRMLThreeDView::interactorObserver ( ) const

Returns the interactor observer of the view.

◆ lookFromViewAxis

void qMRMLThreeDView::lookFromViewAxis ( const ctkAxesWidget::Axis & axis)
inlineslot
Deprecated
Use lookFromAxis instead.

Definition at line 143 of file qMRMLThreeDView.h.

◆ mrmlViewNode()

Q_INVOKABLE vtkMRMLViewNode * qMRMLThreeDView::mrmlViewNode ( ) const

Get the 3D View node observed by view.

◆ resetCamera()

Q_INVOKABLE void qMRMLThreeDView::resetCamera ( bool resetRotation = true,
bool resetTranslation = true,
bool resetDistance = true )

◆ resetFocalPoint()

virtual void qMRMLThreeDView::resetFocalPoint ( )
virtual

Reimplemented to hide items to not take into account when computing the boundaries

◆ rotateToViewAxis() [1/2]

Q_INVOKABLE void qMRMLThreeDView::rotateToViewAxis ( const std::string & axisLabel)

◆ rotateToViewAxis() [2/2]

Q_INVOKABLE void qMRMLThreeDView::rotateToViewAxis ( unsigned int axisId)

Methods to rotate/reset the camera, Can defined a view axis by its index (from 0 to 5) or its label (defined in vtkMRMLViewNode::AxisLabels) to rotate to the axis ranged in that order: -X, +X, -Y, +Y, -Z, +Z

◆ setAmbientShadowsIntensityScale()

void qMRMLThreeDView::setAmbientShadowsIntensityScale ( double )

◆ setAmbientShadowsIntensityShift()

void qMRMLThreeDView::setAmbientShadowsIntensityShift ( double )

◆ setAmbientShadowsSizeScale()

void qMRMLThreeDView::setAmbientShadowsSizeScale ( double )

◆ setAmbientShadowsVolumeOpacityThreshold()

void qMRMLThreeDView::setAmbientShadowsVolumeOpacityThreshold ( double )

◆ setDefaultViewCursor()

Q_INVOKABLE void qMRMLThreeDView::setDefaultViewCursor ( const QCursor & cursor)

Set default cursor in the view area.

◆ setInteractor()

void qMRMLThreeDView::setInteractor ( vtkRenderWindowInteractor * interactor)
override

Sets the interactor of the view.

◆ setMRMLScene

void qMRMLThreeDView::setMRMLScene ( vtkMRMLScene * newScene)
slot

Set the MRML scene that should be listened for events When the scene is in batch process state, the view blocks all refresh.

See also
renderEnabled

◆ setMRMLViewNode

void qMRMLThreeDView::setMRMLViewNode ( vtkMRMLViewNode * newViewNode)
slot

Set the current viewNode to observe.

◆ setShadowsVisibility()

void qMRMLThreeDView::setShadowsVisibility ( bool )

◆ setViewCursor()

Q_INVOKABLE void qMRMLThreeDView::setViewCursor ( const QCursor & )

Set cursor in the view area.

◆ shadowsVisibility()

bool qMRMLThreeDView::shadowsVisibility ( ) const

◆ ssaoPass()

Q_INVOKABLE vtkSSAOPass * qMRMLThreeDView::ssaoPass ( ) const

Advanced option to directly access SSAO pass used to render the ambient shadows. Intended for experimentation and troubleshooting only.

◆ unsetViewCursor()

Q_INVOKABLE void qMRMLThreeDView::unsetViewCursor ( )

Restore default cursor in the view area.


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