vrshoot

view libs/assimp/irrXML/irrTypes.h @ 2:334d17aed7de

visual studio project files
author John Tsiombikas <nuclear@member.fsf.org>
date Sun, 02 Feb 2014 18:36:38 +0200
parents
children
line source
1 // Copyright (C) 2002-2005 Nikolaus Gebhardt
2 // This file is part of the "Irrlicht Engine".
3 // For conditions of distribution and use, see copyright notice in irrlicht.h
5 #ifndef __IRR_TYPES_H_INCLUDED__
6 #define __IRR_TYPES_H_INCLUDED__
8 namespace irr
9 {
11 //! 8 bit unsigned variable.
12 /** This is a typedef for unsigned char, it ensures portability of the engine. */
13 typedef unsigned char u8;
15 //! 8 bit signed variable.
16 /** This is a typedef for signed char, it ensures portability of the engine. */
17 typedef signed char s8;
19 //! 8 bit character variable.
20 /** This is a typedef for char, it ensures portability of the engine. */
21 typedef char c8;
25 //! 16 bit unsigned variable.
26 /** This is a typedef for unsigned short, it ensures portability of the engine. */
27 typedef unsigned short u16;
29 //! 16 bit signed variable.
30 /** This is a typedef for signed short, it ensures portability of the engine. */
31 typedef signed short s16;
35 //! 32 bit unsigned variable.
36 /** This is a typedef for unsigned int, it ensures portability of the engine. */
37 typedef unsigned int u32;
39 //! 32 bit signed variable.
40 /** This is a typedef for signed int, it ensures portability of the engine. */
41 typedef signed int s32;
45 // 64 bit signed variable.
46 // This is a typedef for __int64, it ensures portability of the engine.
47 // This type is currently not used by the engine and not supported by compilers
48 // other than Microsoft Compilers, so it is outcommented.
49 //typedef __int64 s64;
53 //! 32 bit floating point variable.
54 /** This is a typedef for float, it ensures portability of the engine. */
55 typedef float f32;
57 //! 64 bit floating point variable.
58 /** This is a typedef for double, it ensures portability of the engine. */
59 typedef double f64;
62 } // end namespace
65 // define the wchar_t type if not already built in.
66 #ifdef _MSC_VER
67 #ifndef _WCHAR_T_DEFINED
68 //! A 16 bit wide character type.
69 /**
70 Defines the wchar_t-type.
71 In VS6, its not possible to tell
72 the standard compiler to treat wchar_t as a built-in type, and
73 sometimes we just don't want to include the huge stdlib.h or wchar.h,
74 so we'll use this.
75 */
76 typedef unsigned short wchar_t;
77 #define _WCHAR_T_DEFINED
78 #endif // wchar is not defined
79 #endif // microsoft compiler
81 //! define a break macro for debugging only in Win32 mode.
82 // WORKAROUND (assimp): remove __asm
83 #if defined(WIN32) && defined(_MSC_VER) && defined(_DEBUG)
84 #if defined(_M_IX86)
85 #define _IRR_DEBUG_BREAK_IF( _CONDITION_ ) /*if (_CONDITION_) {_asm int 3}*/
86 #else
87 #define _IRR_DEBUG_BREAK_IF( _CONDITION_ )
88 #endif
89 #else
90 #define _IRR_DEBUG_BREAK_IF( _CONDITION_ )
91 #endif
93 //! Defines a small statement to work around a microsoft compiler bug.
94 /** The microsft compiler 7.0 - 7.1 has a bug:
95 When you call unmanaged code that returns a bool type value of false from managed code,
96 the return value may appear as true. See
97 http://support.microsoft.com/default.aspx?kbid=823071 for details.
98 Compiler version defines: VC6.0 : 1200, VC7.0 : 1300, VC7.1 : 1310, VC8.0 : 1400*/
100 // WORKAROUND (assimp): remove __asm
101 #if defined(WIN32) && defined(_MSC_VER) && (_MSC_VER > 1299) && (_MSC_VER < 1400)
102 #define _IRR_IMPLEMENT_MANAGED_MARSHALLING_BUGFIX /*__asm mov eax,100*/
103 #else
104 #define _IRR_IMPLEMENT_MANAGED_MARSHALLING_BUGFIX
105 #endif // _IRR_MANAGED_MARSHALLING_BUGFIX
107 #endif // __IRR_TYPES_H_INCLUDED__