FIFE
2008.0
|
00001 /*************************************************************************** 00002 * Copyright (C) 2005-2010 by the FIFE team * 00003 * http://www.fifengine.net * 00004 * This file is part of FIFE. * 00005 * * 00006 * FIFE is free software; you can redistribute it and/or * 00007 * modify it under the terms of the GNU Lesser General Public * 00008 * License as published by the Free Software Foundation; either * 00009 * version 2.1 of the License, or (at your option) any later version. * 00010 * * 00011 * This library is distributed in the hope that it will be useful, * 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00014 * Lesser General Public License for more details. * 00015 * * 00016 * You should have received a copy of the GNU Lesser General Public * 00017 * License along with this library; if not, write to the * 00018 * Free Software Foundation, Inc., * 00019 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * 00020 ***************************************************************************/ 00021 00022 #ifndef FIFE_UTIL_FIFE_STDINT_H 00023 #define FIFE_UTIL_FIFE_STDINT_H 00024 00025 // Standard C++ library includes 00026 00027 // Platform specific includes 00028 #if defined( WIN32 ) && defined( _MSC_VER ) 00029 #ifndef _SDL_H 00030 typedef signed __int8 int8_t; 00031 typedef unsigned __int8 uint8_t; 00032 typedef signed __int16 int16_t; 00033 typedef unsigned __int16 uint16_t; 00034 typedef signed __int32 int32_t; 00035 typedef unsigned __int32 uint32_t; 00036 typedef signed __int64 int64_t; 00037 typedef unsigned __int64 uint64_t; 00038 #endif 00039 #else 00040 #include <stdint.h> 00041 #endif 00042 00043 // 3rd party library includes 00044 00045 // FIFE includes 00046 // These includes are split up in two parts, separated by one empty line 00047 // First block: files included from the FIFE root src directory 00048 // Second block: files included from the same folder 00049 00050 // SDL masks for SDL_CreateRGBSurface 00051 namespace FIFE { 00052 #if SDL_BYTEORDER == SDL_LIL_ENDIAN 00053 const uint32_t RMASK = 0xff000000; 00054 const uint32_t GMASK = 0x00ff0000; 00055 const uint32_t BMASK = 0x0000ff00; 00056 const uint32_t AMASK = 0x000000ff; 00057 #else 00058 const uint32_t RMASK = 0x000000ff; 00059 const uint32_t GMASK = 0x0000ff00; 00060 const uint32_t BMASK = 0x00ff0000; 00061 const uint32_t AMASK = 0xff000000; 00062 #endif 00063 const int32_t NULLMASK = 0x00000000; 00064 } //FIFE 00065 00066 #endif // FIFEINT_H