00001
00002
00003
00004
00005
00008
00009 #define _TYPES_H_
00012
00013 #include <windows.h>
00014 #include <assert.h>
00015
00018
00019 typedef unsigned __int64 qword;
00020 typedef unsigned __int32 dword;
00021 typedef unsigned __int16 word;
00022 typedef unsigned char byte;
00023
00024 typedef signed __int64 sqword;
00025 typedef signed __int32 sdword;
00026 typedef signed __int16 sword;
00027 typedef signed char sbyte;
00028
00031
00032 #ifndef ADLL
00033 #ifdef WIN32
00034 #define ADLL __declspec(dllimport)
00035 #define DLLIMPORT __declspec(dllimport)
00036 #define DLLEXPORT __declspec(dllexport)
00037 #else
00038 #define ADLL
00039 #define DLLIMPORT
00040 #define DLLEXPORT
00041 #endif
00042 #endif
00043
00044 #define countof(x) (sizeof(x)/sizeof(x[0]))
00045
00046 #define GUID(a,b) ((((qword)(dword)a)<<32)|((qword)(dword)b))
00047
00048 #define MAXTEXT 128
00049 #define MAXFILETEXT 256
00050
00051 #define ALIBOBJ\
00052 public:\
00053 ADLL static ACI CI;\
00054 virtual ACI *getCI () { return &CI; }
00055
00056 #define AOBJ\
00057 public:\
00058 static ACI CI;\
00059 virtual ACI *getCI () { return &CI; }
00060
00061 #define PI 3.141592654
00062
00065
00066 __inline int mini(int x, int y) { return x<y?x:y; }
00067 __inline float mini(float x, float y) { return x<y?x:y; }
00068 __inline double mini(double x, double y) { return x<y?x:y; }
00069
00070 __inline int maxi(int x, int y) { return x>y?x:y; }
00071 __inline float maxi(float x, float y) { return x>y?x:y; }
00072 __inline double maxi(double x, double y) { return x>y?x:y; }
00073
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122
00123
00124
00125
00126
00127
00132 #endif //_TYPES_H_