On Mon, Jun 18, 2012 at 03:22:56PM +0100, Mans Rullgard wrote:
>
> --- a/libavformat/flvdec.c
> +++ b/libavformat/flvdec.c
> @@ -749,33 +749,6 @@ static int flv_read_seek(AVFormatContext *s, int
> stream_index,
>
> -#if 0 /* don't know enough to implement this */
> -static int flv_read_seek2(AVFormatContext *s, int stream_index,
> - int64_t min_ts, int64_t ts, int64_t max_ts, int flags)
> -{
> - int ret = AVERROR(ENOSYS);
> -
> - if (ts - min_ts > (uint64_t)(max_ts - ts)) flags |= AVSEEK_FLAG_BACKWARD;
> -
> - if (!s->pb->seekable) {
> - if (stream_index < 0) {
> - stream_index = av_find_default_stream_index(s);
> - if (stream_index < 0)
> - return -1;
> -
> - /* timestamp for default must be expressed in AV_TIME_BASE units
> */
> - ts = av_rescale_rnd(ts, 1000, AV_TIME_BASE,
> - flags & AVSEEK_FLAG_BACKWARD ? AV_ROUND_DOWN : AV_ROUND_UP);
> - }
> - ret = avio_seek_time(s->pb, stream_index, ts, flags);
> - }
> -
> - if (ret == AVERROR(ENOSYS))
> - ret = av_seek_frame(s, stream_index, ts, flags);
> - return ret;
> -}
> -#endif
> -
> @@ -784,9 +757,6 @@ AVInputFormat ff_flv_demuxer = {
> .read_packet = flv_read_packet,
> .read_seek = flv_read_seek,
> -#if 0
> - .read_seek2 = flv_read_seek2,
> -#endif
> .read_close = flv_read_close,
> .extensions = "flv",
I sent this same thing ages ago :)
https://patches.libav.org/patch/6548/
Diego
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel