Max Kellermann
815d72065c
output: rename struct audio_output to AudioOutput
2014-01-28 11:34:09 +01:00
Max Kellermann
e0dc721324
OutputPlugin: rename struct audio_output_plugin to AudioOutputPlugin
2014-01-28 11:33:15 +01:00
Max Kellermann
f5a923b9d1
OutputAll: convert to class, move instance to class Partition
...
Another big chunk of code for multi-player support.
2014-01-28 09:20:53 +01:00
Max Kellermann
68eda78704
Mixer*: move to mixer/
2014-01-24 16:44:32 +01:00
Max Kellermann
7c52a1c04b
Filter*: move to filter/
2014-01-24 16:43:57 +01:00
Max Kellermann
e199c33c6e
Client*: move to client/
2014-01-24 00:26:53 +01:00
Max Kellermann
197b503f3e
Config*: move to config/
2014-01-24 00:20:01 +01:00
Max Kellermann
ea5b901bcc
output/*: move to output/plugins/
2014-01-23 23:49:50 +01:00
Max Kellermann
655ad34414
Encoder*: move to src/encoder
...
.. and move the plugins to src/encoder/plugins/.
2014-01-23 23:09:14 +01:00
Max Kellermann
4f83c60296
copyright year 2014
2014-01-13 22:31:55 +01:00
Max Kellermann
27ca0db7a6
util/Alloc: new library replacing GLib's g_malloc()
2014-01-07 23:35:18 +01:00
Max Kellermann
793962c5b8
event/SocketMonitor: don't close the socket automatically
...
Users now have to call Close() explicitly. This simplifies using the
class, as most users have automatic socket management already, and
Steal() had to be used often.
2014-01-06 18:26:55 +01:00
Max Kellermann
0d20130d07
util/Cast: new utility library
2014-01-06 18:21:45 +01:00
Max Kellermann
4ddfc6e9a2
output/httpd: move the clients.clear() call to the IOThread
...
This call is not thread-safe.
2014-01-05 02:13:35 +01:00
Max Kellermann
dcbc05a9cd
output/httpd: import GetEventLoop()
2014-01-05 02:13:21 +01:00
Max Kellermann
bfe7533546
output/httpd: move Bind()/Unbind() to the IOThread
...
Fixes more thread-safety bugs.
2014-01-04 19:29:51 +01:00
Max Kellermann
c9da3363a0
output/httpd: move all broadcast operations to the IOThread
...
Add a Page queue to class HttpdOutput, and use DeferredMonitor to
flush this queue inside the IOThread. This fixes a thread-safety
issue: much of EventLoop is not thread-safe, and the httpd plugin
ignored that problem.
2014-01-04 18:22:55 +01:00
Max Kellermann
9bd4ed3e60
output/httpd: use the IOThread
...
Do all I/O in the IOThread and not in the main thread. This solves an
upcoming deadlock problem.
2014-01-04 18:21:40 +01:00
Max Kellermann
68fcc19565
output/httpd: move queue size check to HttpdClient::PushPage()
...
Don't let the server care for client problems.
2014-01-04 17:42:03 +01:00
Max Kellermann
8e4efd071e
output/httpd: wrap the std::list in std::queue
2014-01-04 17:12:59 +01:00
Max Kellermann
f2ad9f6fad
output/httpd: merge duplicate code to ClearQueue()
2014-01-04 17:11:22 +01:00
Max Kellermann
968c5eb767
output/httpd: keep track of queue size
...
Don't iterate the std::list each time.
2014-01-04 17:06:05 +01:00
Max Kellermann
d477a9222e
output/httpd: change "struct" to "class"
2013-12-31 17:04:40 +01:00
Max Kellermann
69a9d29190
output/httpd: move code to methods Delay(), Play(), Cancel()
2013-12-31 17:01:08 +01:00
Max Kellermann
e2425592b6
output/httpd: move Cast() into the class
2013-12-31 16:59:24 +01:00
Max Kellermann
964b2661d8
output/httpd: add methods Init(), Finish()
2013-12-31 16:55:26 +01:00
Max Kellermann
8b65b524d5
output/httpd: use reference instead of pointer
2013-12-31 16:32:33 +01:00
Max Kellermann
f1ac2cd336
output/httpd: make the HttpdClient base class "private"
2013-12-31 16:24:51 +01:00
Max Kellermann
45ad7696fe
output/osx: fix typo
2013-12-19 12:46:21 +01:00
Max Kellermann
0e84d71559
output/osx: use DynamicFifoBuffer instead of struct fifo_buffer
2013-12-19 12:16:29 +01:00
Max Kellermann
65b8e52d80
output/alsa: use new[] instead of g_malloc()
2013-12-14 22:17:19 +01:00
Max Kellermann
c7b1038a9d
Merge branch 'v0.18.x'
2013-12-14 12:37:16 +01:00
Lukas Stabe
695ca29274
output/osx: fix build failure
2013-12-10 19:19:31 +01:00
Max Kellermann
e1901e97c2
system/Resolver: sockaddr_to_string() returns std::string()
...
No GLib memory allocation.
2013-12-04 08:43:55 +01:00
Lukas Stabe
0ea5f4ac3a
output/openal: check __APPLE__ instead of HAVE_OSX
...
On OSX, the configure-flag --enable-osx is used to enable the
unsupported osx output. It sets the HAVE_OSX preprocessor define.
src/output/OpenALOutputPlugin.cxx uses this define to determine wether
it is building on OSX, and imports different headers (which have
nothing to do with the osx output) depending on wether or not it is
set.
2013-12-02 13:08:52 +01:00
Max Kellermann
f90abe9530
include cleanup using iwyu
2013-11-28 11:50:54 +01:00
Denis Krjuchkov
22fb49fa90
HttpdOutputPlugin.cxx: fix null pointer dereference
2013-11-26 18:13:23 +06:00
Max Kellermann
188673b746
output/httpd: don't use incomplete template argument with libc++
2013-11-11 08:31:50 +01:00
Max Kellermann
62baec1841
output/alsa: avoid endless loop in Raspberry Pi workaround
...
See code comment.
2013-11-04 23:40:34 +01:00
Max Kellermann
ecf12a60e8
Log: add level "DEFAULT"
...
Map LogLevel::INFO to G_LOG_LEVEL_INFO, and LogLevel::DEFAULT to
G_LOG_LEVEL_MESSAGE. Now client connect/disconnect message are only
logged on log_level "secure".
2013-11-04 22:27:49 +01:00
Max Kellermann
8555b65c50
*: update copyright year to 2013
2013-10-30 23:37:06 +01:00
Max Kellermann
20597b3632
*: use nullptr instead of NULL
2013-10-28 23:58:17 +01:00
Oddegamra
5f13c1cd9c
output/httpd: accept icy-metadata with and without space
...
Some, or most, Win32 audio players will pass "icy-metadata:1" to
streaming servers. MPD expects a space between ":" and "1" at this
point, and thus does not send any stream metadata. This applies to
foobar2k and Winamp, for example.
According to forums.radiotoolbox.com/viewtopic.php?t=74 not having
a space there is expected behavior, so maybe MPD could accept
both forms to determine if metadata should be sent or not.
2013-10-26 16:32:00 +02:00
Max Kellermann
e17da71a70
output/httpd: support HEAD requests
2013-10-25 00:32:48 +02:00
Max Kellermann
610bef9ff5
output/httpd: remove bogus assertion
2013-10-25 00:26:02 +02:00
Max Kellermann
222dc8a239
Util/ASCII: add StringEqualsCaseASCII() overload with length
...
Replaces GLib's g_ascii_strncasecmp().
2013-10-21 08:42:55 +02:00
Max Kellermann
a78b2d84ed
TagType: rename enum tag_type to TagType
2013-10-20 13:32:59 +02:00
Max Kellermann
5dc4cbdf82
util/FormatString: new library to replace g_strdup_printf()
2013-10-19 17:24:21 +02:00
Max Kellermann
abfbd55305
fs/Path: rename to AllocatedPath
...
The new class Path only holds a string pointer without being
responsible for allocation/deallocation. The FileSystem.hxx library
accepts Path arguments instead of AllocatedPath, to avoid forcing
callers to allocate another string object.
2013-10-17 23:43:46 +02:00
Max Kellermann
5e26e2ab1d
system/ByteOrder: new library for byte ordering / endianess
...
Replacing GLib macros.
2013-10-16 22:09:44 +02:00
Max Kellermann
328131b7aa
output/roar: use const_cast instead of g_strdup()
2013-10-15 23:14:34 +02:00
Max Kellermann
85003429af
output/roar: use std::string
2013-10-15 23:11:32 +02:00
Max Kellermann
6db77dcf75
output/roar: move code into the RoarOutput class
2013-10-15 22:58:38 +02:00
Max Kellermann
1cde86823d
output/pipe: use std::string
2013-10-15 22:52:04 +02:00
Max Kellermann
12ab556477
event/BufferedSocket: pass writable pointer to OnSocketInput()
...
Remove the const_cast from HttpdClient.cxx, and avoid one allocation
in ClientRead.cxx.
2013-10-15 22:47:46 +02:00
Max Kellermann
509f8dab89
Util/Macros: replacement for GLib's G_N_ELEMENTS()
2013-10-15 22:47:39 +02:00
Max Kellermann
77429b6dd3
output/winmm: use delete instead of g_free()
2013-10-15 22:47:25 +02:00
Max Kellermann
be2951b45f
gcc.h: rename to Compiler.h
2013-10-15 09:21:59 +02:00
Max Kellermann
6fd481df97
Mapper, ...: use memcmp() instead of strncmp() where appropriate
...
Micro-optimization.
2013-10-14 22:00:21 +02:00
Max Kellermann
86316b1828
output/httpd: don't include glib.h in header
2013-10-02 12:20:36 +02:00
Max Kellermann
060814daa8
Log: new logging library API
...
Prepare to migrate away from GLib. Currently, we're still using GLib
as a backend.
2013-10-02 08:57:55 +02:00
Max Kellermann
ccd7f0825a
DecoderControl: use GLib forward declarations
2013-09-27 23:00:23 +02:00
Max Kellermann
5bc4ab899f
*Plugin: remove redundant "line %i" from error messages
...
The MPD core will add this as a prefeix.
2013-09-26 20:59:40 +02:00
Max Kellermann
7a4c9f5f4c
mpd_error.h: remove obsolete header
...
Migrate the remaining callers to FatalError().
2013-09-05 18:26:46 +02:00
Max Kellermann
fccba1af2a
use standard snprintf() instead of GLib g_snprintf()
2013-09-05 09:21:53 +02:00
Max Kellermann
29030b54c9
util/Error: new error passing library
...
Replaces GLib's GError.
2013-09-04 18:14:22 +02:00
Max Kellermann
c9fcc7f148
system/resolver: convert to C++
2013-09-04 18:02:09 +02:00
Max Kellermann
d1f4a31b5e
output/pulse: require libpulse 0.9.16
...
Remove all #ifdefs. Old versions of libpulse are not being tested,
and thus I'm removing support.
2013-09-04 16:55:03 +02:00
Max Kellermann
0005221533
output/httpd: use "unsigned" instead of "guint"
2013-08-08 00:18:59 +02:00
Max Kellermann
b76a29a69a
ConfigPath: return a Path object
...
Migrate all callers to use Path directly, instead of doing the
conversion in each caller.
2013-08-07 19:59:09 +02:00
Max Kellermann
abe090ec1f
*: remove remaining __cplusplus checks
2013-08-07 19:58:52 +02:00
Max Kellermann
b70d38dc10
Makefile.am: move sources to libsystem.a
2013-08-07 10:31:31 +02:00
Max Kellermann
85b77b81ca
*: use gcc.h macros instead of GLib
2013-08-04 23:48:01 +02:00
Max Kellermann
ca0d09c50f
EncoderPlugin: pass config_param reference
2013-08-04 14:07:50 +02:00
Max Kellermann
81c3224076
OutputPlugin: pass config_param reference
2013-08-04 14:07:49 +02:00
Max Kellermann
d1e7b4e381
audio_format: convert to C++
2013-08-03 21:37:56 +02:00
Max Kellermann
67f591a9ce
gcc.h: add macro gcc_unreachable()
2013-08-03 21:34:17 +02:00
Max Kellermann
44621f7326
output/winmm: adapt to PcmBuffer API changes
2013-07-31 00:57:52 +02:00
Max Kellermann
06f898cc12
tag: convert to C++
2013-07-30 20:19:53 +02:00
Max Kellermann
9a0061c511
encoder_api: convert to C++
2013-07-30 09:04:05 +02:00
Max Kellermann
28030d7edb
include cleanup
2013-07-30 08:39:21 +02:00
Max Kellermann
648196319f
output_api: convert to C++
2013-07-30 08:34:10 +02:00
Denis Krjuchkov
49a3845135
timer: convert to class
2013-05-12 19:03:42 +06:00
Max Kellermann
9e5d2c5bb7
encoder_list: convert to C++
2013-04-17 22:22:37 +02:00
Max Kellermann
0954f580fa
output/oss,null: use new/delete
2013-04-17 01:21:33 +02:00
Max Kellermann
3a2254c91f
output: convert to C++
2013-04-17 01:12:05 +02:00
Max Kellermann
4aeec4bb60
output/solaris: convert to C++
2013-04-17 01:08:35 +02:00
Max Kellermann
750b2ad6a8
output/openal: convert to C++
2013-04-17 01:04:27 +02:00
Max Kellermann
86c276f538
output/ao: convert to C++
2013-04-17 00:56:09 +02:00
Max Kellermann
166569200a
output/shout: convert to C++
2013-04-17 00:47:20 +02:00
Max Kellermann
e903d00968
output/ffado: remove broken plugin
...
This plugin has been in MPD for three years, and it has never worked.
Enough!
2013-04-17 00:44:02 +02:00
Max Kellermann
cc6c452854
output/mvp: remove obsolete plugin
...
The hardware is obsolete, and the product does not exist anymore on
the Hauppauge web site. Let's see if anybody complains about the
removal.
2013-04-17 00:37:30 +02:00
Max Kellermann
f492c78e2e
output/jack: convert to C++
2013-04-17 00:37:30 +02:00
Max Kellermann
6b83d08228
output/fifo: convert to C++
2013-04-17 00:37:30 +02:00
Max Kellermann
dc415b761e
output/pipe: convert to C++
2013-04-17 00:37:30 +02:00
Max Kellermann
f1034eb657
output/recorder: convert to C++
2013-04-17 00:37:30 +02:00
Max Kellermann
9f625b0a0d
mixer/Pulse: convert to a class
2013-04-16 21:18:54 +02:00
Max Kellermann
e63420a8c2
output/Pulse: convert to C++
2013-04-16 20:51:21 +02:00
Max Kellermann
e02d8ad8d2
output/roar: work around libroar's use of "new"
2013-04-16 20:04:11 +02:00
Max Kellermann
1729388634
pcm_export: convert to C++
2013-04-09 01:31:05 +02:00
Max Kellermann
c654c7630a
pcm_*: move to src/pcm/
2013-04-09 01:24:52 +02:00
Max Kellermann
496f70fc0d
mixer_plugin: convert to C++
2013-02-22 20:51:23 +01:00
Max Kellermann
9ede4c5f3c
{output,mixer}/winmm: convert to C++
2013-02-22 20:29:03 +01:00
Max Kellermann
af99176581
output/alsa: workaround for noise after manual song change
...
Workaround for driver bug observed on the Raspberry Pi, see code
comment for details.
2013-02-04 15:51:32 +01:00
Max Kellermann
57e825dfe7
output/alsa: pre-allocate the silence buffer
2013-02-04 15:30:31 +01:00
Max Kellermann
e06dd129dd
output/alsa: move code to alsa_write_silence()
2013-02-04 14:30:16 +01:00
Max Kellermann
7e92820c50
output/alsa: default "device" is an empty string
...
Fixes nullptr dereference in std::string::operator=(). Also fixes a
memory leak by using config_get_block_string() instead of
config_dup_block_string().
2013-02-04 11:46:49 +01:00
Max Kellermann
7bb5a960fd
output/null: convert to C++
2013-02-02 09:30:29 +01:00
Max Kellermann
5ed9f02c4d
TagPool, ...: include cleanup
2013-01-30 22:53:12 +01:00
Max Kellermann
5e8f51a963
output/httpd: use the BufferedSocket class for HttpdClient
2013-01-30 15:08:09 +01:00
Max Kellermann
fa51db449f
ServerSocket: replace callback with virtual method
2013-01-30 14:16:04 +01:00
Max Kellermann
cb9a05ac77
output/httpd: safer cast, consider offset
2013-01-30 14:14:42 +01:00
Max Kellermann
f1f22019f5
output/httpd: forward-declare class HttpdClient
2013-01-30 13:42:16 +01:00
Max Kellermann
6d79a1cdfc
output/httpd: add constructor, destructor, Configure()
2013-01-30 13:41:27 +01:00
Max Kellermann
ad5eb2f8d6
ServerSocket: expose the class
...
Eliminate the C wrappers.
2013-01-30 13:40:56 +01:00
Max Kellermann
39d56d6b65
ServerSocket: move to libevent.a
2013-01-30 13:39:12 +01:00
Max Kellermann
fe3f0332f7
page: convert to C++
2013-01-30 09:18:52 +01:00
Max Kellermann
718fd97612
icy_server: convert to C++
2013-01-30 09:17:03 +01:00
Max Kellermann
f8ff45b212
icy_server: pass pointer to _metadata_page()
...
Don't use va_list.
2013-01-30 09:13:46 +01:00
Max Kellermann
20f85745e7
require GLib 2.24
2013-01-29 18:33:37 +01:00
Max Kellermann
84eb95466b
output/osx: convert to C++
2013-01-29 16:59:21 +01:00
Max Kellermann
26a9ce7b29
output/{alsa,oss}: convert to C++
2013-01-29 14:32:32 +01:00
Max Kellermann
2aa34882b7
output/httpd: move functions into the HttpdOutput class
2013-01-27 23:23:46 +01:00
Max Kellermann
27f8ef2f33
output/httpd: rename struct httpd_output
2013-01-27 23:21:39 +01:00
Max Kellermann
e22ef6c481
output/roar: convert to C++
2013-01-16 23:29:56 +01:00
Max Kellermann
0dd5f2915a
ServerSocket: use the SocketMonitor class
2013-01-15 22:56:06 +01:00
Max Kellermann
bc66dc45e6
server_socket: convert to C++
2013-01-15 21:42:55 +01:00
Max Kellermann
7087935656
output/httpd: convert to C++
2013-01-15 20:20:51 +01:00
Max Kellermann
f9fc3a42cc
fifo_buffer: move to util/
2013-01-15 01:02:13 +01:00
Max Kellermann
49f3855407
configure.ac: enable WIN32_LEAN_AND_MEAN on Windows
2013-01-11 11:06:16 +01:00
Max Kellermann
ed8798e82f
output/shout: refactor check_block_param() to a function
...
Don't use macro magic, don't dereference the block_param.
2013-01-10 18:46:33 +01:00
Max Kellermann
38474961fd
Log, ...: include cleanup
2013-01-10 18:34:40 +01:00
Max Kellermann
d3e1b72d38
mixer/{alsa,pulse}: convert to C++
2013-01-09 22:25:24 +01:00
Max Kellermann
ade0483641
Merge branch 'v0.17.x'
2012-10-02 17:34:03 +02:00
Gregory Smith
03a401e477
OSX: Set mDataByteSize correctly on AudioBuffers during render.
2012-10-02 17:27:52 +02:00
Max Kellermann
9a715267ad
output/shout: move code to my_shout_configure()
...
Eliminate the evil goto.
2012-10-02 00:39:21 +02:00
Max Kellermann
d95e538020
Merge branch 'v0.17.x'
2012-10-02 00:36:05 +02:00
Max Kellermann
adbe8c409a
output/{recorder,shout}: call encoder_read() in a loop
...
This is necessary for Ogg packets that span more than one page.
2012-10-02 00:26:40 +02:00
Max Kellermann
58e600f408
output/recorder: move code to _write_to_file()
2012-10-02 00:26:40 +02:00
Max Kellermann
d34e55c370
output/recorder: fix write() error check
...
We can only check for negative values if the variable is signed.
2012-10-02 00:20:42 +02:00
Max Kellermann
fbcbcdc001
output/recorder: make variables more local
2012-10-02 00:20:32 +02:00
Max Kellermann
4227a325a5
output/httpd: make variables more local
2012-10-02 00:20:13 +02:00
Max Kellermann
43d8252050
output/recorder, test/*: invoke encoder_read() after _open()
...
Make sure the file header gets written at the beginning, before
_write() gets called.
2012-10-02 00:18:18 +02:00
Max Kellermann
674b4ab647
output/shout: eliminate struct shout_buffer
...
Move the raw buffer to struct shout_data.
2012-10-02 00:18:04 +02:00
Max Kellermann
fe8fc1081a
output/shout: remove shout_buffer.len
...
Make it a local variable instead.
2012-10-02 00:17:53 +02:00
Max Kellermann
c7748fedab
output/shout: fix memory leak in error handler
2012-10-02 00:17:27 +02:00
Max Kellermann
c392efb481
output/shout: make variables more local
2012-10-02 00:17:17 +02:00
Max Kellermann
7d27d2ea5e
Merge branch 'v0.17.x'
2012-08-14 23:58:54 +02:00
Max Kellermann
c9aaabb5d4
output/jack: implement method delay()
...
Eliminate the g_usleep() call.
2012-08-14 22:47:25 +02:00
Max Kellermann
335d5d5d72
output/pulse: implement method delay()
...
Reduce command latency while paused.
2012-08-14 22:30:46 +02:00
Max Kellermann
51d793bec1
output/pulse: simplify _wait_stream()
...
One large loop and only one pa_stream_get_state() call.
2012-08-14 22:22:55 +02:00
Max Kellermann
249dcd967e
output/httpd: move delay from _pause() to _delay()
2012-08-14 21:54:47 +02:00
Max Kellermann
302972e9fc
output/httpd: fix throttling bug after resuming playback
...
Reset the timer when paused and no client is connected.
This fixes Mantis ticket 0003527.
2012-08-14 21:39:33 +02:00
Max Kellermann
31b380b266
output/httpd: move code to _has_clients()
2012-08-14 20:22:32 +02:00
Max Kellermann
8e331cfc65
gcc.h: re-add gcc_const and gcc_pure
...
Remove GLib dependency from some headers.
2012-08-02 19:12:18 +02:00
Max Kellermann
edf811fa02
DatabaseVisitor, ...: use GError forward declaration
2012-08-02 19:12:06 +02:00
Max Kellermann
5dfc0918c3
require GLib 2.16
...
GLib 2.16 was released more than 4 years ago. Let's remove some cruft
from the glib_compat.h header, and avoid new cruft to it.
2012-07-10 01:28:52 +02:00
Max Kellermann
457d98c860
output/raop: delete the RAOP plugin
...
This plugin is horrible code, I mean it. Last year, I tried hard to
fix it, but I figured would take less time to do a full rewrite.
Given that I don't even have any device that supports RAOP, I can't do
that properly. After 16 months, nobody volunteered for fixing it.
Hereby, I delete it, because having no RAOP plugin is better than
having this mess. Sorry.
2012-05-29 23:15:41 +02:00
Max Kellermann
89377556cd
output/alsa: multiply writei() result with out_frame_size
...
.. and not in_frame_size, because this relates to the frame size being
sent to ALSA. pcm_export_source_size() will then turn it back into
the in_frame_size scale.
2012-04-23 21:54:09 +02:00
Max Kellermann
df1c5ce314
pcm_export: add _frame_size()
...
Move code from the ALSA output plugin.
2012-04-23 21:54:09 +02:00
Max Kellermann
a0e4b6e266
output/alsa: fix out_frame_size formula, multiply with channels
...
The hard-coded "3 bytes" was wrong because it ignored the number of
channels.
2012-04-23 21:54:08 +02:00
Max Kellermann
c22cbbf828
Merge branch 'v0.16.x'
...
Conflicts:
src/output/osx_plugin.c
src/text_input_stream.c
2012-04-05 00:45:39 +02:00
Max Kellermann
5acee73fc8
encoder/vorbis: generate end-of-stream packet when playback ends
...
Add the encoder_plugin method end(). This is important for the
recorder plugin.
2012-04-05 00:21:53 +02:00
Max Kellermann
a9edf85a69
output/jack: check for connection failure before starting playback
2012-04-04 21:40:56 +02:00
Max Kellermann
e7a1862517
output/jack: workaround for libjack1 crash bug
2012-04-04 21:38:29 +02:00
Max Kellermann
8ff0197a43
output/osx: use the fifo_buffer library instead of rolling own
...
The existing buffer implementation has a major flaw: it is unable to
re-fill the buffer until it has been consumed completely, leading to
many occasions where the render callback needs to generate silence,
just because the play() implementation was unable to append more
data. The fifo_buffer library handles that well.
2012-03-28 21:51:17 +02:00
Max Kellermann
a2b5db0003
audio_format: remove SAMPLE_FORMAT_DSD_OVER_USB
...
DSD-over-USB should not be a MPD core format, because it is not a
"natural" format; it is just a temnporary over-the-wire format. This
format has been implemented in pcm_export, and does not need to be
supported by pcm_convert.
2012-03-27 01:22:50 +02:00
Max Kellermann
2803ec2e96
output/alsa: support 32 bit DSD-over-USB
2012-03-27 01:22:50 +02:00
Max Kellermann
ddd4f675a2
pcm_export: implement 24 to 32 bit conversion
...
For 32 bit DSD-over-USB support.
2012-03-27 01:22:50 +02:00
Max Kellermann
d271dd2cce
output/alsa: use pcm_export for the DSD-over-USB conversion
2012-03-27 01:22:50 +02:00
Max Kellermann
ebfdd37451
pcm_export: support DSD to DSD-over-USB conversion
...
Prepare for removing SAMPLE_FORMAT_DSD_OVER_USB.
2012-03-27 01:17:11 +02:00
Max Kellermann
f6d6110aaa
output/alsa: move pcm_export_open() to caller
...
Give the caller more control, prepare for DSD-over-USB improvements.
2012-03-27 01:17:11 +02:00
Max Kellermann
2f0674807c
output/alsa: more debug output
2012-03-27 00:14:37 +02:00
Max Kellermann
167242fec0
output/alsa: add option to enable DSD over USB
2012-03-22 01:30:16 +01:00
Max Kellermann
725fbe946b
output/alsa: split the frame_size attribute
...
Make it in_frame_size and out_frame_size, to account for packing.
2012-03-22 01:01:11 +01:00
Max Kellermann
b99ecb4dc9
audio_format: remove the packed S24 format
...
For simplicity, the MPD core should not have to deal with packing. It
is rarely used, and those plugins that need it should use the
pcm_export library instead.
2012-03-22 00:42:12 +01:00
Max Kellermann
208a96b211
output/alsa: use pcm_export to pack 24 bit samples
2012-03-22 00:33:59 +01:00
Max Kellermann
43774455cc
output/oss: use pcm_export to pack 24 bit samples
2012-03-22 00:33:40 +01:00
Max Kellermann
5b61e077e0
pcm_export: add option "pack"
...
Converts padded 24 bit samples to packed 24 bit samples. Will replace
the packed S24 sample format, which is not used internally.
2012-03-22 00:33:40 +01:00
Max Kellermann
921cc3e5db
output/oss: remember the real OSS format
...
Improving oss_reopen() by using the very same value that was used
initially.
2012-03-22 00:33:40 +01:00
Max Kellermann
51dce3d161
output/alsa: simplify setup_format()
2012-03-22 00:29:56 +01:00
Max Kellermann
c10f013fc2
output/alsa: don't pass audio_format to _try_format()
...
Let the caller configure the audio_format object.
2012-03-22 00:24:56 +01:00
Max Kellermann
2874d68bdb
output/alsa: simplify alsa_output_try_format_both()
...
Merge three functions into one and call get_bitformat() only once.
2012-03-22 00:23:07 +01:00
Max Kellermann
11e83eb7e7
output/oss: move code to oss_probe_sample_format()
2012-03-21 22:28:18 +01:00
Max Kellermann
170635e3a6
output/{alsa,oss}: move endian code to new library pcm_export
2012-03-21 21:16:50 +01:00
Max Kellermann
8c5ebdff36
audio_format: remove the reverse_endian attribute
...
Eliminate support for reverse endian samples from the MPD core. This
moves a lot of complexity to the plugins that really need it (only
ALSA and CDIO currently).
2012-03-21 19:31:04 +01:00
Max Kellermann
1c84f324a1
output/oss: always receive host byte order samples
...
Don't use audio_format.reverse_endian.
2012-03-21 19:25:59 +01:00
Max Kellermann
3dba09f339
output/alsa: always receive host byte order samples
...
Don't use audio_format.reverse_endian.
2012-03-21 19:14:05 +01:00
Max Kellermann
766905ba9f
output/alsa: merge alsa_data_free() into destructor
2012-03-21 18:58:11 +01:00
Rich Healey
396e97fc94
Fix the build on OSX
2012-03-21 10:32:54 +01:00
Max Kellermann
9c6a4505c8
audio_format: remove the format SAMPLE_FORMAT_DSD_LSBFIRST
...
This format is unused since the DSDIFF decoder plugin now reverses the
bit order.
2012-03-21 09:06:48 +01:00
Max Kellermann
08ce24ec3f
audio_format: basic support for DSD-over-USB
2012-03-19 23:49:29 +01:00
Max Kellermann
5016839b90
use g_strerror() instead of strerror()
...
Make sure we get a UTF-8 encoded string.
2012-03-06 22:06:08 +01:00
Kurt Van Dijck
c551c8b31b
raop_output: fix raop_session inbalance
...
raop_session_free must be called from raop_output_finish,
not from raop_output_remove.
In raop_output_remove, do close the ntp_server & control port.
Signed-off-by: Kurt Van Dijck <kurt.van.dijck@skynet.be>
2012-03-01 09:51:37 +01:00
Max Kellermann
2516496993
audio_format: add DSD sample format
...
Basic support for Direct Stream Digital. No conversion yet, and no
decoder/output plugin support.
2012-03-01 01:15:22 +01:00
Max Kellermann
c616165f81
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
src/decoder/ffmpeg_decoder_plugin.c
test/read_tags.c
2012-02-13 19:15:18 +01:00
Max Kellermann
9c92afa5fe
output/winmm: remove pointless NULL check
...
pcm_buffer_get() cannot ever return NULL.
2012-02-13 18:10:36 +01:00
Max Kellermann
95b2df8261
output/osx: fix memory leak after AudioUnitSetProperty() failure
2012-01-04 20:47:41 +01:00
Max Kellermann
1ebadf8620
output/osx: implement 32 bit playback
2011-12-24 18:18:42 +01:00
Max Kellermann
9179d9592d
output/osx: allocate the device in enable()
...
Keep the device open as long as the output is enabled, but initialize
it only when playback starts.
2011-12-24 18:15:24 +01:00
Max Kellermann
43c5058682
Merge branch 'v0.16.x'
2011-12-24 18:15:17 +01:00
Max Kellermann
97b4a6b51f
output/osx: clear render buffer when there's not enough data
...
When we don't have enough data, generate some silence, hoping the
input buffer will fill soon. Reducing the render buffer size is not
legal.
2011-12-24 17:59:36 +01:00
Max Kellermann
f405d27c56
output/osx: remove sleep call from render callback
...
Blocking inside the render callback is forbidden, and this sleep call
didn't make any sense.
2011-12-24 17:56:10 +01:00
Max Kellermann
78c4351e04
output/openal: improve synchronization
...
This plugin's use of the "Timer" library was wrong; it added the same
amount of virtual data in every iteration in _play(), but did not
actually play something. This created an artificial, but useless,
delay. This patch implements the method _cancel(), and implements
hard-coded sleep values. This is only slightly better, but does not
attempt to look sane.
2011-12-13 22:02:05 +01:00
Max Kellermann
0a427890fe
output/openal: move code to inline functions
2011-12-13 22:00:18 +01:00
Max Kellermann
e735abe334
output/openal: use alGetSourcei(AL_BUFFER) to force-unqueue buffers
...
The implementation of cancel() did not work well: you cannot use
alSourceUnqueueBuffers() to unqueue queued buffers, and our function
openal_unqueue_buffers() left the OpenAL library in a rather undefined
state; nothing was supposed to be queued, but the "filled" variable
was not reset.
2011-12-13 21:59:10 +01:00
Max Kellermann
c0070b2f13
output/openal: make attribute "filled" unsigned
2011-12-13 21:58:13 +01:00
Max Kellermann
cfedc6e9b4
output/openal: remove bogus format check from _open()
...
The expression "!format" does not make sense, and cannot occur.
2011-12-13 21:58:09 +01:00
Max Kellermann
b66d7f7e0b
output/fifo: implement output_plugin method delay()
2011-12-13 21:58:07 +01:00
Max Kellermann
e01df06cd7
output/null: implement output_plugin method delay()
2011-12-13 21:58:02 +01:00
Max Kellermann
6584897b69
output/null: don't initialize the "timer" attribute in _init()
...
Unnecessary overhead.
2011-12-13 21:57:59 +01:00
Max Kellermann
aa4f45b9a5
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-12-13 21:57:44 +01:00
Max Kellermann
96ad5b8444
output/openal: force 16 bit playback, as 8 bit doesn't work
...
The OpenAL specification says that AL_FORMAT_MONO8 and
AL_FORMAT_STEREO8 expect unsigned 8 bit samples, but MPD uses unsigned
samples.
2011-12-13 21:32:19 +01:00
Denis Krjuchkov
33232face9
winmm_output_plugin: fail if wrong device specified instead of using fallback.
...
Silently choosing default is misleading and can cause hours of investigation.
It's better to fail immediately telling user what is wrong with config.
2011-12-13 19:12:33 +01:00
Max Kellermann
545685bc32
audio_format: basic support for floating point samples
...
Support for conversion from float to 16, 24 and 32 bit integer
samples.
2011-10-20 02:32:39 +02:00
Max Kellermann
8dd83a2cf3
output/roar: move code to _use_audio_format()
2011-10-08 14:51:19 +02:00
Max Kellermann
b43bf4dd74
Merge branch 'v0.16.x'
2011-10-08 14:50:44 +02:00
Max Kellermann
5ed0eb51d1
output/openal: auto-fallback to mono if channel count is unsupported
...
.. instead of failing playback completely.
2011-10-08 14:41:22 +02:00
Max Kellermann
72a1ca3b99
output/alsa: remove "default" case from switch
...
Allow gcc to warn when a new format isn't supported.
2011-10-08 14:41:11 +02:00
Steven Blackburn
21851c0673
Add support for streaming to a DLNA client
...
The Naim Uniti does not appear to support icecast-style streaming of FLAC
music but does support the codec from a DLNA server. This change looks for
"transferMode.dlna.org: Streaming" in the HTTP request header and responds
with something the Uniti (and hopefully other DLNA clients) accepts.
The only difference in the DLNA streaming mode is the reponse header and
that icecast metadata is disabled. If a client request indicates both modes
are supported, the DLNA mode is preferred (as the Uniti says it supports
both but then rejects a FLAC ICY stream).
Note: This change may be specific to Naim equipment (the only device it was
tested on). E.g. the hardcoding of Content-Length which works but is not a
logically correct value. The change should be backwards-compatible, so
only those clients requesting a DLNA stream will see any difference.
2011-09-30 08:53:09 +02:00
Dan McGee
8176880173
Simplify setsockopt() casting workaround
...
On Win32, the third setsockopt parameter has type (char *) while on POSIX
systems it is (void *). However, given that it is a no-op cast to go from a
char pointer to a void pointer, we can cast to a char pointer (with a
possible const modifier) on all platforms and satisfy the compiler.
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-09-21 17:54:44 +02:00
Max Kellermann
3ea1073809
socket_util: move sockaddr_to_string() to resolver.c
2011-09-20 08:49:36 +02:00
Max Kellermann
76a959a578
rtsp_client, output/raop: use close_socket() instead of close()
2011-09-20 08:48:48 +02:00
Max Kellermann
921553d7bb
Merge branch 'v0.16.x'
2011-09-20 08:47:06 +02:00
Max Kellermann
c476819cb1
fd_util: add function close_socket()
...
Wrap close(), use closesocket() on WIN32/WinSock.
2011-09-20 08:38:58 +02:00
Max Kellermann
b03f9ece05
glib_socket.h: wrap g_io_channel_*_new() calls portably
...
The server_socket library (used by the httpd output plugin) didn't
check for WIN32, that's fixed now.
2011-09-20 08:35:25 +02:00
Max Kellermann
74617389c8
output_plugin: the plugin allocates the audio_output object
...
Pass audio_output objects around instead of void pointers. This will
give some more control to the plugin, and prepares for non-blocking
audio outputs.
2011-09-19 09:41:21 +02:00
Max Kellermann
1d8840412f
configure.ac: add option --enable-solaris-output
...
Allow enabling the plugin explicitly without running Solaris, to test
the build.
2011-09-19 09:39:35 +02:00
Max Kellermann
ffa9f4b47f
output/roar: check return values
...
Fixes gcc warnings.
2011-09-18 12:07:06 +02:00
Max Kellermann
667e22bbc7
output/roar: unknown volume is -1, not 0
2011-09-18 12:06:46 +02:00
Max Kellermann
d4d838c8bb
output/roar: move code to roar_cancel_locked() and others
...
Wrap the locking code.
2011-09-18 11:51:18 +02:00
Max Kellermann
c61a889c86
output/roar: use GLib memory allocation functions
...
GLib has a built-in OOM handler.
2011-09-17 20:12:45 +02:00
Max Kellermann
567fe89a77
output/roar: use config_get_block_string() for temporary
2011-09-17 20:11:51 +02:00
Max Kellermann
950772ab8a
output/roar: reorder methods
2011-09-17 20:10:26 +02:00
Max Kellermann
0bd0e2a3ec
output: rename plugin variables
...
Consistent naming.
2011-09-17 20:04:18 +02:00
Max Kellermann
47774ce882
Merge branch 'v0.16.x'
2011-09-17 19:59:52 +02:00
Max Kellermann
3c9bcdd347
output: per-plugin header
...
Move the "extern" declarations from output_list.c, for more type
safety.
2011-09-17 19:51:41 +02:00
Max Kellermann
3934d2d30c
output/pulse: don't expose internal struct in public header
...
Provide _lock() and _unlock() to wrap all accesses from the mixer
plugin.
2011-09-17 19:50:36 +02:00
Max Kellermann
423ce9557a
output/raop: don't expose internal structs in public header
2011-09-17 19:44:30 +02:00
Max Kellermann
947848ebf6
output/roar: export volume methods
...
Use these instead of exposing the internal roar_t struct.
2011-09-17 19:33:51 +02:00
Max Kellermann
5e22fe488e
output: rename plugin source files
2011-09-17 08:54:50 +02:00
Max Kellermann
c666cf1c44
output/pulse: move code to _setup_stream()
2011-09-17 08:53:53 +02:00
Max Kellermann
27206368da
output/pulse: improve locking
...
Always lock the main loop when operating on PULSE objects. Document
this.
2011-09-17 07:30:59 +02:00
Max Kellermann
87b624f5d5
Merge branch 'v0.16.x'
2011-09-16 07:52:39 +02:00
Max Kellermann
1cbba4fc59
input/curl, output/pulse: fix "unused local variable" warnings
2011-09-16 07:41:41 +02:00
Max Kellermann
9f5c938ff3
conf: add config_dup_block_path()
2011-09-09 23:01:22 +02:00
Max Kellermann
b42a8d2364
utils: parsePath() returns GError on failure
...
Better error messages.
2011-09-09 22:55:57 +02:00
Max Kellermann
35af940166
conf: get_block_param() returns a const pointer
...
No caller needs to write.
2011-09-09 21:36:41 +02:00
Max Kellermann
6a3008d7ff
Merge branch 'v0.16.x'
...
Conflicts:
configure.ac
src/output_control.c
2011-09-01 19:19:42 +02:00
Max Kellermann
596f36bb78
output/osx: don't drain the buffer when closing
...
Eliminate an unnecessary source of deadlocks.
2011-09-01 18:21:46 +02:00
Max Kellermann
e7abdab58d
output/osx: signal the GCond while mutex is locked
2011-09-01 18:21:46 +02:00
Max Kellermann
60f7ff3de5
output/pulse: reset callbacks before closing stream/context
...
Fixes assertion failure when a stream callback is invoked too late
after a format change.
2011-08-31 21:01:34 +02:00
Max Kellermann
e76c752987
output/pulse: add function _delete_stream()
...
Merge common code.
2011-08-31 21:01:22 +02:00
Max Kellermann
042c1abc6e
output/pulse: use _delete_context()
...
Eliminate duplicate code.
2011-08-31 20:58:36 +02:00
Max Kellermann
1401621913
output/raop: remove Audio-Jack-Status check
...
The value of this is not used, the code is commented out - let's get
rid of it.
2011-08-31 20:19:36 +02:00
Max Kellermann
3c034b0a0c
output/raop: remove empty function raopcl_stream_connect()
2011-08-31 20:17:24 +02:00
Max Kellermann
7f3dc5f040
output/raop: cast sendto() parameter to void pointer
...
Fix compilation on mingw32.
2011-08-31 08:30:26 +02:00
Max Kellermann
9209ccfa40
rtsp_client: allow parameter "kd" to be NULL
...
When the caller isn't interested in the values.
2011-08-31 08:16:55 +02:00
Max Kellermann
2525d32e17
rtsp_client: don't wait if packet is over due
...
Check if the time difference is negative. That would have caused
sleeping forever.
2011-08-31 07:47:01 +02:00
Max Kellermann
57526067f5
output/raop: move code to raop_session_new()
...
.. and fix a few memory leaks.
2011-08-30 22:36:54 +02:00
Max Kellermann
34d9d8abd4
output/raop: merge raopcl_close() into _finish()
...
.. and fix a double free bug.
2011-08-30 22:20:32 +02:00
Max Kellermann
bd67e986f4
output/raop: free the raop_data object in finish()
2011-08-30 22:02:55 +02:00
Max Kellermann
e587518d85
output/raop: remove from the session when opening fails
2011-08-30 22:00:19 +02:00
Max Kellermann
210b6c38bd
output/raop: move code to raop_output_remove()
2011-08-30 21:56:57 +02:00
Max Kellermann
74a39c715b
ntp_server: move code to udp_server.c
2011-08-30 07:39:05 +02:00
Max Kellermann
195496333b
output/raop: move RTSP client code to rtsp_client.c
...
Restore some of the original file structure from from raop_play.
2011-08-29 11:27:08 +02:00
Max Kellermann
9ccaa90439
ntp_server: use the I/O thread
2011-08-29 11:23:51 +02:00
Max Kellermann
a769352a74
output/raop: fallback for g_set_error_literal()
...
This function was added in GLib 2.18. Make the plugin compatible with
older GLib versions.
2011-08-29 09:39:03 +02:00
Max Kellermann
8a63c27925
output/raop: move NTP code to separate library
2011-08-28 16:44:12 +02:00
Jonathan Neuschäfer
310895f060
rename 'Timer' to 'struct timer'
2011-08-27 11:30:34 +02:00
Max Kellermann
0575a6d652
output/raop: use GLib byte order macros
2011-08-24 02:19:40 +02:00
Max Kellermann
08b88714e0
output/raop: use fill_int() in fill_time_...()
...
Eliminate duplicate code.
2011-08-24 02:18:51 +02:00
Max Kellermann
bcaff4b844
output/raop: check if the "host" option is present
...
Better than dereferencing NULL.
2011-08-24 01:47:31 +02:00
Max Kellermann
82f336a78f
output/raop: remove excessive debug messages
2011-08-24 01:47:27 +02:00
Max Kellermann
350aa33022
output/raop: consistently use GError
2011-08-24 01:47:26 +02:00
Max Kellermann
d6290a2f1a
output/raop: use GLib heap functions
2011-08-24 01:47:25 +02:00
Max Kellermann
71e9d08863
output/raop: functions that always succeed return void
...
No point in returning true, and checking that.
2011-08-24 01:47:23 +02:00
Max Kellermann
9729dc7594
output/raop: rtspcl_connect() returns false on error
...
.. and not -1, which is "true".
2011-08-24 01:47:22 +02:00
Max Kellermann
92c1b8f31e
output/raop: error checking in send_control_command()
2011-08-24 01:47:21 +02:00
Max Kellermann
9ffa2604f8
output/raop: make some allocations static
...
Allocate objects on the stack to reduce heap overhead.
2011-08-24 01:47:20 +02:00
Max Kellermann
03b1fad4d4
output/raop: remove unused local variables
2011-08-24 01:47:18 +02:00
Max Kellermann
72eb4c534f
output/raop: make some exec_request parameters const
2011-08-24 01:47:17 +02:00
Max Kellermann
47d936e9cc
output/raop: use "char*" for string buffers
...
Not unsigned char. Eliminate useless casts.
2011-08-24 01:47:15 +02:00
Max Kellermann
8e08407090
output/raop: make send_control_command() static
...
Only used internally.
2011-08-24 01:47:14 +02:00
Max Kellermann
c0a4558c62
output/raop: remove useless test_default_device() implementation
...
This defaults to "false" when the method pointer is NULL.
2011-08-24 01:47:13 +02:00
Max Kellermann
5ecb6fecc4
Merge branch 'v0.16.x'
2011-08-24 01:47:10 +02:00
Max Kellermann
b3df4dc2c9
output/pulse: fix deadlock when the stream was suspended
...
Check if the stream is suspended; wake up the main loop when it
becomes suspended.
2011-08-23 23:02:13 +02:00
Max Kellermann
3db9ab82ea
output/pulse: add assertions
2011-08-23 22:48:22 +02:00
Max Kellermann
2dc3acc5f0
output/pulse: return 0 on error
...
Not a bool.
2011-08-23 22:48:22 +02:00
Max Kellermann
25686e5bce
pulse/output: fix deadlock when resuming the stream
...
Unlock the mainloop in all code paths.
2011-08-23 22:45:47 +02:00
Max Kellermann
7c887af1ea
output/httpd: add assertions
2011-08-23 18:14:39 +02:00
Max Kellermann
b7f435b50e
output/httpd: don't warn on client disconnect
...
This warning should only be logged when we really received something.
When the client disconnects, G_IO_IN is triggered, and the read
returns G_IO_STATUS_EOF.
2011-08-23 18:02:56 +02:00
Jonathan Neuschäfer
eea726740b
output/raop: rewrite remove_char_from_string
2011-07-25 11:23:22 +02:00
Max Kellermann
0ea4c970d7
Merge branch 'v0.16.x'
...
Conflicts:
src/player_thread.c
src/playlist_control.c
2011-07-20 21:46:05 +02:00
Max Kellermann
57936a1374
output/raop: use memset() instead of bzero()
...
There's no bzero() on WIN32.
2011-07-20 21:20:23 +02:00
Max Kellermann
9242fde6b8
output/raop: include winsock.h on WIN32
2011-07-20 21:18:55 +02:00
Max Kellermann
d1f653be65
output/raop: use GMutex instead of pthread_mutex_t
...
Be portable on WIN32.
2011-07-20 21:11:06 +02:00
Max Kellermann
0035dceb0a
output/raop: add missing mutex unlock call in error handler
2011-07-20 21:09:39 +02:00
Max Kellermann
838f7cd210
encoder_plugin: add method pre_tag()
...
In the "vorbis" plugin, this is a copy of the old flush() method,
while flush() gets a lot of code remove, it just sets the "flush" flag
and nothing else. It doesn't start a new stream now, which should fix
a few problems in some players.
2011-07-20 20:54:34 +02:00
Max Kellermann
13539961b2
output/httpd: explicitly convert size_t to bool in pause()
2011-07-20 19:16:47 +02:00
Max Kellermann
d1eeed6a5b
output/alsa: fix SIGFPE when alsa announces a period size of 0
2011-07-20 06:54:51 +02:00
Jonathan Neuschäfer
a222c4879c
output/shout: fix a memory leak
2011-07-19 00:24:48 +02:00
Max Kellermann
eb2f413cf0
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-07-19 00:24:20 +02:00
Jonathan Neuschäfer
7d6a605a85
output/shout: fix a memory leak
2011-07-18 22:04:48 +02:00
Jonathan Neuschäfer
a6a8bdffc3
output/recorder: fix a memory leak
2011-07-18 22:04:10 +02:00
Jonathan Neuschäfer
296085ff23
output/httpd: add missing g_free in error path
2011-07-18 22:04:06 +02:00
Jonathan Neuschäfer
36aa8ce3c9
output/ao: add missing g_free in error path
2011-07-18 22:03:48 +02:00
Hans-Kristian Arntzen
d9353c4fd3
Remove unused headers in Roar plugin.
...
Should fix build errors for Win32.
2011-03-23 21:59:22 +01:00
Max Kellermann
0c9fc2f809
Merge commit 'release-0.16.2'
...
Conflicts:
Makefile.am
NEWS
configure.ac
2011-03-19 09:58:07 +01:00
Max Kellermann
8d83914f05
output/httpd: include sys/socket.h only when building with libwrap
...
Fixes build failure on WIN32.
2011-03-18 19:44:12 +01:00
Max Kellermann
6dcec36621
Merge release 0.15.16 into v0.16.x
...
Conflicts:
NEWS
configure.ac
src/output/jack_plugin.c
src/update.c
2011-03-16 18:08:54 +01:00
Hans-Kristian Arntzen
1a954748a0
RoarAudio output plugin
2011-03-16 17:57:47 +01:00
Ulrich Spörlein
e2aea6bce5
output/httpd: include sys/socket.h for AF_UNIX
2011-03-09 19:53:48 +01:00
Max Kellermann
a1d1c2beaa
output/oss: disable 24 bit playback on FreeBSD
...
See code comment.
2011-02-28 00:09:45 +01:00
Max Kellermann
ee9c60fad4
output/oss: AFMT_S24_PACKED is little-endian
...
According to the Solaris dsp manpage, AFMT_S24_PACKED is
little-endian:
http://download.oracle.com/docs/cd/E19963-01/821-1475/6nmf5baot/index.html
The Minix soundcard.h header says the same.
2011-02-28 00:00:41 +01:00
Max Kellermann
1674a4ec82
output/jack: fix crash with mono playback
...
With mono sound, jack_sample_size is smaller than frame_size (4 vs 2
bytes), and "space/jack_sample_size==0". That means mpd_jack_play()
will return 0, although no error has occurred.
2011-02-27 23:26:50 +01:00
Max Kellermann
ce370bee60
output/jack: rename variable sample_size to jack_sample_size
2011-02-25 10:46:44 +01:00
Christopher Brannon
2a1f4539f6
Insure proper initialization of stack-allocated struct.
...
Version 1.0.0 of the libao library added a new field to the
ao_sample_format struct. It is a char * named matrix. When
an ao_sample_format is allocated on the stack, this field contains
garbage. The proper course is to insure that is initialized to NULL.
NULL indicates that we do not want any mapping.
The struct is now initialized using a static initializer, and this
technique is compatible with all known versions of libao.
2011-02-15 12:16:25 +01:00
Thomas Jansen
144d092637
output/shout: add possibility to set url
...
Added a new optional parameter for the shout plugin called "url".
2011-02-09 22:42:51 +01:00
Thomas Jansen
948b8f35e6
general: whitespace cleanup
...
Remove trailing whitespace found by this command:
find -name '*.[ch]' | xargs grep "[[:space:]]$"
2011-02-09 22:42:31 +01:00
Thomas Jansen
e776c605ad
output/httpd: initialize unflushed_input
...
This fixes the following valgrind warning occuring on the first call of
httpd_output_read_page:
==20124== Conditional jump or move depends on uninitialised value(s)
==20124== at 0x425E65: httpd_output_read_page (httpd_output_plugin.c:240)
==20124== by 0x426087: httpd_output_open (httpd_output_plugin.c:279)
==20124== by 0x41D862: ao_open (output_plugin.h:206)
==20124== by 0x41E133: audio_output_task (output_thread.c:590)
2011-02-09 22:41:36 +01:00
Max Kellermann
c6cbcc2c25
copyright year 2011
2011-01-29 10:13:54 +01:00
Dustin Puckett
79e0db4ca0
output/raop: new output plugin
...
Remote Audio Output Protocol (RAOP), for Apple devices.
2011-01-28 21:17:09 +01:00
Max Kellermann
1a2ea4c06c
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-01-07 23:52:23 +01:00
Max Kellermann
8c0afd8557
Merge branch 'v0.15.x' into v0.16.x
...
Conflicts:
NEWS
configure.ac
src/directory.h
2011-01-07 23:50:23 +01:00
Max Kellermann
4f2d67dfb0
output/httpd: define G_LOG_DOMAIN in httpd_client.c
2011-01-07 18:00:12 +01:00
Max Kellermann
b5645ab29f
output/osx: fix up audio format first, then apply it to device
...
This is a MPD 0.16 regression: when playing a 24 bit file, the switch
to 16 bit was made only partially, after mBytesPerPacket and
mBytesPerFrame had already been applied.
That means mBytesPerFrame referred to 24 bit, and mBitsPerChannel
referred to 16 bits. Of course, that cannot work.
2011-01-07 17:31:36 +01:00
Greg Ward
9cb4aaf3c2
osx_output: always pass OS X result code to g_set_error().
...
Should be safe on OS X 10.4 (32-bit), since Apple's OSStatus boils
down to "signed long", and g_set_error() takes gint, which is really
just "int". Assigning "signed long" to "int" on 32-bit Unix should be
just fine, since both are signed 32-bit ints.
No idea if this is safe on 64-bit OS X.
2010-12-21 07:37:54 +01:00
Greg Ward
80dc602193
osx_output: allow user to specify other audio devices.
...
Add new config parameter 'device' to audio_output type "osx":
- if not supplied or set to "default", open default device
- if set to "system", open system device
- otherwise 'device' should be an audio device name: mpd will find and
open the specified audio device, falling back to the default
device if it's not found
2010-12-21 07:36:28 +01:00
Alex Viskovatoff
144ad7992e
output/solaris: add missing parameter to open_cloexec() call
2010-12-21 07:31:08 +01:00
Max Kellermann
f384f8da93
Merge release 0.15.15 from branch 'v0.15.x'
...
Conflicts:
NEWS
configure.ac
2010-11-08 18:50:22 +01:00
Max Kellermann
cc1debc948
output/shout: artist comes first in stream title
...
After popular demand, I've switched the order of "artist" and "title"
in the stream title. There is no standard, and there is no reliable
way to parse those from the stream title.
2010-11-08 18:46:14 +01:00
Max Kellermann
5a26320680
output/alsa: dump buffer and period limits
2010-11-05 10:35:46 +01:00
Max Kellermann
90dc880e67
output/httpd: implement delay()
2010-11-05 09:49:22 +01:00
Max Kellermann
e11ff967d0
output/shout: implement delay()
...
This makes the plugin more responsive to control commands, because it
will listen to control events while waiting.
2010-11-05 09:49:20 +01:00
Max Kellermann
754015544f
output/ffado: transfer_playback_buffers() returns a boolean
...
libffado documentation says this function returns -1 on error, but
that is a lie - it returns a boolean value, and "false" means error.
2010-11-04 20:08:04 +01:00
Denis Krjuchkov
9dee419b7c
winmm_output: handle empty string case when parsing device id
2010-11-04 11:09:50 +05:00
Denis Krjuchkov
7612bf1bfa
winmm_output: added "device" configuration option
...
Device can be specified either by magic index (starting with 0)
or by device name.
2010-11-04 00:51:18 +05:00
Denis Krjuchkov
ad56e10e5b
winmm_output: improved test_default_device
...
If no device is available test_default_device returns false.
2010-11-03 23:31:49 +05:00
Max Kellermann
75f4772ba2
output: new output plugin "ffado"
...
Using libffado, to play on firewire audio devices.
Warning: this plugin was not tested successfully. I just couldn't
keep libffado2 from crashing. Use at your own risk.
For details, see my Debian bug reports:
http://bugs.debian.org/601657
http://bugs.debian.org/601659
2010-10-27 21:25:41 +02:00
Denis Krjuchkov
e6fc88a758
mixer: winmm_mixer implemented
2010-10-09 02:45:08 +06:00
Denis Krjuchkov
20004b7ee0
win32_output: renamed win32 output plugin to winmm
...
Win32 has many audio APIs. New name is slightly more correct.
2010-10-08 23:55:14 +06:00
Max Kellermann
84e037631d
output/httpd: use the new server_socket library
2010-10-05 21:18:54 +02:00
Max Kellermann
04c4398bfc
output/httpd: don't close socket in open() failure
...
This cleanup call is obsolete, since we moved the binding code to
enable()/disable().
2010-10-05 21:18:54 +02:00
Max Kellermann
5923cfcde3
output/httpd: MIME type audio/ogg for Ogg Vorbis
...
RFC 5334 10.3 defines the MIME type "audio/ogg". We could use
"application/ogg" as well, but we know for sure that we only emit
audio data.
2010-10-03 16:22:03 +02:00
Thomas Jansen
28bcb8bdf5
eliminate g_error() usage
...
Replaced all occurrences of g_error() with MPD_ERROR() located in a new header
file 'mpd_error.h'. This macro uses g_critical() to print the error message
and then exits gracefully in contrast to g_error() which would internally call
abort() to produce a core dump.
The macro name is distinctive and allows to find all places with dubious error
handling. The long-term goal is to get rid of MPD_ERROR() altogether. To
facilitate the eventual removal of this macro it was added in a new header
file rather than to an existing header file.
This fixes #2995 and #3007 .
2010-09-25 15:00:43 +02:00
Thomas Jansen
9af9fd1400
output/httpd: bind_to_address support (including IPv6)
...
Added support for a new optional configuration setting for the httpd output
named "bind_to_address". Setting it to a specific IP address (v4 or v6) will
cause the httpd output to bind to that address exclusively. Supporting
multiple addresses in parallel is future work.
This implements the feature requests #2998 and #2646 .
2010-09-25 15:00:43 +02:00
Max Kellermann
5b996ab880
output/httpd: access sockaddr_storage object directly
...
Work around aliasing warning.
2010-09-23 09:01:17 +02:00
Max Kellermann
917434269c
output/httpd: implement "pause"
...
Send silence to all connected clients while paused, to avoid
connection interruption.
2010-08-31 06:50:14 +02:00
Max Kellermann
a77506ae21
output/httpd: forced flush after 32 kB of input data
...
Avoid buffer underruns on the streaming client, if the encoder is "too
efficient" (e.g. when encoding silence while paused).
2010-08-31 06:49:06 +02:00