Hello

Sorry to bother, but I can't seem to find a way (in the mailing list or the
documentation) to pass a string as some kind of argument to Programmable
Source (using pvpython interpreter). The python "program" needs to load a
custom binary format using numpy.fromfile.

What I've thought is to write a wrapper function. The function should
receive a string as argument and then instantiate a programmable filter and
execute
myscript.replace(random_var_name, myfilename)
MyProgrammableSource.Script = myscript
return MyProgrammableSource

Where random_var_name is the argument of my numpy.fromfile call. But that
doesn't seem very "pythonic". Is there a way to pass a string to the Script
without the .replace hack?

Sorry if this is documented, I couldn't find it.

Cheers,
Mauro
_______________________________________________
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