AGXDynamics  2.35.0.2
Integer.h
Go to the documentation of this file.
1 /*
2 Copyright 2007-2022. Algoryx Simulation AB.
3 
4 All AGX source code, intellectual property, documentation, sample code,
5 tutorials, scene files and technical white papers, are copyrighted, proprietary
6 and confidential material of Algoryx Simulation AB. You may not download, read,
7 store, distribute, publish, copy or otherwise disseminate, use or expose this
8 material unless having a written signed agreement with Algoryx Simulation AB, or having been
9 advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10 valid commercial license from Algoryx Simulation AB.
11 
12 Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13 from using this software, unless otherwise stated in written agreements with
14 Algoryx Simulation AB.
15 */
16 
17 #ifndef AGXDATA_INTEGER_H
18 #define AGXDATA_INTEGER_H
19 
20 #include <agx/config.h>
21 #include <agx/stdint.h>
22 #include <stdlib.h>
23 #include <limits>
24 
25 namespace agx
26 {
27 
28 #if AGX_64BIT_ARCHITECTURE
29  #define AGX_LONG_IS_DEFAULT true
30  typedef uint64_t UInt;
31  typedef int64_t Int;
32 #else
33  #define AGX_LONG_IS_DEFAULT false
34  typedef uint32_t UInt;
35  typedef int32_t Int;
36 #endif
37 
38  typedef uint8_t UInt8;
39  typedef uint16_t UInt16;
40  typedef uint32_t UInt32;
41  typedef uint64_t UInt64;
42 
43  typedef int8_t Int8;
44  typedef int16_t Int16;
45  typedef int32_t Int32;
46  typedef int64_t Int64;
47 
48  typedef bool Bool;
49 
50  typedef size_t Size;
51 
52  typedef UInt32 Index;
53 
54  // Use UInt types for non-default index types
55  // typedef UInt8 Index8;
56  // typedef UInt16 Index16;
57  // typedef UInt32 Index32;
58  // typedef UInt64 Index64;
59 
60 #ifdef max
61 #undef max
62 #endif
63 
64 #ifdef min
65 #undef min
66 #endif
67 
68  // Name clash with global macro definitions
74 
80 
82 }
83 
84 #endif /* _AGXDATA_INTEGER_H_ */
agx::IntMax
const Int IntMax
Definition: Integer.h:75
agx::UInt64
uint64_t UInt64
Definition: Integer.h:41
agx::UIntMax
const UInt UIntMax
Definition: Integer.h:69
agx::Int8Max
const Int8 Int8Max
Definition: Integer.h:76
agx::Int16
int16_t Int16
Definition: Integer.h:44
agx::Int64Max
const Int64 Int64Max
Definition: Integer.h:79
agx::UInt64Max
const UInt64 UInt64Max
Definition: Integer.h:73
agx::Int16Max
const Int16 Int16Max
Definition: Integer.h:77
agx::Int
int32_t Int
Definition: Integer.h:35
agx
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Definition: AddedMassInteraction.h:22
agx::UInt16
uint16_t UInt16
Definition: Integer.h:39
agx::UInt8
uint8_t UInt8
Definition: Integer.h:38
agx::Size
size_t Size
Definition: Integer.h:50
agx::Index
UInt32 Index
Definition: Integer.h:52
agx::UInt8Max
const UInt8 UInt8Max
Definition: Integer.h:70
agx::Int8
int8_t Int8
Definition: Integer.h:43
stdint.h
agx::SizeMax
const Size SizeMax
Definition: Integer.h:81
agx::UInt
uint32_t UInt
Definition: Integer.h:34
agx::Bool
bool Bool
Definition: Integer.h:48
agx::UInt16Max
const UInt16 UInt16Max
Definition: Integer.h:71
agx::Int64
int64_t Int64
Definition: Integer.h:46
agx::UInt32Max
const UInt32 UInt32Max
Definition: Integer.h:72
agx::Int32Max
const Int32 Int32Max
Definition: Integer.h:78
agx::max
Vec3T< T > max(const Vec3T< T > &lhs, const Vec3T< T > &rhs)
Definition: Vec3Template.h:874
agx::Int32
int32_t Int32
Definition: Integer.h:45
agx::UInt32
uint32_t UInt32
Definition: Integer.h:40