title: VTK: Trying to select visible cells in area with vtkrubberbandpick & vtkHardwareSelector
body: <p>I'm trying to do an area pick of visible cells on an object using a subclass of vtkInteractorStyleRubberBandPick. I've got everything working, except for one problem: If I change the perspective of the camera at all, the pick no longer works correctly. It just picks seemingly random cells on the object, instead of the ones inside the rubberband.</p>
  
  <p>My LeftButtonUp in my InteractorStyle is basically like this:</p>
  
  <pre><code>        vtkSmartPointer&lt;vtkHardwareSelector&gt; selector = vtkSmartPointer&lt;vtkHardwareSelector&gt;::New();
          selector-&gt;SetRenderer(this-&gt;Interactor-&gt;GetRenderWindow()-&gt;GetRenderers()-&gt;GetFirstRenderer());
          unsigned int windowSize[4];
  
          windowSize[0] = StartPosition[0] &lt; EndPosition[0] ? StartPosition[0] : EndPosition[0]; // xmin
          windowSize[1] = StartPosition[1] &lt; EndPosition[1] ? StartPosition[1] : EndPosition[1]; // ymin
          windowSize[2] = StartPosition[0] &lt; EndPosition[0] ? EndPosition[0] : StartPosition[0]; // xmax
          windowSize[3] = StartPosition[1] &lt; EndPosition[1] ? EndPosition[1] : StartPosition[1]; // ymax
  
          selector-&gt;SetArea(windowSize);
          selector-&gt;SetFieldAssociation(vtkDataObject::FIELD_ASSOCIATION_CELLS);
          selector-&gt;CaptureBuffers();
          vtkSmartPointer&lt;vtkSelection&gt; selection = selector-&gt;GenerateSelection();
  
  
          vtkSmartPointer&lt;vtkExtractSelection&gt; extractSelection = vtkSmartPointer&lt;vtkExtractSelection&gt;::New();
          extractSelection-&gt;SetInputData(0, actor-&gt;GetMapper()-&gt;GetInput());
          extractSelection-&gt;SetInputData(1, selection);
  
          extractSelection-&gt;Update();
  
          vtkSmartPointer&lt;vtkUnstructuredGrid&gt; selected = vtkSmartPointer&lt;vtkUnstructuredGrid&gt;::New();
          selected-&gt;ShallowCopy(extractSelection-&gt;GetOutput());
  
          _faceSelectMapper-&gt;SetInputData(selected);
  </code></pre>
  
  <p>Do I need to do some kind of transformation somewhere? Do I need to somehow update the hardwareselector? I have searched everywhere but I'm at a loss...</p>