Re: [Musicpd-dev-team] [PATCH] Fix build with FFmpeg 2.0.

2013-08-07 Thread Alexis Ballier
On Wed, 7 Aug 2013 08:01:14 +0200 Max Kellermann m...@duempel.org wrote: On 2013/08/07 04:19, Alexis Ballier aball...@gentoo.org wrote: Allocate the buffer as needed instead of relying on an arbitrary constant that might not be enough. That allocates a new buffer for each frame. I

Re: [Musicpd-dev-team] [PATCH] Fix build with FFmpeg 2.0.

2013-08-07 Thread Max Kellermann
On 2013/08/07 13:48, Alexis Ballier aball...@gentoo.org wrote: not much more than the current code that does it for each packet (there's usually only one frame per packet) The difference is: it's allocated on the stack currently. The computational cost of a stack allocation is negligible, and

[Musicpd-dev-team] [PATCH] FfmpegDecoderPlugin: Allocate the interleaved buffer as needed instead of using an arbitrary big constant.

2013-08-07 Thread Alexis Ballier
Also, save a memcpy when FFmpeg outputs interleaved audio. Fixes build with FFmpeg 2.0. --- src/decoder/FfmpegDecoderPlugin.cxx | 46 +++-- 1 file changed, 29 insertions(+), 17 deletions(-) diff --git a/src/decoder/FfmpegDecoderPlugin.cxx

[Musicpd-dev-team] [PATCH] CommandLine.cxx: look for config file in XDG_CONFIG_HOME too

2013-08-07 Thread Alexander Gehrke
Hello, I wrote a little patch for searching the config file under the XDG_CONFIG_HOME directory too. It will look for $XDG_CONFIG_HOME/mpd/mpd.conf, similar to where mpd looks for the file under Windows. --- INSTALL | 6 +++--- doc/mpd.1 | 4 ++-- doc/mpd.conf.5 | 5