ogg, ffmpeg: try to decode, even when the stream is not seekable

Ogg and ffmpeg detection was disabled when the stream was not
seekable, because the detection was too expensive.  Since the curl
input stream can now rewind the stream cheaply, we can re-enable
detection on streams.
This commit is contained in:
Max Kellermann 2008-11-02 17:06:32 +01:00
parent 460b15d29c
commit 4d069b4991
3 changed files with 1 additions and 11 deletions

View File

@ -210,7 +210,7 @@ ffmpeg_helper(struct input_stream *input, bool (*callback)(BasePtrs *ptrs),
static bool
ffmpeg_try_decode(struct input_stream *input)
{
return input->seekable && ffmpeg_helper(input, NULL, NULL);
return ffmpeg_helper(input, NULL, NULL);
}
static enum decoder_command

View File

@ -281,11 +281,6 @@ static struct tag *oggflac_TagDup(const char *file)
static bool oggflac_try_decode(struct input_stream *inStream)
{
if (!inStream->seekable)
/* we cannot seek after the detection, so don't bother
checking */
return true;
return ogg_stream_type_detect(inStream) == FLAC;
}

View File

@ -364,11 +364,6 @@ static struct tag *oggvorbis_TagDup(const char *file)
static bool
oggvorbis_try_decode(struct input_stream *inStream)
{
if (!inStream->seekable)
/* we cannot seek after the detection, so don't bother
checking */
return true;
return ogg_stream_type_detect(inStream) == VORBIS;
}