Permalink
Browse files

BUG: Fixed volume rendering disp.man. handling of modified image data

This bug broke display updates when Sequences updated the image data under a volume node.

git-svn-id: http://svn.slicer.org/Slicer4/trunk@27159 3bd1e089-480b-0410-8dfb-8563597acbee
  • Loading branch information...
pinter
pinter committed Apr 23, 2018
1 parent 3fca161 commit 4449f7e8d6793977198b2b928f16f556a587e95a
Showing with 13 additions and 13 deletions.
  1. +13 −13 Modules/Loadable/VolumeRendering/MRMLDM/vtkMRMLVolumeRenderingDisplayableManager.cxx
@@ -918,6 +918,19 @@ void vtkMRMLVolumeRenderingDisplayableManager::ProcessMRMLNodesEvents(vtkObject*
this->RequestRender();
}
+ else if (event == vtkMRMLScalarVolumeNode::ImageDataModifiedEvent)
+ {
+ int numDisplayNodes = volumeNode->GetNumberOfDisplayNodes();
+ for (int i=0; i<numDisplayNodes; i++)
+ {
+ vtkMRMLVolumeRenderingDisplayNode* displayNode = vtkMRMLVolumeRenderingDisplayNode::SafeDownCast(volumeNode->GetNthDisplayNode(i));
+ if (this->Internal->UseDisplayNode(displayNode))
+ {
+ this->Internal->UpdateDisplayNode(displayNode);
+ this->RequestRender();
+ }
+ }
+ }
}
else if (event == vtkCommand::StartEvent ||
event == vtkCommand::StartInteractionEvent)
@@ -961,19 +974,6 @@ void vtkMRMLVolumeRenderingDisplayableManager::ProcessMRMLNodesEvents(vtkObject*
this->RequestRender();
}
}
- else if (event == vtkMRMLScalarVolumeNode::ImageDataModifiedEvent)
- {
- int numDisplayNodes = volumeNode->GetNumberOfDisplayNodes();
- for (int i=0; i<numDisplayNodes; i++)
- {
- vtkMRMLVolumeRenderingDisplayNode* displayNode = vtkMRMLVolumeRenderingDisplayNode::SafeDownCast(volumeNode->GetNthDisplayNode(i));
- if (this->Internal->UseDisplayNode(displayNode))
- {
- this->Internal->UpdateDisplayNode(displayNode);
- this->RequestRender();
- }
- }
- }
else if (event == vtkMRMLViewNode::GraphicalResourcesCreatedEvent)
{
this->UpdateFromMRML();

0 comments on commit 4449f7e

Please sign in to comment.