Hi
I Using three Vtk Image Plan Widget To Cut dicom Series And Get Three View
Axial Coronal and Sagittal And Return To Me This View
But In 3dSlicer View Of Series Return This View
Code Of Vtk Image Plan Widget its
public void PrepareImagePlaneWidget(ImagePlanWidgetsM planeWidgetM, vtkImageData data, vtkRenderWindowInteractor interactor)
{
renderWindowInteractor = interactor;
SetPlanWidgetProperties(planeWidgetM.AxialimagePlaneWidget, data);
SetPlanWidgetProperties(planeWidgetM.CoronalimagePlaneWidget, data);
SetPlanWidgetProperties(planeWidgetM.SagitalimagePlaneWidget, data);
SetOrientationOfWidgets(planeWidgetM.AxialimagePlaneWidget, direction.AXIAL);
SetOrientationOfWidgets(planeWidgetM.CoronalimagePlaneWidget, direction.CORONAL);
SetOrientationOfWidgets(planeWidgetM.SagitalimagePlaneWidget, direction.SAGITTAL);
}
private void SetOrientationOfWidgets(vtkImagePlaneWidget planeWidget, direction direction)
{
switch (direction)
{
case direction.AXIAL:
planeWidget.SetPlaneOrientationToZAxes();
planeWidget.GetPlaneProperty().SetColor(0.0, 0.0, 1.0);
break;
case direction.CORONAL:
planeWidget.SetPlaneOrientationToYAxes();
planeWidget.GetPlaneProperty().SetColor(0.0, 1.0, 0.0);
break;
case direction.SAGITTAL:
planeWidget.SetPlaneOrientationToXAxes();
planeWidget.GetPlaneProperty().SetColor(1.0, 0.0, 0.0);
break;
}
planeWidget.On();
}
private void SetPlanWidgetProperties(vtkImagePlaneWidget planeWidget, vtkImageData imageData)
{
vtkCellPicker picker = CellPicker();
planeWidget.SetInteractor(renderWindowInteractor);
planeWidget.SetPicker(picker);
planeWidget.RestrictPlaneToVolumeOn();
planeWidget.DisplayTextOn();
planeWidget.TextureInterpolateOn();
planeWidget.SetResliceInterpolateToCubic();
planeWidget.SetInputData(imageData);
planeWidget.GetTexturePlaneProperty().SetOpacity(0);
}
private static vtkCellPicker CellPicker()
{
vtkCellPicker picker = vtkCellPicker.New();
picker.SetTolerance(0.005);
return picker;
}
I for Fix This Problam Rotate Image Actor In The End And When Show Image
But For Use Other Tools I Have Problem
I would be grateful if you could help me to solve this problem