#include <Thread.h>
Public Member Functions | |
Thread (bool LockMemory, bool RealTime, int PriorityMax, int PriorityDelta) | |
virtual | ~Thread () |
virtual int | StartThread () |
virtual int | StopThread () |
virtual int | SignalStartThread () |
virtual int | SignalStopThread () |
void | TestCancel () |
virtual bool | IsRunning () |
virtual int | SetSchedulingPriority () |
virtual int | LockMemory () |
virtual void | EnableDestructor () |
virtual int | Destructor () |
virtual int | Main ()=0 |
This method needs to be implemented by the descendant and is the entry point for the new thread. FIXME: should be protected. | |
Static Public Member Functions | |
static void * | allocAlignedMem (size_t boundary, size_t size) |
Allocates an aligned block of memory. | |
static void | freeAlignedMem (void *ptr) |
Frees an aligned block of memory allocated with allocAlignedMem(). | |
static bool | lockMemory (void *addr, size_t size) |
Locks a region of memory in physical RAM. | |
static bool | unlockMemory (void *addr, size_t size) |
Unlocks a region of memory in physical RAM. |
Definition at line 51 of file Thread.h.
LinuxSampler::Thread::Thread | ( | bool | LockMemory, | |
bool | RealTime, | |||
int | PriorityMax, | |||
int | PriorityDelta | |||
) |
virtual LinuxSampler::Thread::~Thread | ( | ) | [virtual] |
static void* LinuxSampler::Thread::allocAlignedMem | ( | size_t | boundary, | |
size_t | size | |||
) | [inline, static] |
Allocates an aligned block of memory.
Allocated memory blocks need to be freed using freeAlignedMem().
boundary | - the alignement boundary, usually a power of 2 e.g. 4 but it can be an arbitrary number between 1 and 128 | |
size | - size in bytes to be allocated |
Definition at line 83 of file Thread.h.
Referenced by LinuxSampler::AudioChannel::AudioChannel().
virtual int LinuxSampler::Thread::Destructor | ( | ) | [virtual] |
virtual void LinuxSampler::Thread::EnableDestructor | ( | ) | [virtual] |
static void LinuxSampler::Thread::freeAlignedMem | ( | void * | ptr | ) | [inline, static] |
Frees an aligned block of memory allocated with allocAlignedMem().
ptr | - pointer to the memory block |
Definition at line 95 of file Thread.h.
Referenced by LinuxSampler::AudioChannel::~AudioChannel().
virtual bool LinuxSampler::Thread::IsRunning | ( | ) | [virtual] |
static bool LinuxSampler::Thread::lockMemory | ( | void * | addr, | |
size_t | size | |||
) | [inline, static] |
virtual int LinuxSampler::Thread::LockMemory | ( | ) | [virtual] |
virtual int LinuxSampler::Thread::Main | ( | ) | [pure virtual] |
This method needs to be implemented by the descendant and is the entry point for the new thread. FIXME: should be protected.
Implemented in LinuxSampler::InstrumentEditor.
virtual int LinuxSampler::Thread::SetSchedulingPriority | ( | ) | [virtual] |
virtual int LinuxSampler::Thread::SignalStartThread | ( | ) | [virtual] |
virtual int LinuxSampler::Thread::SignalStopThread | ( | ) | [virtual] |
virtual int LinuxSampler::Thread::StartThread | ( | ) | [virtual] |
virtual int LinuxSampler::Thread::StopThread | ( | ) | [virtual] |
static bool LinuxSampler::Thread::unlockMemory | ( | void * | addr, | |
size_t | size | |||
) | [inline, static] |