DescriptionFix an issue that audio and video may ran out of sync
this is cloned from https://codereview.chromium.org/215783002/, it fixes some flaky unit test.
This CL fixes 3 issues:
1. In ProcessPendingEvents(), if there is a non-seek pending event, UpdateTimestamps() will not get called. This is probably the number 1 contributor to losing sync issue.
2. MSP use its internal clock to estmate the current presentation time. However, hardware may consume data at a different rate. Passing the current frame position from AudioTrack to MSP so we get a better estimation of the current time.
3. When config change comes, We don't need to reset the clock if audio decoder is not recreated.
BUG=351722
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=264744
Patch Set 1 #Patch Set 2 : Fix the flaky test in previous patch #
Total comments: 4
Patch Set 3 : addressing comments #
Total comments: 8
Patch Set 4 : fixing nits #Patch Set 5 : fixing another flakiness #
Total comments: 4
Patch Set 6 : addressing comments #Messages
Total messages: 14 (0 generated)
|