View Issue Details

IDProjectCategoryView StatusLast Update
0002620Slicer4Module VolumeRenderingpublic2013-09-03 16:30
Reporterlassoan Assigned Tofinetjul  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version 
Target VersionSlicer 4.2.0Fixed in VersionSlicer 4.2.0 
Summary0002620: Volume rendering module creates invalid annotation ROI
Description

If the volume rendering module is opened it creates an annotation ROI that cannot be saved. Tested on latest nightly Slicer-4.1.0-2012-10-05-win-amd64.

An error message is reported during saving: "Cannot write data file: C:/Users/lasso/tmp/AnnotationROI.txt. Do you want to continue saving?"

And an invalid AnnotationROI.txt file is generated, with the following contents:

Annotation file C:/Users/lasso/tmp/AnnotationROI.txt

TagsNo tags attached.

Relationships

related to 0002606 assignednicole Design comments/issues on Annotation nodes 

Activities

finetjul

finetjul

2012-10-07 16:32

administrator   ~0006427

Last edited: 2012-10-07 16:33

Reminder sent to: alexy, nicole

Alex, Nicole, I would need your help here.
When saving the ROI, eventually vtkMRMLAnnotationStorageNode::WriteAnnotationTextProperties complains because there is no text display node.

Is text really mandatory ? Why should it matter if there is no text display node to the ROI node ?
What's the proper way to create a ROI node ?
Please look at vtkSlicerVolumeRenderingLogic::UpdateDisplayNodeFromVolumeNode to see if I create the node correctly.
Thanks for your help.

nicole

nicole

2012-10-09 07:25

administrator   ~0006465

The annotation storage nodes are a bit fragile, the writing is chained through the classes, and display nodes are required in increasing number as you get into sub classes.
The ROI derives from text nodes, as does every other MRML Annotation node, to support the display properties of text associated with an annotation. The ROI widget doesn't use text currently, though it could be a useful addition for differentiating mulitple ROIs in a scene.
In vtkSlicerVolumeRenderingLogic::UpdateDisplayNodeFromVolumeNode you're just instantiating the ROI node and adding it to the scene, but the annotation nodes tend to do important things in the Initialize method, like creating necessary display nodes, and adding themselves to the scene (which is something I've already changed in my re-write).

Short answer: try calling this in your method:
roiNode->Initialize(this->GetMRMLScene())

finetjul

finetjul

2012-10-09 08:02

administrator   ~0006470

Fixed in r21146

Thanks Nicole, that works.

lassoan

lassoan

2013-09-03 16:30

developer   ~0009881

The problem is not reproducible anymore (tested on Slicer-4.2.2-2013-08-28).

Issue History

Date Modified Username Field Change
2012-10-06 05:51 lassoan New Issue
2012-10-06 05:51 lassoan Status new => assigned
2012-10-06 05:51 lassoan Assigned To => finetjul
2012-10-07 16:32 finetjul Note Added: 0006427
2012-10-07 16:33 finetjul Note Edited: 0006427
2012-10-09 07:25 nicole Note Added: 0006465
2012-10-09 08:02 finetjul Note Added: 0006470
2012-10-09 08:02 finetjul Status assigned => resolved
2012-10-09 08:02 finetjul Fixed in Version => Slicer 4.2.0 - coming release
2012-10-09 08:02 finetjul Resolution open => fixed
2012-10-09 08:16 finetjul Relationship added related to 0002606
2012-12-08 09:46 jcfr Target Version => Slicer 4.2.0
2013-09-03 16:30 lassoan Note Added: 0009881
2013-09-03 16:30 lassoan Status resolved => closed