Closed
Bug 962878
Opened 11 years ago
Closed 10 years ago
Fix bugs & re-enable test_mediarecorder_record_4ch_audiocontext.html on emulators
Categories
(Core :: Audio/Video: Recording, defect)
Tracking
()
RESOLVED
FIXED
mozilla33
People
(Reporter: jsmith, Assigned: bechen)
References
(Blocks 1 open bug)
Details
Attachments
(2 files, 3 obsolete files)
(deleted),
patch
|
bechen
:
review+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
bechen
:
review+
|
Details | Diff | Splinter Review |
In bug 916135, we managed to get a large amount of content/media mochitests enabled. However, test_mediarecord_4ch_audiocontext.html could not be enabled. We should debug why that test can't be ran cleanly on emulators, fix the issues, and get the test enabled on emulators.
Comment 1•11 years ago
|
||
I will investigate these disabled bugs one by one and try to fix them.
Assignee: nobody → jwwang
Updated•11 years ago
|
Component: Video/Audio → Video/Audio: Recording
Comment 2•11 years ago
|
||
logs: https://tbpl.mozilla.org/php/getParsedLog.php?id=35266509&tree=Try&full=1#error0
01:05:23 INFO - 1764 INFO TEST-START | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html
01:05:23 INFO - 1765 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.start
01:05:23 INFO - 1766 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4521
01:05:23 INFO - 1767 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4322
01:05:23 INFO - 1768 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4300
01:05:23 INFO - 1769 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4295
01:05:58 INFO - 1770 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4237
01:05:58 INFO - 1771 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=4169
01:05:58 INFO - 1772 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=395
01:05:58 INFO - 1773 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.ondataavailable, data.size=0
01:05:58 INFO - 1774 ERROR TEST-UNEXPECTED-FAIL | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | check blob has data
01:05:58 INFO - 1775 INFO TEST-INFO | /tests/content/media/test/test_mediarecorder_record_4ch_audiocontext.html | MediaRecorder.onstop
http://hg.mozilla.org/mozilla-central/file/49191bc5ad7a/content/media/MediaRecorder.cpp
ExtractRunnable::Run()
mSession->Extract() will send 'dataavailable' callback asynchronously if timing condition is met. And the callback will be sent again if mSession->mEncoder->IsShutdown() is false. Therefore it could send 'dataavailable' twice in the last recording run. And you will see the last blob size is zero which will fail the test.
This test will be fixed when bug 956997 is landed.
Depends on: 956997
Comment 3•10 years ago
|
||
Bug 956997 won't be fixed. We still need to fix this bug now.
No longer depends on: 956997
Assignee | ||
Updated•10 years ago
|
Status: NEW → ASSIGNED
Assignee | ||
Comment 5•10 years ago
|
||
Comment 6•10 years ago
|
||
Comment on attachment 8441815 [details] [diff] [review]
bug-962878.patch
Review of attachment 8441815 [details] [diff] [review]:
-----------------------------------------------------------------
Thanks for this patch and it looks good for me.
Remember to change the patch title.
Attachment #8441815 -
Flags: feedback+
Assignee | ||
Updated•10 years ago
|
Assignee | ||
Comment 7•10 years ago
|
||
Obviously the ExtractRunnable::Run will dispatch two successive |PushBlobRunnable| tasks to main thread if
mSession->mEncoder->IsShutdown() is TRUE. And then the second |PushBlobRunnable| task will easily push a blob with no data.
By apply the patch, we can eliminate this case, but essentially we still not resolve the issue "blob must have data" since the testcase written "ok(e.data.size > 0, 'check blob has data');".
It is because the MediaRecorder push a blob with a timeslice, and the MediaStream will be stop unpredictably. Once the MediaRecorder push a blob when meet the timeslice and immediately the MediaStream is stopped, TrackEncoders can not guarantee there is still enough raw data can be encoded and output.
Neither the muxer. Result in the MediaRecorder pwill ush an empty blob.
Assignee | ||
Comment 8•10 years ago
|
||
One more thing done in this patch: Adjust the code flow in Session:Extract because the |mEncoder->GetEncodedData();| should take some times if encoding loading is heavy.
Attachment #8441815 -
Attachment is obsolete: true
Assignee | ||
Comment 9•10 years ago
|
||
Modify the testcase because we can not ensure the blob always has data.
Assignee | ||
Updated•10 years ago
|
Attachment #8443274 -
Flags: review?(roc)
Assignee | ||
Updated•10 years ago
|
Attachment #8443275 -
Flags: review?(rlin)
Attachment #8443275 -
Flags: review?(rlin) → review+
Assignee | ||
Comment 10•10 years ago
|
||
Hi Roc:
Did you finish the review of the patch? Or just press the wrong button r+ on the testcase?
Try server result looks good:
https://tbpl.mozilla.org/?tree=Try&rev=2ea92b35f2b7
Flags: needinfo?(roc)
Attachment #8443274 -
Flags: review?(roc) → review+
Assignee | ||
Comment 11•10 years ago
|
||
r=roc
Attachment #8443274 -
Attachment is obsolete: true
Attachment #8444976 -
Flags: review+
Assignee | ||
Comment 12•10 years ago
|
||
r=roc
Attachment #8443275 -
Attachment is obsolete: true
Attachment #8444977 -
Flags: review+
Assignee | ||
Comment 13•10 years ago
|
||
Hi sheriff:
Please help to check in these two patches.
Thanks.
Flags: needinfo?(roc)
Keywords: checkin-needed
Comment 14•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/7e5778b9a81b
https://hg.mozilla.org/integration/mozilla-inbound/rev/e36cf3ad5704
Keywords: checkin-needed
Comment 15•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/7e5778b9a81b
https://hg.mozilla.org/mozilla-central/rev/e36cf3ad5704
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla33
You need to log in
before you can comment on or make changes to this bug.
Description
•