2 * Modified for use with MPlayer, detailed changelog at
3 * http://svn.mplayerhq.hu/mplayer/trunk/
18 * Internal functions and structures for COM emulation code.
32 extern const GUID IID_IUnknown
;
33 extern const GUID IID_IClassFactory
;
35 typedef long (*GETCLASSOBJECT
) (GUID
* clsid
, const GUID
* iid
, void** ppv
);
36 int RegisterComClass(const GUID
* clsid
, GETCLASSOBJECT gcs
);
37 int UnregisterComClass(const GUID
* clsid
, GETCLASSOBJECT gcs
);
40 #define STDCALL __attribute__((__stdcall__))
47 long STDCALL (*QueryInterface
)(struct IUnknown
* this, const GUID
* iid
, void** ppv
);
48 long STDCALL (*AddRef
)(struct IUnknown
* this) ;
49 long STDCALL (*Release
)(struct IUnknown
* this) ;
52 typedef struct IUnknown
54 struct IUnknown_vt
* vt
;
57 struct IClassFactory_vt
59 long STDCALL (*QueryInterface
)(struct IUnknown
* this, const GUID
* iid
, void** ppv
);
60 long STDCALL (*AddRef
)(struct IUnknown
* this) ;
61 long STDCALL (*Release
)(struct IUnknown
* this) ;
62 long STDCALL (*CreateInstance
)(struct IClassFactory
* this, struct IUnknown
* pUnkOuter
, const GUID
* riid
, void** ppvObject
);
67 struct IClassFactory_vt
* vt
;
71 long CoCreateInstance(GUID
* rclsid
, struct IUnknown
* pUnkOuter
,
72 long dwClsContext
, const GUID
* riid
, void** ppv
);
73 void* CoTaskMemAlloc(unsigned long cb
);
74 void CoTaskMemFree(void* cb
);
76 long STDCALL
CoCreateInstance(GUID
* rclsid
, struct IUnknown
* pUnkOuter
,
77 long dwClsContext
, const GUID
* riid
, void** ppv
);
78 void* STDCALL
CoTaskMemAlloc(unsigned long);
79 void STDCALL
CoTaskMemFree(void*);
82 #endif /* MPLAYER_COM_H */