Isodose Generation

Hi all,

I would like to create isodose and the color bar. I followed the isodose tutorial (SlicerRtDoc/tutorials/SlicerRT_Tutorial_Isodose.pptx at master · SlicerRt/SlicerRtDoc · GitHub). However, in the Isodose feature I could only edit the number of iso levels, but cannot change the color, dose and Opacity for each level by double clicking (please see the picture below).

Could you give me some help? Thank you so much!

@cpinter @Sunderlandkyl is there a reason why the color table entries are editable only if “Relative isolevels of dose” option is enabled in Isodose module?

Hi Andrass, thank you co much for your reply! And yes, that’s exactly the problem I have. The color table is only editable if “Relative isolevels of dose” option is checked.

@lassoan @cpinter @Sunderlandkyl I appreciate any help from your side!

I think the problem is not only in “Isodose” module. You can’t modify that color table in the “Colors” module as well. “Isodose_ColorTable_Relative” can be edited, but “Isodose_ColorTable_Default” is blocked for editing.

1 Like

@Cody_Xie @cpinter @Sunderlandkyl

The problem in that part of code.

Logic loads default (absolute dose) color table, and creates relative dose color table, if both color table are created without loading, both absolute and relative doses are available for editing.

Possible solution

//---------------------------------------------------------------------------
void vtkSlicerIsodoseModuleLogic::SetMRMLSceneInternal(vtkMRMLScene* newScene)
{
  vtkNew<vtkIntArray> events;
  events->InsertNextValue(vtkMRMLScene::NodeAddedEvent);
  events->InsertNextValue(vtkMRMLScene::NodeRemovedEvent);
  events->InsertNextValue(vtkMRMLScene::EndCloseEvent);
  events->InsertNextValue(vtkMRMLScene::EndBatchProcessEvent);
  this->SetAndObserveMRMLSceneEvents(newScene, events.GetPointer());

    // Create isodose color tables
    vtkSlicerIsodoseModuleLogic::CreateDefaultDoseColorTable(newScene);
    vtkSlicerIsodoseModuleLogic::CreateRelativeDoseColorTable(newScene);
}
2 Likes

Hi Mik,

many thanks for pointing it out!

Besides, may I know if you have the similar problem when you create isodose surfaces? The dose will be enlarged after clicking “Create isodose surfaces”. I posted a new topic here Dose will be distorted when creating isodose surfaces

Thank you so much!

Good catch @Mik ! This issue with color tables that they are not editable sometimes has been around for a good while, but I wasn’t aware that it affected one of the isodose color tables. If it’s not easy to make it editable then a workaround could be added that creates a new editable one and copies the colors from the loaded one.

1 Like

I will try to look at that bug.

2 Likes

Thank yo so much Mik! :smiley:

@lassoan @cpinter Hello Andras and Csaba, may I know why I cannot download and install the Preview Release Slicer (built by 2021-10-20)? The size of the .zip file looks wrong. Thank you so much!


There was a download server failure yesterday - see here for details and workaround: Slicer Preview Release package for Windows failed to upload

1 Like

Thank you so much Andras! It works fine now

1 Like