From: Michael Niedermayer <michael@niedermayer.cc>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH 1/2] libavformat: Improve ff_configure_buffers_for_index for excessive deltas
Date: Sat, 25 Mar 2023 01:37:18 +0100
Message-ID: <20230325003718.GR375355@pb2> (raw)
In-Reply-To: <20230321123729.74124-1-martin@martin.st>
[-- Attachment #1.1: Type: text/plain, Size: 1552 bytes --]
On Tue, Mar 21, 2023 at 02:37:28PM +0200, Martin Storsjö wrote:
> Previously, the ff_configure_buffers_for_index function had
> upper sanity limits of 16 MB (1<<24) for buffer_size and
> 8 MB (1<<23) for short_seek_threshold.
>
> However, if the index analysis showed a need for even larger
> buffer sizes (for a really badly interleaved file), over the
> sanity limits, we previously didn't increase the buffer sizes
> at all.
>
> Instead, if the file shows a need for really large buffers and
> short_seek_threshold, just set them to the maximum sanity limit;
> while it might not be enough for all cases in the file, it might
> be enough for most of it.
>
> This can happen e.g. with a mov file with some tracks containing
> some samples that belong in the start of the file, at the end of
> the mdat, while the rest of the file is mostly reasonably interleaved;
> previously those samples caused the maximum pos_delta to skyrocket,
> skipping any buffer size enlargement.
>
> Signed-off-by: Martin Storsjö <martin@martin.st>
> ---
> libavformat/seek.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
I think, if iam not too tired ATM that
instead of taking the maximum it would be better to ignore the cases
which are above the maximum, so the value would be optimal for the
cases that it can help
[...]
thx
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
It is a danger to trust the dream we wish for rather than
the science we have, -- Dr. Kenneth Brown
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
next prev parent reply other threads:[~2023-03-25 0:37 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-21 12:37 Martin Storsjö
2023-03-21 12:37 ` [FFmpeg-devel] [PATCH 2/2] aviobuf: Avoid clearing the whole buffer in fill_buffer Martin Storsjö
2023-03-21 19:29 ` Marton Balint
2023-03-21 20:24 ` Martin Storsjö
2023-03-24 11:11 ` Anton Khirnov
2023-03-24 11:25 ` Martin Storsjö
2023-03-24 11:55 ` Anton Khirnov
2023-03-24 20:45 ` Marton Balint
2023-03-24 21:05 ` Martin Storsjö
2023-03-24 21:35 ` Marton Balint
2023-03-24 21:41 ` Martin Storsjö
2023-03-24 21:49 ` [FFmpeg-devel] [PATCH 1/2] libavformat: Improve ff_configure_buffers_for_index for excessive deltas Marton Balint
2023-03-25 0:37 ` Michael Niedermayer [this message]
2023-03-25 22:17 ` Martin Storsjö
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230325003718.GR375355@pb2 \
--to=michael@niedermayer.cc \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git