24#ifndef __LS_THREAD_H__
25#define __LS_THREAD_H__
29#define WIN32_SIGNALSTARTTHREAD_WORKAROUND 1
96 unsigned char *p = (
unsigned char *)
ptr;
180 #if defined(WIN32_SIGNALSTARTTHREAD_WORKAROUND)
198 static void* pthreadLauncher(
void*
thread);
199 static void pthreadDestructor(
void*
thread);
Wraps as a kind of pointer class some data object shared with other threads, to protect / synchronize...
Abstract base class for classes that need to run in an own thread.
void TestCancel()
Synchronization point for potentially terminating the thread.
static void pushCancelable(bool cancel)
virtual int SignalStopThread()
virtual int onThreadEnd()
static void popCancelable()
static void setNameOfCaller(std::string name)
virtual int Main()=0
This method needs to be implemented by the descending class and is the entry point for the new thread...
static bool lockMemory(void *addr, size_t size)
Locks a region of memory in physical RAM.
Thread(bool LockMemory, bool RealTime, int PriorityMax, int PriorityDelta)
static bool unlockMemory(void *addr, size_t size)
Unlocks a region of memory in physical RAM.
static std::string nameOfCaller()
virtual int SignalStartThread()
static void * allocAlignedMem(size_t boundary, size_t size)
Allocates an aligned block of memory.
virtual void EnableDestructor()
static void freeAlignedMem(void *ptr)
Frees an aligned block of memory allocated with allocAlignedMem()
virtual int SetSchedulingPriority()
virtual int StartThread()