Jonathan Neuschäfer
8b6b25220d
decoder/ffmpeg: add webm as a supported format
2012-05-29 22:38:40 +02:00
Jurgen Kramer
3c3f1b7ff2
Add support for DSF files to DSDIFF decoder - v4
...
Version 4 of my patch to add DSF support to the DSDIFF
decoder plugin.
This time I have taken a different approach and created a new
read_metadata function specific for reading DSF files. This saves an
indent (and for me a lot of indent nightmares) and also useful for
splitting the DSF and DFF decoders later on.
There are still a few lines which exceed the 80 character width limit by
a few chars. I was not able to stay within the limit and create (for me)
readable code.
Jurgen
2012-05-02 08:47:02 +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
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
7ebf8e66c9
decoder/pcm: always supply host byte order samples
...
Don't use audio_format.reverse_endian.
2012-03-21 19:10:57 +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
238c3adad1
decoder/dsdiff: reverse bits to most significant bit first
...
Allow to remove this complexity from the MPD core.
2012-03-21 09:01:56 +01:00
Max Kellermann
08ce24ec3f
audio_format: basic support for DSD-over-USB
2012-03-19 23:49:29 +01:00
Jonathan Neuschäfer
b9e64d0472
decoder/audiofile: fix compiler warnings with libaudiofile 0.3.3
...
This might break older versions, I didn't test.
2012-03-19 23:21:12 +01:00
Max Kellermann
9c36e71081
decoder/dsdiff: don't convert to PCM
...
Move the responsibility for the conversion to the PCM library. This
will allow passing the verbatim DSD samples to an output plugin.
2012-03-01 02:05:40 +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
Jonathan Neuschäfer
00a20fc8a5
decoder/ffmpeg: always use AV_VERSION_INT
2012-02-15 21:42:52 +01:00
Max Kellermann
645663cdfe
Merge branch 'af' of git://git.musicpd.org/jn/mpd
2012-02-15 21:06:53 +01:00
Jonathan Neuschäfer
ee2bcbb41d
decoder/audiofile: fix compiler warnings with libaudiofile 0.3.3
...
This might break older versions, I didn't test.
2012-02-15 20:52:48 +01:00
Jonathan Neuschäfer
e77d96cf89
decoder/sidplay: remove unused variable 'ret'
2012-02-15 20:35:05 +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
103832742d
decoder/ffmpeg: read the "year" tag
...
This was disabled when compiled with a new ffmpeg version. Older
ffmpeg versions used it explicitly, while newer ones may pass it
through from the codec.
2012-02-13 19:05:39 +01:00
Max Kellermann
8a3192ffc1
decoder/wavpack: bigger tag value buffer
...
Prepare for big CUESHEET tags.
2012-02-12 16:10:20 +01:00
Max Kellermann
ffea273a28
tag_handler: handle arbitrary name/value pairs
...
The new method pair() receives an arbitrary name/value pair. Support
for this is being added to a few decoder plugins.
2012-02-12 13:41:48 +01:00
Max Kellermann
1783aac438
decoder/wavpack: move code to wavpack_scan_tag_item()
...
Remove clutter from wavpack_scan_file(), and use a (large) fixed
buffer for the tag item.
2012-02-11 19:36:59 +01:00
Max Kellermann
29bf3d2c04
decoder/wavpack: use the tag_table library
2012-02-11 19:34:10 +01:00
Max Kellermann
ee16fc958c
decoder/{mikmod,fluidsynth,mp4ff}: adapt to tag_handler API
...
Fixes build regression.
2012-02-11 19:28:56 +01:00
Max Kellermann
5d73215a8d
decoder_plugin: scan tags with callback table
...
Pass a callback table to scan_file() and scan_stream(), instead of
returning a tag object.
2012-02-11 17:04:29 +01:00
Max Kellermann
b7356bc526
decoder/gme: convert runtime check to assertion
...
When gme_track_info() returns with success, then the gme_info_t
pointer must be set.
2012-02-11 16:59:24 +01:00
Max Kellermann
8ec8282f38
decoder/ffmpeg: use the tag_table library
2012-02-11 16:39:03 +01:00
Max Kellermann
43b7b98949
decoder/ffmpeg: move code to ffmpeg_metadata.c
2012-02-11 16:37:29 +01:00
Max Kellermann
f791065a98
decoder/ffmpeg: remove AV_VERSION_INT definition
...
All supported ffmpeg/libav versions have this.
2012-02-11 16:37:25 +01:00
Max Kellermann
d95db28695
decoder/flac: check for errors only after _process_single()
...
The only other libFLAC call (seek) does not produce fatal errors.
2012-02-11 12:57:18 +01:00
Max Kellermann
851fb16e7c
decoder/flac: symmetric FLAC__stream_decoder_finish() calls
...
Call it in the function that also invokved
FLAC__stream_decoder_init_*().
2012-02-11 12:56:52 +01:00
Max Kellermann
a4cbaafd10
decoder/flac: use error messages from libFLAC
2012-02-11 12:37:24 +01:00
Max Kellermann
c5f2cdb822
decoder/flac: eliminate the remaining "gotos"
...
https://www.xkcd.com/292/
2012-02-11 12:37:24 +01:00
Max Kellermann
1892d29be0
decoder/{vorbis,flac}: use the tag_table library
2012-02-11 12:37:24 +01:00
Max Kellermann
767ade02f4
tag_table: convert to a struct
...
The struct is smaller because it is sparse. Its traversal is also
more efficient.
2012-02-11 12:37:24 +01:00
Max Kellermann
c8a990b9d3
decoder/vorbis: move code to vorbis_comment.c
2012-02-11 10:04:02 +01:00
Max Kellermann
c46239af22
Merge branch 'v0.16.x'
...
Conflicts:
src/decoder/ffmpeg_decoder_plugin.c
test/read_tags.c
test/run_decoder.c
2012-02-04 17:23:53 +01:00
Max Kellermann
5d9876e338
decoder/ffmpeg: use AV_SAMPLE_FMT_* if available
...
Implements support for libavcodec 0.9, which removes the compatibility
macros SAMPLE_FMT_*
2012-02-03 09:55:25 +01:00
Max Kellermann
083340a937
decoder/ffmpeg: use sentinel for the ffmpeg_tag_maps table
...
Minor optimisation.
2012-02-03 09:18:05 +01:00
Max Kellermann
378fa5ee6a
decoder/ffmpeg: support all MPD tags
...
Use the tag_item_names table to look up the names of all MPD tags, and
remove the duplicate entries from ffmpeg_tag_maps.
2012-02-03 09:10:48 +01:00
Max Kellermann
4764daf3c2
decoder/ffmpeg: pass tag_type and name to _copy_metadata()
...
Allow using this function without the ffmpeg_tag_map struct.
2012-02-03 09:09:18 +01:00
Max Kellermann
6357496d17
decoder/ffmpeg: merge code to _copy_dictionary()
...
Eliminate some duplicate code.
2012-02-03 09:09:18 +01:00
Max Kellermann
001e2a604b
decoder/ffmpeg: add macros emulating AVDictionary
...
Move the #ifdefs out of _copy_metadata().
2012-02-03 09:02:14 +01:00
Max Kellermann
f370911c15
decoder/ffmpeg: _copy_metadata() returns void
...
No interest in this return value.
2012-02-03 08:59:26 +01:00
Max Kellermann
c2fe961db1
decoder/ffmpeg: remove debug code
2012-01-24 17:15:29 +01:00
Max Kellermann
ec43721c3c
Merge branch 'v0.16.x'
...
Conflicts:
src/decoder/ffmpeg_decoder_plugin.c
2012-01-12 18:59:21 +01:00
Max Kellermann
39d52762d1
decoder/ffmpeg: check libavutil version for AVDictionaryEntry
...
Require libavutil 51.5.0.
2012-01-12 18:45:18 +01:00
Max Kellermann
8d45d0d104
decoder/ffmpeg: raise version dependency for avformat_find_stream_info()
...
This function was added when the libavformat version was 53.2.0, but
the actual release 53.2.0 did not have it.
2012-01-12 18:28:19 +01:00
Max Kellermann
9937ff8ac0
Merge branch 'v0.16.x'
...
Conflicts:
src/decoder/ffmpeg_decoder_plugin.c
src/input/ffmpeg_input_plugin.c
2012-01-05 00:33:23 +01:00
Max Kellermann
abd1949825
decoder/ffmpeg: support libavformat 0.8
2012-01-05 00:17:56 +01:00
Max Kellermann
4e6bc77a70
decoder/ffmpeg: use avcodec_decode_audio4(), support libavcodec 0.8
2012-01-04 22:10:38 +01:00
Max Kellermann
531948358b
decoder/ffmpeg: include libavutil/mathematics.h
...
Needed for av_rescale_q() in ffmpeg 0.8.
2012-01-04 21:54:54 +01:00
Max Kellermann
21caca4aea
decoder/ffmpeg: use avcodec_open2() on newer ffmpeg versions
...
avcodec_open() has been deprecated.
2012-01-04 21:48:30 +01:00
Max Kellermann
fbf3edf07d
decoder/ffpmeg: don't use av_metadata_conv() in ffmpeg 0.7
...
It's a no-op and deprecated.
2012-01-04 21:47:56 +01:00
Max Kellermann
76fcf25898
decoder/ffmpeg: use AVIOContext instead of ByteIOContext
2012-01-04 21:47:47 +01:00
Max Kellermann
99949c8f6f
command: new command "seekcur"
...
For simpler seeking within current song.
2011-12-24 11:20:02 +01:00
Max Kellermann
aa4f45b9a5
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-12-13 21:57:44 +01:00
Max Kellermann
533e4fcdad
decoder/mp4ff: work around assertion failure in read() callback
...
This workaround leads to an infinite loop instead of an assertion
failure, but hey, now it's libmp4ff's fault.
2011-12-13 20:08:31 +01:00
Max Kellermann
4f093d5b97
Merge branch 'v0.16.x'
...
Conflicts:
Makefile.am
NEWS
configure.ac
src/encoder/flac_encoder.c
src/log.c
src/pcm_buffer.c
2011-11-28 11:56:01 +01:00
Max Kellermann
e1b032cbad
decoder/ffmpeg: work around bogus channel count
...
Initialize the audio_format before calling avcodec_open(), because
avcodec_open() will fill bogus values.
2011-11-28 11:39:21 +01:00
Max Kellermann
1e89ca0994
decoder/dsdiff: provide floating point samples
...
Eliminate the conversion to integer samples, the MPD core can do this
now.
2011-10-20 03:01:31 +02:00
Max Kellermann
92bb10eed8
decoder/wavpack: read float samples as-is, don't convert to integer
...
For MPD's new floating point support: when a decoded wavpack file
needs to be resampled, don't convert float to int and back to float.
2011-10-20 02:55:05 +02: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
4c9782ee28
decoder/pcm: support reverse byte order
2011-10-10 10:13:43 +02:00
Max Kellermann
f3ea834322
decoder/{pcm,dsdiff}: add missing stdio.h include
2011-10-09 17:40:37 +02:00
Max Kellermann
b9e99575ce
Merge commit 'release-0.16.5'
...
Conflicts:
NEWS
configure.ac
2011-10-09 16:32:36 +02:00
Max Kellermann
71536eb412
decoder/wavpack: don't call WavpackGetMode() twice
...
Use local variable "is_float".
2011-10-08 15:37:47 +02:00
Max Kellermann
894b9cfdb9
decoder/dsdiff: add option "lsbitfirst"
...
Defaults to "no", which fixes the noise problems.
2011-10-07 10:10:43 +02:00
Max Kellermann
7ecbb0454f
decoder/dsdiff: add documentation
2011-10-07 06:38:23 +02:00
Max Kellermann
4e909f9411
decoder/dsdiff: new decoder plugin
...
Doesn't seem to work yet, getting just noise from a test file.
Seeking isn't implemented yet.
2011-10-04 21:41:03 +02:00
Max Kellermann
47774ce882
Merge branch 'v0.16.x'
2011-09-17 19:59:52 +02:00
Tim Harder
79435dbdec
decoder/audiofile: include stdio header for SEEK_* defines
...
The stdio header is no longer pulled in by af_vfs.h in audiofile-0.3.0.
2011-09-17 07:33:42 +02:00
Max Kellermann
754f26a97c
input_stream: non-blocking I/O
...
Add GMutex, GCond attributes which will be used by callers to
conditionally wait on the stream.
Remove the (now-useless) plugin method buffer(), wait on GCond
instead. Lock the input_stream before each method call. Do the same
with the playlist plugins.
2011-09-16 21:22:13 +02:00
Max Kellermann
f804a739b1
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-09-15 21:48:33 +02:00
Max Kellermann
2ed870c854
decoder/ffmpeg: flush the codec after seeking
...
Let the codec start with fresh buffers. This should fix the remaining
seeking issues.
2011-09-15 21:41:25 +02:00
Max Kellermann
ce35ba9ac9
decoder/ffmpeg: explicitly specify the current stream for seeking
...
Use AVStream.time_base to convert the decoder_seek_where() value, and
pass the current stream number to av_seek_frame().
2011-09-15 21:35:29 +02:00
Max Kellermann
724a59aaf7
decoder/ffmpeg: don't require key frame for seeking
...
Use flag AV_TIME_BASE.
2011-09-15 21:32:29 +02:00
Max Kellermann
42d8c2981f
decoder/ffmpeg: higher precision timestamps
2011-09-15 21:30:27 +02:00
Max Kellermann
9aa91e0f17
decoder/ffmpeg: move formula to time_from_ffmpeg()
2011-09-15 21:23:48 +02:00
Max Kellermann
5aabee8996
decoder/ffmpeg: add local variable "av_stream"
...
Code simplification.
2011-09-15 21:14:53 +02:00
Max Kellermann
3d3bca5338
decoder/oggflac: delete this obsolete plugin
...
libOggFLAC has been deprecated for 5 years now, and we havn't been
testing it for a long time. Let's delete it.
2011-09-01 19:29:04 +02:00
Jonathan Neuschäfer
310895f060
rename 'Timer' to 'struct timer'
2011-08-27 11:30:34 +02:00
Max Kellermann
5ecb6fecc4
Merge branch 'v0.16.x'
2011-08-24 01:47:10 +02:00
Max Kellermann
d3b15f8fda
decoder/mpcdec: fix gcc warning
...
Move the variable "vbr_update_acc" into the #ifdef block.
2011-08-23 17:58:56 +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
2e28ed8f81
wavpack: obey all decoder commands, stop at CUE track border
...
It used to ignore the decoder_data() return value.
2011-07-20 12:54:30 +02:00
Max Kellermann
4c4f8bf02a
decoder/wavpack: use the correct integer types
...
libwavpack provides int32_t samples, and wants uin32_t for sample
counts.
2011-07-20 12:54:22 +02:00
Max Kellermann
e464be5f39
decoder/wavpack: simplify the WavpackUnpackSamples()==0 check
...
.. and remove one indent level.
2011-07-20 12:32:48 +02:00
Max Kellermann
eb2f413cf0
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-07-19 00:24:20 +02:00
Max Kellermann
736fd0e293
decoder/ffmpeg: use avformat_open_input() if available
...
av_open_input_stream() has been deprecated.
2011-07-18 23:31:47 +02:00
Max Kellermann
6592ca9f88
decoder: use AVDictionary instead of AVMetadata
...
AVMetadata has been deprecated.
2011-07-18 23:31:31 +02:00
Max Kellermann
6aa6a9c272
decoder/flac: validate the sample rate when scanning the tag
...
Don't calculate the song duration when the sample rate is 0 (division
by zero crash).
2011-07-03 14:57:56 +02:00
oblique
8d1c7ca206
ffmpeg: workaround for semantic API change in recent ffmpeg versions
2011-07-03 14:54:56 +02:00
Max Kellermann
e228caaca6
Merge branch 'v0.16.x'
...
Conflicts:
src/decoder/ffmpeg_decoder_plugin.c
2011-06-03 16:58:09 +02:00
Max Kellermann
c6a72a14ac
decoder/ffpmeg: don't use av_metadata_conv() in ffmpeg 0.7
...
It's a no-op and deprecated.
2011-05-09 21:24:18 +02:00
Max Kellermann
c74edd0e33
decoder/ffmpeg: use AVIOContext instead of ByteIOContext
2011-05-09 21:23:58 +02:00
Max Kellermann
246db3d565
decoder/ffmpeg: use avcodec_decode_audio3() if available
...
avcodec_decode_audio3() has been added in libavformat 52.25.0, and the
predecessor avcodec_decode_audio2() has been deprecated.
2011-05-09 09:24:17 +02:00
Max Kellermann
eaf414cbc8
decoder/ffmpeg: make variables more local
2011-05-09 09:24:15 +02:00
Anton Khirnov
327d41c00f
decoder/ffmpeg: don't use deprecated CODEC_TYPE_AUDIO with new lavc
...
fixes build with lavc 53.
2011-05-09 08:00:45 +02:00
Max Kellermann
05d8ce3bcd
decoder/ffmpeg: define fallback macro AV_VERSION_INT()
...
For ffmpeg < 0.5. Copied from libavutil 0.5.
2011-05-09 08:00:45 +02:00
Max Kellermann
fe30db935b
decoder/ffmpeg: use avcodec_decode_audio3() if available
...
avcodec_decode_audio3() has been added in libavformat 52.25.0, and the
predecessor avcodec_decode_audio2() has been deprecated.
2011-04-12 08:20:35 +02:00
Max Kellermann
6303d54cbb
decoder/ffmpeg: make variables more local
2011-04-12 08:17:30 +02:00
Anton Khirnov
9d91aa23e6
decoder/ffmpeg: drop support for pre-0.5 ffmpeg
...
All modern distros ship 0.5, so there's no need to support old and buggy
ffmpeg versions.
2011-04-12 08:14:14 +02:00
Max Kellermann
c2ada39fd3
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-04-12 08:11:33 +02:00
Max Kellermann
f680b0a431
decoder/flac: fix enum mismatch in flac_tell_cb()
...
Fix clang warning.
2011-03-23 22:31:40 +01:00
Simon Kagstrom
640bac1aa4
decoder: PCM decoder: Inherit seekable from the input stream
...
E.g., spotify isn't seekable.
2011-03-23 22:13:11 +01:00
Simon Kagstrom
0b12fae84d
decoder: PCM decoder: Break loop if EOF is encountered
...
Otherwise the song playing might go on forever.
2011-03-23 22:13:08 +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
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
Tony Miller
8b2f4fc823
Set fadeout in gme_decoder_plugin. Due to the nature of the gme library,
...
this needs to be done for the end of songs to be detected.
2011-02-03 00:25:35 +01:00
Max Kellermann
c6cbcc2c25
copyright year 2011
2011-01-29 10:13:54 +01:00
Yuriy Kaminskiy
9ae3acf2e7
mpg123 decoder: implement seeking
2011-01-21 15:37:08 +01:00
Yuriy Kaminskiy
731ea9b489
mpg123 decoder: report bitrate
2011-01-21 15:37:08 +01:00
Max Kellermann
1a2ea4c06c
Merge branch 'v0.16.x'
...
Conflicts:
NEWS
configure.ac
2011-01-07 23:52:23 +01:00
Max Kellermann
e3cba18532
decoder: new "pcm" decoder plugin
...
Just there to support the "cdio_paranoia" input plugin.
2010-12-22 09:48:48 +01:00
Alex Viskovatoff
41fdcf328c
decoder/mad: work around build failure on Solaris
...
Rename the "version" struct, because it seems to be a reserved name on
Solaris:
"src/decoder/mad_decoder_plugin.c", line 550: (enum) tag redeclared: version
cc: acomp failed for src/decoder/mad_decoder_plugin.c
2010-12-21 07:57:07 +01:00
Max Kellermann
4478b3ef74
Merge release 0.15.14 from branch 'v0.15.x'
...
Conflicts:
NEWS
configure.ac
src/decoder_control.c
src/decoder_control.h
src/input/rewind_input_plugin.c
src/output_control.c
src/output_thread.c
src/player_thread.c
2010-11-07 15:30:18 +01:00
Max Kellermann
e8d8bd4c0d
decoder/{mp4ff,ffmpeg}: add extension ".m4b" (audio book)
...
Same as ".m4a".
2010-11-05 02:01:35 +01:00
Max Kellermann
3f89f77429
decoder/ffmpeg: check AVCodecContext.sample_fmt value
...
.. instead of av_get_bits_per_sample_format(). The SampleFormat enum
value is authoritative.
2010-11-04 20:04:15 +01:00
Alder Hornbridge
fe1b626f76
decoder/sidplay: play mus, str, prg, x00 files
2010-10-27 21:18:43 +02:00
Alder Hornbridge
4e94516912
decoder/sidplay: play monaural SID tunes in mono
2010-10-27 21:16:24 +02:00
Tony Miller
dadb6747ad
Container support for gme decoder.
2010-10-14 17:11:59 +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
Max Kellermann
0955f33a86
decoder/mp4ff: support more variations of "album artist"
...
According to the mantis bug report 2847, there are several possible
variations of the "album artist" tag:
- "album artist"
- "album_artist"
- "albumartist"
This patch adds support for the latter two.
2010-09-23 21:19:41 +02:00
Max Kellermann
635cfbae13
decoder_control: use g_free() to manage mixramp allocations
...
Be consistent with the rest of MPD, and don't use the non-portable
header "malloc.h".
2010-09-23 08:49:21 +02:00
Rasi
31ab0b3df1
Added album tag support for libgme decoder
2010-07-23 23:13:03 +02:00
Max Kellermann
4364b30c42
decoder/mad: move RVA2 code to tag_rva2.c
2010-07-20 23:03:54 +02:00
Max Kellermann
c0da938d4f
Merge release 0.15.12 from branch 'v0.15.x'
...
Conflicts:
NEWS
configure.ac
2010-07-20 23:03:06 +02:00
Max Kellermann
8b055c3127
tag_rva2: set "gain", not "peak"
...
RVA2 tags only store the "gain" value, there is no "peak" attribute.
2010-07-20 22:32:55 +02:00
Max Kellermann
172182b18f
decoder/mad: parse_rva2() returns bool
2010-07-20 18:27:11 +02:00
Max Kellermann
898a13f196
decoder/wildmidi: support version 0.2.3
...
In libwildmidi 0.2.3, the function WildMidi_SampledSeek() was removed,
without changing the SO name. This patch adds an autoconf check for
that function. Fall back to WildMidi_FastSeek() if
WildMidi_SampledSeek() is not available anymore.
2010-07-20 18:23:56 +02:00
Max Kellermann
e2e8d0d2f3
decoder/ffmpeg: fix libavformat 0.6 by using av_open_input_stream()
...
libavformat 0.6 does not pass the original URI pointer to the "open"
method, which leads to a crash because MPD was using a dirty hack to
pass a pointer to that method.
This patch switches to av_open_input_stream() with a custom
ByteIOContext class, instead of doing the URI string hack with
av_open_input_file().
Loosely based on a patch from Jasper St. Pierre.
2010-07-19 23:03:06 +02:00
Max Kellermann
b2e3c0757b
decoder/ffmpeg: manual format probing
...
Use the libavformat function av_probe_input_format() to probe the
AVInputFormat, instead of letting av_open_input_file() do it
implicitly. We will switch to av_open_input_stream() very soon, which
does not have the probing code.
Loosely based on a patch from Jasper St. Pierre.
2010-07-19 22:59:59 +02:00
Anton Khirnov
0fc0196dba
ffmpeg: read the audio stream metadata in addition to global
...
in some formats, e.g. vorbis, the metadata is stored per-stream.
2010-07-12 11:36:55 +02:00
Anton Khirnov
1492324c76
ffmpeg: factor tag_type <-> ffmpeg tag name maps into a table.
2010-07-12 11:36:55 +02:00
Max Kellermann
49bc317fb8
decoder/ffmpeg: fix libavformat 0.6 by using av_open_input_stream()
...
libavformat 0.6 does not pass the original URI pointer to the "open"
method, which leads to a crash because MPD was using a dirty hack to
pass a pointer to that method.
This patch switches to av_open_input_stream() with a custom
ByteIOContext class, instead of doing the URI string hack with
av_open_input_file().
Loosely based on a patch from Jasper St. Pierre.
2010-06-30 23:41:32 +02:00
Max Kellermann
375a09d6f6
decoder/ffmpeg: manual format probing
...
Use the libavformat function av_probe_input_format() to probe the
AVInputFormat, instead of letting av_open_input_file() do it
implicitly. We will switch to av_open_input_stream() very soon, which
does not have the probing code.
Loosely based on a patch from Jasper St. Pierre.
2010-06-30 23:40:31 +02:00
Max Kellermann
0265c34bed
decoder/ffmpeg: free URI, fix memory leak
...
Free the string allocated by decoder_get_uri().
2010-06-30 23:40:04 +02:00
Max Kellermann
a1882f48be
decoder/vorbis: handle uri==NULL
...
This fixes a theoretical crash, which has never occurred in practice.
2010-06-30 23:38:49 +02:00
Anton Khirnov
c3569814bd
ffmpeg: read more metadata.
2010-06-30 23:18:45 +02:00
Max Kellermann
814daac5ba
decoder/ffmpeg: free AVFormatContext on error
...
Fix a memory leak in some code paths.
2010-06-30 23:14:43 +02:00
Max Kellermann
ec89ce5a8a
decoder/mp4ff: support tag "album artist"
...
We already supported "albumartist", but it seems some folks also use
"album artist" (with a space).
2010-06-30 21:55:03 +02:00
Max Kellermann
77e6810c14
decoder/mikmod: fix memory leak
...
The return value of Player_LoadTitle() is allocated with malloc(), and
must be freed by the caller.
2010-06-30 19:37:36 +00:00
Max Kellermann
5ebe33653c
decoder/mp4ff: remove duplicate entries in the tag name table
...
Reuse the function tag_name_parse_i().
2010-06-30 21:36:15 +02:00
Max Kellermann
8e3eace289
decoder/mp4ff: moved code to mp4ff_tag_name_parse()
2010-06-30 21:36:00 +02:00
Max Kellermann
4d6d372a5b
decoder/vorbis: use single global ov_callbacks constant
...
Initialize the ov_callbacks struct at compile time.
2010-06-30 19:24:41 +00:00
Max Kellermann
0aeec90590
decoder/mp4ff: support tags "albumartist", "band"
...
I'm not sure if mapping "band" to TAG_PERFORMER is correct, but it
might be better than nothing.
2010-06-30 21:22:13 +02:00
Max Kellermann
cfcd84655c
decoder/mp4ff: use tag_table.h to parse tag names
...
Convert if/else/else/... to a loop.
2010-06-30 21:19:30 +02:00
Max Kellermann
9eb292c1e5
decoder/mp4ff: support tag "album artist"
...
We already supported "albumartist", but it seems some folks also use
"album artist" (with a space).
2010-06-25 22:54:18 +02:00
Romain Bignon
b571ba27a4
fix crash when decoder is NULL
2010-05-31 22:11:59 +02:00
Max Kellermann
de8f2739c2
decoder/mikmod: fix memory leak
...
The return value of Player_LoadTitle() is allocated with malloc(), and
must be freed by the caller.
2010-05-31 10:24:08 +02:00
Max Kellermann
2c1c588868
decoder/mikmod: duplicate the path only once
2010-05-31 10:22:08 +02:00
Max Kellermann
e271f69a34
decoder/mikdmod: moved local variable declarations in tag_dup()
2010-05-31 10:16:09 +02:00
Max Kellermann
39105f2119
decoder/wildmidi: moved local variable declarations in tag_dup()
2010-05-31 10:14:48 +02:00
Max Kellermann
4e080a9b06
decoder/gme: replace macro GME_BUF_SIZE
...
Added macros with better names: GME_BUFFER_FRAMES, GME_BUFFER_SAMPLES
(the former only used to calculate the latter).
2010-05-31 10:03:43 +02:00
Max Kellermann
d55740808d
decoder/gme: added constants for sample rate and channels
...
Move into enums.
2010-05-31 10:02:43 +02:00
Max Kellermann
6566038df9
decoder/gme: pass the whole buffer to decoder_data()
...
Pass sizeof(buf) to decoder_data(), not the number of samples (which
is half the size). At the same time, pass GME_BUF_SIZE to gme_play()
- libgme really wants to get the number of samples, not the number of
stereo frames. Previously, this plugin had been using only the first
half of the buffer.
2010-05-31 09:57:15 +02:00
Max Kellermann
f0faf00320
decoder/gme: allocate tag later, fixes memory leak
...
Allocate the "tag" object after the file has been opened successfully.
2010-05-31 09:43:25 +02:00
Max Kellermann
51c7577c8f
decoder/mp4ff: rename and move local variable
...
Allocate the "tag" object after the file has been checked. That
removes one tag_free() call in an error handler.
2010-05-31 09:35:49 +02:00
Max Kellermann
be308c6657
decoder/mp4ff: merge code into mp4ff_input_stream_open()
2010-05-31 09:29:45 +02:00
Max Kellermann
1729a0b437
decoder/mp4ff: move mp4ff_callback_t into mp4ff_input_stream
...
Allocate only one item on the stack.
2010-05-31 09:23:27 +02:00
Max Kellermann
1b2fc2ae19
decoder/mp4ff: rename mp4_context to mp4ff_input_stream
2010-05-31 09:22:42 +02:00
Max Kellermann
58a75f0b78
decoder/mp4ff: remove duplicate entries in the tag name table
...
Reuse the function tag_name_parse_i().
2010-05-31 08:48:41 +02:00
Max Kellermann
daf6e2b5da
decoder/mp4ff: moved code to mp4ff_tag_name_parse()
2010-05-31 08:47:59 +02:00
Max Kellermann
ca08c4dbf4
decoder/vorbis: rename local variable "ret"
2010-05-31 00:06:37 +02:00
Max Kellermann
8af52fa205
decoder/vorbis: implement method stream_tag()
...
This allows tags in archive files.
2010-05-31 00:02:57 +02:00
Max Kellermann
3b0bf856c4
decoder/vorbis: move code to vorbis_open_stream()
2010-05-31 00:00:04 +02:00
Max Kellermann
28f5803d34
decoder/vorbis: use single global ov_callbacks constant
...
Initialize the ov_callbacks struct at compile time.
2010-05-30 23:59:36 +02:00
Max Kellermann
0b72299857
decoder/vorbis: rename struct vorbis_decoder_data to vorbis_is
2010-05-30 23:57:58 +02:00
Max Kellermann
017d61a1aa
decoder/mp4ff: support tags "albumartist", "band"
...
I'm not sure if mapping "band" to TAG_PERFORMER is correct, but it
might be better than nothing.
2010-05-30 22:55:02 +02:00
Max Kellermann
4028d03a6e
decoder/mp4ff: use tag_table.h to parse tag names
...
Convert if/else/else/... to a loop.
2010-05-30 22:52:45 +02:00
Max Kellermann
44b771aca1
decoder/mp4ff: rename plugin "mp4" to "mp4ff"
...
The underlying library is named "libmp4ff". To reduce confusion,
rename the plugin to a more specific name.
2010-05-30 22:52:44 +02:00
Max Kellermann
9dda53e1d2
Merge release 0.15.10 from branch 'v0.15.x'
...
Conflicts:
NEWS
configure.ac
src/input/mms_input_plugin.c
2010-05-30 18:26:33 +02:00
Max Kellermann
442d2e74e3
decoder/mad: fix buffer variable name on !HAVE_ID3TAG
2010-05-30 17:27:03 +02:00
Max Kellermann
fa2ff849c5
input/ffmpeg: new input plugin using libavformat's "avio" library
2010-05-18 21:20:31 +02:00
Tim Phipps
0ac5b6e613
mixramp: Adjust MixRamp threshold to account for ReplayGain.
2010-05-08 00:19:44 -07:00
Max Kellermann
cf3ada3d04
Merge branch 'master' of git://github.com/mcfiredrill/mpd
2010-04-20 21:16:39 +02:00
Max Kellermann
a1a03deed2
decoder/mad: properly calculate ID3 size without libid3tag
...
Without libid3tag, we were trying to skip the ID3 frame (since
0.15.2). Its length however was not calculated at all, we were just
dropping everything from the current input buffer. This lead to the
first few seconds of the file being skipped. This patch attempts to
calculate the ID3v2 frame size with the formula from:
http://www.id3.org/id3v2.4.0-structure 3.1 and 6.2
2010-04-13 08:51:29 +02:00
Charles Kerr
6a95898038
decoder/ffmpeg: fix crash on startup in mpd_ffmpeg_log_callback()
...
What's happening is the `ptr' argument to that function is NULL for me
every time. `ptr' is unconditionally dereferenced to generate a log
message, and this is where mpd crashes.
Attached is a simple patch that tests for NULL and omits the log. With
this patch the crash disappeared and mpd went back to working well.
2010-04-11 19:18:30 +02:00
Tony Miller
9d55b16998
Decoder for game music emulation library.
...
Supports a number of videogame music formats, more info here:
http://www.fly.net/~ant/libs/audio.html
I wrote this plugin for the latest svn, get it here:
http://code.google.com/p/game-music-emu/source/checkout
2010-04-10 01:05:16 -07:00
Max Kellermann
8446b70ddc
decoder/ffmpeg: print item name in log callback
2010-03-28 19:48:57 +02:00
Max Kellermann
e9beea072d
Merge release 0.15.9 from branch 'v0.15.x'
...
Conflicts:
NEWS
configure.ac
src/cue/cue_tag.c
src/decoder/mpcdec_decoder_plugin.c
src/player_thread.c
2010-03-28 19:31:47 +02:00
Tim Phipps
e7a515c8b1
Add support for MixRamp tags
...
Adds mixrampdb and mixrampdelay commands. Reads MIXRAP_START and
MIXRAMP_END tags from FLAC files and overlaps instead of crossfading.
2010-03-21 18:21:47 +01:00
Aleksei Kaveshnikov
73ba4ea3da
decoder/mpcdec: fix replay gain formula with v8
...
"When playing musepack files with mpd v0.15.8, rg seems to have no effect.
Using sample file below, mpd says 'computing ReplayGain album scale with gain 122.879997, peak 0.549150'.
One thing though, if I build mpd against old libmpcdec-1.2.6, rg works
as expected: 'computing ReplayGain album scale with gain 16.820000,
peak 0.099765'"
2010-03-19 10:26:08 +01:00
Piotr Gozdur
96033e4b4e
decoder/mpcdec: fix negative shift on fixed-point samples
...
"There is a bug in fixed-point musepack (musepack_src_r435) playback.
In floating-point audio is OK but in fixed audio is distorted. I have
made a patch for this"
2010-03-17 17:54:21 +01:00
Max Kellermann
5842015b90
decoder/ffmpeg: fix indentation
2010-03-07 19:20:34 +01:00
Max Kellermann
ae56901863
decoder/ffmpeg: implement the libavutil log callback
...
Pass everything to the GLib logging library. No direct stderr access.
2010-02-27 19:32:59 +01:00
Max Kellermann
4e364854ab
decoder/ffmpeg: don't close the AVFormatContext after open failure
...
The pointer is invalid if av_open_input_file() fails.
2010-02-27 19:25:56 +01:00
Max Kellermann
35c5a371ea
decoder/mad: fix crash when seeking at end of song
...
Removed the decoder_command_finished() call at the end of
mp3_decode(). This is invalid, because decoder_command_finished() has
already been called in mp3_read().
2010-02-27 18:35:31 +01:00
Max Kellermann
5e0117b444
replay_gain_info: allocate the struct statically
...
Don't allocate each replay_gain_info object on the heap. Those
objects who held a pointer now store a full replay_gain_info object.
This reduces the number of allocations and heap fragmentation.
2010-02-17 07:22:44 +01:00
Anton Khirnov
766b9fd453
ffmpeg: read more metadata.
2010-02-02 17:55:58 +01:00
Tim Phipps
891dab7b91
decoder/flac: fix replay gain (short-circuiting "or")
2010-01-28 20:54:04 +01:00
Max Kellermann
acb0ff1ea8
decoder/wavpack: fixed WVC URI
...
Pass the current URI to wavpack_open_wvc().
2010-01-20 12:08:44 +01:00
Max Kellermann
2acad9fe1e
decoder/ffmpeg: call decoder_timestamp() once per packet
2010-01-18 13:11:04 +01:00
Max Kellermann
8914ebc964
decoder/ffmpeg: merged ffmpeg_helper() into ffmpeg_decode()
2010-01-18 11:06:09 +01:00
Max Kellermann
5477c31160
decoder/ffmpeg: optimized the stream_tag() method
...
Don't use the function ffmpeg_helper(), don't initialize the codec.
2010-01-18 11:06:04 +01:00
Max Kellermann
acd3f8cd91
decoder/ffmpeg: free AVFormatContext on error
...
Fix a memory leak in some code paths.
2010-01-18 11:05:15 +01:00
Max Kellermann
ca1fc13116
decoder_api: removed function decoder_get_uri()
...
Use input_stream.uri.
2010-01-18 10:21:57 +01:00
Max Kellermann
a0a26d3341
Merge release 0.15.8 from branch 'v0.15.x
...
Conflicts:
Makefile.am
NEWS
configure.ac
src/decoder/ffmpeg_decoder_plugin.c
src/decoder_thread.c
2010-01-18 07:52:58 +01:00
Max Kellermann
2579a2f924
decoder/ffmpeg: added more MIME types
...
Taken from the ffmpeg sources.
2010-01-17 16:00:14 +01:00
Max Kellermann
1b441837f1
decoder/ffmpeg: append file name suffix to virtual stream URL
...
To allow libavformat to detect the format of the input file, append
the suffix of the input file to the URL of the virtual stream. This
specifically enables the "shorten" codec, which is supported by
libavformat/raw.c, detected only by the suffix.
2010-01-17 02:36:07 +01:00
Max Kellermann
1abfcc56af
audio_format: support packed 24 bit samples
2010-01-16 23:44:54 +01:00