diff options
author | waker <wakeroid@gmail.com> | 2011-01-31 19:29:57 +0100 |
---|---|---|
committer | waker <wakeroid@gmail.com> | 2011-01-31 19:29:57 +0100 |
commit | 80e8e0f4a5a214de8884be245049b5fbc53cf4aa (patch) | |
tree | 1c108752208456d9d2da0410926f73779b7a8042 /plugins/vorbis | |
parent | c3d28f081ec9263980e863316a3eeae177a15be4 (diff) |
added container support to vfs plugin api
Diffstat (limited to 'plugins/vorbis')
-rw-r--r-- | plugins/vorbis/vorbis.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/vorbis/vorbis.c b/plugins/vorbis/vorbis.c index dc3e3a72..c4958d39 100644 --- a/plugins/vorbis/vorbis.c +++ b/plugins/vorbis/vorbis.c @@ -184,7 +184,7 @@ cvorbis_init (DB_fileinfo_t *_info, DB_playItem_t *it) { return -1; } int ln = deadbeef->fgetlength (info->info.file); - if (info->info.file->vfs->streaming && ln == -1) { + if (info->info.file->vfs->is_streaming () && ln == -1) { ov_callbacks ovcb = { .read_func = cvorbis_fread, .seek_func = NULL, @@ -238,7 +238,7 @@ cvorbis_init (DB_fileinfo_t *_info, DB_playItem_t *it) { _info->readpos = 0; info->currentsample = 0; - if (!info->info.file->vfs->streaming) { + if (!info->info.file->vfs->is_streaming ()) { if (it->endsample > 0) { info->startsample = it->startsample; info->endsample = it->endsample; @@ -285,7 +285,7 @@ cvorbis_read (DB_fileinfo_t *_info, char *bytes, int size) { int samplesize = _info->fmt.channels * _info->fmt.bps / 8; - if (!info->info.file->vfs->streaming) { + if (!info->info.file->vfs->is_streaming ()) { if (info->currentsample + size / samplesize > info->endsample) { size = (info->endsample - info->currentsample + 1) * samplesize; trace ("size truncated to %d bytes, cursample=%d, info->endsample=%d, totalsamples=%d\n", size, info->currentsample, info->endsample, ov_pcm_total (&info->vorbis_file, -1)); @@ -427,7 +427,7 @@ cvorbis_insert (DB_playItem_t *after, const char *fname) { trace ("vorbis: failed to fopen %s\n", fname); return NULL; } - if (fp->vfs->streaming) { + if (fp->vfs->is_streaming ()) { DB_playItem_t *it = deadbeef->pl_item_alloc (); it->fname = strdup (fname); it->filetype = "OggVorbis"; @@ -535,7 +535,7 @@ cvorbis_read_metadata (DB_playItem_t *it) { trace ("cvorbis_read_metadata: failed to fopen %s\n", it->fname); return -1; } - if (fp->vfs->streaming) { + if (fp->vfs->is_streaming ()) { trace ("cvorbis_read_metadata: failed to fopen %s\n", it->fname); goto error; } |