Skip to content

Commit

Permalink
Merge pull request #92 from Kitware/point-picker
Browse files Browse the repository at this point in the history
fix(ItkVtkViewProxy): Use vtkPointPicker instead of vtkCellPicker
  • Loading branch information
thewtex authored Jul 26, 2018
2 parents 42ac23a + ce314df commit 528f362
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/ItkVtkViewProxy.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import macro from 'vtk.js/Sources/macro';

import vtkViewProxy from 'vtk.js/Sources/Proxy/Core/ViewProxy';
import vtkCellPicker from 'vtk.js/Sources/Rendering/Core/CellPicker';
import vtkPointPicker from 'vtk.js/Sources/Rendering/Core/PointPicker';
import vtkActor from 'vtk.js/Sources/Rendering/Core/Actor';
import vtkCubeSource from 'vtk.js/Sources/Filters/Sources/CubeSource';
import vtkMapper from 'vtk.js/Sources/Rendering/Core/Mapper';
Expand Down Expand Up @@ -76,7 +76,7 @@ function ItkVtkViewProxy(publicAPI, model) {
[renderPosition.x, renderPosition.y, 0.0],
callData.pokedRenderer
);
const ijk = model.annotationPicker.getCellIJK();
const ijk = model.annotationPicker.getPointIJK();
if (model.volumeRepresentation) {
const imageData = model.volumeRepresentation.getInputDataSet();
const size = imageData.getDimensions();
Expand Down Expand Up @@ -123,7 +123,7 @@ function ItkVtkViewProxy(publicAPI, model) {
'N/A ',
});
publicAPI.setAnnotationOpacity(0.0);
model.annotationPicker = vtkCellPicker.newInstance();
model.annotationPicker = vtkPointPicker.newInstance();
model.annotationPicker.setPickFromList(1);
model.annotationPicker.initializePickList();
model.interactor.onMouseMove((event) => {
Expand Down

0 comments on commit 528f362

Please sign in to comment.