Mercurial > audlegacy-plugins
changeset 261:9ce03bf021ae trunk
[svn] So input.c wants to have the old-style function available...
author | chainsaw |
---|---|
date | Sat, 18 Nov 2006 16:26:08 -0800 |
parents | 4f7b72c88319 |
children | f653f1219db2 |
files | ChangeLog src/alac/plugin.c |
diffstat | 2 files changed, 41 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Sat Nov 18 16:21:15 2006 -0800 +++ b/ChangeLog Sat Nov 18 16:26:08 2006 -0800 @@ -1,3 +1,11 @@ +2006-11-19 00:21:15 +0000 Tony Vroon <chainsaw@gentoo.org> + revision [544] + So input.c wants to have the old-style function available... + trunk/src/musepack/libmpc.cxx | 19 +++++++++++++++++-- + trunk/src/musepack/libmpc.h | 3 ++- + 2 files changed, 19 insertions(+), 3 deletions(-) + + 2006-11-19 00:16:01 +0000 Tony Vroon <chainsaw@gentoo.org> revision [542] So input.c wants to have the old-style function available...
--- a/src/alac/plugin.c Sat Nov 18 16:21:15 2006 -0800 +++ b/src/alac/plugin.c Sat Nov 18 16:26:08 2006 -0800 @@ -86,6 +86,38 @@ /* empty */ } +gboolean is_our_file(char *filename) +{ + demux_res_t demux_res; + VFSFile *input_file; + stream_t *input_stream; + + input_file = vfs_fopen(filename, "rb"); + input_stream = stream_create_file(input_file, 1); + + set_endian(); + + if (!input_stream) + { + vfs_fclose(input_file); + return FALSE; + } + + /* if qtmovie_read returns successfully, the stream is up to + * the movie data, which can be used directly by the decoder */ + if (!qtmovie_read(input_stream, &demux_res)) + { + stream_destroy(input_stream); + vfs_fclose(input_file); + return FALSE; + } + + stream_destroy(input_stream); + vfs_fclose(input_file); + + return TRUE; +} + gboolean is_our_fd(char *filename, VFSFile* input_file) { demux_res_t demux_res; @@ -201,7 +233,7 @@ alac_init, alac_about, NULL, - NULL, + is_our_file, NULL, play_file, stop,