In the ParaView GUI, a source in the pipeline browser and its representation in a view are linked, shown by the eye icon.
How can I find using Python scripting the source for a given view proxy object, and the view proxy objects for a given source?
In the ParaView GUI, a source in the pipeline browser and its representation in a view are linked, shown by the eye icon.
How can I find using Python scripting the source for a given view proxy object, and the view proxy objects for a given source?
Hello @CsatiZoltan ,
In ParaView python, you can retrieve the source from a view by first fetching the view:
view = GetActiveView()viewList = GetViews()From this view proxy, you can then find the representation of your source and get it’s input which will be the source: source = view.Representations[0].Input
As far as I know, the other way around is not possible if your source is not active.
You can however always retrieve actives objects as I explained above:
GetActiveView()
GetActiveSource()
GetActiveCamera()
etc…
Thank you, it works.
When does a view have multiple representations? I am asking it because you indexed the first element of it. Could you please point me to a source that explains the representations in ParaView?
Each entry in the pipeline browser with an active “eyeball” icon next to it is a representation in that view.
(Also: Each pipline object should have either 0 or 1 representations in a particular view, but since there may be multiple views, pipeline objects may have multiple representations.)