Closed
Bug 1264195
Opened 9 years ago
Closed 9 years ago
SetMicrophoneActive() call was lost in GraphDriver landing
Categories
(Core :: Audio/Video: MediaStreamGraph, defect, P1)
Tracking
()
RESOLVED
FIXED
mozilla48
People
(Reporter: jesup, Assigned: jesup)
References
Details
Attachments
(3 files)
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
Details | Diff | Splinter Review | |
(deleted),
patch
|
padenot
:
review+
|
Details | Diff | Splinter Review |
In Bug 848954 - Part 10 (which actually inserted the GraphDriver into use - initial landing of the GraphDriver), it removed the SetMicrophoneActive() calls from UpdateStreamOrder(). The patch 22 of that bug, it added SetMicrophoneActive() to the Graphdriver code -- but it didn't add the call to it back into MSG.
Thus we've lost the "PanOutput" functionality we added for MacbookPro's to avoid audio coming out the speaker immediately underneath the microphone. In a AEC trace in speakerphone mode, I saw an echo of -5 to -10 db with maybe 50-70% volume - and an output signal of -5 db. When I talked, the mic saw it as about -15-20 db, so the echo was at least 8-10x stronger than my speaking - and volume was well below max. When I manually panned to the right speaker, the echo went to -25-35db, or a good 20-25db lower raw echo, or perhaps 100-150x lower volume.
Assignee | ||
Updated•9 years ago
|
Assignee: nobody → rjesup
Rank: 10
Assignee | ||
Comment 1•9 years ago
|
||
This patch only works in full-duplex mode; it may need to be tied to the mixer callbacks as it was before GraphDriver landed, at least if full_duplex is off
Assignee | ||
Comment 2•9 years ago
|
||
untested patch to maintain mMicrophoneActive across multiple drivers; should work for non-full-duplex unless there's a problem calling PanOutput before we Start() the driver (there may be - if so, we can defer until after Start)
Assignee | ||
Updated•9 years ago
|
Attachment #8740801 -
Flags: feedback?(padenot)
Assignee | ||
Updated•9 years ago
|
Attachment #8740808 -
Flags: feedback?(padenot)
Comment 3•9 years ago
|
||
Comment on attachment 8740801 [details] [diff] [review]
WIP patch to add SetMicrophoneActive
Review of attachment 8740801 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/media/GraphDriver.cpp
@@ +659,5 @@
> NextDriver()->Start();
> return;
> }
> }
> + SetMicrophoneActive(mGraphImpl->mInputWanted);
Hrm why are a bunch of attributes of the MSGImpl public? In any case, this should be a method that asserts that you're on the right thread.
Attachment #8740801 -
Flags: feedback?(padenot)
Comment 4•9 years ago
|
||
Comment on attachment 8740808 [details] [diff] [review]
WIP patch to add SetMicrophoneActive for non-full_duplex
Review of attachment 8740808 [details] [diff] [review]:
-----------------------------------------------------------------
::: dom/media/GraphDriver.cpp
@@ +59,5 @@
> mWaitState(WAITSTATE_RUNNING),
> mCurrentTimeStamp(TimeStamp::Now()),
> mPreviousDriver(nullptr),
> + mNextDriver(nullptr),
> + mMicrophoneActive(false)
I'd prefer querying the graph state each time, duplicating state leads to errors.
@@ +1104,5 @@
> +GraphDriver::SetMicrophoneActive(bool aActive) {
> + MonitorAutoLock mon(mGraphImpl->GetMonitor());
> +
> + mMicrophoneActive = aActive;
> +}
Can we just get the state from the graph to when we're ::Init-ing an AudioCallbackDriver ? I think that would be less code and would work.
Attachment #8740808 -
Flags: feedback?(padenot)
Assignee | ||
Comment 5•9 years ago
|
||
Updated (simpler) patch to use the far-end-observer state to know if we should pan or not. Added a graph-thread assertion as well. Also made the MicrophoneActive code mac-only since nothing else (currently) cares. We may be able to avoid the device-changed stuff if full-duplex is on, but that's a separate issue
Attachment #8740979 -
Flags: review?(padenot)
Updated•9 years ago
|
Attachment #8740979 -
Flags: review?(padenot) → review+
Assignee | ||
Updated•9 years ago
|
status-firefox46:
--- → wontfix
status-firefox47:
--- → affected
Comment 7•9 years ago
|
||
Backed out for "/home/worker/workspace/build/src/dom/media/GraphDriver.h:536:8: error: private field 'mMicrophoneActive' is not used [-Werror,-Wunused-private-field]"
Backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/af97159979d24895030137be678cbfd5beea681c
Push with failure: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=53f96832a304865e2416b703bdd507f1d90efe24
Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=25732703&repo=mozilla-inbound
Flags: needinfo?(rjesup)
Assignee | ||
Updated•9 years ago
|
Flags: needinfo?(rjesup)
Comment 9•9 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla48
You need to log in
before you can comment on or make changes to this bug.
Description
•