Hi, experts!
I tried to use SelectSurfaceCells() to select one of several data sources and found that it was not what I expected. The following code do not get the same source, assuming I selecte the same source:
Perhaps with a solution, I could take the ID of the VTKSMRepresentationProxy I got and compare it with the VTKSMRepresentationProxy of all the sources, and then get the data source I wanted.
I don’t know if this isn’t the best solution to the problem, right?
I want to use the mouse click location to get one of the multiple data sources in the pipeline, and then do something to the selected data source, such as clip.
I’ve used the Pick() method in VTKSMRepresentationProxy to get the representation of the data source(VTKSMRepresentationProxy) I want to select. I get the source by comparing the global ID of the source’s representation with the global ID of all the source’s representations in the pipeline. I think this approach may be one way, may not be the best.
That was my initial question. The source I get from using selectSurfaceCells () is an IdSelectionSource. I don’t think it’s an active source because it can’t be used with filters.
Yes, this is very clear. You are trying to select an active source by clicking on it in the render view.
I’ve used the Pick() method in VTKSMRepresentationProxy to get the representation of the data source(VTKSMRepresentationProxy) I want to select. I get the source by comparing the global ID of the source’s representation with the global ID of all the source’s representations in the pipeline. I think this approach may be one way, may not be the best.
Correct, but this should work.
That was my initial question. The source I get from using selectSurfaceCells () is an IdSelectionSource. I don’t think it’s an active source because it can’t be used with filters.
The IDSelectionSource should ave an input, this should be the correct source you are looking for.