From: Good Guy Date: Mon, 11 Sep 2017 20:17:57 +0000 (-0600) Subject: ffmpeg frame reset retry to push design limits X-Git-Url: https://cinelerra-gg.org/git/?a=commitdiff_plain;h=9304882bd349ce15be054efb7cdcf69a0829f0f9;p=goodguy%2Fhistory.git ffmpeg frame reset retry to push design limits --- diff --git a/cinelerra-5.1/cinelerra/ffmpeg.C b/cinelerra-5.1/cinelerra/ffmpeg.C index 74b32cf1..dcbb49c6 100644 --- a/cinelerra-5.1/cinelerra/ffmpeg.C +++ b/cinelerra-5.1/cinelerra/ffmpeg.C @@ -739,6 +739,7 @@ int FFAudioStream::load(int64_t pos, int len) init_swr(frame->channels, frame->format, frame->sample_rate); load_history(&frame->extended_data[0], frame->nb_samples); curr_pos += frame->nb_samples; + i = 0; } } if( end_pos > curr_pos ) { @@ -868,7 +869,7 @@ int FFVideoStream::load(VFrame *vframe, int64_t pos) } for( int i=0; ret>=0 && !flushed && curr_pos<=pos && i 0 ) ++curr_pos; + if( ret > 0 ) { ++curr_pos; i = 0; } } if( frame->format == AV_PIX_FMT_NONE || frame->width <= 0 || frame->height <= 0 ) ret = -1;