time == -1 and duration. Complicated since time is relative to stream,
duration relative to container time base.
Originally committed as revision 18019 to svn://svn.ffmpeg.org/ffmpeg/trunk
Has been tested against streamed / non-seekable input and passes make
seektest. See "[PATCH] rmdec.c: parse INDX chunk" thread on mailinglist.
Originally committed as revision 18013 to svn://svn.ffmpeg.org/ffmpeg/trunk
as requested by Kostya). See "[PATCH] rmdec.c: remove cache access
duplication".
Originally committed as revision 18010 to svn://svn.ffmpeg.org/ffmpeg/trunk
cache, since this can already be accessed through ff_rm_retrieve_cache().
See "[PATCH] rmdec.c: remove cache access duplication" thread.
Originally committed as revision 18009 to svn://svn.ffmpeg.org/ffmpeg/trunk
the newer (.rm, audio/video) files. See "[PATCH] rmdec.c: merge old/new
packet reading code" thread on mailinglist.
Originally committed as revision 18005 to svn://svn.ffmpeg.org/ffmpeg/trunk
discussion in the ML thread "[PATCH] rmdec.c: merge old/new packet reading
code".
Over time, this code broke somewhat, e.g. seq was never actually written
into (and was thus always 1, therefore the seq condition was always true),
whereas it was supposed to be set to the sequence number of the video slice
in case the video frame is divided over multiple RM packets (slices). The
problem of this is that packets other than those containing the beginning
of a video frame would be indexed as well.
Secondly, flags&2 is supposed to be true for video keyframes and for these
audio packets containing the start of a block. For some codecs (e.g. AAC),
that is every single packet, whereas for others (e.g. cook), that is the
packet containing the first of a series of scrambled packets that are to be
descrambled together. Indexing any of the following would lead to incomplete
and thus useless frames. Problem here is that flags would be reset to 2 to
indicate that the first packet is ready to be returned, and in addition if
no data was left to be returned (which is always true for the first packet),
then we wouldn't actually write the index entry anyway.
All in all, the idea was good and it probably worked at some point, but that
is long ago. This patch should at the very least make it likely for this code
to be executed again at the right times, i.e. the way it was originally
intended to be used.
Originally committed as revision 17993 to svn://svn.ffmpeg.org/ffmpeg/trunk
seeking before data_offset and is more consistent with how the generic index
seeking code handles it.
Originally committed as revision 17964 to svn://svn.ffmpeg.org/ffmpeg/trunk
pre-parsing the file in read_header.
This avoids some code duplication and seeking, and also avoids an IO error
for small video-only files (as created during e.g. the FATE encoder test).
Originally committed as revision 17945 to svn://svn.ffmpeg.org/ffmpeg/trunk
and if the size is broken (20 bytes, header-only), calculate the expected
size and skip the index entries anyway. See "[PATCH] rmdec.c: correctly
skip indexes" thread.
Originally committed as revision 17924 to svn://svn.ffmpeg.org/ffmpeg/trunk