Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

global.hpp

Go to the documentation of this file.
00001 // libdoomwad: manipulates Doom wad files.
00002 // Copyright (C) 2005  John Gaughan
00003 //
00004 // This library is free software; you can redistribute it and/or
00005 // modify it under the terms of the GNU Lesser General Public
00006 // License as published by the Free Software Foundation; either
00007 // version 2.1 of the License, or (at your option) any later version.
00008 //
00009 // This library is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012 // Lesser General Public License for more details.
00013 //
00014 // You should have received a copy of the GNU Lesser General Public
00015 // License along with this library; if not, write to the Free Software
00016 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017 //
00018 // This library is distributed with the full text of the LGPL. Please see
00019 // the accompanying file named COPYING.
00020 // 
00021 // You may contact the author at john@johngaughan.net
00022 
00059 // C++ required.
00060 #if !defined __cplusplus
00061 #error C++ compiler required
00062 #endif
00063 
00064 // OS headers
00065 #if defined WINDOWS
00066 #include <windows.h>
00067 #endif
00068 
00069 // C++ headers
00070 #include <string>
00071 
00072 // Include guard.
00073 #if !defined GLOBAL_HPP
00074 #define GLOBAL_HPP
00075 
00076 // Endian-ness. Make sure only one type is defined. Prefer little endian if
00077 // both or neither are defined.
00078 #if defined LITTLE_ENDIAN
00079 #undef BIG_ENDIAN
00080 #elif defined BIG_ENDIAN
00081 #undef LITTLE_ENDIAN
00082 #else
00083 
00086 #define LITTLE_ENDIAN
00087 #endif
00088 
00089 // DLL linkage specifications for Win32.
00090 #if defined WINDOWS
00091 
00092 #if defined MAKEDLL
00093 #define EXPORT __declspec(dllexport)
00094 #else
00095 #define EXPORT __declspec(dllimport)
00096 #endif // MAKEDLL
00097 
00098 #else // Not WINDOWS
00099 
00122 #define EXPORT
00123 
00124 #endif // WINDOWS
00125 
00149 namespace Doomwad
00150 {
00151 
00153   typedef char int8;
00154 
00156   typedef unsigned char uint8;
00157 
00159   typedef short int int16;
00160 
00162   typedef unsigned short int uint16;
00163 
00165   typedef int int32;
00166 
00168   typedef unsigned int uint32;
00169 
00171   typedef long long int int64;
00172 
00174   typedef unsigned long long int uint64;
00175 
00177   typedef uint8 byte;
00178 
00180   typedef uint16 word;
00181 
00183   typedef uint32 dword;
00184 
00186   typedef uint64 qword;
00187 }
00188 #endif

Generated on Fri Jun 10 19:38:51 2005 for libdoomwad by  doxygen 1.4.0