Closed
Bug 1411535
Opened 8 years ago
Closed 8 years ago
the voice is unnormal when set airpod as output audio device in system settings in macbook
Categories
(Core :: WebRTC: Audio/Video, defect, P2)
Tracking
()
RESOLVED
FIXED
People
(Reporter: xpeng, Assigned: achronop)
References
Details
Attachments
(5 files)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:56.0) Gecko/20100101 Firefox/56.0
Build ID: 20170926190823
Steps to reproduce:
step 1 . set output device to airpod in System Preferences - Sound in macbook
step 2 . click the button "call" and choose airpod in demo : https://webrtc.github.io/samples/src/content/peerconnection/audio/
step 3 . check the vioce heard
step 4. change input device in System Preferences - Sound - Input .
step 5 . check the vioce heard
Actual results:
the result of step 3 : the voice is unnormal or no voice heard.
the result of step 5: the voice is normal
Expected results:
the voice should be normal.
Updated•8 years ago
|
Component: Untriaged → WebRTC: Audio/Video
Product: Firefox → Core
Comment 1•8 years ago
|
||
Just checking that these are the wireless ones? I assume so if you're seeing "airpod" under System Preferences.
Flags: needinfo?(xpeng)
| Assignee | ||
Comment 2•8 years ago
|
||
Thanks for the report. Can you please provide some logs:
export MOZ_LOG=cubeb:5,MediaStreamGraph:4
Updated•8 years ago
|
Assignee: nobody → achronop
Updated•8 years ago
|
Rank: 12
Priority: -- → P2
| Assignee | ||
Comment 4•8 years ago
|
||
There is a clear error in the logs. We cannot render the input:
2017-10-26 08:41:29.125166 UTC - [Unnamed thread 0x121ba8840]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:310: AudioUnitRender rv=-10863
Also the duplex callback reports abnormal values:
2017-10-26 08:41:06.469447 UTC - [Unnamed thread 0x121ba8970]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:443: (0x12a76dc00) output: buffers 1, size 22584, channels 2, frames 2823, total input frames -4109.
Something that would make more sense is what we get in the output only callback:
2017-10-26 08:41:04.509050 UTC - [Unnamed thread 0x173ea7ff0]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:443: (0x11f30a000) output: buffers 1, size 4096, channels 2, frames 512, total input frames 0.
Can you double check that your device is configured correctly? Can you use the your device on a different application as mic?
Can you use a second WebRTC service with your device to verify that you get the same (logs are welcome)? We use the following:
https://mozilla.github.io/webrtc-landing/gum_test.html (audio button)
(In reply to Jan-Ivar Bruaroey [:jib] (needinfo? me) from comment #1)
> Just checking that these are the wireless ones? I assume so if you're seeing
> "airpod" under System Preferences.
we checked usb audio device ,it's ok . other wireless device also has this problem.
(In reply to Alex Chronopoulos [:achronop] from comment #4)
> There is a clear error in the logs. We cannot render the input:
>
> 2017-10-26 08:41:29.125166 UTC - [Unnamed thread 0x121ba8840]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:310:
> AudioUnitRender rv=-10863
>
> Also the duplex callback reports abnormal values:
>
> 2017-10-26 08:41:06.469447 UTC - [Unnamed thread 0x121ba8970]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:443:
> (0x12a76dc00) output: buffers 1, size 22584, channels 2, frames 2823, total
> input frames -4109.
>
> Something that would make more sense is what we get in the output only
> callback:
>
> 2017-10-26 08:41:04.509050 UTC - [Unnamed thread 0x173ea7ff0]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:443:
> (0x11f30a000) output: buffers 1, size 4096, channels 2, frames 512, total
> input frames 0.
>
> Can you double check that your device is configured correctly? Can you use
> the your device on a different application as mic?
>
> Can you use a second WebRTC service with your device to verify that you get
> the same (logs are welcome)? We use the following:
> https://mozilla.github.io/webrtc-landing/gum_test.html (audio button)
it's the same problem, the log has been uploaded : log_gum_test.txt
| Assignee | ||
Comment 8•8 years ago
|
||
Second log is good, it does not have the render issue. Are you sure it is captured using the "bad" device?
| Reporter | ||
Comment 10•8 years ago
|
||
| Assignee | ||
Comment 11•8 years ago
|
||
Something is wrong with the device sampling rate. On the last log call is started using 44100 and at the end it is 8000:
2017-10-27 09:01:00.364632 UTC - [CubebOperation #1]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203: (0x1284eac00) Output device sampling rate: 44100.00
2017-10-27 09:01:01.078718 UTC - [CubebOperation #1]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203: (0x132204000) Output device sampling rate: 44100.00
2017-10-27 09:01:20.669698 UTC - [CubebOperation #2]: E/cubeb /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203: (0x126f89c00) Output device sampling rate: 8000.00
That explains the "abnormal" values in output callback which are making sense now.
In log_gum_test.txt the call is configured with sample rate of 8000 from the beginning and I do not see the error. Can you mention if log_gum_test.txt is captured from a working case?
A way to check your device sampling rate is to go to 'Applications -> Utilities -> Audio MIDI Setup'. Start by setting your device at 44100, make a call, if the call is bad can you check the sampling rate? I would expect to be 8000 according to the logs.
Can you please mention your device? Is it the wireless airpod mentioned by jib in an earlier comment? If yes I could buy it in an hour or so and try it myself.
PS. AudioUnitRender rv=-10863 is error kAudioUnitErr_CannotDoInCurrentContext
| Reporter | ||
Comment 12•8 years ago
|
||
(In reply to Alex Chronopoulos [:achronop] from comment #11)
> Something is wrong with the device sampling rate. On the last log call is
> started using 44100 and at the end it is 8000:
>
> 2017-10-27 09:01:00.364632 UTC - [CubebOperation #1]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203:
> (0x1284eac00) Output device sampling rate: 44100.00
>
> 2017-10-27 09:01:01.078718 UTC - [CubebOperation #1]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203:
> (0x132204000) Output device sampling rate: 44100.00
>
> 2017-10-27 09:01:20.669698 UTC - [CubebOperation #2]: E/cubeb
> /home/worker/workspace/build/src/media/libcubeb/src/cubeb_audiounit.cpp:2203:
> (0x126f89c00) Output device sampling rate: 8000.00
>
> That explains the "abnormal" values in output callback which are making
> sense now.
>
> In log_gum_test.txt the call is configured with sample rate of 8000 from the
> beginning and I do not see the error. Can you mention if log_gum_test.txt is
> captured from a working case?
yes it's the same case.
>
> A way to check your device sampling rate is to go to 'Applications ->
> Utilities -> Audio MIDI Setup'. Start by setting your device at 44100, make
> a call, if the call is bad can you check the sampling rate? I would expect
> to be 8000 according to the logs.
>
> Can you please mention your device? Is it the wireless airpod mentioned by
> jib in an earlier comment? If yes I could buy it in an hour or so and try it
> myself.
we tried other wireless device like HM1200 to reproduce the issue , it's the same problem.
>
> PS. AudioUnitRender rv=-10863 is error kAudioUnitErr_CannotDoInCurrentContext
| Reporter | ||
Comment 13•8 years ago
|
||
Case 1:
set output/input device to airpod in System Preferences - Sound in macbook
Step 1) : set the airpod's format to : 44100 hz 2ch-32bit Float in Audio MIDI SetUp.
Step 2) : use the demo to test audio using airpod : https://mozilla.github.io/webrtc-landing/gum_test.html
check the format of airpod in Audio MIDI SetUp : it has been reset to 8000 hz 1ch-16bit Integer (it's same in firefox and chrome)
Result : no voice in speaker in firefox . it works fine in chrome
Step 3): Quit the browse(firefox/chrome)
check the format of airpod in Audio MIDI SetUp soon later : it has been reset to 44100 hz 2ch-32bit Float (it's same in firefox and chrome)
log file (firefox): log_44100.txt
Case 2:
set output/input device to airpod in System Preferences - Sound in macbook
Step 1) : set the airpod's format to : 8000 hz 1ch-16bit Integer in Audio MIDI SetUp.
Step 2) : use the demo to test audio using airpod : https://mozilla.github.io/webrtc-landing/gum_test.html
check the format of airpod in Audio MIDI SetUp : it 's 8000 hz 1ch-16bit Integer (it's same in firefox and chrome)
Result : no voice in speaker in firefox . it works fine in chrome
Step 3): Quit the browse(firefox/chrome)
check the format of airpod in Audio MIDI SetUp soon later : it has been reset to 44100 hz 2ch-32bit Float (it's same in firefox and chrome)
log file (firefox): log_8000.txt
| Reporter | ||
Comment 14•8 years ago
|
||
| Reporter | ||
Comment 15•8 years ago
|
||
| Assignee | ||
Comment 16•8 years ago
|
||
Thanks for the detailed description. I bought the device and I repro the issue. I'll come up with an update soon.
| Assignee | ||
Updated•8 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
| Assignee | ||
Comment 17•8 years ago
|
||
Workaround:
In the Audio MIDI Setup tool you must have two entries for airpod device, one for input and one for output. Go to _both_ entries and set format to: 8000Hz 1ch-16bit Integer. This one is working here. Note that output's format is updated at the end calls to 44.1KH, 2 ch 32-bit Float.
Also, my device has 16000Hz as minimum rate which is something different from yours. In addition, input airpod offers only one format (Audio MIDI Setup tool). No option to change it. Is that the same with your device?
| Reporter | ||
Comment 18•8 years ago
|
||
(In reply to Alex Chronopoulos [:achronop] from comment #17)
> Workaround:
> In the Audio MIDI Setup tool you must have two entries for airpod device,
> one for input and one for output. Go to _both_ entries and set format to:
> 8000Hz 1ch-16bit Integer. This one is working here. Note that output's
> format is updated at the end calls to 44.1KH, 2 ch 32-bit Float.
>
> Also, my device has 16000Hz as minimum rate which is something different
> from yours. In addition, input airpod offers only one format (Audio MIDI
> Setup tool). No option to change it. Is that the same with your device?
we do not have 16000Hz ; input airpod offers only one format : 8000Hz
| Assignee | ||
Comment 19•8 years ago
|
||
| Assignee | ||
Comment 20•8 years ago
|
||
Can you please test this build for me:
https://queue.taskcluster.net/v1/task/IuQzrRfiSD6KoRMfcx4J8w/runs/0/artifacts/public/build/target.dmg
It works here. Please keep the airpods on your ears during the call, there is a problem otherwise. Don't worry about that I have fixed it locally. Just tell me if the audio through the airpods is good for you.
| Assignee | ||
Updated•8 years ago
|
Flags: needinfo?(xpeng)
| Reporter | ||
Comment 21•8 years ago
|
||
the first time I use the nightly version , it does not work and crashes several times. but after I restart the nightly , it all works fine.
Flags: needinfo?(xpeng)
| Assignee | ||
Comment 22•8 years ago
|
||
Fix pushed for review https://github.com/kinetiknz/cubeb/pull/377
| Assignee | ||
Comment 23•8 years ago
|
||
Fixed by Bug 1420930
| Assignee | ||
Updated•8 years ago
|
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•