69 #if defined(XSENS_DEBUG) && defined(_MSC_VER)
70 #pragma warning (disable: 4985)
75 #pragma warning(disable: 4127)
83 #ifndef WINVER // Allow use of features specific to Windows XP or later.
84 #define WINVER 0x0502 // Change this to the appropriate value to target other versions of Windows.
87 #ifndef _WIN32_WINNT // Allow use of features specific to Windows XP or later.
88 #define _WIN32_WINNT 0x0502 // Change this to the appropriate value to target other versions of Windows.
91 #ifndef _WIN32_WINDOWS // Allow use of features specific to Windows 98 or later.
92 #define _WIN32_WINDOWS 0x0410 // Change this to the appropriate value to target Windows Me or later.
95 #ifndef _WIN32_IE // Allow use of features specific to IE 6.0 or later.
96 #define _WIN32_IE 0x0600 // Change this to the appropriate value to target other versions of IE.
119 #define XSENS_THREAD_RETURN DWORD
120 #define XSENS_THREAD_TYPE WINAPI
121 #define XSENS_THREAD_PARAM LPVOID
123 #define XSENS_INVALID_THREAD INVALID_HANDLE_VALUE
131 #define xsYield() Sleep(0)
142 #define xsStartThread(func,param,pid) CreateThread(NULL,0,(LPTHREAD_START_ROUTINE) func,param,0,pid)
146 #define xsGetCurrentThreadId() GetCurrentThreadId()
147 #define xsSuspendThread(thrd) SuspendThread(thrd)
148 #define xsResumeThread(thrd) ResumeThread(thrd)
149 #define xsSetThreadPriority(thrd,prio) SetThreadPriority(thrd,prio)
150 #define xsGetThreadPriority(thrd) GetThreadPriority(thrd)
154 #include <semaphore.h>
175 #define XSENS_THREAD_RETURN void* // DWORD
176 #define XSENS_THREAD_TYPE // WINAPI
177 #define XSENS_THREAD_PARAM void* // LPVOID
179 #define XSENS_INVALID_THREAD 0 // INVALID_HANDLE_VALUE
182 #define xsYield() sched_yield()
190 pthread_t
xsStartThread(
void* (func)(
void*),
void* param,
void* pid);
191 #define xsGetCurrentThreadId() pthread_self()
192 #define xsSuspendThread(thrd)
193 #define xsResumeThread(thrd)
194 #define xsSetThreadPriority(thrd,prio)
198 #if !defined(XSENS_USE_POSIX_LOCKING)
199 #if defined(XSENS_WINDOWS)
200 #define XSENS_USE_POSIX_LOCKING 0
202 #define XSENS_USE_POSIX_LOCKING 1
207 #pragma warning(default: 4127)