开发者

How to get IUnknown from WDM driver CreateInstance

开发者 https://www.devze.com 2022-12-18 11:42 出处:网络
In documentation (C++ example) L开发者_开发知识库Unknown* pIUnknown = CreateInstance(slot); I try this

In documentation (C++ example)

L开发者_开发知识库Unknown* pIUnknown = CreateInstance(slot);

I try this

>> import ctypes
>> print type(ctypes.cdll.lcomp.CreateInstance(0))
<type 'int'>

How to get IUNKNOWN and QueryInterface?


I guess that accessing COM object with ctypes might be a bit difficult. I would recommend to have a look to win32com included in the windows extensions by Mark Hammond.

You can start with this tutorial : http://www.boddie.org.uk/python/COM.html

I hope it helps

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号