aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/audiofile_plugin.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* audio_format: changed "bits" to "enum sample_format"Max Kellermann2009-12-021-3/+23
| | | | | | This patch prepares support for floating point samples (and probably other formats). It changes the meaning of the "bits" attribute from a bit count to a symbolic value.
* decoder/audio: eliminate the "bits" variableMax Kellermann2009-11-141-4/+1
| | | | | Pass the audiofile_setup_sample_format() result to audio_format_init_checked().
* decoder/audiofile: moved code to audiofile_setup_sample_format()Max Kellermann2009-11-141-10/+20
|
* decoder: use audio_format_init_checked()Max Kellermann2009-11-141-7/+9
| | | | | | Let the audio_check library verify the audio format in all (relevant, i.e. non-hardcoded) plugins.
* include config.h in all sourcesMax Kellermann2009-11-121-1/+2
| | | | | | After we've been hit by Large File Support problems several times in the past week (which only occur on 32 bit platforms, which I don't have), this is yet another attempt to fix the issue.
* Add audio_format_init() functionDavid Woodhouse2009-07-191-5/+3
| | | | | It makes no difference right now, but we're about to add an endianness flag and will want to make sure it's correctly initialised every time.
* decoder: Rename all main decoder plugins functions to *decoder_plugin.Avuton Olrich2009-04-021-1/+1
|
* all: Update copyright header.Avuton Olrich2009-03-131-9/+8
| | | | | | | | This updates the copyright header to all be the same, which is pretty much an update of where to mail request for a copy of the GPL and the years of the MPD project. This also puts all committers under 'The Music Player Project' umbrella. These entries should go individually in the AUTHORS file, for consistancy.
* audiofile: added 24 bit supportMax Kellermann2009-03-011-1/+8
| | | | | Don't hard code the "bits" parameter to 16. Try to use the input's sample format, if possible.
* audiofile: removed duplicate decoder_get_command() callsMax Kellermann2009-02-281-12/+16
| | | | | decoder_data() returns a decoder_command, no need to call decoder_get_command() twice after decoder_command().
* audiofile: refuse to play non-seekable filesMax Kellermann2009-02-281-0/+5
| | | | | | | | | If an input_stream is not seekable, libaudiofile fails to play at all: Audio File Library: unrecognized audio file format [error 0] Since we know in advance whether the input_stream is seekable, just refuse to play on a non-seekable stream.
* audiofile: no CamelCaseMax Kellermann2009-02-281-9/+9
| | | | Renamed several variables and a function.
* audiofile: don't close onput stream in libaudiofile destroy()Max Kellermann2008-12-271-2/+3
| | | | | | The input_stream object should only be closed by the MPD core (i.e. decoder_thread.c / decoder_run()). A decoder plugin which attempts to close it will result in a segmentation fault.
* decoder: audiofile plugin using input stream instead of fileViliam Mateicka2008-12-031-15/+74
|
* decoder: check audio_format_valid() in all decodersMax Kellermann2008-11-211-7/+8
| | | | Refuse to play audio formats which are not supported by MPD.
* audiofile: use GLib instead of log.hMax Kellermann2008-11-211-8/+10
|
* audiofile: fixed misplaced ifViliam Mateicka2008-11-181-2/+1
| | | | [mk: by definition, tag_new() cannot fail - removed check]
* decoder: return void from decode() methodsMax Kellermann2008-11-111-5/+4
| | | | | | | | The stream_decode() and file_decode() methods returned a boolean, indicating whether they were able to decode the song. This is redundant, since we already know that: if decoder_initialized() has been called (and dc.state==DECODE), the plugin succeeded. Change both methods to return void.
* decoder: removed stream_typesMax Kellermann2008-11-041-1/+0
| | | | | Instead of checking the stream_types bit set, we can simply check whether the methods stream_decode() and file_decode() are implemented.
* decoder_api: pass "seekable" flag to decoder_initialized()Max Kellermann2008-11-021-2/+2
| | | | | | Don't pass the "seekable" flag with every decoder_data() invocation. Since that flag won't change within the file, it is enough to pass it to decoder_initialized() once per file.
* decoder: make the suffixes and mime_types arrays really constMax Kellermann2008-11-011-1/+3
| | | | | The strings were constant, but the pointers weren't. C syntax is somewhat tricky..
* decoder: make all decoder_plugin structs constMax Kellermann2008-11-011-1/+1
| | | | | All decoder_plugin structs are initialized at compile time, and must never change.
* decoder_api: pass constant path pointersMax Kellermann2008-10-311-3/+3
|
* decoder: use bool for return values and flagsMax Kellermann2008-10-301-5/+6
| | | | | Don't return 0/-1 on success/error, but true/false. Instead of int, use bool for storing flags.
* decoder: automatically flush the output buffer after decoder exitsMax Kellermann2008-10-291-3/+0
| | | | | | | A decoder_flush() invocation was missing in the FLAC plugin, resulting in casual assertion failures due to a wrong assumption about the last chunk's audio format. It's much easier to remove that decoder_flush() function and make the decoder thread call ob_flush().
* decoder_api: removed decoder_clear()Max Kellermann2008-10-291-1/+0
| | | | | Call ob_clear() in decoder_command_finished() instead of implementing that call in every decoder plugin.
* renamed src/inputPlugins/ to src/decoder/Max Kellermann2008-10-261-0/+147
These plugins are not input plugins, they are decoder plugins. No CamelCase in the directory name.