Do Flush command after EOS for MSE.

RESOLVED FIXED in Firefox 46

Status

()

defect
P2
normal
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: ayang, Assigned: ayang)

Tracking

unspecified
mozilla46
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox46 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

MediaFormatReader could send more data after calling Drain (send EOS in OmxDataDecoder) in MSE case. In OMX, it won't accept any input after EOS, to fix it, we need to call flush command to reset decoder [1].

[1] spec 3.2.2.4 OMX_CommandFlush:
"When a port is flushed, the component shall reset any internal state associated with the port so as to be ready to process from another location within the stream after the flush."
Posted patch reset_decoder_after_eos (obsolete) — Splinter Review
Assignee: nobody → ayang
I found this bug when trying dom/media/mediasource/test/test_BufferingWait_mp4.html.
Do you think the MediaFormatReader should always issue a Flush() command after a drain?

Right now, following a drain, it may simply re-seek in the media and start feeding new data to the decoder.
(In reply to Jean-Yves Avenard [:jya] from comment #3)
> Do you think the MediaFormatReader should always issue a Flush() command
> after a drain?
> 
> Right now, following a drain, it may simply re-seek in the media and start
> feeding new data to the decoder.

Yes, it'd be better IMHO.
1. Refine log
2. call flush after eos
Attachment #8706815 - Flags: review?(sotaro.ikeda.g)
Priority: -- → P2
Comment on attachment 8706815 [details] [diff] [review]
reset_decoder_after_eos

LGTM.
Attachment #8706815 - Flags: review?(sotaro.ikeda.g) → review+
After this patch, all 2015 MSE tests [1] are passed. (you need to press play button in test 20 and 42 due to preload is off on b2g IIRC)

[1] http://yt-dash-mse-test.commondatastorage.googleapis.com/unit-tests/2015.html?timestamp=1452850350917
Attachment #8706815 - Attachment is obsolete: true
Attachment #8708249 - Flags: review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/9f02ddf84813
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla46
You need to log in before you can comment on or make changes to this bug.