Closed
Bug 944615
Opened 11 years ago
Closed 11 years ago
gUM with audio on emulator fails
Categories
(Firefox OS Graveyard :: Emulator, defect)
Tracking
(blocking-b2g:-)
People
(Reporter: slee, Assigned: slee)
References
Details
Attachments
(2 files, 1 obsolete file)
On emulator, when we calling gUM with audio, it fails. Because the mic on emulator only supports 8k audio. GIPS always initialized with 48k on B2G, [1]. [1] http://dxr.mozilla.org/mozilla-central/source/media/webrtc/trunk/webrtc/modules/audio_device/android/opensles_input.cc#314
Updated•11 years ago
|
Blocks: b2g-getusermedia
Assignee | ||
Comment 1•11 years ago
|
||
Making AudioHardwareGeneric supports more sampling frequency.
Attachment #8340947 -
Flags: feedback?(vyang)
Attachment #8340947 -
Flags: feedback?(mwu)
Comment 2•11 years ago
|
||
After enabling this, we might want to consider fixing the gUM mochitests to leverage real devices for audio instead the fake streams. That will get us better test coverage.
Comment 3•11 years ago
|
||
(In reply to StevenLee from comment #1) > Making AudioHardwareGeneric supports more sampling frequency. Note: this patch is to be applied to device/generic/goldfish of 'master' branch. For emulator-jb, a similar thing has to be applied to device/generic/goldfish/audio/audio_hw.c: static size_t in_get_buffer_size(...) { return IN_BUFFER_SIZE; }
Comment 4•11 years ago
|
||
(In reply to Vicamo Yang [:vicamo][:vyang] from comment #3) > static size_t in_get_buffer_size(...) Correct: static size_t adev_get_input_buffer_size(...)
Comment 5•11 years ago
|
||
Comment on attachment 8340947 [details] [diff] [review] patch Review of attachment 8340947 [details] [diff] [review]: ----------------------------------------------------------------- ::: audio/AudioHardwareGeneric.cpp @@ +210,5 @@ > + return 1024*channelCount; > + } else { > + return 512*channelCount; > + } > + } nit: uint32_t bytesPerSample = audio_bytes_per_sample(format); uint32_t samplesPerChannel = 0; if (sampleRate == 8000 || sampleRate == 16000) { samplesPerChannel = sampleRate / 50; } else if (sampleRate >= 44100) { samplesPerChannel = 512; } else { samplesPerChannel = 256; } return samplesPerChannel * channelCount * bytesPerSample; ::: audio/AudioHardwareGeneric.h @@ +134,4 @@ > virtual void closeInputStream(AudioStreamIn* in); > > void closeOutputStream(AudioStreamOutGeneric* out); > + virtual size_t getInputBufferSize(uint32_t sampleRate, int format, int channelCount); nit: align to |closeOutputStream|.
Attachment #8340947 -
Flags: feedback?(vyang) → feedback+
Assignee | ||
Comment 6•11 years ago
|
||
Attachment #8340947 -
Attachment is obsolete: true
Attachment #8340947 -
Flags: feedback?(mwu)
Attachment #8342839 -
Flags: review?(vyang)
Updated•11 years ago
|
Attachment #8342839 -
Flags: review?(vyang) → review+
Assignee | ||
Updated•11 years ago
|
blocking-b2g: --- → koi?
Comment 7•11 years ago
|
||
Please have a pull request to https://github.com/mozilla-b2g/device_generic_goldfish/ :)
Assignee: nobody → slee
Assignee | ||
Updated•11 years ago
|
Assignee: slee → nobody
blocking-b2g: koi? → 1.3?
Assignee | ||
Comment 8•11 years ago
|
||
Assignee | ||
Updated•11 years ago
|
Assignee: nobody → slee
Comment 9•11 years ago
|
||
Plus this one for emulator to better support audio test
blocking-b2g: 1.3? → 1.3+
Updated•11 years ago
|
Comment 10•11 years ago
|
||
As soon as this is pulled and installed, we need to land the test patch from bug 853356 (which is perma-orange without it, since it wants 44100Hz). mwu: any chance of pull/install?
Flags: needinfo?(mwu)
Updated•11 years ago
|
Flags: needinfo?(mwu)
Keywords: checkin-needed
Comment 11•11 years ago
|
||
(In reply to Ivan Tsay (:ITsay) from comment #9) > Plus this one for emulator to better support audio test Tests won't block the release, so this isn't a blocker.
blocking-b2g: 1.3+ → -
Comment 12•11 years ago
|
||
Master: https://github.com/mozilla-b2g/device_generic_goldfish/commit/5be0a9c4b3c6c004786917fdb5bee248960d045b
Status: NEW → RESOLVED
Closed: 11 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 1.3 Sprint 6 - 12/6
You need to log in
before you can comment on or make changes to this bug.
Description
•