Commit Graph

910 Commits

Author SHA1 Message Date
Max Kellermann 5a8d2e8057 output/jack: cache AudioFormat::channels 2014-12-24 23:22:56 +01:00
Max Kellermann 687fc358fd output/jack: fix typo 2014-12-24 23:22:56 +01:00
Max Kellermann c4c2da06b7 output/jack: use jack_ringbuffer_get_write_vector()
Reduce number of libjack calls.
2014-12-24 23:14:15 +01:00
Max Kellermann 8928cd53bf output/jack: move jack_ringbuffer_write_space() call to WriteSamples() 2014-12-24 23:08:39 +01:00
Max Kellermann ca88fc4ed3 output/jack: cache AudioFormat::channels 2014-12-24 23:04:29 +01:00
Max Kellermann b83a1d79b7 output/jack: pass float* to WriteSamples() 2014-12-24 23:02:19 +01:00
Max Kellermann cec2a837cf output/jack: WriteSamples() returns size_t 2014-12-24 23:00:46 +01:00
Max Kellermann cff47262da output/jack: pass size_t to WriteSamples() 2014-12-24 23:00:15 +01:00
Max Kellermann da83eae754 output/jack: use SampleFormat::FLOAT
What JACK expects is already implemented in MPD, just not used.  The
sample format conversion code in the JACK plugin was redundant and
could reduce sound quality.
2014-12-24 22:40:00 +01:00
Max Kellermann c5409d52f5 output/Internal: move enum AudioOutputCommand into the struct 2014-12-24 22:18:47 +01:00
Max Kellermann 54fc8f0e8c output/Internal: convert audio_output_command to strictly-typed enum 2014-12-24 22:13:50 +01:00
Max Kellermann 2ea633a2f7 output/jack: use std::fill() 2014-12-24 16:27:13 +01:00
Max Kellermann 9a52043fad output/jack: move functions into the struct 2014-12-24 16:10:27 +01:00
Max Kellermann 39a5be2df9 output/jack: merge two mpd_jack_available() calls 2014-12-24 16:10:27 +01:00
Max Kellermann 96560e317a output/jack: make variables more local 2014-12-24 15:21:23 +01:00
Max Kellermann adb27903eb output/jack: convert const to constexpr 2014-12-24 15:14:51 +01:00
Max Kellermann 51150faa39 output/jack: convert enum to constexpr 2014-12-24 09:52:32 +01:00
Max Kellermann 25f89afbfb output/winmm: show detailed error messages 2014-12-17 19:43:14 +01:00
Max Kellermann a588aef921 output/oss: make the static arrays "constexpr" 2014-12-09 22:02:18 +01:00
Max Kellermann de43bddc1a Merge tag 'v0.19.6' 2014-12-08 15:22:44 +01:00
Max Kellermann 4b70f9d213 util/DivideString: add option "strip" 2014-12-04 23:05:44 +01:00
Max Kellermann e69bef3ce3 util/SplitString: new utility class
Replaces GLib's g_strsplit().
2014-12-04 09:14:28 +01:00
Max Kellermann c1c0fc79bc output/jack: use usleep() instead of g_usleep() 2014-12-04 09:14:28 +01:00
Max Kellermann 050f0c3d8f util/SplitString: rename to DivideString 2014-12-03 21:38:06 +01:00
Max Kellermann d3d9a04e62 output/ao: use class SplitString instead of g_strsplit() 2014-12-02 22:29:41 +01:00
Max Kellermann 0debba0f6e mixer/null: new mixer plugin 2014-12-02 18:20:44 +01:00
Max Kellermann f2bd2c318c MixerType: convert to strictly-typed enum 2014-12-02 18:20:44 +01:00
Max Kellermann 21c42819c7 MixerType: rename to CamelCase 2014-12-02 18:19:31 +01:00
Max Kellermann 7363d50a1e output/httpd/IcyMetaDataServer: use CopyString() instead of g_strlcpy() 2014-12-01 22:33:57 +01:00
Max Kellermann 15213a041d output/httpd/IcyMetaDataServer: don't use GLib types 2014-12-01 22:31:29 +01:00
Max Kellermann fb70a34c80 output/httpd/IcyMetaDataServer: make variables more local 2014-12-01 22:28:14 +01:00
Nix 811af02f56 Output: start with a null mixer.
There are code paths (mostly error cases) in which it is possible to
initialize an AudioOutput and then kill it without ever calling
audio_output_new().  In such a case, its destructor will attempt to
free a mixer that was never initialized, leading to an attempt to
take out a lock on a mutex that was similarly never initialized,
which hangs forever.

Fix by always initializing the mixer appropriately.
2014-12-01 22:14:09 +01:00
Max Kellermann d93172bee8 Compiler.h: add macro CLANG_OR_GCC_VERSION() 2014-11-28 19:09:56 +01:00
Max Kellermann b3f5b4932c configure.ac: add macro MPD_ENABLE_AUTO_PKG
Simplify the definition of many build options.
2014-11-21 22:19:57 +01:00
Max Kellermann 303d67aed2 Merge tag 'v0.19.2' 2014-11-02 14:06:05 +01:00
Max Kellermann c50a0cf7bf output/roar: remove unnecessary "volatile" keyword
A mutex acts as a memory barrier, and thus "volatile" is not
necessary.
2014-11-02 11:50:56 +01:00
Max Kellermann d7f024c510 OutputThread: fall back to PCM if given DSD sample rate is not supported
Works around the "PCM conversion from f to dsd is not implemented"
error message that prevents DSD playback.
2014-10-25 22:06:08 +02:00
Steven Newbury 76f277eeb4 Set pulseaudio channel map to WAVE-EX
Pulseaudio expects clients to specify their channel-map if the
default (ALSA) map does not route the audio to the expected speakers.

Many Google results suggest dealing with this by re-routing the audio
channels with the appropriate ALSA plugin, but this will then simply
break any clients which expect the default ALSA mapping.

Virtually all media files and codecs, certainly flac, dca, a52, and of
course anything based on Microsoft's WAVEFORMAT_EXTENSIBLE specification,
assume the layout in the table here:
http://en.wikipedia.org/wiki/Surround_sound#Standard_speaker_channels

Fortunately, pulseaudio directly addresses this with a built-in channel
map for WAVE-EX which can be set automatically in the stream sample-spec.
2014-10-25 01:08:09 +02:00
Max Kellermann a7b09d3d1c OutputThread: close the output plugin after filter failure
Fixes memory leak because ao_plugin_close() never gets called.
2014-10-24 00:35:16 +02:00
Max Kellermann 8fc3768166 OutputThread: unlock mutex for CloseFilter()
Be consistent.
2014-10-24 00:29:03 +02:00
Max Kellermann b07bddf742 output/roar: remove unnecessary "volatile" keyword
A mutex acts as a memory barrier, and thus "volatile" is not
necessary.
2014-10-23 23:29:56 +02:00
Wieland Hoffmann 5525ea45a4 Add MusicBrainz' Release Track Id tag
The Release Track Id uniquely identifies a recording on a release - that
is, even if a recording appears twice on a release (meaning that the
combination of recording and release id are not enough to figure out
which one it is), the release track id will allow differentiating the two.

The tag names are taken from
https://musicbrainz.org/doc/MusicBrainz_Picard/Tags/Mapping
2014-09-27 19:54:12 +02:00
Max Kellermann 8397196fbb output/alsa: change a few "dsd" to "dop" 2014-09-26 11:07:53 +02:00
Max Kellermann 9270485723 Merge branch 'v0.18.x' 2014-09-24 21:49:20 +02:00
Max Kellermann 223c129b6b output/pulse: simplify _wait_for_operation()
Eliminate the duplicate pa_operation_get_state() call.
2014-09-05 11:16:09 +02:00
Max Kellermann e5a28bfd8d output/alsa, pcm: rename "DSD over USB" to "DoP"
The standard has been renamed since the early draft that was
implemented in MPD.
2014-08-31 16:12:26 +02:00
Max Kellermann 6e04d66a35 Merge tag 'v0.18.13' 2014-08-31 15:03:34 +02:00
Max Kellermann 2406152576 output/alsa: fix endless loop at end of file in dsd_usb mode 2014-08-31 14:01:57 +02:00
Max Kellermann af260b5a64 output/{alsa,oss}: add assertions 2014-08-31 14:00:09 +02:00
Max Kellermann b373c53ce4 *: add missing Compiler.h includes
Necessary for "final" on gcc 4.6.
2014-08-30 00:46:52 +02:00