Main MRPT website
>
C++ reference for MRPT 1.9.9
xSens_MT4
xstypes
include
xsens
xstypedefs.h
Go to the documentation of this file.
1
/* +------------------------------------------------------------------------+
2
| Mobile Robot Programming Toolkit (MRPT) |
3
| http://www.mrpt.org/ |
4
| |
5
| Copyright (c) 2005-2018, Individual contributors, see AUTHORS file |
6
| See: http://www.mrpt.org/Authors - All rights reserved. |
7
| Released under BSD License. See details in http://www.mrpt.org/License |
8
+------------------------------------------------------------------------+ */
9
#ifndef XSTYPEDEFS_H
10
#define XSTYPEDEFS_H
11
12
#include "
xstypesconfig.h
"
13
14
#ifndef XSENS_SINGLE_PRECISION
15
#include <stddef.h>
16
/** Defines the floating point type used by the Xsens libraries */
17
typedef
double
XsReal
;
18
/** XsSize must be unsigned number! */
19
typedef
size_t
XsSize
;
20
#ifndef PRINTF_SIZET_MODIFIER
21
#if defined(XSENS_64BIT)
22
#define PRINTF_SIZET_MODIFIER "l"
23
#else
24
#define PRINTF_SIZET_MODIFIER ""
25
#endif
26
#endif // PRINTF_SIZET_MODIFIER
27
#else
28
/** Defines the floating point type used by the Xsens libraries */
29
typedef
float
XsReal
;
30
/** XsSize must be unsigned number! */
31
typedef
unsigned
int
XsSize
;
32
#endif // XSENS_SINGLE_PRECISION
33
34
/*! \addtogroup enums Global enumerations
35
@{
36
*/
37
/*! \brief These flags define the behaviour of data contained by Xsens data
38
structures
39
\details Normally, the user should never need to use these directly.
40
*/
41
enum
XsDataFlags
42
{
43
/** No flag set */
44
XSDF_None
= 0
45
/** The contained data should be managed (freed) by the object, when false,
46
the object assumes the memory is freed by some other process after its
47
destruction */
48
,
49
XSDF_Managed
= 1
50
/** The contained data points to a fixed-size buffer, this allows creation
51
of dynamic objects on the stack without malloc/free overhead. */
52
,
53
XSDF_FixedSize
= 2
54
/** The object contains undefined data / should be considered empty. Usually
55
only relevant when XSDF_FixedSize is also set, as otherwise the data
56
pointer will be nullptr and empty-ness is implicit. */
57
,
58
XSDF_Empty
= 4
59
};
60
/*! @} */
61
typedef
enum
XsDataFlags
XsDataFlags
;
62
63
#ifdef __cplusplus
64
extern
"C"
{
65
#endif
66
67
XSTYPES_DLL_API
const
char
*
XsDataFlags_toString
(
XsDataFlags
f);
68
69
#ifdef __cplusplus
70
}
// extern "C"
71
/*! \brief \copybrief XsDataFlags_toString \sa XsDataFlags_toString */
72
inline
const
char
* toString(
XsDataFlags
s
) {
return
XsDataFlags_toString
(
s
); }
73
#else
74
// define BOOL, TRUE and FALSE
75
#ifndef BOOL
76
typedef
int
BOOL
;
77
#endif
78
79
#ifndef TRUE
80
#define TRUE (1)
81
#endif
82
83
#ifndef FALSE
84
#define FALSE (0)
85
#endif
86
#endif // __cplusplus
87
88
#define XS_ENUM_TO_STR_CASE(value) \
89
case value: \
90
return #value;
91
92
#endif // file guard
s
GLdouble s
Definition:
glext.h:3676
XSDF_FixedSize
@ XSDF_FixedSize
Definition:
xstypedefs.h:53
XsDataFlags_toString
const XSTYPES_DLL_API char * XsDataFlags_toString(XsDataFlags f)
XsReal
double XsReal
Defines the floating point type used by the Xsens libraries.
Definition:
xstypedefs.h:17
XsSize
size_t XsSize
XsSize must be unsigned number!
Definition:
xstypedefs.h:19
XSDF_Empty
@ XSDF_Empty
Definition:
xstypedefs.h:58
xstypesconfig.h
BOOL
int BOOL
Definition:
xstypedefs.h:76
XSDF_None
@ XSDF_None
No flag set.
Definition:
xstypedefs.h:44
XSTYPES_DLL_API
#define XSTYPES_DLL_API
Definition:
xstypesconfig.h:9
XsDataFlags
XsDataFlags
These flags define the behaviour of data contained by Xsens data structures.
Definition:
xstypedefs.h:41
XSDF_Managed
@ XSDF_Managed
Definition:
xstypedefs.h:49
Page generated by
Doxygen 1.8.17
for MRPT 1.9.9 Git: ad3a9d8ae Tue May 1 23:10:22 2018 -0700 at miƩ 12 jul 2023 10:03:34 CEST