Commit Graph

3653 Commits

Author SHA1 Message Date
Max Kellermann 3a75f15844 mms: declare GLib log domain 2009-01-29 21:43:45 +01:00
Max Kellermann caa4d28f04 added support for the MMS protocol
This patch implements the MMS protocol, by using libmms.  It is quite
experimental: it does not support seeking yet, and it is currently
using synchronous I/O, which causes MPD to hang while waiting for the
server.
2009-01-29 21:42:10 +01:00
Max Kellermann 36ca114629 player_control: reset pc.error if pc.errored_song is cleared
When the playlist is cleared, pc.errored_song is also cleared.  This
causes pc_errored_song_uri() to crash, because it assumes that
pc.errored_song is set.  Reset pc.error to fix that assumption.
2009-01-29 21:39:29 +01:00
Max Kellermann d1b3377f4a AUTHORS: moved people to "Former Developers", added Thomas Jansen
Moved people who havn't contributed during the 0.14 development cycle.
2009-01-29 18:22:22 +01:00
Max Kellermann a73266962f jack: reduced sleep time to 1ms
When waiting for free space in the ring buffer, the JACK plugin
sleeped 10ms until there is enough space.  This delay was too large
for low-latency setups (<10ms), and created a lot of xruns.  Work
around that by reducing the sleep time to 1ms.

A proper solution for this would be to use an event based approach,
and we will do it, just not now.
2009-01-29 18:13:09 +01:00
Max Kellermann 1e0ceb3d88 jack: clear "shutdown" flag on reconnect
When the connection failed once, you had to restart MPD, because it
never cleared the jack_data.shutdown flag.  Instead, it refused to
play anything "because there is no client thread" (which is wrong at
that point).
2009-01-29 18:13:03 +01:00
Max Kellermann 3a070d3d23 jack: allocate ring buffers before connecting
If the ring buffers are allocated after jack_activate(),
mpd_jack_process() might segfault because it attempts to access them.
2009-01-29 18:12:52 +01:00
Max Kellermann bbf0453709 jack: register ports before activating clients
Call jack_port_register() before jack_activate().
2009-01-29 18:12:25 +01:00
Avuton Olrich 9ef6c79991 Modify version string to post-release version 0.14.2~git 2009-01-29 18:10:02 +01:00
Max Kellermann 24d6ae8bea zeroconf: corrected default service name usage
The variable "serviceName" is initialized with SERVICE_NAME, but was
overwritten with NULL when the setting is not configured.
2009-01-27 20:17:44 +01:00
Rasmus Steinke 3f2ed33f57 changed sticker names to be lowercase and without spaces 2009-01-26 08:12:10 +01:00
Max Kellermann 8bc6bca555 client: use the GIOChannel for I/O
GIOChannel is more portable than raw read()/write() calls.  We're
using GIOChannel anyway, because we need it for plugging the client
into the GLib main loop.

Configure the GIOChannel to the bare minimum: no character set, no
buffering.
2009-01-25 19:54:57 +01:00
Max Kellermann b0ea975642 client: use GLib's win32 IO channel on WIN32
Use g_io_channel_win32_new_socket() instead of g_io_channel_unix_new()
on WIN32.
2009-01-25 19:40:10 +01:00
Laszlo Ashin 808a369ca8 tag: remove unused variable param
This variable doesn't have a role since 80799fa8.
2009-01-25 19:38:49 +01:00
Max Kellermann c4bb227bdb database: eliminate "goto" usage
http://xkcd.com/292/
2009-01-25 18:47:23 +01:00
Max Kellermann a45922cd66 use g_free() instead of free()
On some platforms, g_free() must be used for memory allocated by
GLib.  This patch intends to correct a lot of occurrences, but is
probably not complete.
2009-01-25 18:47:21 +01:00
Max Kellermann 7960ad32fc doc: chunk the DocBook HTML output
Create a HTML chunk of each DocBook chapter.  Use the UTF-8 character
set instead of docbook-xsl's ISO-Latin-1 default.
2009-01-25 18:24:42 +01:00
Max Kellermann 936449c622 mixer_api: removed struct mixer_data
The mixer plugins should re-use the mixer struct and incorporate it in
their object class.
2009-01-25 17:45:16 +01:00
Max Kellermann dc575106c2 mixer: merged methods "init" and "configure"
Both methods are always called together.  There is no point in having
them separate.  This simplifies the code, because the old configure()
method could be called more than once, and had to free old
allocations.
2009-01-25 17:38:12 +01:00
Max Kellermann db2058a265 mixer: removed mixer_configure_legacy(), AC_MIXER_CONFIGURE
Those have been superseded by the new legacy configuration code.
2009-01-25 17:38:06 +01:00
Max Kellermann 188f9e663c mixer: configure legacy mixer before the audio outputs
Reimplemented the legacy mixer configuration: copy the deprecated
configuration values into the audio_output section.  Don't configure
the mixers twice (once for the audio_output, and a second time for the
legacy values).

This requires volume_init() to be called before initAudioDriver().
2009-01-25 17:38:02 +01:00
Max Kellermann 8695b94232 mixer: removed mixer_configure(), configure mixer in mixer_new()
Allocate the mixer object when it is configured.

Merged mixer_configure() into mixer_new().  mixer_new() was quite
useless anyway.
2009-01-25 17:37:59 +01:00
Max Kellermann 763dd8c1dd mixer: return a mixer struct pointer
Don't use statically allocated mixer objects.
2009-01-25 17:37:55 +01:00
Max Kellermann ad8561bfdc mixer: make all mixer_plugin pointers const
The plugin structures must never be modified.
2009-01-25 17:37:52 +01:00
Max Kellermann 899eb5383d mixer: added missing copyright headers 2009-01-25 17:37:50 +01:00
Max Kellermann cb1f2e0c01 conf: added config_add_param()
The function config_add_param() allows adding new configuration
parameters.
2009-01-25 17:37:45 +01:00
Qball Cow b6c3adcaaa Add idle event on sticker deletion, update and insertion 2009-01-25 16:37:29 +01:00
Max Kellermann 3635c93acb conf: allow param==NULL
Return the default value in the conf_get_block_*() functions when
param==NULL was passed.

This simplifies a lot of code, because all initialization can be done
in one code path, regardless whether configuration is present.
2009-01-25 16:04:03 +01:00
Max Kellermann 5f77910097 conf: const pointers in block get functions
All config_get_block_*() functions should accept constant config_param
pointers.
2009-01-25 16:03:49 +01:00
Max Kellermann 80799fa84e use config_get_string() instead of config_get_param()
config_get_string() is easier to use than config_get_param() because
it unpacks the config_param struct.
2009-01-25 16:00:51 +01:00
Max Kellermann bdfb6c239a playlist: moved is_valid_playlist_name() to stored_playlist.c 2009-01-25 14:19:28 +01:00
Max Kellermann 98cb8f3969 playlist: moved savePlaylist() and loadPlaylsit() to playlist_save.c 2009-01-25 14:11:47 +01:00
Max Kellermann 69c74afa25 playlist: removed g_rand, PLAYLIST_HASH_MULT
Both are unused.
2009-01-25 14:01:27 +01:00
Max Kellermann 688880bc0b queue: added queue_shuffle_order_last()
This function shuffles the last song of a range.  This is used by
addSongToPlaylist().
2009-01-25 14:00:51 +01:00
Max Kellermann 1a59afa388 stored_playlist: moved configuration variables from playlist.c
Don't declare and export variables specific to stored playlists in
playlist.c/playlist.h.
2009-01-25 13:53:16 +01:00
Max Kellermann 85f7e964de player_thread: start decoder thread in player thread
Start the decoder thread when the player thread starts.  The decoder
thread is already stopped by the player thread.
2009-01-25 13:44:39 +01:00
Max Kellermann d628eb3e8b player_control: added player_control.thread
player_control.thread contains the handle of the player thread, or
NULL if the player thread isn't running.
2009-01-25 13:44:33 +01:00
Max Kellermann ac0e799965 decoder_control: added decoder_control.thread
decoder_control.thread contains the handle of the decoder thread, or
NULL if the decoder thread isn't running.
2009-01-25 13:44:27 +01:00
Max Kellermann 2c45224be7 mapper: added dot to PLAYLIST_FILE_SUFFIX
Some code will be a little bit simpler if the dot is part of the
string literal.
2009-01-25 13:43:57 +01:00
Max Kellermann 7cc15ffc08 alsa: added comments
Document alsa_data members.
2009-01-25 13:13:24 +01:00
Max Kellermann fb3e43ed73 alsa: frame_size is size_t, not int
frame_size is a memory size and should be a size_t, not a signed integer.
2009-01-25 13:07:06 +01:00
Max Kellermann d887b6353f alsa: no CamelCase
Renamed types, functions, variables.
2009-01-25 13:05:16 +01:00
Dan McGee 27baf6913e alsa: fix option parsing and restore default period_time
Two bugs here led to a large number of interrupts being generated on the
sound card when ALSA output is being used. Because we specify no default
period_time, the sound card gives us 3000 interrupts/sec rather than a more
sane 20 or 30. This completes the revert of dd7711 already started by
4ca24f.

The larger bug was in the change to config_get_block_unsigned() and using 0
as the default value for both 'buffer_time' and 'period_time'. This means
any pre-setting of these options in newAlsaData() gets wiped out. Add a new
default for period_time, and ensure default values for buffer_time and
period_time are used if none are provided by the user.

Signed-off-by: Dan McGee <dan@archlinux.org>
[mk: set defaults in newAlsaData() to fix auto-configuration; renamed
"_MS" back to "_US" because ALSA expects microseconds, not milliseconds]
Signed-off-by: Max Kellermann <max@duempel.org>
2009-01-25 12:52:37 +01:00
Qball Cow 16796b1209 Fix tag not being set when casefolding the locate_item_list 2009-01-25 12:20:47 +01:00
Max Kellermann 2bfe6f6412 renamed the "mod" decoder plugin to "mikmod"
We have two mod plugins now: modplug and mod.  Rename the latter to a
more useful name.
2009-01-24 20:18:44 +01:00
Max Kellermann 5795be1f8d tag_id3: added MusicBrainz tag support
Added support for the MusicBrainz TXXX tags, documented on:

  http://musicbrainz.org/doc/MusicBrainzTag
2009-01-24 20:07:23 +01:00
Max Kellermann b4d90cc28c tag_id3: always allocate tag object
Save some code: always allocate the tag object, and free it when it
turns out to be empty.
2009-01-24 20:02:59 +01:00
Max Kellermann 30e2880675 tag: added support for MusicBrainz tags
Added all important id tags from the MusicBrainz wiki:

 http://musicbrainz.org/doc/MusicBrainzTag

This should automatically enable its suport in the vorbis and flac
decoder plugins.
2009-01-24 20:02:55 +01:00
Max Kellermann 0dc1b4a44e modplug: removed EOF check from the while loop
EOF is checked by input_stream_read() (decoder_read() here).  Don't do
it twice.  The check was wrong anyway, it was reversed.
2009-01-24 20:02:06 +01:00
Max Kellermann 793934cf9c modplug: check for input_stream errors
When input_stream_read() returns 0, and input_stream_eof() returns
false, an I/O error has occured.  Skip this song.
2009-01-24 19:16:33 +01:00