[Paraview] TypeError: WriteImage() takes exactly 3 arguments (1 given)
Sebastien Jourdain
sebastien.jourdain at kitware.com
Mon Mar 18 13:13:54 EDT 2013
Probably because in the documentation the WriteImage() used is a function
and not a method on the view proxy.
>>> WriteImage("/tmp/image.png")
On Thu, Mar 14, 2013 at 11:28 AM, Anton Shterenlikht <mexas at bristol.ac.uk>wrote:
> I get this error:
>
> >>> view.WriteImage("z.png")
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File
> "/usr/local/lib/paraview-3.10/site-packages/paraview/servermanager.py",
> line 331, in __ConvertArgumentsAndCall
> retVal = func(*newArgs)
> TypeError: WriteImage() takes exactly 3 arguments (1 given)
> >>>
>
> The tutorial suggests that just the filename is enough:
>
> http://paraview.org/Wiki/ParaView/Python_Scripting
>
> Anyway, I can see in other examples that the second argument
> is the file format, e.g.:
>
> view.WriteImage("z.png","vtkPNGWriter")
>
> but this gives the same error:
>
> >>> view.WriteImage("z.png","vtkPNGWriter")
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File
> "/usr/local/lib/paraview-3.10/site-packages/paraview/servermanager.py",
> line 331, in __ConvertArgumentsAndCall
> retVal = func(*newArgs)
> TypeError: WriteImage() takes exactly 3 arguments (2 given)
> >>>
>
> I cannot find what the third argument must be.
>
> Please help
>
> Anton
> _______________________________________________
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20130318/8bc4a8ca/attachment.htm>
More information about the ParaView
mailing list