I am trying to use the QuickCamLib library with Python.net. I looks like I'm not getting the .net library loaded right, but I'm new to Python.net and to .net in general, so I'm not sure I'm doing everything right.
The quickcamlib is here: http://grazz.com/projects/quickcamlib Here's what I get on the shell: Python 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)] on win32 Type "copyright", "credits" or "license()" for more information. **************************************************************** Personal firewall software may warn about the connection IDLE makes to its subprocess using this computer's internal loopback interface. This connection is not visible on any external interface and no data is sent to or received from the Internet. **************************************************************** IDLE 1.2.2 >>> import clr >>> import QuickCamLib >>> from QuickCamLib import QuickCam >>> dir(QuickCam) ['Capture', 'Dispose', 'Equals', 'Finalize', 'Focus', 'GetAvailableDevices', 'GetAvailableResolutions', 'GetHashCode', 'GetType', 'MemberwiseClone', 'Pan', 'ReferenceEquals', 'ResetPTZ', 'Tilt', 'ToString', 'Zoom', '__call__', '__class__', '__cmp__', '__delattr__', '__delitem__', '__doc__', '__getattribute__', '__getitem__', '__hash__', '__init__', '__iter__', '__module__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__setitem__', '__str__'] >>> QuickCam.GetAvailableDevices <unbound method 'GetAvailableDevices'> >>> for r in QuickCam.GetAvailableDevices: print r Traceback (most recent call last): File "<pyshell#6>", line 1, in <module> for r in QuickCam.GetAvailableDevices: print r TypeError: 'MethodBinding' object is not iterable >>> from System.Drawing import Point >>> p = Point(5,5) >>> print p {X=5,Y=5} >>> (the "Point" stuff is there to show that Python.net seems to work for some objects, just not others) The 'unbound method' message is worrisome. Seems to me it should have done something instead of just complain that it is unbound. Lazy binding isn't usually this lazy :) I don't know enough about .net to really test this library any other way, so it is also possible the library is dorked up somehow. If I need to send more/different data, please let me know. Like I said, I'm new at a lot of this, so I'm likely missing something simple. Thanks in advance. -- Beware programmers with screwdrivers. Or, for that matter, any other mixed drink.
_________________________________________________ Python.NET mailing list - PythonDotNet@python.org http://mail.python.org/mailman/listinfo/pythondotnet