Hello everyone,

I am used to create vector images (PDF) using the export view tool in the
Paraview 4.3 GUI.
As I wanted to use it in scripts I used Start Trace to get the python
instructions which is :

ExportView('your_path.pdf', view=your_render_view, Rasterize3DGeometry=0)

Problem is, the Rasterize3DGeometry option is unknown when you try and use
it in the console (and without it you get a pixeled image).

I looked up old messages and found this piece of code :

rw = your_render_view.GetRenderWindow()
exp = paraview.vtk.vtkInstantiator.CreateInstance('vtkGL2PSExporter')
exp.SetRenderWindow(rw)
exp.SetDrawBackground(0)
exp.SetSortToSimple()
exp.SetFileFormatToPDF()
exp.SetFilePrefix("your_path.pdf")
exp.Write3DPropsAsRasterImageOff()
exp.Write()

that should take care of it in a less direct way. Unfortunately, the
instanciation fail and the object (named exp here) is undefined.

Is it only an interface problem with python ? Is there any way to get the
correct instance of the renderer ?

Best regards,

Silvère Pierre
_______________________________________________
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

Search the list archives at: http://markmail.org/search/?q=ParaView

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/paraview

Reply via email to