|
228db352
|
2022-02-08T13:29:40
|
|
audio: pipewire: Tidy up formatting
|
|
9da9e85c
|
2022-02-08T12:59:01
|
|
audio: pipewire: Reset all hotplug values and pointers on shutdown
Ensure that all hotplug variables and pointers are reset to NULL or their original value when shutting down.
|
|
5b36a527
|
2022-02-08T12:30:28
|
|
audio: pipewire: Remove redundant locks
The io_list_check_add() and io_list_remove() functions are only ever called from within the Pipewire thread loop, so the locks are redundant. io_list_sort() is called from within a lock in the device detection function, so those additional locks are redundant as well.
|
|
48b4d1c4
|
2022-02-08T12:20:52
|
|
audio: pipewire: Convert atomic hotplug conditional variables to SDL_bool
The hotplug loop condition variables are always guarded by the loop mutex while the loop is running, so they don't need to be atomic.
|
|
53091e36
|
2022-02-02T12:30:34
|
|
audio: pipewire: Remove the hard upper bound on rates and buffer sizes
Remove the hard upper limit of 8192 samples and instead use the buffer sizes provided by Pipewire to determine the size of the intermediate input buffer and whether double buffering is required for output streams. This allows for higher latency streams to potentially avoid double-buffering in the output case, and we can guarantee that the intermediate input buffer will always be large enough to handle whatever Pipewire may deliver.
As the buffer size calculations occur in a callback in the Pipewire processing thread itself, the stream readiness check has been modified to wait on two distinct flags set when the buffers have been configured and when the stream is ready and running.
|
|
66866249
|
2022-02-02T11:09:02
|
|
audio: pipewire: Condition variable doesn't need to be atomic
The condition variable is guarded by a mutex, so no need for it to be atomic.
|
|
0b34f180
|
2022-01-30T12:00:55
|
|
audio: pipewire: Don't double free properties on init failure
The context and stream creation functions will destroy the passed properties object on failure, so no need to do it manually.
The pw_properties_free() function pointer is no longer needed, so it can be removed.
|
|
1043dd8c
|
2022-01-19T12:58:04
|
|
adjust handling of iscapture
- drop iscapture parameter of OpenDevice
- use SDL_bool for iscapture
|
|
0dda8a7f
|
2022-01-17T11:21:01
|
|
cleanup init functions of audio
- use SDL_bool if possible
- assume NULL/SDL_FALSE filled impl
- skip zfill of current_audio at the beginning of SDL_AudioInit (done before the init() calls)
|
|
a70bb259
|
2022-01-20T13:16:03
|
|
drop handle parameter of OpenDevice
|
|
b3984df1
|
2022-01-19T13:14:54
|
|
audio: pipewire: Use client config files instead of module names
Pipewire, as of 0.3.22, uses client config files to load modules instead of explicitly specifying them (PW_KEY_CONTEXT_PROFILE_MODULES is deprecated). Use the new method to load the realtime module to boost the audio thread priority.
|
|
120c76c8
|
2022-01-03T09:40:00
|
|
Updated copyright for 2022
|
|
a1ffeda0
|
2021-08-28T22:52:13
|
|
Add SDL_HINT_APP_NAME and DBUS inhibition hint
See SDL bug #4703. This implements two new hints:
- SDL_APP_NAME
- SDL_SCREENSAVER_INHIBIT_ACTIVITY_NAME
The former is the successor to SDL_HINT_AUDIO_DEVICE_APP_NAME, and acts
as a generic "application name" used both by audio drivers and DBUS
screensaver inhibition. If SDL_AUDIO_DEVICE_APP_NAME is set, it will
still take priority over SDL_APP_NAME.
The second allows the "activity name" used by
org.freedesktop.ScreenSavver's Inhibit method, which are often shown in
the UI as the reason the screensaver (and/or suspend/other
power-managment features) are disabled.
|
|
70c23b25
|
2021-08-18T13:18:11
|
|
audio: pipewire: Reset hotplug atomic variables on deinit.
|
|
bfa15931
|
2021-08-18T12:04:38
|
|
audio: pipewire: Set PW_KEY_NODE_RATE to suggest a rate.
This can be used by recent pipewire to avoid resampling.
|
|
5f9effaa
|
2021-03-28T17:45:41
|
|
audio: pipewire: Block while waiting on stream state info
Initializing streams, particularly capture streams, can take many milliseconds, which is a bit much for a busy wait. Use a blocking wait instead.
|
|
8deb4063
|
2021-03-28T17:22:59
|
|
audio: pipewire: Avoid redundant locking
The pw_thread_loop already locks and unlocks the thread mutex at the start and end of each loop iteration, so these locks are unnecessary.
|
|
5bb2bbd4
|
2021-03-28T17:17:00
|
|
audio: pipewire: Don't use uninitialized variables in callbacks
Some of the SDL_AudioDevice struct members aren't initialized until after returning from the OpenDevice function. Since Pipewire uses it's own processing threads, the callbacks can be entered before all members of SDL_AudioDevice are initialized, such as work_buffer, callbackspec and the processing stream, which creates a race condition. Don't use these members when in the paused state to avoid potentially using uninitialized values and memory.
|
|
4fbd60b8
|
2021-03-09T12:22:48
|
|
audio: pipewire: Remove the nickname portion of sink/source names
Removes the node nickname from sink/source nodes as it doesn't provide any useful information and names now match those used in Pulseaudio, so any stored configuration data will be compatible between the two audio backends.
|
|
67e8522d
|
2021-02-27T17:37:25
|
|
Add SDL_GetAudioDeviceSpec.
This API is supported by pipewire, pulseaudio, coreaudio, wasapi, and disk.
|
|
4de0c74a
|
2021-03-02T10:02:59
|
|
audio: pipewire: Add the application name to the stream properties
|
|
9ed01da7
|
2021-03-02T09:47:47
|
|
audio: pipewire: Constify and clarify period size calculations
Constify the min/max period variables, use a #define for the base clock rate used in the calculations and note that changing the upper limit can have dire side effects as it's a hard limit in Pipewire.
|
|
d7ca855c
|
2021-03-02T09:33:11
|
|
audio: pipewire: Add missing static qualifiers to globals
|
|
84c44e01
|
2021-03-01T12:39:52
|
|
audio: pipewire: fix uninitialized variable warnings
|
|
21adec93
|
2021-02-24T12:02:54
|
|
audio: pipewire: Make enumeration structure and function names more descriptive
Rename the add/remove/clear list functions and rename connected_device to io_node, as a sink/source node isn't necessarily a device.
|
|
a07f5434
|
2021-02-21T13:24:20
|
|
audio: pipewire: Report default devices first
Further refactor the device enumeration code to retrieve the default sink/source node IDs from the metadata node. Use the retrieved IDs to sort the device list so that the default devices are at the beginning and thus are the first reported to SDL.
|
|
9afd7570
|
2021-02-20T13:33:12
|
|
audio: pipewire: Always buffer source audio
The latency of source nodes can change depending on the overall latency of the processing graph. Incoming audio must therefore always be buffered to ensure uninterrupted delivery.
The SDL_AudioStream path was removed in the input callback as the only thing it was used for was buffering audio outside of Pipewire's min/max period sizes, and that case is now handled by the omnipresent buffer.
|
|
106dc009
|
2021-02-19T17:18:36
|
|
audio: pipewire: Pass proper parameter to user audio callback
The audio callbacks should pass the callbackspec.userdata parameter to the callback, not spec.userdata
Co-authored-by: Oschowa <Oschowa@web.de>
|
|
f3ebbc06
|
2021-02-19T16:02:20
|
|
audio: pipewire: Retrieve the channel count and default sample rate for sinks/sources
Extend device enumeration to retrieve the channel count and default sample rate for sink and source nodes. This required a fairly significant rework of the enumeration procedure as multiple callbacks are involved now. Sink/source nodes are tracked in a separate list during the enumeration process so they can be cleaned up if a device is removed before completion. These changes also simplify any future efforts that may be needed to retrieve additional configuration information from the nodes.
|
|
2f0b99a7
|
2021-02-13T11:56:05
|
|
audio: Add Pipewire playback/capture sink
|
|
7001b531
|
2021-02-27T12:53:08
|
|
audio: pipewire: Add vim format lines to files and fix indentation
Increase indentation spacing from 2 to 4 to comply with style standards.
|
|
2fcba50e
|
2021-02-27T12:08:15
|
|
audio: pipewire: Code and comment cleanups
Replace "magic numbers" with #defines, explain the requirements when using the userdata pointer in the node_object struct and a few other minor code and comment cleanups.
|
|
4eadd147
|
2021-02-25T14:00:23
|
|
audio: pipewire: Fix outdated comment
|
|
cd56f1b3
|
2021-02-24T14:36:58
|
|
audio: pipewire: Use "rear" designation for rear channels
Use the 'R' (rear) prefixed designations for the rear audio channels instead of 'S' (surround). Surround designated channels are only used in the 8 channel configuration.
|