[Bf-python] Accessing LeapPython.so files from bge scripts

Paul Coones paulcoones at comcast.net
Fri Apr 5 01:53:42 CEST 2013


Hi, this is Paul (upretirementman) and I am a Leap Motion developer using a Mac Mini/Snow Leopard.
I am trying to develop this Leap Motion technology for a bge demo. I'm having some difficulty with accessing key/values in a LeapPython.so (dynlib).

This is sample of part of the LeapPython.so (.dynlib) I need to access in Blender 2.66a Game Engine on my MacMini SnowLeopard 32 bit:

(Not necessarily the beginning of the /C/C++ Library)

Possible C/C++ prototypes are:
   Leap::Tool::Tool()
   Leap::Tool::Tool(Leap::Pointable const &)
O:new_Tool in method 'new_Tool', argument 1 of type 'Leap::Pointable const &' invalid null reference in method 'new_Tool', argument 1 of type 'Leap::Pointable const &' :new_Tool O:delete_Finger in method 'delete_Finger', argument 1 of type 'Leap::Finger *' O:Finger___str__ in method 'Finger___str__', argument 1 of type 'Leap::Finger const *' Wrong number or type of arguments for overloaded function 'new_Finger'.

This is the type of errors I am getting when there is a call like:

    __swig_destroy__ = LeapPython.delete_FloatArray


Python script error - object 'TheMostImportantEmpty', controller 'Process':
Traceback (most recent call last):
 File "Process.py", line 1, in <module>
   import Leap, GameLogic
 File "/Users/paulcoones/Desktop/AUTODESK(1).blend/Leap.py", line 247, in <module>
 File "/Users/paulcoones/Desktop/AUTODESK(1).blend/Leap.py", line 289, in FloatArray
AttributeError: 'module' object has no attribute 'delete_FloatArray'

After looking at this type of error, what is the correct location to put the LeapPython.so ( dynamic library ) so a Blender script can find it and access the data on it? Any other thoughts? Thanks.

I just found out I had the LeapPython library file extension is .py not .so! Would that make a difference?

Paul




More information about the Bf-python mailing list