[Paraview] Cutting With Python

Berk Geveci berk.geveci at kitware.com
Fri Feb 29 15:49:30 EST 2008


Hi Kent,

>  1) Why are there items in servermanager that are NOT already proxys? As I
>  understand it servermanager is used only in client-server mode.

I am not sure I understand the question. Also, servermanager is always
used not only in client-server mode. It is the Model, in paraview's
Model-View architecture. There are a few cases where it is required to
access the client-side VTK objects directly but most of the time, you
should access proxies only.

>  2) Why are the implicit functions not already in servermanager.filters? The Cut
>  filter is useless without them.

I will add that group to the default modules we create.

>  3) Why is none of this mentioned in my shiny, expensive new book "The ParaView
>  Guide"? The book is also missing the secrets of custom modules that Mike
>  Jackson has been trying to unearth.

There is always so much to cover in documentation! We tend to be
behind our coding in our documenting :-) There is hope though. We now
have a technical writer in our team. I am sure she will be MAKING us
write more documentation.

Also, the python modules are very young and immature. It will take
some time for the community to converge to a good, stable
implementation. At one point, I will restructure the wiki such that
others can contribute to the python documentation as well as provide
examples. If there are any volunteers, I can provide the servermanager
documentation as a Word file so that it can imported into Wiki
properly.

-berk

>
>  Utkarsh Ayachit wrote:
>  > The problem with your code is that you are connecting a vtk object (the
>  > vtkPlane) directly to a proxy (the Cut filter). To create a plane proxy
>  > refer to Robert's link. Here's the script updated to the current CVS
>  > (servermanager.createModule() is now directly accessible):
>  >
>  > implicit_functions = servermanager.createModule("implicit_functions")
>  > plane1 = implicit_functions.Plane()
>  > plane1.Normal = [1, 0, 0]
>  >
>  > cutfunc = servermanager.filters.Cut(Input=cube1)
>  > cutfunc.CutFunction = plane1
>  >
>  > cutfunc.ContourValues = [1.0,2.5]
>
> _______________________________________________
>  ParaView mailing list
>  ParaView at paraview.org
>  http://www.paraview.org/mailman/listinfo/paraview
>


More information about the ParaView mailing list