Crudebyte Logo
thread.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2001-2013
3 
4  Developers:
5 
6  Paul Davis
7  Jack O'Quin
8  Steve Harris
9  Rui Nuno Capela
10  Devin Anderson
11  Kai Vehmanen
12  Ian Esten
13  Dmitry Baikov
14  Torben Hohn
15  Rohan Drape
16  Stephane Letz
17  Christian Schoenebeck
18 
19  This program is free software; you can redistribute it and/or modify
20  it under the terms of the GNU Lesser General Public License as published by
21  the Free Software Foundation; either version 2.1 of the License, or
22  (at your option) any later version.
23 
24  This program is distributed in the hope that it will be useful,
25  but WITHOUT ANY WARRANTY; without even the implied warranty of
26  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27  GNU Lesser General Public License for more details.
28 
29  You should have received a copy of the GNU Lesser General Public License
30  along with this program; if not, write to the Free Software
31  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
32 
33  You are permitted to statically link against a binary version of
34  the JACK library obtained from
35 
36  http://jackaudio.org/downloads/JackiOS-SDK.zip
37 
38  and distribute the resulting application without complying with section 6
39  (requiring recipients of your application to be able to relink against
40  modified versions of libjack).
41 
42  This permission is granted if and ONLY if the resulting application binary
43  issue is intended for execution in any one of the following environments:
44 
45  * Apple Inc. iOS
46 
47  Additional environments may be added to this list in the future.
48  All other terms of the LGPL continue to apply.
49 
50 */
51 
52 #ifndef __jack_thread_h__
53 #define __jack_thread_h__
54 
55 #ifdef __cplusplus
56 extern "C"
57 {
58 #endif
59 
60 #include <jack/systemdeps.h>
61 #include <jack/weakmacros.h>
62 
63 /* use 512KB stack per thread - the default is way too high to be feasible
64  * with mlockall() on many systems */
65 #define THREAD_STACK 524288
66 
93 int jack_client_real_time_priority (jack_client_t*) JACK_OPTIONAL_WEAK_EXPORT;
94 
101 int jack_client_max_real_time_priority (jack_client_t*) JACK_OPTIONAL_WEAK_EXPORT;
102 
113 int jack_acquire_real_time_scheduling (jack_native_thread_t thread, int priority) JACK_OPTIONAL_WEAK_EXPORT;
114 
132  jack_native_thread_t *thread,
133  int priority,
134  int realtime, /* boolean */
135  void *(*start_routine)(void*),
136  void *arg) JACK_OPTIONAL_WEAK_EXPORT;
137 
145 int jack_drop_real_time_scheduling (jack_native_thread_t thread) JACK_OPTIONAL_WEAK_EXPORT;
146 
154 int jack_client_stop_thread(jack_client_t* client, jack_native_thread_t thread) JACK_OPTIONAL_WEAK_EXPORT;
155 
163  int jack_client_kill_thread(jack_client_t* client, jack_native_thread_t thread) JACK_OPTIONAL_WEAK_EXPORT;
164 
165 #ifndef WIN32
166 
167  typedef int (*jack_thread_creator_t)(pthread_t*,
168  const pthread_attr_t*,
169  void* (*function)(void*),
170  void* arg);
190 void jack_set_thread_creator (jack_thread_creator_t creator) JACK_OPTIONAL_WEAK_EXPORT;
191 
192 #endif
193 
194 /* @} */
195 
196 #ifdef __cplusplus
197 }
198 #endif
199 
200 #endif /* __jack_thread_h__ */
DE • EN
Copyright © MMXIII Crudebyte. All rights reserved.

twitter