[IronPython] Using callback function

Harri Vartiainen harri.vartiainen at iki.fi
Tue Mar 4 18:23:41 CET 2008


Hi,

 I'm trying to use callback function of dll. The API has VB.NET
definition for callback:

Public Class FosdkApi
...
   ' set callback function
    'FOSDKLIB_API BOOL WINAPI FOSDKSetCallback(IN INT nCamIndex,
    '                                          IN INT (CALLBACK
*pCallbackFunc)(VOID *pContext, DOUBLE SampleTime, BYTE *pBuf, LONG
lBufferSize)
    '
                IN VOID *pCBContext);

    Public Declare Function FOSDKSetCallback Lib "FOSDK" (ByVal
nCamIndex As Long, ByVal pCallbackFunc As Long, ByVal pCBContext As
Long) As Long

 Help(FosdkApi.FOSDKSetCallback) prints:

Help on built-in function FOSDKSetCallback

 |  FOSDKSetCallback(...)
 |          Int64 FOSDKSetCallback(Int64 nCamIndex, Int64
pCallbackFunc, Int64 pCBContext)

 So how I can use that?



More information about the Ironpython-users mailing list