PortAudio 2.0
pa_linux_pulseaudio_cb_internal.h
Go to the documentation of this file.
1
2/*
3 * PulseAudio host to play natively in Linux based systems without
4 * ALSA emulation
5 *
6 * Copyright (c) 2014-2023 Tuukka Pasanen <tuukka.pasanen@ilmi.fi>
7 * Copyright (c) 2016 Sqweek
8 *
9 * Based on the Open Source API proposed by Ross Bencina
10 * Copyright (c) 1999-2002 Ross Bencina, Phil Burk
11 *
12 * Permission is hereby granted, free of charge, to any person obtaining
13 * a copy of this software and associated documentation files
14 * (the "Software"), to deal in the Software without restriction,
15 * including without limitation the rights to use, copy, modify, merge,
16 * publish, distribute, sublicense, and/or sell copies of the Software,
17 * and to permit persons to whom the Software is furnished to do so,
18 * subject to the following conditions:
19 *
20 * The above copyright notice and this permission notice shall be
21 * included in all copies or substantial portions of the Software.
22 *
23 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
26 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
27 * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
28 * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
29 * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
30 */
31
32/*
33 * The text above constitutes the entire PortAudio license; however,
34 * the PortAudio community also makes the following non-binding requests:
35 *
36 * Any person wishing to distribute modifications to the Software is
37 * requested to send the modifications to the original developer so that
38 * they can be incorporated into the canonical version. It is also
39 * requested that these non-binding requests be included along with the
40 * license above.
41 */
42
43#ifndef _PA_HOSTAPI_PULSEAUDIO_CB_H_
44#define _PA_HOSTAPI_PULSEAUDIO_CB_H_
45
46#include "pa_util.h"
47#include "pa_allocation.h"
48#include "pa_hostapi.h"
49#include "pa_stream.h"
50#include "pa_cpuload.h"
51#include "pa_process.h"
52
53#include "pa_unix_util.h"
54#include "pa_ringbuffer.h"
55
56
57/* PulseAudio headers */
58#include <stdio.h>
59#include <string.h>
60#include <pulse/pulseaudio.h>
61
63
64
65#ifdef __cplusplus
66extern "C"
67{
68#endif /* __cplusplus */
69
70int PaPulseAudio_updateTimeInfo( pa_stream * s,
72 int record );
73
74void *PaPulseAudio_processThread( void *userdata );
75
77
79
81
83
84void PaPulseAudio_StreamRecordCb( pa_stream * s,
85 size_t length,
86 void *userdata );
87
88void PaPulseAudio_StreamPlaybackCb( pa_stream * s,
89 size_t length,
90 void *userdata );
91
92#ifdef __cplusplus
93}
94#endif /* __cplusplus */
95
96
97#endif
Allocation Group prototypes. An Allocation Group makes it easy to allocate multiple blocks of memory ...
Functions to assist in measuring the CPU utilization of a callback stream. Used to implement the Pa_G...
Interfaces and representation structures used by pa_front.c to manage and communicate with host API i...
void PaPulseAudio_StreamRecordCb(pa_stream *s, size_t length, void *userdata)
Definition pa_linux_pulseaudio_cb.c:493
PaError PaPulseAudio_StartStreamCb(PaStream *stream)
Definition pa_linux_pulseaudio_cb.c:713
int PaPulseAudio_updateTimeInfo(pa_stream *s, PaStreamCallbackTimeInfo *timeInfo, int record)
Definition pa_linux_pulseaudio_cb.c:70
PaError PaPulseAudio_StopStreamCb(PaStream *stream)
Definition pa_linux_pulseaudio_cb.c:1011
PaError PaPulseAudio_AbortStreamCb(PaStream *stream)
Definition pa_linux_pulseaudio_cb.c:1017
PaError PaPulseAudio_CloseStreamCb(PaStream *stream)
Definition pa_linux_pulseaudio_cb.c:568
void PaPulseAudio_StreamPlaybackCb(pa_stream *s, size_t length, void *userdata)
Definition pa_linux_pulseaudio_cb.c:515
void * PaPulseAudio_processThread(void *userdata)
Buffer Processor prototypes. A Buffer Processor performs buffer length adaption, coordinates sample f...
Single-reader single-writer lock-free ring buffer.
Stream interfaces, representation structures and helper functions used to interface between pa_front....
Prototypes for utility functions used by PortAudio implementations.
void PaStream
Definition portaudio.h:644
int PaError
Definition portaudio.h:122
Definition portaudio.h:708