31 #include "libavutil/avassert.h"
32 #include "libavutil/avstring.h"
33 #include "libavutil/file.h"
86 int r2= write(c->
fd, buf, r);
110 pos= lseek(c->
fd, pos, whence);
113 }
else if(pos <= c->
end){
117 if(lseek(c->
fd, c->
pos, SEEK_SET) < 0) {
139 .priv_data_size =
sizeof(
Context),
support non continuous caching support keeping files support filling with a background thread ...
AVIOInterruptCB interrupt_callback
void av_log(void *avcl, int level, const char *fmt,...) av_printf_format(3
Send the specified message to the log if the level is less than or equal to the current av_log_level...
void av_freep(void *ptr)
Free a memory block which has been allocated with av_malloc(z)() or av_realloc() and set the pointer ...
int av_tempfile(const char *prefix, char **filename, int log_offset, void *log_ctx)
Wrapper to work around the lack of mkstemp() on mingw.
miscellaneous OS support macros and functions.
static av_cold int end(AVCodecContext *avctx)
URLProtocol ff_cache_protocol
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
static int cache_open(URLContext *h, const char *arg, int flags)
static int cache_close(URLContext *h)
static int64_t cache_seek(URLContext *h, int64_t pos, int whence)
static void close(AVCodecParserContext *s)
static int cache_read(URLContext *h, unsigned char *buf, int size)
int ffurl_close(URLContext *h)
int av_strstart(const char *str, const char *pfx, const char **ptr)
Return non-zero if pfx is a prefix of str.
int64_t ffurl_seek(URLContext *h, int64_t pos, int whence)
Change the position that will be used by the next read/write operation on the resource accessed by h...
int ffurl_open(URLContext **puc, const char *filename, int flags, const AVIOInterruptCB *int_cb, AVDictionary **options)
Create an URLContext for accessing to the resource indicated by url, and open it. ...
unbuffered private I/O API
#define av_assert0(cond)
assert() equivalent, that is always enabled.
int ffurl_read(URLContext *h, unsigned char *buf, int size)
Read up to size bytes from the resource accessed by h, and store the read bytes in buf...