~ubuntu-branches/ubuntu/saucy/jack-audio-connection-kit/saucy

« back to all changes in this revision

Viewing changes to jackd/clientengine.h

  • Committer: Bazaar Package Importer
  • Author(s): Luca Falavigna
  • Date: 2008-12-06 11:05:15 UTC
  • mfrom: (4.1.3 sid)
  • Revision ID: james.westby@ubuntu.com-20081206110515-xa9v9pajr9jqvfvg
Tags: 0.115.6-1ubuntu1
* Merge from Debian unstable, remaining Ubuntu changes:
  - Redirect stderr in bash completion (Debian #504488).

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *  Client creation and destruction interfaces for JACK engine.
 
3
 *
 
4
 *  Copyright (C) 2001-2003 Paul Davis
 
5
 *  Copyright (C) 2004 Jack O'Quin
 
6
 *  
 
7
 *  This program is free software; you can redistribute it and/or
 
8
 *  modify it under the terms of the GNU General Public License as
 
9
 *  published by the Free Software Foundation; either version 2 of the
 
10
 *  License, or (at your option) any later version.
 
11
 *
 
12
 *  This program is distributed in the hope that it will be useful,
 
13
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
15
 *  General Public License for more details.
 
16
 *
 
17
 *  You should have received a copy of the GNU General Public License
 
18
 *  along with this program; if not, write to the Free Software
 
19
 *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
20
 *
 
21
 */
 
22
 
 
23
static inline int 
 
24
jack_client_is_internal (jack_client_internal_t *client)
 
25
{
 
26
        return (client->control->type == ClientInternal) ||
 
27
                (client->control->type == ClientDriver);
 
28
}
 
29
 
 
30
static inline char *
 
31
jack_client_state_name (jack_client_internal_t *client)
 
32
{
 
33
        static char *client_state_names[] = {
 
34
                "Not triggered",
 
35
                "Triggered",
 
36
                "Running",
 
37
                "Finished"
 
38
        };
 
39
 
 
40
        return client_state_names[client->control->state];
 
41
}
 
42
 
 
43
#define JACK_ERROR_WITH_SOCKETS 10000000
 
44
 
 
45
int     jack_client_activate (jack_engine_t *engine, jack_client_id_t id);
 
46
int     jack_client_deactivate (jack_engine_t *engine, jack_client_id_t id);
 
47
int     jack_client_create (jack_engine_t *engine, int client_fd);
 
48
void    jack_client_delete (jack_engine_t *engine,
 
49
                            jack_client_internal_t *client);
 
50
int     jack_mark_client_socket_error (jack_engine_t *engine, int fd);
 
51
jack_client_internal_t *
 
52
        jack_create_driver_client (jack_engine_t *engine, char *name);
 
53
void    jack_intclient_handle_request (jack_engine_t *engine,
 
54
                                       jack_request_t *req);
 
55
void    jack_intclient_load_request (jack_engine_t *engine,
 
56
                                     jack_request_t *req);
 
57
void    jack_intclient_name_request (jack_engine_t *engine,
 
58
                                     jack_request_t *req);
 
59
void    jack_intclient_unload_request (jack_engine_t *engine,
 
60
                                       jack_request_t *req);
 
61
void    jack_check_clients (jack_engine_t* engine, int with_timeout_check);
 
62
void    jack_remove_clients (jack_engine_t* engine);
 
63
void    jack_client_registration_notify (jack_engine_t *engine,
 
64
                                         const char* name, int yn);