
Sat, 12/12/2015 - 02:23
I am using occ vtk VIS services as so:
IVtkOCC_Shape::Handle aShapeImpl = m_geometryShapes[anIt.Value()];
IVtk_ShapeIdList anIdSubList = m_picker->GetPickedSubShapesIds(anIt.Value(), false);
vtkSmartPointer<IVtkTools_ShapeDataSource> aDataSource = vtkSmartPointer<IVtkTools_ShapeDataSource>::New();
aDataSource->SetShape(aShapeImpl);
// Create a new sub-polydata filter for sub-shapes filtering
vtkSmartPointer<IVtkTools_SubPolyDataFilter> subShapesFilter = IVtkTools_SubPolyDataFilter::New();
// Set a shape source as an input of the subpolydata filter
subShapesFilter->SetInputConnection(aDataSource->GetOutputPort());
// Set ids to the filter to pass only picked sub-shapes
subShapesFilter->SetData(anIdSubList);
subShapesFilter->Modified();
// Output the result into a mapper
vtkSmartPointer<vtkPolyDataMapper> aMapper = vtkPolyDataMapper::New();
aMapper->ImmediateModeRenderingOn();
aMapper->SetResolveCoincidentTopologyPolygonOffsetParameters(1, 2);
aMapper->AddInputConnection(subShapesFilter->GetOutputPort());
If I use GetPickedSubShapesIds(anIt.Value(), false) it returns the top face although mouse coordinates are on the cylindrical surface. I thought it might be a problem with coordinate x, y but it is working correctly on the edges which seems to indicate the x,y are correct. I have also tried changing setTolerance but seems that theres is no effect.
Mon, 12/14/2015 - 12:06
Dear Billy,
I suggest you to register the issue in OCCT Mantis BugTracker available via the Collaborative portal - http://dev.opencascade.org/index.php?q=home/get_involved.
Best regards
FSR
Fri, 12/18/2015 - 13:26
Dear Billy,
you can read this http://tracker.dev.opencascade.org/view.php?id=27011
Sat, 12/31/2022 - 14:39
垃圾