Skip to content
Snippets Groups Projects
Commit 3c4cdf5e authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

rm local vars

parent a7d9ba89
No related branches found
No related tags found
1 merge request!2115rm scale=1; correct coords/bins in mask presenter (repairs worst of #823)
......@@ -102,12 +102,8 @@ void DetectorItem::addMasksToCore(IDetector* detector) const
const QVector<MaskItem*> maskItems = m_maskContainerItem.maskItems();
for (auto maskIter = maskItems.rbegin(); maskIter != maskItems.rend(); maskIter++)
if ((*maskIter)->isVisible()) {
if (auto* roiItem = dynamic_cast<RegionOfInterestItem*>(*maskIter)) {
const double xlow = roiItem->xLow();
const double ylow = roiItem->yLow();
const double xup = roiItem->xUp();
const double yup = roiItem->yUp();
detector->setRegionOfInterest(xlow, ylow, xup, yup);
if (auto* ii = dynamic_cast<RegionOfInterestItem*>(*maskIter)) {
detector->setRegionOfInterest(ii->xLow(), ii->yLow(), ii->xUp(), ii->yUp());
} else {
std::unique_ptr<IShape2D> shape((*maskIter)->createShape());
detector->addBinMask(*shape, (*maskIter)->maskValue());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment