[vtkusers] vtkXMLImageDataReader load from stream/buffer/string

Markus Fuger markus.fuger at outlook.com
Fri May 23 02:08:42 EDT 2014


Hello everybody,

I am using VTK 6.1 from Python and would like to load the data for a vtkXMLImageDataReader from a stream/buffer or string rather than by giving a filename.

I found in the documentation that vtkXMLStructuredDataReader has a method SetReadFromInputString(int) and ReadFromInputStringOn()
http://www.vtk.org/doc/nightly/html/classvtkXMLStructuredDataReader.html
in combination with SetInputString(string) I believed this could work

But I cannot find those using dir(vtkXMLImageDataReader). I found that there is a function called SafeDownCast(vtkObjectBase) - I am not sure if this is the right approach - but even if I do not know how to use it.
Perhaps someone could give me some short example of how to make this task work (preferably in Python but I can 'translate' it as well if C++ code is given)

Thanks a lot!
Markus



 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20140523/73294f7f/attachment.html>


More information about the vtkusers mailing list