thread.h File Reference

#include <pthread.h>

Go to the source code of this file.

Functions

int jack_acquire_real_time_scheduling (pthread_t thread, int priority)
int jack_create_thread (pthread_t *thread, int priority, int realtime, void *(*start_routine)(void *), void *arg)
int jack_drop_real_time_scheduling (pthread_t thread)


Detailed Description

Library functions to standardize thread creation for JACK and its clients. These interfaces hide some system variations in the handling of realtime scheduling and associated privileges.

Function Documentation

int jack_acquire_real_time_scheduling pthread_t  thread,
int  priority
 

Attempt to enable realtime scheduling for a thread. On some systems that may require special privileges.

Parameters:
thread POSIX thread ID.
priority requested thread priority.
Returns:
0, if successful; EPERM, if the calling process lacks required realtime privileges; otherwise some other error number.

int jack_create_thread pthread_t *  thread,
int  priority,
int  realtime,
void *(*  start_routine)(void *),
void *  arg
 

Create a thread for JACK or one of its clients. The thread is created executing start_routine with arg as its sole argument.

Parameters:
thread place to return POSIX thread ID.
priority thread priority, if realtime.
realtime true for the thread to use realtime scheduling. On some systems that may require special privileges.
start_routine function the thread calls when it starts.
arg parameter passed to the start_routine.
Returns:
0, if successful; EPERM, if the calling process lacks required realtime privileges; otherwise some other error number.

int jack_drop_real_time_scheduling pthread_t  thread  ) 
 

Drop realtime scheduling for a thread.

Parameters:
thread POSIX thread ID.
Returns:
0, if successful; otherwise an error number.


Generated on Sun Sep 19 10:22:22 2004 for JACK-AUDIO-CONNECTION-KIT by doxygen 1.3.8