1 Nov 2008 14:07
Re: about Windows handles (Thomas Heller)
Stegmann Patricio <kpoman <at> hotmail.com>
2008-11-01 13:07:34 GMT
2008-11-01 13:07:34 GMT
thanks for you answer. I was looking on google for IIRC but cant find what it is. Is it a python module ? Where can I get it ?
Thanks again.
> From: ctypes-users-request <at> lists.sourceforge.net
> Subject: ctypes-users Digest, Vol 31, Issue 1
> To: ctypes-users <at> lists.sourceforge.net
> Date: Sat, 1 Nov 2008 12:09:33 +0000
>
> Send ctypes-users mailing list submissions to
> ctypes-users <at> lists.sourceforge.net
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/ctypes-users
> or, via email, send a message with subject or body 'help' to
> ctypes-users-request <at> lists.sourceforge.net
>
> You can reach the person managing the list at
> ctypes-users-owner <at> lists.sourceforge.net
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of ctypes-users digest..."
>
>
> Today's Topics:
>
> 1. Re: about Windows handles (Thomas Heller)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Fri, 31 Oct 2008 20:20:08 +0100
> From: Thomas Heller <theller <at> ctypes.org>
> Subject: Re: [ctypes-users] about Windows handles
> To: ctypes-users <at> lists.sourceforge.net
> Message-ID: <geflp3$418$1 <at> ger.gmane.org>
> Content-Type: text/plain; charset=ISO-8859-15
>
> Stegmann Patricio schrieb:
> > Hello to all,
> >
> > I am currently developping a python library to drive Crossmatch fingerprint live scanners.
> > The SDK has lot of functions related to device handles or window handles, for example:
> >
> > int WINAPI LSCAN_Main_Initialize (
> > const int deviceIndex,
> > const BOOL reset,
> > int * handle
> > )
> >
> > or
> >
> > int WINAPI LSCAN_Visualization_SetWindow (
> > const int handle,
> > const HWND hWnd,
> > const RECT drawRect
> > )
> >
> > I am having some problems with this.
> >
> > 1) when I use the LSCAN_Main_Initialize, it is returning me a correct
> > handle ( 0 in my case ) but whenever the python I have returns I get
> > a Windows 'access violation' error, but if I maintain the object
> > alive by some loop it doesn't make that error, I guess there is
> > somekind of garbage collection that makes this error happen. See this
> > block of code:
>
> > if __name__ == '__main__':
> > c = LscanDevice()
> > devs = c.listDevices()
> > c.selectDevice(device_index=0)
> > c.openDevice()
> > c.doNothing()
> >
> > with
> > def doNothing(self):
> > while 1:
> > print 'doing nothing ...'
> > time.sleep(1)
> >
> > as soon as I break that loop with Ctrl+C it makes the access violation error !
> >
>
> I cannot help with this problem.
>
> > 2) with the LSCAN_Visualization_SetWindow I guess it is asking me to
> > create some "windows window" and to have a handle for it and pass it
> > as the hWnd argument. Is there a way to create those kind of windows
> > with ctypes or somehow ? I used to use wxpython for those kind of
> > matters, but now it is requiring a handle HWND for it so I guess I
> > cannot do it with WxPython. Is there a way to create a window to have
> > the SDK write on it ?
>
> IIRC (I don't use wx myself nowadays) wx windows have a GetHandle() method
> or something like that.
>
> Thomas
>
>
>
>
> ------------------------------
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
>
> ------------------------------
>
> _______________________________________________
> ctypes-users mailing list
> ctypes-users <at> lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/ctypes-users
>
>
> End of ctypes-users Digest, Vol 31, Issue 1
> *******************************************
Invite your mail contacts to join your friends list with Windows Live Spaces. It's easy! Try it!
------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________ ctypes-users mailing list ctypes-users <at> lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ctypes-users
a matter of generating wrapper code for them, similar to how code for
functions is generated. Maybe I can look into it when I have time...
Thomas
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
RSS Feed