1
0
Fork 0
forked from len0rd/rockbox

Another AV sync bugfix - the initial avdelay was being incorrectly calculated in some cases

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12975 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Dave Chapman 2007-03-30 23:58:12 +00:00
parent dc33e1e8a7
commit 1088f695a2

View file

@ -631,7 +631,9 @@ static void audio_thread(void)
if (!found_avdelay) {
if ((audio_str.first_pts != 0) && (video_str.first_pts != 0)) {
avdelay = ((audio_str.first_pts - video_str.first_pts)*44100)/90000;
avdelay = audio_str.first_pts - video_str.first_pts;
avdelay *= 44100;
avdelay /= 90000;
found_avdelay = 1;
DEBUGF("First Audio PTS = %u, First Video PTS=%u, A-V=%d samples\n",(unsigned int)audio_str.first_pts,(unsigned int)video_str.first_pts,avdelay);
}