source: trunk/src/quartz/iunk.h@ 6578

Last change on this file since 6578 was 6578, checked in by sandervl, 24 years ago

wine updates

File size: 1.0 KB
Line 
1/*
2 * An implementation of IUnknown.
3 *
4 * hidenori@a2.ctktv.ne.jp
5 */
6
7#ifndef WINE_DSHOW_IUNK_H
8#define WINE_DSHOW_IUNK_H
9
10/*
11 To avoid implementing IUnknown for all interfaces,
12
13 1) To give a method to get rel-offset of IUnknown.
14 2) The IUnknown knows all IIDs and offsets of interfaces.
15
16 So each implementation must have following two members
17 with the following order:
18
19 typedef struct IDispatchImpl
20 {
21 ICOM_VFIELD(IDispatch); <-pointer of the interface.
22 size_t ofsIUnknown; <-ofs<IDispatchImpl> - ofs<QUARTZ_IUnkImpl>
23 };
24
25 */
26
27typedef struct QUARTZ_IFEntry
28{
29 REFIID piid; /* interface ID. */
30 size_t ofsVTPtr; /* offset from IUnknown. */
31} QUARTZ_IFEntry;
32
33typedef struct QUARTZ_IUnkImpl
34{
35 /* pointer of IUnknown interface. */
36 ICOM_VFIELD(IUnknown);
37
38 /* array of supported IIDs and offsets. */
39 const QUARTZ_IFEntry* pEntries;
40 DWORD dwEntries;
41
42 /* IUnknown fields. */
43 ULONG ref;
44 IUnknown* punkControl;
45} QUARTZ_IUnkImpl;
46
47
48void QUARTZ_IUnkInit( QUARTZ_IUnkImpl* pImpl, IUnknown* punkOuter );
49
50
51#endif /* WINE_DSHOW_IUNK_H */
Note: See TracBrowser for help on using the repository browser.