- 14 Aug, 2009 1 commit
-
-
Max Kellermann authored
Explicitly make the output thread leave the ao_pause() loop. This patch is a workaround, and the "pause" flag is not managed in a thread-safe way, but that's good enough for now.
-
- 19 Jul, 2009 1 commit
-
-
David Woodhouse authored
-
- 06 Jul, 2009 3 commits
-
-
Max Kellermann authored
This patch adds initial filter support for audio outputs. Each audio output gets a "filter" attribute, which is used by ao_play_chunk(). The PCM conversion is now performed by convert_filter_plugin. audio_output.convert_state has been removed.
-
Max Kellermann authored
REOPEN is called when the input audio format changes. The output thread may be reconfigure the PCM converter.
-
Max Kellermann authored
-
- 29 Jun, 2009 1 commit
-
-
Max Kellermann authored
When the PAUSE loop ends, re-check the next command before calling ao_play() again.
-
- 26 Mar, 2009 1 commit
-
-
Max Kellermann authored
This patch fixes a longer delay when moving around songs in the playlist. The main thread wants to enqueue a new "next" song into the player thread, but the player thread is waiting inside audio_output_all_wait() for the output threads. Use player_control.notify there, so audio_output_all_wait() gets woken up by the main thread, too.
-
- 25 Mar, 2009 2 commits
-
-
Max Kellermann authored
Use audio_output_client_notify instead of g_usleep(1ms) in audio_output_all_wait() to synchronize with the output_thread. Signal the audio_output_client_notify object in ao_play().
-
Max Kellermann authored
There was a deadlock between the output thread and the player thread: when the output thread failed (and closed itself) while the player thread worked with the audio_output object, MPD could crash.
-
- 13 Mar, 2009 1 commit
-
-
Avuton Olrich authored
This updates the copyright header to all be the same, which is pretty much an update of where to mail request for a copy of the GPL and the years of the MPD project. This also puts all committers under 'The Music Player Project' umbrella. These entries should go individually in the AUTHORS file, for consistancy.
-
- 10 Mar, 2009 1 commit
-
-
Max Kellermann authored
Check audio_output.command after each sub-chunk has been played. It discards the rest of the chunk, but since all commands make the device stop anyway, this is not a problem, but part of the improvement. This improves the latency of audio output commands.
-
- 09 Mar, 2009 2 commits
-
-
Max Kellermann authored
Instead of passing individual buffers to audio_output_all_play(), pass music_chunk objects. Append all those chunks asynchronously to a music_pipe instance. All output threads may then read chunks from this pipe. This reduces MPD's internal latency by an order of magnitude.
-
Max Kellermann authored
This is similar to the MPD 0.14 patch "wait 10 seconds before reopening a failed device", which only covered open() failures. This patch adds the same feature for play().
-
- 08 Mar, 2009 1 commit
-
-
Max Kellermann authored
-
- 01 Mar, 2009 1 commit
-
-
Max Kellermann authored
To aid debugging, print the audio format of the output plugin in a debug message, and print information about PCM conversion.
-
- 28 Feb, 2009 1 commit
-
-
Max Kellermann authored
time() is not a monotonic timer, and MPD might get confused by clock skews. clock_gettime() provides a monotonic clock, but is not portable to non-POSIX systems (i.e. Windows). This patch uses GLib's GTimer API, which aims to be portable.
-
- 26 Feb, 2009 2 commits
-
-
Max Kellermann authored
Use GLib's GError library for reporting output device failures. Note that some init() methods don't clean up properly after a failure, but that's ok for now, because the MPD core will abort anyway.
-
Max Kellermann authored
ao_play() gets PCM data in the in_audio_format, and converts it to out_audio_format. Comparing the input data with out_audio_format is wrong. prefixed with "STG:" will be automatically removed. STG: Trailing empty lines will be automatically removed. STG: vi: set textwidth=75 filetype=diff nobackup:
-
- 25 Feb, 2009 1 commit
-
-
Max Kellermann authored
-
- 23 Feb, 2009 1 commit
-
-
Max Kellermann authored
The old API required an output plugin to not return until all data passed to the play() method is consumed. Some output plugins have to loop to fulfill that requirement, and may block during that. Simplify these, by letting them consume only part of the buffer: make play() return the length of the consumed data.
-
- 16 Feb, 2009 1 commit
-
-
Max Kellermann authored
Similar to the decoder plugin API: added wrapper functions to increase code readability.
-
- 10 Feb, 2009 4 commits
-
-
Max Kellermann authored
Merge some duplicate code into one function.
-
Max Kellermann authored
When the pause() method fails, leave the pause loop, because calling pause() on a closed device is not allowed.
-
Max Kellermann authored
Fix a memory leak: it was not guaranteed that pcm_convert_deinit() was called for each pcm_convert_init(). This patch always (de)initializes the pcm_convert library when the audio_output.open flag is flipped.
-
Max Kellermann authored
Renamed audio_output struct members.
-
- 30 Jan, 2009 1 commit
-
-
Max Kellermann authored
Move the "while" loop which checks for commands to the caller ao_pause(). This simplifies the pause() method, and lets us remove audio_output_is_pending().
-
- 17 Jan, 2009 1 commit
-
-
Max Kellermann authored
Removed yet another superfluous buffer layer: return the PCM buffer from pcm_convert() instead of copying PCM data into the caller-supplied buffer.
-
- 07 Jan, 2009 2 commits
-
-
Max Kellermann authored
Be sure that the output thread has quite before we start destructing the output object.
-
Max Kellermann authored
Free memory allocated by libsamplerate when the output or the decoder is closed.
-
- 04 Jan, 2009 1 commit
-
-
Max Kellermann authored
GLib mandates that you initialize all GError objects with NULL prior to passing it.
-
- 28 Dec, 2008 1 commit
-
-
Thomas Jansen authored
-
- 24 Dec, 2008 1 commit
-
-
Max Kellermann authored
It is illegal to pass an empty audio buffer around. pcm_resample() sometimes seems to result in 0 samples, maybe related to libsamplerate. To work around that problem, add special checks after both pcm_convert() invocations. Removed the pcm_resample()==0 checks from pcm_convert().
-
- 25 Nov, 2008 1 commit
-
-
Max Kellermann authored
-
- 02 Nov, 2008 1 commit
-
-
Max Kellermann authored
Nobody should call playAudio() with an empty chunk. Add some assertions on that.
-
- 29 Oct, 2008 5 commits
-
-
Max Kellermann authored
Since open() and play() close the device on error, we can simply check audio_output.open instead of audio_output.result after a call.
-
Max Kellermann authored
When one of several output devices failed, MPD tried to reopen it quite often, wasting a lot of resources. This patch adds a delay: wait 10 seconds before retrying. This might be changed to exponential delays later, but for now, it makes the problem go away.
-
Max Kellermann authored
Stopping an audio output device without cancelling its buffer doesn't make sense. Combine the two operations, which saves several cancel calls.
-
Max Kellermann authored
When an output plugin fails to play a chunk, close it. This replaces various manual close() calls in nearly all plugins.
-
Max Kellermann authored
Don't return 0/-1 on success/error, but true/false. Instead of int, use bool for storing flags.
-
- 21 Oct, 2008 1 commit
-
-
Max Kellermann authored
Renamed all functions which were still in CamelCase.
-