1 /* 2 This file is part of Deadbeef Player source code 3 http://deadbeef.sourceforge.net 4 5 high-level vfs access interface 6 7 Copyright (C) 2009-2013 Alexey Yakovenko 8 9 This software is provided 'as-is', without any express or implied 10 warranty. In no event will the authors be held liable for any damages 11 arising from the use of this software. 12 13 Permission is granted to anyone to use this software for any purpose, 14 including commercial applications, and to alter it and redistribute it 15 freely, subject to the following restrictions: 16 17 1. The origin of this software must not be misrepresented; you must not 18 claim that you wrote the original software. If you use this software 19 in a product, an acknowledgment in the product documentation would be 20 appreciated but is not required. 21 2. Altered source versions must be plainly marked as such, and must not be 22 misrepresented as being the original software. 23 3. This notice may not be removed or altered from any source distribution. 24 25 Alexey Yakovenko waker@users.sourceforge.net 26 */ 27 28 #ifndef __VFS_H 29 #define __VFS_H 30 31 #include "deadbeef.h" 32 33 DB_FILE* vfs_fopen (const char *fname); 34 void vfs_set_track (DB_FILE *stream, DB_playItem_t *it); 35 void vfs_fclose (DB_FILE *f); 36 size_t vfs_fread (void *ptr, size_t size, size_t nmemb, DB_FILE *stream); 37 int vfs_fseek (DB_FILE *stream, int64_t offset, int whence); 38 int64_t vfs_ftell (DB_FILE *stream); 39 void vfs_rewind (DB_FILE *stream); 40 int64_t vfs_fgetlength (DB_FILE *stream); 41 const char *vfs_get_content_type (DB_FILE *stream); 42 void vfs_fabort (DB_FILE *stream); 43 44 #endif // __VFS_H 45