Closed Bug 1137511 Opened 5 years ago Closed 5 years ago

MDSM can start buffering 1s earlier than necessary when audio frames have been pushed to audio hardware but not yet played

Categories

(Core :: Audio/Video, defect, P1)

x86
macOS
defect

Tracking

()

RESOLVED FIXED
mozilla39
Tracking Status
firefox37 --- fixed
firefox38 --- fixed
firefox39 --- fixed

People

(Reporter: bholley, Assigned: bholley)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

This was exposed by the tests I wrote in bug 1136399.

OutOfDecodedAudio() is overly-simplistic, and doesn't consider the fact that we can have a bit more than 1s of audio in the hardware buffer. I've got a patch that seems to do the trick.
Attachment #8570202 - Flags: review?(kinetik) → review+
(In reply to Bobby Holley (:bholley) from comment #2)
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=098a64f8a733

The oranges in the try push were a test that I pushed alongside this patch and wasn't ready yet. Aside from that this is green.

https://hg.mozilla.org/integration/mozilla-inbound/rev/3148c577bfd9
This could improve our MTBR stats on YouTube. Let's consider uplifting after it bakes a bit.
Flags: needinfo?(giles)
https://hg.mozilla.org/mozilla-central/rev/3148c577bfd9
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Comment on attachment 8570202 [details] [diff] [review]
Account for audio frames already pushed to audio hardware but not yet played when computing OutOfDecodedAudio. v1

Requesting uplift approval for 38 and 37b3 since this is a low risk fix to a high priority issue.

Approval Request Comment
[Feature/regressing bug #]: MSE
[User impact if declined]: Unnecessary rebuffering pauses during youtube playback.
[Describe test coverage new/current, TreeHerder]: Landed on m-c.
[Risks and why]: Risk looks low. This just adds another condition to deciding we're out of audio data and need to request more.
[String/UUID change made/needed]: None.
Flags: needinfo?(giles)
Attachment #8570202 - Flags: approval-mozilla-beta?
Attachment #8570202 - Flags: approval-mozilla-aurora?
Attachment #8570202 - Flags: approval-mozilla-beta?
Attachment #8570202 - Flags: approval-mozilla-beta+
Attachment #8570202 - Flags: approval-mozilla-aurora?
Attachment #8570202 - Flags: approval-mozilla-aurora+
Depends on: 1181913
You need to log in before you can comment on or make changes to this bug.