1 /* -----------------------------------------------------------------------------
2 * See the LICENSE file for information on copyright, usage and redistribution
3 * of SWIG, and the README file for authors - http://www.swig.org/release.html.
7 * SWIG library file to support types found in windows.h as well as Microsoft
8 * integral type extensions. The types are set for 32 bit Windows.
9 * ----------------------------------------------------------------------------- */
11 // Support for non ISO (Windows) integral types
12 %apply unsigned char { unsigned __int8 };
13 %apply const unsigned char& { const unsigned __int8& };
15 %apply signed char { __int8 };
16 %apply const signed char& { const __int8& };
18 %apply unsigned short { unsigned __int16 };
19 %apply const unsigned short& { const unsigned __int16& };
21 %apply short { __int16 };
22 %apply const short& { const __int16& };
24 %apply unsigned int { unsigned __int32 };
25 %apply const unsigned int& { const unsigned __int32& };
27 %apply int { __int32 };
28 %apply const int& { const __int32& };
30 %apply unsigned long long { unsigned __int64 };
31 %apply const unsigned long long& { const unsigned __int64& };
33 %apply long long { __int64 };
34 %apply const long long& { const __int64& };
37 // Workaround Microsoft calling conventions
53 #define __declspec(WINDOWS_EXTENDED_ATTRIBUTE)
57 // Types from windef.h
58 typedef unsigned long ULONG;
59 typedef ULONG *PULONG;
60 typedef unsigned short USHORT;
61 typedef USHORT *PUSHORT;
62 typedef unsigned char UCHAR;
63 typedef UCHAR *PUCHAR;
65 typedef unsigned long DWORD;
67 typedef unsigned char BYTE;
68 typedef unsigned short WORD;
70 typedef FLOAT *PFLOAT;
80 typedef DWORD *PDWORD;
81 typedef DWORD *LPDWORD;
83 typedef const void *LPCVOID;
85 typedef unsigned int UINT;
86 typedef unsigned int *PUINT;
88 // Types from basetsd.h
89 typedef signed char INT8, *PINT8;
90 typedef signed short INT16, *PINT16;
91 typedef signed int INT32, *PINT32;
92 typedef signed __int64 INT64, *PINT64;
93 typedef unsigned char UINT8, *PUINT8;
94 typedef unsigned short UINT16, *PUINT16;
95 typedef unsigned int UINT32, *PUINT32;
96 typedef unsigned __int64 UINT64, *PUINT64;
97 typedef signed int LONG32, *PLONG32;
98 typedef unsigned int ULONG32, *PULONG32;
99 typedef unsigned int DWORD32, *PDWORD32;
100 typedef __w64 int INT_PTR, *PINT_PTR;
101 typedef __w64 unsigned int UINT_PTR, *PUINT_PTR;
102 typedef __w64 long LONG_PTR, *PLONG_PTR;
103 typedef __w64 unsigned long ULONG_PTR, *PULONG_PTR;
104 typedef unsigned short UHALF_PTR, *PUHALF_PTR;
105 typedef short HALF_PTR, *PHALF_PTR;
106 typedef __w64 long SHANDLE_PTR;
107 typedef __w64 unsigned long HANDLE_PTR;
108 typedef ULONG_PTR SIZE_T, *PSIZE_T;
109 typedef LONG_PTR SSIZE_T, *PSSIZE_T;
110 typedef ULONG_PTR DWORD_PTR, *PDWORD_PTR;
111 typedef __int64 LONG64, *PLONG64;
112 typedef unsigned __int64 ULONG64, *PULONG64;
113 typedef unsigned __int64 DWORD64, *PDWORD64;
115 // Types from winnt.h
117 typedef void *PVOID64;
122 typedef CHAR *LPCH, *PCH;
123 typedef const CHAR *LPCCH, *PCCH;
125 typedef CHAR *LPSTR, *PSTR;
126 typedef const CHAR *LPCSTR, *PCSTR;
127 typedef char TCHAR, *PTCHAR;
128 typedef unsigned char TBYTE , *PTBYTE ;
129 typedef LPSTR LPTCH, PTCH;
130 typedef LPSTR PTSTR, LPTSTR, PUTSTR, LPUTSTR;
131 typedef LPCSTR PCTSTR, LPCTSTR, PCUTSTR, LPCUTSTR;
132 typedef SHORT *PSHORT;
134 typedef void *HANDLE;
135 typedef HANDLE *PHANDLE;
139 typedef LONG HRESULT;
142 typedef PDWORD PLCID;
144 typedef __int64 LONGLONG;
145 typedef unsigned __int64 ULONGLONG;
146 typedef LONGLONG *PLONGLONG;
147 typedef ULONGLONG *PULONGLONG;
148 typedef ULONGLONG DWORDLONG;
149 typedef DWORDLONG *PDWORDLONG;
150 typedef BYTE BOOLEAN;
151 typedef BOOLEAN *PBOOLEAN;