Commit Graph

4408 Commits

Author SHA1 Message Date
Jochen Keil
4bfbdfe5c5 Tag subtracks according to "cuesheet" vorbis comment value
Cuesheets are often saved as vorbis comment
flac files (CUESHEET=.. case doesn't matter).
We can parse this now and use the information to
tag the subtracks (from the embedded cuesheets).
2009-03-31 22:17:56 +02:00
Jochen Keil
d7b0c768b0 track length is computed correctly now 2009-03-31 22:17:56 +02:00
Jochen Keil
6720a0a940 free previously allocated flac metadata object 2009-03-31 22:17:56 +02:00
Jochen Keil
a1bde6b99d remove old commented code 2009-03-31 22:17:56 +02:00
Jochen Keil
192e29107d Configure/Make dependencies for cue/cue_tag.h/.c
Autoconf/automake support for libcue which
is needed for cue/cue_tag.h/.c.
Libcue will have/has pkg-config support
so this is fairly straightforward.
2009-03-31 22:17:56 +02:00
Jochen Keil
d41e7f7cec Build tags from information in cue sheets
With these methods a tag struct can be created
from the cdtext information in a cue sheet.
The methods depend on a cue parsing library.
Reading from strings (char*) as well as from
a file (FILE*) is supported.
2009-03-31 22:17:56 +02:00
Romain Bignon
62a72a5e4d do not consider single mode with "next" command
This is a little ugly, but as nextSongInPlaylist is both called when
queued is update (in case playlist ended) and for user "next" command,
there isn't any other (simple) solution
2009-03-31 14:15:33 +02:00
Avuton Olrich
1f4f6e6df2 exconf: Fix spacing 2009-03-30 19:21:42 +02:00
Avuton Olrich
98e81287e3 client: group static function declarations together. 2009-03-30 19:21:42 +02:00
Avuton Olrich
ee7369a8f1 queue_print: queue_print_song_info() is not necessry for export. 2009-03-30 19:21:41 +02:00
Avuton Olrich
68a4bb90da queue: queue_generate_id() is not necessary for export. 2009-03-30 19:21:41 +02:00
Avuton Olrich
ed96db3fae player_control: remove unused function playerCurrentDecodeSong(). 2009-03-30 19:21:41 +02:00
Avuton Olrich
6405db931b conf: config_param_free() not necessary for export. 2009-03-30 19:21:41 +02:00
Avuton Olrich
96ab110b44 command: command_error() is not necessary for export. 2009-03-30 19:21:41 +02:00
Avuton Olrich
215cdda08d client: client_write() does not necessary for export. 2009-03-30 19:21:41 +02:00
Romain Bignon
e81f683a18 implemented the 'consume' mode
Consume mode removes each song played
2009-03-30 17:37:55 +02:00
Max Kellermann
7d9380fd91 configure.ac: fix error on disabled features
In the MPD_AUTO_DISABLED() function, I forgot to check for "explicitly
disabled".
2009-03-29 21:44:55 +02:00
Avuton Olrich
bfc25cfd3b exconf: update mixer documentation. 2009-03-29 21:40:08 +02:00
Avuton Olrich
12b6ca8832 exconf: The usual defaults updates.
Ths usual defaults updates, this includes clarifications, cleanups, updates
and fixes.
2009-03-29 21:40:08 +02:00
Avuton Olrich
b964480767 exconf: Comment formerly required files. 2009-03-29 21:40:08 +02:00
Avuton Olrich
3836dcf59b exconf: Merge required files with optional. 2009-03-29 21:40:01 +02:00
Max Kellermann
cd2d47b01c configure.ac: use more MPD_AUTO_PKG() 2009-03-28 21:48:09 +01:00
Max Kellermann
87e0b1adc4 configure.ac: added M4 function MPD_AUTO_PKG() for ALSA
MPD_AUTO_PKG() runs pkg-config and then forwards control to
MPD_AUTO_RESULT().  This is a commonly used short cut.
2009-03-28 21:48:07 +01:00
Max Kellermann
33aeac4fcb Makefile.am: use PULSE_CFLAGS and PULSE_LIBS
Don't add those to MPD_CFLAGS and MPD_LIBS.
2009-03-28 21:39:26 +01:00
Max Kellermann
5164cc1ff8 Makefile.am: use JACK_CFLAGS and JACK_LIBS
Don't add those to MPD_CFLAGS and MPD_LIBS.
2009-03-28 21:38:53 +01:00
Max Kellermann
50c53e4b24 Makefile.am: use SAMPLERATE_CFLAGS and SAMPLERATE_LIBS
Don't add those to MPD_CFLAGS and MPD_LIBS.
2009-03-28 21:38:44 +01:00
Max Kellermann
de7c16d1be configure.ac: removed debug line 2009-03-28 11:12:09 +01:00
Max Kellermann
53ed647b22 configure.ac: fail when ALSA is enabled but not found
This patch adds a small autoconf M4 library which deals with
auto-detected features.  The default for those features is "auto",
which is like the old default: if the library is present on the
system, enable the feature, disable otherwise.  If the user explicitly
enables that feature (--enable-alsa), and the library is not present,
configure must fail, because it cannot fulfill the request.
2009-03-28 11:10:40 +01:00
Jochen Keil
80e2aaf379 Bugfix for time/offset in flac plugin
Previous cast to float didn't have any effect because one value is uint
and the other is a floating type but the number itself is even..
This caused some tracks to end before they were really at an end.
2009-03-28 10:13:44 +01:00
Max Kellermann
43864762ee mixer: assert that the new volume value is valid
Added an assertion in mixer_set_volume().  Removed the range checks
from the ALSA and OSS plugins.
2009-03-27 20:10:39 +01:00
Max Kellermann
49e548e773 mpcdec: changed plugin name to "mpcdec"
The "mpcdec" plugin is based on the libmpcdec library.
2009-03-27 19:58:50 +01:00
Max Kellermann
f5548a8654 mpcdec: support the new libmpcdec SV8 API 2009-03-27 19:51:59 +01:00
Max Kellermann
0e18fab655 mpcdec: no CamelCase
Renamed variables and functions.
2009-03-27 19:37:08 +01:00
Max Kellermann
86827fc63e tag_pool: use memcmp() instead of strcmp() for non-terminated string
The strings passed to tag_pool_get_item() are not null-terminated, and
the caller passes the string length.  Don't assume it is
null-terminated anyway by using strcmp().
2009-03-27 19:36:24 +01:00
Max Kellermann
51894725ec tag_pool: use size_t for string length 2009-03-27 19:36:03 +01:00
Max Kellermann
8fa44d53ab configure.ac: require GLib 2.6
We're using GLib macros which were introduced in GLib 2.6, like
G_GNUC_MALLOC.  Let's just drop support for GLib versions older than
2.6 instead of adding more complicated compatibility hacks.
2009-03-27 18:04:34 +01:00
Sean McNamara
94479ca40f event_pipe can only be non-blocking if !WIN32 2009-03-27 18:03:46 +01:00
Sean McNamara
f5ff243a8b More debugging for Win32 ioctlsocket: complain if it's not a Winsock
socket, because there is no ioctl for non-sockets on Windows
2009-03-27 18:03:10 +01:00
Sean McNamara
37531f6f1e Add winsock2 headers for curl's use of select() on sockets 2009-03-27 18:03:03 +01:00
Sean McNamara
b1e0bde529 Uniform getaddrinfo() on WIN32 or POSIX, because MinGW now supports it 2009-03-27 18:02:56 +01:00
Sean McNamara
9c63ffa546 Winsock2 is needed on MinGW (or other pure Win32 toolchains) for
networking, select(), ntohl(), etc.
2009-03-27 18:02:31 +01:00
Max Kellermann
b91517e761 sticker: move SQLite statements into an array
Simplify initialization and finalization.
2009-03-27 17:05:04 +01:00
Max Kellermann
7d3921bb88 pulse_mixer: protect the struct with a mutex
There are numerous race conditions between the libpulse thread
(pulse_mixer.c callbacks) and the rest of MPD.  Protect the volatile
attributes of the pulse_mixer struct with a mutex to fix that.
2009-03-27 16:55:17 +01:00
Max Kellermann
7f762a5cec pulse_mixer: return if mixer is offline
Eliminate one indent level.  Also remove several debug useless debug
messages.
2009-03-27 16:44:37 +01:00
Max Kellermann
13319e0b70 pulse_mixer: removed superfluous G_GNUC_UNUSED attributes
Those parameters are used after all.
2009-03-27 16:44:36 +01:00
Max Kellermann
d448392f25 pulse_mixer: use local pa_cvolume variable for set_volume()
Don't mess with pulse_mixer.volume for setting the volume.  This
variable should only be used to transfer the current volume from
sink_input_vol() to pulse_mixer_get_volume().
2009-03-27 16:44:36 +01:00
Max Kellermann
8258457b43 pulse_mixer: wait for get_volume() operation to complete
The pa_context_get_sink_input_info() function is asynchronous, and
after it returns, libpulse does not guarantee that the operation has
completed yet; in fact, it is not likely.  Explicitly wait for the
operation to complete.

The code for the new pulse_wait_for_operation() function was inspired
by mplayer and xine code.
2009-03-27 16:44:36 +01:00
Max Kellermann
1a411b1ced mixer_control: don't lock the mutex twice in mixer_failed()
The function mixer_failed() expects the mixer mutex to be already
locked, yet it calls mixer_close(), which attempts to lock the mutex
again, deadlocking itself.
2009-03-27 16:44:31 +01:00
Romain Bignon
e7519829ac renamed smartstop to single and changed behavior
When single mode is enabled, after current song it stops playback,
or it replay same song if repeat mode is activated.
2009-03-27 15:28:49 +01:00
Romain Bignon
e46722b2eb implements the smartstop feature
The smartstop feature is a way to tell mpd to stop playing after
current song.
This patche provides:
- 'state' command returns 'smartstop' state (1 or 0)
- 'smartstop' can activate or not the smartstop state
- when song is terminated, mpd stops playing and smartstop is set to 0
2009-03-27 14:58:31 +01:00