38 const char *
data, *opt, *next;
46 data = strchr(uri,
',');
55 if (!memchr(opt,
'/', next - opt)) {
57 (
int)(next - opt), opt);
61 (
int)(next - opt), opt);
67 (
int)(next - opt), opt);
74 in_size = strlen(
data);
76 size_t out_size = 3 * (in_size / 4) + 1;
Convenience header that includes libavutil's core.
#define flags(name, subs,...)
static av_cold int data_open(URLContext *h, const char *uri, int flags)
const URLProtocol ff_data_protocol
static int data_read(URLContext *h, unsigned char *buf, int size)
static av_cold int data_close(URLContext *h)
int av_base64_decode(uint8_t *out, const char *in_str, int out_size)
Decode a base64-encoded string.
#define AVERROR_EOF
End of file.
#define AV_LOG_VERBOSE
Detailed information.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
static void * av_x_if_null(const void *p, const void *x)
Return x default pointer in case p is NULL.
int av_strstart(const char *str, const char *pfx, const char **ptr)
Return non-zero if pfx is a prefix of str.
int av_strncasecmp(const char *a, const char *b, size_t n)
Locale-independent case-insensitive compare.
Memory handling functions.
unbuffered private I/O API