20 #include <QVBoxLayout>
22 #include <QStringList>
32 BaseWidget(parent,
"ImagePropertiesWidget",
"Image Properties"),
35 mInterpolationType =
new QComboBox(
this);
36 mInterpolationType->insertItem(0,
"Nearest");
37 mInterpolationType->insertItem(1,
"Linear");
38 mInterpolationType->insertItem(2,
"Cubic");
39 mInterpolationType->setToolTip(
"Change VTK interpolation type");
41 connect(mInterpolationType, SIGNAL(currentIndexChanged(
int)),
this, SLOT(interpolationTypeChanged(
int)));
43 QLabel* interpolationTypeLabel =
new QLabel(
"Volume interpolation type",
this);
45 QHBoxLayout* layout =
new QHBoxLayout(
this);
46 layout->addWidget(interpolationTypeLabel);
47 layout->addWidget(mInterpolationType);
50 void ImageRenderPropertiesWidget::interpolationTypeChanged(
int index)
53 mImage->setInterpolationType(index);
60 mInterpolationType->setCurrentIndex(mImage->getInterpolationType());
68 BaseWidget(parent,
"shading_widget",
"Shading"),
69 mLayout(new QVBoxLayout(this)),
70 mActiveData(activeData),
75 this->
init(connectToActiveImage);
84 this->setToolTip(
"Volume shading properties");
88 QGridLayout* shadingLayput =
new QGridLayout();
95 shadingAmbientWidget->setEnabled(
false);
96 shadingDiffuseWidget->setEnabled(
false);
97 shadingSpecularWidget->setEnabled(
false);
98 shadingSpecularPowerWidget->setEnabled(
false);
100 if (connectToActiveImage)
109 mLayout->addLayout(shadingLayput);
117 mImage->setShadingOn(val);