[vtkusers] Python wrapping
David Gobbi
david.gobbi at gmail.com
Sun Nov 2 08:18:36 EST 2014
Hi Gib,
The vtk*Python.pyd files are the DLLs that you are looking for. See here:
https://docs.python.org/2/faq/windows.html#is-a-pyd-file-the-same-as-a-dll
- David
On Sun, Nov 2, 2014 at 12:09 AM, Gib Bogle <g.bogle at auckland.ac.nz> wrote:
> Hi David,
>
> All the .pyd files are where they should be, and all the vtk*PythonD.dll
> files are where they should be, in C:\vtk-vs10-x64\bin, which is in the
> PATH. The point of my question was that the VTK release build did not
> create any vtk*Python.dll files, although it did create the .lib files.
> Correct me if I'm wrong, but I think that vtkpython is looking for the
> missing DLL files - specifically, for vtkRenderingPython.dll. Am I wrong
> in thinking that they should have been built?
>
> Gib
> ------------------------------
> *From:* David Gobbi [david.gobbi at gmail.com]
> *Sent:* Sunday, 2 November 2014 4:11 p.m.
> *To:* Gib Bogle
> *Cc:* vtkusers at vtk.org
> *Subject:* Re: [vtkusers] Python wrapping
>
> Hi Gib,
>
> The python modules are called "vtk*Python.pyd" on Windows.
> On your system, I'm guessing that they should be in this directory:
> c:\VTK-VS10-x64\lib\site-packages\vtk
>
> And, in order for the modules to be loaded, all of the VTK DLLs
> must also be in your PATH. Either that, or you can copy them all
> into c:\VTK-VS10-x64\lib\site-packages\vtk so that the .pyd files
> will be able to find them there.
>
> The vtk*PythonD.dll files are not python modules, they are support
> libraries that are needed by the python modules.
>
> - David
>
>
>
> On Sat, Nov 1, 2014 at 8:54 PM, Gib Bogle <g.bogle at auckland.ac.nz> wrote:
>
>> I just rebuilt VTK-5.10.1 64-bit on Windows with VTK_WRAP_PYTHON ON.
>> The build completed without errors. I do not understand why I have 14 .lib
>> and .dll files named vtk*PythonD.dll and vtk*PythonD.lib, and 14 .lib files
>> named vtk*Python.lib, but no vtk*Python.dll. This causes my attempt to run
>> a VTK-Python example to fail like this:
>>
>> D:\testing\VTK\Superquadric>vtkpython superquadric.py
>> Traceback (most recent call last):
>> File "superquadric.py", line 1, in <module> import vtk
>> File "c:\VTK-VS10-x64\lib\site-packages\vtk\__init__.py", line 63, in
>> <module> __helper.refine_import_err('rendering', 'vtkRenderingPython', exc)
>> File "c:\VTK-VS10-x64\lib\site-packages\vtk\__helper.py", line 32, in
>> refine_import_err raise LinkError, str(exc)
>> vtk.__helper.LinkError: DLL load failed: %1 is not a valid Win32
>> application.
>>
>> I see that somebody was asking exactly the same question back in October,
>> 2010, but there was no answer.
>>
>> Any suggestions?
>>
>> Thanks
>> Gib
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20141102/2d10cf7b/attachment.html>
More information about the vtkusers
mailing list