Hello, I still have a problem …
Well I need to change the color of the fudicial, I saw that it was possible but I do not know why, I am blocking with … I have already tried something but without success.
viridis = cm.get_cmap('viridis', 8)
nbClust = -1
if len(points) != 0:
for i in range(len(points)):
if points['nbClust'][i] != nbClust:
nodeName = f"Cluster {nbClust+2}"
markupsNode = slicer.mrmlScene.AddNewNodeByClass("vtkMRMLMarkupsFiducialNode", nodeName)
markupsNode.CreateDefaultDisplayNodes()
nbClust=points['nbClust'][i]
pos = [points['p1z'][i], points['p1y'][i], points['p1x'][i]]
markupsNode.AddFiducialFromArray(pos, 'point')
# --------- Couleur ----------
color = points['volume'][i]/100
color = viridis(color)
# color = (r, g, b, a)
'''
points = {
'p1x': p1[0],
'p1y': p1[1],
'p1z': p1[2],
'volume': volume,
'nbClust': nbClust,
'red': color[0],
'blue': color[1],
'green': color[2],
}
'''
So i need to display a part of point with the color.
In addition, I also need to change the color of the lines but hey, there I found nothing.
Thank’s for your help !