Hi. I am creating an effect inside Segment Editor. I have looked at the code from other effects and saw how a volume selector was being written.
self.inputVolumeSelector = slicer.qMRMLNodeComboBox()
self.inputVolumeSelector.nodeTypes = [“vtkMRMLScalarVolumeNode”]
self.inputVolumeSelector.selectNodeUponCreation = True
self.inputVolumeSelector.addEnabled = True
self.inputVolumeSelector.removeEnabled = True
self.inputVolumeSelector.noneEnabled = True
self.inputVolumeSelector.noneDisplay = “(Master volume)”
self.inputVolumeSelector.showHidden = False
self.inputVolumeSelector.setMRMLScene(slicer.mrmlScene)
self.inputVolumeSelector.setToolTip(“Volume to split. Default is current master volume node.”)
self.inputVolumeSelector.connect(“currentNodeChanged(vtkMRMLNode*)”, self.updateMRMLFromGUI)
This creates a volume selector dropdown from where the user can select an input volume for their logic.
Similarly, I would like to add a inputModelSelector and inputMarkupsSelector. But, when I try it, I am not able to select anything in the dropdown. Also, no other effects have taken input a model or markups, therefore I cannot find any reference for this.