[vtkusers] add circles & sphere to DICOM slices & 3D viewer

chasank chasank at gmail.com
Fri Jan 9 06:45:02 EST 2015


Hi Richard

1) You may convert display coordinates into world coordinates using
vtkCellPicker

double *displayPoint = renderer->GetDisplayPoint();

vtkCellPicker *picker = vtkCellPicker::New();
picker->PickFromListOn();
picker->AddPickList(vtkPropInstance);
picker->Pick(displayPoint[0], displayPoint[1], 0, renderer);
        
double *worldCoordinates = picker->GetPickPosition();


2) Use vtkImageProperty for opacity issues between overlapped planes. Play
with ambient, diffuse and opacity

vtkImagePropery *imageProperty = vtkImagePropery::New();
imageProperty->SetInterpolationTypeToLinear();
imageProperty->SetAmbient(1.0); 
imageProperty->SetDiffuse(1.0);
imageProperty->SetOpacity(1.0);

imageSlice->SetProperty(imageProperty);

Best regards.



--
View this message in context: http://vtk.1045678.n5.nabble.com/add-circles-sphere-to-DICOM-slices-3D-viewer-tp5730043p5730044.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list