Enable hardware selection for vtkCellGrid
- This commit adds two new properties on
vtkSelectionNodeto indicate the cell type index that was picked in avtkCellGridand whether a cell or side was picked. - The
vtkDGRenderResponderand it's OpenGL shaders encode various indices during the new picking passes into the framebuffer. - The hardware selector decodes the pixel information encoded by
vtkDGRenderResponderin the framebuffer intovtkSelectionNodeobjects. - The
vtkAreaPicker,vtkRenderedAreaPickerandvtkHardwarePickercan now determine whether avtkDataObjectwas picked. Earlier, it only recognized derived instances ofvtkDataSet. This is required becausevtkCellGriddirectly inheritsvtkDataObject. - The new
TestCellGridHardwarePicker.pyunit test verifies basic point and click selection usingvtkHardwarePicker. It tests that the picker populates correct information in the different pick result indices. - The new
TestCellGridRenderedAreaPicker.pyunit test verifies rubberband selection usingvtkRenderedAreaPicker. It tests that the picker populates correct values for the different information integer keys on selection nodes. - The new
TestCellGridRenderedAreaPickerWithPolyData.pyextends the selection to includevtkPolyDatain the same renderer used byvtkCellGrid.
Edited by Jaswant Panchumarti (Kitware)