30 #define AV_CAT_SEPARATOR "|" 51 for (i = 0; i != data->
length; i++)
56 return err < 0 ? -1 : 0;
61 char *node_uri =
NULL;
63 int64_t
size, total_size = 0;
74 for (i = 0, len = 1; uri[
i]; i++) {
77 if (++len == UINT_MAX /
sizeof(*nodes)) {
91 for (i = 0; *uri; i++) {
141 if (i + 1 == data->
length ||
147 return total ? total :
result;
153 return total ? total :
result;
167 for (i = data->
length - 1; i && pos < -nodes[i].
size; i--)
168 pos += nodes[
i].
size;
172 for (i = 0; i != data->
current; i++)
173 pos += nodes[i].
size;
178 for (i = 0; i != data->
length - 1 && pos >= nodes[
i].
size; i++)
179 pos -= nodes[i].
size;
189 result += nodes[--
i].
size;
201 .default_whitelist =
"concat,file,subfile",
int ffurl_open_whitelist(URLContext **puc, const char *filename, int flags, const AVIOInterruptCB *int_cb, AVDictionary **options, const char *whitelist, const char *blacklist, URLContext *parent)
Create an URLContext for accessing to the resource indicated by url, and open it. ...
void * av_realloc(void *ptr, size_t size)
Allocate, reallocate, or free a block of memory.
ptrdiff_t const GLvoid * data
static av_cold int concat_close(URLContext *h)
Memory handling functions.
AVIOInterruptCB interrupt_callback
size_t length
number of cat'ed nodes
struct concat_nodes * nodes
list of nodes to concat
static int concat_read(URLContext *h, unsigned char *buf, int size)
#define AVERROR_EOF
End of file.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
const char * protocol_whitelist
size_t av_strlcpy(char *dst, const char *src, size_t size)
Copy the string src to dst, but no more than size - 1 bytes, and null-terminate dst.
static int64_t concat_seek(URLContext *h, int64_t pos, int whence)
int ffurl_closep(URLContext **hh)
Close the resource accessed by the URLContext h, and free the memory used by it.
int av_reallocp(void *ptr, size_t size)
Allocate, reallocate, or free a block of memory through a pointer to a pointer.
const char * protocol_blacklist
int64_t ffurl_size(URLContext *h)
Return the filesize of the resource accessed by h, AVERROR(ENOSYS) if the operation is not supported ...
static av_cold int concat_open(URLContext *h, const char *uri, int flags)
#define flags(name, subs,...)
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...
const URLProtocol ff_concat_protocol
#define AVSEEK_SIZE
ORing this as the "whence" parameter to a seek function causes it to return the filesize without seek...
size_t current
index of currently read node
and forward the result(frame or status change) to the corresponding input.If nothing is possible
unbuffered private I/O API
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later.That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another.Frame references ownership and permissions
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...
URLContext * uc
node's URLContext