Age | Commit message (Collapse) | Author |
|
This makes RTP custom IO work properly with pure read-only
AVIOContexts as well.
Signed-off-by: Martin Storsjö <martin@martin.st>
|
|
So far, aviocontexts are used either in pure-read or pure-write
mode - full read/write mode doesn't work well (and implementing it
is a much larger, not totally trivial change).
This patch allows using avio_read and ffio_read_partial on
read/write aviocontexts, where the read operations are passed
through directly unbuffered, while writes are buffered as usual.
This is enough to support the operations needed by packet based
data transfer like in udp/rtp, where aviocontext is the only
public API for hooking up custom IO.
Signed-off-by: Martin Storsjö <martin@martin.st>
|
|
|
|
|
|
This seemed to assume that one never used writing avio unless
muxers or networking was enabled.
This ifdef is a remnant since 8fa641f8.
Signed-off-by: Martin Storsjö <martin@martin.st>
|
|
|
|
This is consistent with stdio, and thus what people would naturally
expect.
|
|
|
|
Its behaviour in line with ffurl_close(NULL).
|
|
|
|
|
|
Fixes an invalid free() with ass in avi. The sample in bug 98 passes
parts of AVPacket.data as buffer for the AVIOContext. Since the packet
is quite large fill_buffer tries to reallocate the buffer before doing
nothing. Fixes bug 98.
|
|
The interrupt callback has to be passed in during opening (setting it
after opening isn't enough), since a blocking open couldn't be
interrupted otherwise.
Options are passed down to procotols and also need to be available
during open() in most cases.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
|
|
Not used anywhere yet, support for passing options from avio_open() will
follow.
|
|
Change all uses of these function to pass the relevant
callback on.
|
|
|
|
|
|
|
|
Signed-off-by: Anton Khirnov <anton@khirnov.net>
|
|
Make AVIO_FLAG_ access constants work as flags, and in particular fix
the behavior of functions (such as avio_check()) which expect them to
be flags rather than modes.
This breaks API.
|
|
|
|
It seems their replacements won't be ready anytime soon.
|
|
|
|
Fixes build with --disable-muxers --disable-network.
Thanks to Hendrik Leppkes for noticing.
|
|
URLContext.max_packet_size should be used directly.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The unbuffered URLContext API will be made private, so there's no point
in this function being public.
|
|
It doesn't look fit to be a part of the public API.
Adding a temporary hack to ffserver to be able to use it, should be
cleaned up when somebody is up for it.
|
|
|
|
|
|
Use it instead of url_is_streamed and AVIOContext.is_streamed.
|
|
|
|
|
|
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
It's an evil hack that assumes an AVIOContext is always based on top of
an URLContext.
It's also not used anywhere.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
Signed-off-by: Mans Rullgard <mans@mansr.com>
|
|
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
It's not used anywhere and its return value looks broken.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
It's only used in one place and does the same thing as
avio_alloc_context.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
And rename it to ffio_read_varlen.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
AVIOContext.error should be used directly instead.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|
|
AVIOContext.eof_reached should be used directly instead.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
|