.dll -> ,pyd

Does anyone know exactly how to make a .pyd from a .dll (the dll only exports a simple function to do some mathematical calculations) and to use .pyd as a module in blender?

i have tried to rename .dll to .pyd . but when importing the module,i got an error like function init… not found or something like that.

Thanks in advance!:smiley:

You need to export the functions as python methods, see http://docs.python.org/extending/extending.html#a-simple-example.

…or use ctypes.

i tried the cytpes and it worked . but can i use ctypes in a standalone game?:smiley:
another problem is with pointers ( returning a string from char * )