I somehow can create new customised volume rendering presets as per explanations
however at present need to restart slicer to see the effects as i need the slicerrc.py file to be read
Is there a way to re read the slicerrc.py file without having to restart slicer
ps : is there anywhere a good detailed explanation for all the settings in custom volume presets
ie the format of the numbers ; pairs / triplets etc
Thanks
Greatly appreciated
Thanks for the reply ; Have achieved what i wanted ( the long way ) multiple anchor points on a preset and alter them when using slicer ; I came across this code propNode = displayNode.GetVolumePropertyNode()
volumeProp = propNode.GetVolumeProperty()
slicer.modules.volumerendering.logic().SetThresholdToVolumeProp(self.scalarRange,[thresholdLevel - thresholdWindow/2, thresholdLevel + thresholdWindow/2],volumeProp,True,True)
color = vtk.vtkColorTransferFunction()
color.AddRGBPoint(-3000, 0, 0, 0)
color.AddRGBPoint(thresholdLevel-self.thresholdWindow/2, 0.6, 0.3, 0.2)
color.AddRGBPoint(thresholdLevel, 1.0, 1.0, 1.0)
color.AddRGBPoint(thresholdLevel+self.thresholdWindow/2, 1.0, 0.9, 0.9)
color.AddRGBPoint(3000, 0.8, 0.7, 1.0)
volumeProp.SetColor(color)
from another discussion ;
which i can find verry useful ;
however when i try it the volume does not respond ; ie aware the line with the feachure i want is the second last and need to alter the x position and the corresponding rgb values , slicer find no error in the code but the volume does not respond with the altered values ; any advice would be useful to me