Jump to content

Hou Navigator 0.1


Recommended Posts

I must admit, that HouNavigator was a bit neglected in the last months, but some things had happened: I tried to implement a linux version of the script. I'm having problems merging the 2 mainloops needed for the 3dconnexion device driver (at the time houdini is calling the event loop callback, the magellan events already seem to be removed from the queue). So here is a question for you linux users out there: Would it be ok, if HouNavigator built on top of the opensource driver Spacenav (http://spacenav.sourceforge.net/index.html)? This one doesn't need an X11 event loop to deliver information from the device and therefore it looks more promising for a plugin approach.

Link to comment
Share on other sites

Hello Frank!

I download your spacemouse_0.1.zip and find that there is no line breaks in text files (readme.txt, build.bat, etc)

Therefore it's realy hard to read and edit it.

Moreover I am new to Houdini, Python and English :)

How I can restore line breaks in your text files?

Edited by Mikx
Link to comment
Share on other sites

I try to build it with different versions of Python and get this errors:

Python 2.5.4

running build
running build_ext
error: Python was built with Visual Studio 2003;
extensions must be built with a compiler than can generate compatible binaries.
Visual Studio 2003 was not found on this system. If you have Cygwin installed,
you can try compiling with MingW32, by passing "-c mingw32" to setup.py.

2.6.4 and 3.1.1

running build
running build_ext
building 'spacemouse' extension
error: Unable to find vcvarsall.bat

I have to install anything else?

Link to comment
Share on other sites

Do you have the Windows SDK installed? If so, please start the build.bat from the "CMD Shell" comming with the SDK instead of the normal command prompt from the "accessories" (Don't know if it's called like that on an english windows). This sets up the environment in such a way, that the build script can find the compiler/linker/vcvarsall.bat/etc.

Link to comment
Share on other sites

I install Visual Studio 2008 and Windows SDK 7 and try to build again

C:\spacemouse_0.1\native>build
running build
running build_ext
building 'spacemouse' extension
creating build\temp.win32-2.6
creating build\temp.win32-2.6\Release
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox
/MD /W3 /GS- /DNDEBUG -IC:\ext\soft\Python264\include -IC:\ext\soft\Python264\PC
 /Tpspacemouse.cpp /Fobuild\temp.win32-2.6\Release\spacemouse.obj /EHsc
spacemouse.cpp
creating build\lib.win32-2.6
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\link.exe /DLL /nologo
/INCREMENTAL:NO /LIBPATH:C:\ext\soft\Python264\libs /LIBPATH:C:\ext\soft\Python2
64\PCbuild /EXPORT:initspacemouse build\temp.win32-2.6\Release\spacemouse.obj /O
UT:build\lib.win32-2.6\spacemouse.pyd /IMPLIB:build\temp.win32-2.6\Release\space
mouse.lib /MANIFESTFILE:build\temp.win32-2.6\Release\spacemouse.pyd.manifest
   Creating library build\temp.win32-2.6\Release\spacemouse.lib and object build
\temp.win32-2.6\Release\spacemouse.exp
mt.exe -nologo -manifest build\temp.win32-2.6\Release\spacemouse.pyd.manifest -o
utputresource:build\lib.win32-2.6\spacemouse.pyd;2
error: command 'mt.exe' failed: No such file or directory

Link to comment
Share on other sites

Well I'm using the Windows SDK 6, which corresponds to Visual Studio 2005 (used by SideFX to build Houdini). I currently don't have SDK 7 installed to test it. The error I see in your log is, that the manifest (mt.exe) tool isn't found. This usually should be found in the path, but SDK 7 might have changed that? You could try to add the path to mt.exe in the build.bat script by hand and see if that works. Nevertheless you will have a VC8<->VC9 conflict with your plugin and houdini. It might work, it might not work. Mixing standard runtimes is a dangerous field ;-)

Link to comment
Share on other sites

I fix path to mt.exe and build it again

C:\spacemouse_0.1\native&gt;build
running build
running build_ext
building 'spacemouse' extension
creating build\temp.win32-2.6
creating build\temp.win32-2.6\Release
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\cl.exe /c /nologo /Ox
/MD /W3 /GS- /DNDEBUG -IC:\ext\soft\Python264\include -IC:\ext\soft\Python264\PC
 /Tpspacemouse.cpp /Fobuild\temp.win32-2.6\Release\spacemouse.obj /EHsc
spacemouse.cpp
creating build\lib.win32-2.6
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\BIN\link.exe /DLL /nologo
/INCREMENTAL:NO /LIBPATH:C:\ext\soft\Python264\libs /LIBPATH:C:\ext\soft\Python2
64\PCbuild /EXPORT:initspacemouse build\temp.win32-2.6\Release\spacemouse.obj /O
UT:build\lib.win32-2.6\spacemouse.pyd /IMPLIB:build\temp.win32-2.6\Release\space
mouse.lib /MANIFESTFILE:build\temp.win32-2.6\Release\spacemouse.pyd.manifest
   Creating library build\temp.win32-2.6\Release\spacemouse.lib and object build
\temp.win32-2.6\Release\spacemouse.exp
C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0\bin\mt.exe -nologo -manifest
build\temp.win32-2.6\Release\spacemouse.pyd.manifest -outputresource:build\lib.w
in32-2.6\spacemouse.pyd;2

no errors?

than I create new button in shell with script

import sys
navigatorPath = "C:\spacemouse_0.1"
if not navigatorPath in sys.path:
  sys.path.append(navigatorPath)
import hou_navigator
hou_navigator.start()

when I click it I get this message:

Traceback (most recent call last):
  File "tool_1", line 5, in &lt;module&gt;
  File "C:\spacemouse_0.1\hou_navigator.py", line 173, in &lt;module&gt;
    import spacemouse
ImportError: No module named spacemouse

line 173:

nativePath = "C:\spacemouse_0.1\native\build\lib.win32-2.5"

Edited by Mikx
Link to comment
Share on other sites

Your line specifying nativePath is wrong. You build against python-2.6, so the native module will be placed in "C:\spacemouse_0.1\native\build\lib.win32-2.6". Additionally it's better to use forward slashes for the path (or use double backslashes to escape them), because some (e.g. \n) have a special meaning (e.g. newline). So your line should look like:

nativePath = "C:/spacemouse_0.1/native/build/lib.win32-2.6"

Hope that helps ;-)

Link to comment
Share on other sites

Traceback (most recent call last):
  File "tool_1", line 5, in &lt;module&gt;
  File "C:\spacemouse_0.1\hou_navigator.py", line 173, in &lt;module&gt;
    import spacemouse
ImportError: Module use of python26.dll conflicts with this version of Python.

:(

Link to comment
Share on other sites

I can't find it

and I'm not sure is it fine to install sdk 6.0 on windows 7?

You can find WinSDK6 here: http://www.microsoft.com/downloads/details.aspx?FamilyID=4377F86D-C913-4B5C-B87E-EF72E5B4E065&displaylang=en

Here's also a helpfull site (it lists all available Windows SDKs): http://msdn.microsoft.com/en-us/windows/bb980924.aspx

I don't know what could prohibit installing WinSDK6 on Windows 7.

Link to comment
Share on other sites

I download it

Reinstall the Windows

Install Python 2.5

Install WinSDK6

try to build and again get this:

running build
running build_ext
error: Python was built with Visual Studio 2003;
extensions must be built with a compiler than can generate compatible binaries.
Visual Studio 2003 was not found on this system. If you have Cygwin installed,
you can try compiling with MingW32, by passing "-c mingw32" to setup.py.

Link to comment
Share on other sites

Where did you get your python installation from? I'm using the 64bit release from here: http://www.python.org/download/releases/2.5.4/

The problem now is, that your python seems to be built using Visual Studio 2003 (VC7), but WinSDK6 (that is needed for Houdini) is VC8. Again a version conflict :ph34r:. What's the output of python.exe if you start the interactive shell? Mine is:

Python 2.5.4 (r254:67916, Dec 23 2008, 15:19:34) [MSC v.1400 64 bit (AMD64)] on win32

Here MSC v.1400 corresponds with the compiler version. You can query the compiler version by calling "cl.exe --version". Here is my output:

Microsoft (R) C/C++ Optimizing Compiler Version 14.00.50727.762 for x64

I just noticed, that H10 is shipping with the python headers, so you should be able to use the python installation from there (%HFS%\python).

Link to comment
Share on other sites

Where did you get your python installation from?

I download python-2.5.4.msi from there

What's the output of python.exe if you start the interactive shell?

Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 bit (Intel)] on win32

You can query the compiler version by calling "cl.exe --version".

Microsoft (R) C/C++ Optimizing Compiler Version 15.00.21022.08 for x64

I just noticed, that H10 is shipping with the python headers, so you should be able to use the python installation from there

you mean add to build.bat a path to Houdini\v10.0.430\python\bin\python2.5.exe ?

Edited by Mikx
Link to comment
Share on other sites

Mikx, if you look at your version numbers vs Frank's, then clearly you have *both* the wrong python build AND wrong compiler build.

yes I know....

But I download Python 2.5.4 from here

and Windows SDK 6 from here

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...