aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* decoder: fixed assertion failure for decoder==NULL in decoder_read()Max Kellermann2008-11-111-1/+2
| | | | | | The assertion on dc.state in decoder_read() was too strict: when a decoder tried to call decoder_read() from tag_dup(), the decoder state was NONE. Allow this special case.
* decoder: removed plugin method try_decode()Max Kellermann2008-11-105-51/+14
| | | | | | Instead of having a seprate try_decode() method, let the stream_decode() and file_decode() methods decide whether they are able to decode the song.
* decoder: fall back to next pluginMax Kellermann2008-11-101-4/+16
| | | | When a plugin is unable to decode a song, try the other plugins.
* decoder: wrapper functions for methods stream_decode() and file_decode()Max Kellermann2008-11-101-5/+66
| | | | Added lots of assertions to the wrapper functions.
* decoder: added more assertionsMax Kellermann2008-11-101-0/+10
| | | | Added a lot of assertions checking the state of the decoder plugin.
* flac: call flac_process_metadata() for ogg filesMax Kellermann2008-11-101-4/+5
| | | | | | | The flac plugin wasn't initialized properly when an OGG file was being decoded. For some reason, flac_process_metadata() was explicitly not called for OGG files. Since that seems to fix the issue, make it always call flac_process_metadata().
* flac: enable the oggflac plugin with older libflac versionsMax Kellermann2008-11-101-3/+14
| | | | | | | | | Since decoder_list.c does not include the libflac headers, it cannot know whether to add the oggflac plugin to the decoder list. Solve this by always enabling the oggflac sub-plugin, even with older libflac versions. When the libflac API cannot support oggflac, disable the plugin at runtime by returning "false" from its init() method.
* flac: enable oggflac with libflacMax Kellermann2008-11-101-1/+1
| | | | | | | The "oggflac" plugin was enabled only if HAVE_FLAC_COMMON was defined. HAVE_FLAC_COMMON however is only an automake variable, and is never available in decoder_list.c. Make decoder_list.c depend on HAVE_FLAC||HAVE_OGGFLAC instead.
* log: properly check log_thresholdDaniel Schömer2008-11-091-1/+1
|
* decoder: updated API documentationMax Kellermann2008-11-091-2/+6
| | | | | Updated documentation on the stream_decode() and file_decode() return values.
* wavpack: removed try_decode() methodMax Kellermann2008-11-091-23/+0
| | | | | | Wavpack's try_decode() implementation does nothing useful, it only duplicates code already in stream_decode() / file_decode(), and slows down MPD.
* flac: make the init() method check for oggflac supportMax Kellermann2008-11-091-2/+8
| | | | | Disable flac's "oggflac" sub-plugin when libflac does not support ogg-flac files.
* decoder: converted dc.error to a dc.state valueMax Kellermann2008-11-084-30/+44
| | | | | | The player did not care about the exact error value, it only checked whether an error has occured. This could fit well into decoder_control.state - introduce a new state "DECODE_STATE_ERROR".
* decoder: removed "plugin" from the decoder structMax Kellermann2008-11-082-6/+0
| | | | decoder.plugin was a write-only attribute.
* wavpack: make 24-bit samples available for mpdLaszlo Ashin2008-11-081-47/+46
| | | | | | | | | This patch makes 24-bit samples available for mpd. I tested with the WavPack Test Suite found on wavpack.com: http://www.rarewares.org/wavpack/test_suite.zip Every test file worked fine.
* wavpack: check last_byte in push_back_byte() methodLaszlo Ashin2008-11-081-2/+6
| | | | | | | | | At this moment the wavpack lib doesn't use the return value of the push_back function, which has an equivalent meaning of the return value of ungetc(). This is a lucky situation, because so far it simply returned with 1 as a hard coded value. From now on the function will return EOF on error. (This function makes exactly one byte pushable back.)
* wavpack: wrapper for converting void* to struct wavpack_input*Laszlo Ashin2008-11-081-13/+20
| | | | | A new function has been added to do a cast and a little check in the wavpack-mpd input stream wrapper.
* wavpack: put braces around one line code blocksLaszlo Ashin2008-11-081-15/+27
| | | | | I think this makes the code more easily modifiable and prevents some annoying mistakes.
* wavpack: added prefix to local function namesLaszlo Ashin2008-11-081-14/+14
| | | | | | There are some functions in the wavpack-mpd input streams wrapper which had too commonly used names (especially can_seek). I prefixed these with "wavpack_input_".
* wavpack: unified code styleLaszlo Ashin2008-11-081-16/+28
| | | | | Not every function header has its return type in a distinct line. This patch corrects that. This way there is more space for the arguments.
* configure.ac: enable _ogg_common.c when flac is enabledMax Kellermann2008-11-071-1/+1
| | | | | | The build failed when the oggvorbis and oggflac decoders were disabled, because the flac decoder references a symbol from _ogg_common.c.
* configure.ac: added AC_CONFIG_SRCDIRMax Kellermann2008-11-071-4/+2
|
* listen: fix namespace collision on OpenSolarisTom Servo2008-11-071-6/+6
| | | | | | | | | The listen.c module breaks the build because the variable name used ("sun") for the Unix domain socket part collides with something else on an OpenSolaris system, likely Sun specific. Renaming it to _sun (or something else of choice) fixes the build. [mk: renamed to "s_un"]
* wavpack: check wvc seekabilityLaszlo Ashin2008-11-061-2/+5
| | | | | Using wvc streams the seekableness depends on the seekability of the wvc stream as well.
* wavpack: close wvc stream on errorLaszlo Ashin2008-11-061-1/+3
| | | | | The input stream opened for wvc is not closed in an if branch. A close call has been added.
* wavpack: enable seekingLaszlo Ashin2008-11-061-1/+1
| | | | | Somehow seeking is disabled on all kinds of wavpack playbacks now in the git version. This patch corrects that.
* input_curl: retrieve error message from ERRORBUFFERMax Kellermann2008-11-061-2/+5
| | | | | libcurl provides better error messages than curl_multi_strerror() when you set the ERRORBUFFER option.
* input_curl: return 0 on error from read()Max Kellermann2008-11-061-1/+2
| | | | | | The read() method must not return a negative value. Make it return 0 on error, just like the file input stream. Also set the "error" attribute to -1.
* input_curl: enable FAILONERRORMax Kellermann2008-11-061-0/+1
| | | | | | | I had this option enabled during development, but at some point, it must have gotten lost. FAILONERROR makes the curl stream fail when the server returns a status code 400 or higher. We are not interested in the server's error document.
* MPD version 0.14~alpha1release-0.14_alpha1Max Kellermann2008-11-051-1/+1
| | | | First alpha version for the upcoming version 0.14.
* path: removed superfluous error check in path_set_fs_charset()Max Kellermann2008-11-051-8/+0
| | | | The code which had a possible error condition had been removed.
* log: check if log_charset is setMax Kellermann2008-11-051-5/+8
| | | | | When logging to a file, log_charset would be NULL and g_convert() would abort.
* NEWS: updated 0.14 changelogMax Kellermann2008-11-051-0/+12
| | | | Adding some of the most important changes since 0.13.
* NEWS: reformatted 0.14 itemsMax Kellermann2008-11-051-8/+9
| | | | Trying to bring a little bit of structure into that list.
* README: added version number to GPLMax Kellermann2008-11-051-1/+1
| | | | | MPD is licensed under the version 2 of the GNU General Public License version 2. Also added "General".
* README: removed mp4ffMax Kellermann2008-11-051-6/+0
| | | | MPD doesn't include the mp4ff library anymore.
* UPGRADING: added a 0.14 sectionMax Kellermann2008-11-051-0/+8
|
* INSTALL: update dependency listMax Kellermann2008-11-051-0/+17
| | | | | Documented dependencies on gcc/C99, glib, libvorbisenc, liblame, ffmpeg.
* Makefile.am: distribute input_curl.hMax Kellermann2008-11-051-0/+1
| | | | | input_curl.h was missing in the tarball because it was not listed in $(mpd_headers).
* main: print usage to stdoutMax Kellermann2008-11-051-26/+25
| | | | Using the logging library here is inappropriate.
* log: convert messages to system charsetMax Kellermann2008-11-051-0/+14
| | | | | When logging to the terminal, we should print messages in the system character set. Convert all messages in this case.
* log: use boolMax Kellermann2008-11-052-8/+10
| | | | Use the bool data type for flags.
* log: provide a GLib logging handlerMax Kellermann2008-11-051-0/+15
| | | | | Install a default handler which writes to stdout or stderr, and prepends a time stamp. This looks just like the 0.13.x logger.
* log: use GLib message loggingMax Kellermann2008-11-052-24/+15
| | | | | | The logging functions from log.h are deprecated, and the code should use GLib logging instead. Make ERROR(), WARNING() etc. call g_logv() internally.
* log: no CamelCaseMax Kellermann2008-11-051-6/+8
| | | | Renamed the variable "logLevel" to "log_threshold".
* log: removed warning bufferMax Kellermann2008-11-053-79/+2
| | | | | The warning buffer is a complex piece of code for no good reason. Remove it and find a better solution, e.g. open the log file earlier.
* main: initialize locale (LC_CTYPE)Max Kellermann2008-11-051-0/+9
| | | | | | Initialize libc's locale functions. Currently, we are only interested in LC_CTYPE (character classification), because this is what is used by GLib's g_get_charset().
* path: don't allocate charset twiceMax Kellermann2008-11-051-5/+3
| | | | | Make the local variable "charset" const, and don't duplicate its value. It is already duplicated by path_set_fs_charset().
* path: get filesystem charset from GLibMax Kellermann2008-11-051-39/+6
| | | | | | GLib provides the function g_get_filename_charsets() which determines the file system character set. This changes MPD's fallback: GLib prefers UTF-8 as a fallback. MPD used to fall back to ISO Latin 1.
* path: no CamelCaseMax Kellermann2008-11-054-30/+27
| | | | Rename variables and functions.