Medical Imaging Interaction Toolkit  2023.04.00
Medical Imaging Interaction Toolkit
MITK Tutorial - Step 8: Use QmitkStdMultiWidget as widget

In this step a QmitkStdMultiWidget is used. It offers four views of the data. From top left to bottom left the views are initialized as axial, sagittal and coronar. The bottom right view is initialized as 3D view.

Step8 inherits from Step6. The method SetupWidgets() is changed: A QmitkStdMultiWidget is used instead of one QmitkRenderWindow and two instances of QmitkSliceWidget.

// Part Ia: create and initialize QmitkStdMultiWidget
//*************************************************************************
QmitkStdMultiWidget *multiWidget = new QmitkStdMultiWidget(viewParent);
hlayout->addWidget(multiWidget);
// Tell the multiWidget which DataStorage to render
multiWidget->SetDataStorage(m_DataStorage);
// Initialize the multiWidget with the render windows
multiWidget->InitializeMultiWidget();
// Add the displayed views to the DataStorage to see their positions in 2D and 3D
multiWidget->AddPlanesToDataStorage();
//*************************************************************************
// Part Ib: create and initialize LevelWindowWidget
//*************************************************************************
QmitkLevelWindowWidget *levelWindowWidget = new QmitkLevelWindowWidget(viewParent);
hlayout->addWidget(levelWindowWidget);
// Tell the levelWindowWidget which DataStorage to access
levelWindowWidget->SetDataStorage(m_DataStorage);

[Previous step] [Next step]

QmitkLevelWindowWidget
Definition: QmitkLevelWindowWidget.h:23
QmitkStdMultiWidget::InitializeMultiWidget
virtual void InitializeMultiWidget() override
QmitkStdMultiWidget
The 'QmitkStdMultiWidget' is a 'QmitkAbstractMultiWidget' that is used to display multiple render win...
Definition: QmitkStdMultiWidget.h:24
QmitkLevelWindowWidget::SetDataStorage
void SetDataStorage(mitk::DataStorage *ds)
QmitkStdMultiWidget::AddPlanesToDataStorage
void AddPlanesToDataStorage()
QmitkAbstractMultiWidget::SetDataStorage
virtual void SetDataStorage(mitk::DataStorage *dataStorage)