Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Issue 6597071: Add a noise indicator to the speech bubble volume indicator. (Closed)

Created:
9 years, 9 months ago by Satish
Modified:
9 years, 7 months ago
Reviewers:
hans, bulach, jam
CC:
chromium-reviews
Visibility:
Public.

Description

Add a noise indicator to the speech bubble volume indicator. The noise indicator is drawn as a light blue area at the beginning and if there was clipping that is denoted with a red area at the end of the meter. The noise level comes from the endpointer -> SpeechRecognizer -> SpeechInputBubbleController -> SpeechInputBubble hence a bunch of volume setting methods are updated with the new parameter. I have also added a new utility method to SpeechInputManager to invoke the platform provided microphone settings UI, this will be used in the next CL which contains windows, mac and linux specific UI changes. BUG=69886 TEST=manual, invoke speech input and check the bubble volume indicator to see background noise and clipping. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=76395

Patch Set 1 : . #

Total comments: 15

Patch Set 2 : Addressed all review comments. #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+151 lines, -55 lines) Patch
M chrome/app/theme/theme_resources.grd View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/speech/speech_input_bubble.h View 1 5 chunks +10 lines, -3 lines 0 comments Download
M chrome/browser/speech/speech_input_bubble.cc View 1 4 chunks +27 lines, -21 lines 0 comments Download
M chrome/browser/speech/speech_input_bubble_controller.h View 2 chunks +3 lines, -2 lines 0 comments Download
M chrome/browser/speech/speech_input_bubble_controller.cc View 3 chunks +11 lines, -9 lines 0 comments Download
M chrome/browser/speech/speech_input_manager.cc View 1 4 chunks +21 lines, -3 lines 2 comments Download
M content/browser/speech/endpointer/endpointer.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M content/browser/speech/endpointer/energy_endpointer.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M content/browser/speech/endpointer/energy_endpointer.cc View 1 2 chunks +13 lines, -5 lines 0 comments Download
M content/browser/speech/speech_input_manager.h View 1 chunk +4 lines, -0 lines 0 comments Download
M content/browser/speech/speech_recognizer.h View 1 chunk +3 lines, -2 lines 0 comments Download
M content/browser/speech/speech_recognizer.cc View 1 2 chunks +36 lines, -7 lines 0 comments Download
M content/browser/speech/speech_recognizer_unittest.cc View 1 5 chunks +16 lines, -3 lines 0 comments Download

Messages

Total messages: 10 (0 generated)
Satish
9 years, 9 months ago (2011-03-01 16:14:47 UTC) #1
Satish
http://codereview.chromium.org/6597071/diff/1013/content/browser/speech/speech_recognizer_unittest.cc File content/browser/speech/speech_recognizer_unittest.cc (right): http://codereview.chromium.org/6597071/diff/1013/content/browser/speech/speech_recognizer_unittest.cc#newcode90 content/browser/speech/speech_recognizer_unittest.cc:90: audio_packet_[i] = static_cast<uint8>(base::RandInt(0, 50)); Please ignore this part, I ...
9 years, 9 months ago (2011-03-01 16:44:17 UTC) #2
hans
lgtm barring green try bots http://codereview.chromium.org/6597071/diff/1013/chrome/browser/speech/speech_input_bubble.h File chrome/browser/speech/speech_input_bubble.h (right): http://codereview.chromium.org/6597071/diff/1013/chrome/browser/speech/speech_input_bubble.h#newcode157 chrome/browser/speech/speech_input_bubble.h:157: void DrawVolumeOverlay(SkCanvas& canvas, SkBitmap* ...
9 years, 9 months ago (2011-03-01 17:25:25 UTC) #3
bulach
LGTM a few comments and suggestions below, and of course, make the bots deterministically happy! ...
9 years, 9 months ago (2011-03-01 17:39:04 UTC) #4
Satish
Thanks for the quick reviews. I have addressed all comments in the latest patch and ...
9 years, 9 months ago (2011-03-01 18:12:06 UTC) #5
jam
http://codereview.chromium.org/6597071/diff/15/chrome/browser/speech/speech_input_manager.cc File chrome/browser/speech/speech_input_manager.cc (right): http://codereview.chromium.org/6597071/diff/15/chrome/browser/speech/speech_input_manager.cc#newcode189 chrome/browser/speech/speech_input_manager.cc:189: // processes, do that in the PROCESS_LAUNCHER thread to ...
9 years, 9 months ago (2011-03-01 19:49:11 UTC) #6
Satish
http://codereview.chromium.org/6597071/diff/15/chrome/browser/speech/speech_input_manager.cc File chrome/browser/speech/speech_input_manager.cc (right): http://codereview.chromium.org/6597071/diff/15/chrome/browser/speech/speech_input_manager.cc#newcode189 chrome/browser/speech/speech_input_manager.cc:189: // processes, do that in the PROCESS_LAUNCHER thread to ...
9 years, 9 months ago (2011-03-01 20:31:21 UTC) #7
jam
On Tue, Mar 1, 2011 at 12:31 PM, <satish@chromium.org> wrote: > > > http://codereview.chromium.org/6597071/diff/15/chrome/browser/speech/speech_input_manager.cc > ...
9 years, 9 months ago (2011-03-01 20:43:50 UTC) #8
Satish
> Does it return right away? What if the binary is large, dlls aren't loaded ...
9 years, 9 months ago (2011-03-01 21:01:35 UTC) #9
jam
9 years, 9 months ago (2011-03-01 21:38:13 UTC) #10
On Tue, Mar 1, 2011 at 1:01 PM, <satish@chromium.org> wrote:

> Does it return right away?  What if the binary is large, dlls aren't loaded
>> etc, does it wait on all that before returning?  If so, better to use FILE
>> thread instead, and to keep PROCSS_LAUNCHER responsive in case the user
>> opens another tab.  PROCESS_LAUNCHER is meant to launch only chrome
>> processes.  For launching files (i.e. download shelf), we use the FILE
>> thread.
>>
>
> I use base::LaunchApp() to start the external process. On windows I see
> that
> uses CreateProcess which supposedly returns before the process
> initialization
> happens. However if PROCESS_LAUNCHER is for launching chrome processes
> only,
> I'll change the code to use the FILE thread instead. Thanks for the
> suggestion.


Thanks.  I'll update browser_thread.h to make this point clear.

On Windows, the average time to load a Chrome process was ~50ms, and on
Linux it sometimes went up to nearly 1s the first time.


>
>
> http://codereview.chromium.org/6597071/
>

Powered by Google App Engine
This is Rietveld 408576698