Skip to content

Commit

Permalink
Temporary fix for stuttery playback of AVI files over Storage Group.
Browse files Browse the repository at this point in the history
This is a reverse of ffmpeg SHA1:8df774be88c347c40f1b2411ed9e391dfec0ebb7
http://git.videolan.org/?p=ffmpeg.git;a=commit;h=8df774be88c347c40f1b2411ed9e391dfec0ebb7

This is not a proper fix. It only reveals an issue with myth Storage Group file ring buffer.
With this ffmpeg change, some AVI files are detected as non-interleaved and the readahead thread starts to pull MB of data which saturates 100Mbit/s link causing the video playback to stutter.
  • Loading branch information
jyavenard committed Dec 15, 2012
1 parent 021b2e5 commit f1540fe
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions mythtv/external/FFmpeg/libavformat/avidec.c
Expand Up @@ -1334,6 +1334,12 @@ static int guess_ni_flag(AVFormatContext *s){
first_end= st->index_entries[n-1].pos;
}
avio_seek(s->pb, oldpos, SEEK_SET);

return (last_start > first_end);

/* myth
if (last_start > first_end)
return 1;
idx= av_mallocz(sizeof(*idx) * s->nb_streams);
Expand All @@ -1360,6 +1366,9 @@ static int guess_ni_flag(AVFormatContext *s){
}
av_free(idx);
return 0;
*/
}

static int avi_load_index(AVFormatContext *s)
Expand Down

0 comments on commit f1540fe

Please sign in to comment.