[Paraview] problem in displaying filters affects
Sebastien Jourdain
sebastien.jourdain at kitware.com
Mon Apr 16 09:12:21 EDT 2012
Try that,
from paraview.simple import *
reader = OpenDataFile( "/home/......./disk_out_ref.ex2" )
Show()
Render()
clip = Clip(reader)
clip.ClipType.Normal = [.5,.5,0]
Show(clip)
Render()
Hide(reader)
Render()
That should do what you script was doing. But at the end I make sure
that I hide the full data so I can see the clip of that data.
Seb
On Mon, Apr 16, 2012 at 8:50 AM, Roba Binyahib
<roba.binyahib at kaust.edu.sa> wrote:
>
>
>
> Hi everyone
>
> I'm having a problem with applying filters using python and paraview
>
> I can load the data file and change the colors but when I apply filters I
> can not see any changes
>
> I'm using paraview version 3.14.0
>
> and this is an example of the code I'm trying to run
>
>>>> from paraview import servermanager
> paraview version 3.14.0, Date: 2012-02-17
>>>> servermanager.Connect()
> Connection (builtin:) [1]
>>>> reader = servermanager.sources.ExodusIIReader()
>>>> reader.FileName = "/home/......./disk_out_ref.ex2"
>>>> view = servermanager.CreateRenderView()
>>>> repRed = servermanager.CreateRepresentation(reader, view)
>>>> view.ResetCamera()
>>>> view.StillRender()
>>>> clipper = servermanager.filters.Clip(Input = reader)
>>>> plane = servermanager.implicit_functions.Plane()
>>>> plane.Normal = [0.5,0.5, 0.0]
>>>> clipper.ClipFunction = plane
>>>> repClip = servermanager.CreateRepresentation(clipper , view)
>>>> view1.ResetCamera()
>>>> view1.StillRender()
>
>
> I hope someone can help
>
> thanks
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview
>
More information about the ParaView
mailing list