<html>
<head>
</head>
<body>
Hi again<br>
<br>
I though it worked but I just tried to redo the whole thing with RPMs for
Python 2.2 and wcPython, i then recompile VTK4 against these versions and
i then got back to the same problem ..<br>
<br>
When i print the type of data , vtk answers vtkobject :<br>
<br>
<i>Python 2.2 (#1, Dec 23 2001, 09:30:32) </i><i><br>
</i><i>[GCC 2.96 20000731 (Red Hat Linux 7.1 2.96-98)] on linux2</i><i><br>
</i><i>Type "help", "copyright", "credits" or "license" for more information.</i><i><br>
</i><i>>>> from vtkpython import *</i><i><br>
</i><i>>>> data=vtkImageData()</i><i><br>
</i><i>>>> reslice=vtkImageReslice()</i><i><br>
</i><i>>>> reslice.SetInput(data)</i><i><br>
</i><i>Traceback (most recent call last):</i><i><br>
</i><i> File "<stdin>", line 1, in ?</i><i><br>
</i><i>ValueError: method requires a VTK object</i><i><br>
</i><i>>>> print type(data)</i><i><br>
</i><i><type 'vtkobject'></i><i><br>
</i><br>
I really can t understand this...<br>
<br>
Regards Emmanuel<br>
<br>
<br>
Jose Paulo Moitinho de Almeida wrote:<br>
<blockquote type="cite" cite="mid:200201140943.g0E9hwf2023903@lmoit2.civil.ist.utl.pt">
<pre wrap="">Hello<br><br>On a similar situation: <NEW> machine + python 2.2 + vtk4, I can reproduce <br>exactly the same problem as Emmanuel. But the quick check that you mention <br>results in a <type 'vtkobject'>.<br><br>I discovered it because I had problems with mayavi in:<br><br> def init_scalar_bar (self):<br> "Sets up the default scalar bar."<br> debug ("In LutHandler::init_scalar_bar ()")<br> self.sc_bar = vtkpython.vtkScalarBarActor ()<br> self.sc_bar.SetLookupTable (self.lut)<br><br>I got in the SetLookupTable command a: <br>"ValueError: method requires a VTK object (in init_scalar_bar)"<br><br>Regards<br><br>Ze Paulo<br><br>On Saturday 12 January 2002 03:40, David Gobbi wrote:<br></pre>
<blockquote type="cite">
<pre wrap="">Hi Emmanual,<br><br>...<br><br>At least for me, the VTK 4.X and python2.2 combination seems<br>to work fine. I built VTK with shared libraries.<br><br>My suspicion is that if you do a "make clean" of VTK and rebuild,<br>then the problem will go away. Also make sure that CMakeCache.txt<br>is pointing to the correct set of header files for python2.2.<br><br></pre>
</blockquote>
<pre wrap=""><!----><br>No other python installed.<br><br><br></pre>
</blockquote>
<br>
</body>
</html>