annotate loader/com.h @ 1597:37b81a811cb2

fixed seeking (now allows seeking before start position)
author arpi
date Mon, 20 Aug 2001 21:20:39 +0000
parents 558c1b03b8d0
children 392316004607
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
1 #ifndef AVIFILE_COM_H
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
2 #define AVIFILE_COM_H
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
3
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
4 #include <inttypes.h>
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
5
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
6 /**
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
7 * Internal functions and structures for COM emulation code.
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
8 */
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
9
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
10 #ifndef WIN32
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
11
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
12 #ifdef __cplusplus
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
13 extern "C" {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
14 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
15
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
16 void* CoTaskMemAlloc(unsigned long cb);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
17 void CoTaskMemFree(void* cb);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
18
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
19 #ifndef GUID_TYPE
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
20 #define GUID_TYPE
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
21 typedef struct
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
22 {
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
23 uint32_t f1;
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
24 uint16_t f2;
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
25 uint16_t f3;
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
26 uint8_t f4[8];
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
27 } GUID;
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
28 #endif
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
29
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
30 extern GUID IID_IUnknown;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
31 extern GUID IID_IClassFactory;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
32
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
33 typedef long (*GETCLASSOBJECT) (GUID* clsid, GUID* iid, void** ppv);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
34 int RegisterComClass(GUID* clsid, GETCLASSOBJECT gcs);
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
35 int UnregisterComClass(GUID* clsid, GETCLASSOBJECT gcs);
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
36
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
37 #ifndef STDCALL
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
38 #define STDCALL __attribute__((__stdcall__))
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
39 #endif
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
40
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
41 struct IUnknown;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
42 struct IClassFactory;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
43 struct IUnknown_vt
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
44 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
45 long STDCALL (*QueryInterface)(struct IUnknown* _this, GUID* iid, void** ppv);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
46 long STDCALL (*AddRef)(struct IUnknown* _this) ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
47 long STDCALL (*Release)(struct IUnknown* _this) ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
48 } ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
49 struct IUnknown
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
50 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
51 struct IUnknown_vt* vt;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
52 };
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
53
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
54 struct IClassFactory_vt
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
55 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
56 long STDCALL (*QueryInterface)(struct IUnknown* _this, GUID* iid, void** ppv);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
57 long STDCALL (*AddRef)(struct IUnknown* _this) ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
58 long STDCALL (*Release)(struct IUnknown* _this) ;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
59 long STDCALL (*CreateInstance)(struct IClassFactory* _this, struct IUnknown* pUnkOuter, GUID* riid, void** ppvObject);
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
60 };
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
61
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
62 struct IClassFactory
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
63 {
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
64 struct IClassFactory_vt* vt;
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
65 };
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
66
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
67 long CoCreateInstance(GUID* rclsid, struct IUnknown* pUnkOuter,
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
68 long dwClsContext, GUID* riid, void** ppv);
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
69
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
70 #ifdef __cplusplus
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
71 };
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
72 #endif /* __cplusplus */
1
3b5f5d1c5041 Initial revision
arpi_esp
parents:
diff changeset
73
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
74 #endif /* WIN32 */
302
a1fe76547e8f gcc 3.0 patch by Felix von Leitner
arpi_esp
parents: 1
diff changeset
75
1544
558c1b03b8d0 updated
arpi
parents: 302
diff changeset
76 #endif /* AVIFILE_COM_H */