No audio indicator when using speechSynthesis.speak() with indirect audio

RESOLVED FIXED in Firefox 43

Status

()

Core
DOM
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: m_kato, Assigned: m_kato)

Tracking

Trunk
mozilla43
Unspecified
Windows
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox42 affected, firefox43 fixed)

Details

Attachments

(3 attachments)

nsSpeechTask has to use nsIAudioChannelAgent to notify audio indicator.

Env
Windows 8.1 (Web Speech Synthesis backend is only implemented on Windows)

Step
1. media.webspeech.synth.enabled=true on about:config and restart
2. Browser http://html5-examples.craic.com/google_chrome_text_to_speech.html
3. Click [Speak] in Demo 1:

Result
no audio indicator on current tab

Expected Result
Show audio indicator on current tab
nsSpeechTask should have nsIAudioChannelAgentCallback interface for audio indicator.  So add dependency bug
Depends on: 1191814
Created attachment 8652174 [details] [diff] [review]
Part 1. Add onVolumeChanged method to nsISpeechTaskCallback
Assignee: nobody → m_kato
Created attachment 8652175 [details] [diff] [review]
Part 2. Call onVolumeChanged when changing volume
Comment on attachment 8652174 [details] [diff] [review]
Part 1. Add onVolumeChanged method to nsISpeechTaskCallback

add onVolumeChanged method to change volume after starting speak.
Attachment #8652174 - Flags: review?(eitan)
Comment on attachment 8652175 [details] [diff] [review]
Part 2. Call onVolumeChanged when changing volume

When WindowVolumeChanged is called, we should change volume on indirect service, too.
Attachment #8652175 - Flags: review?(eitan)
Comment on attachment 8652174 [details] [diff] [review]
Part 1. Add onVolumeChanged method to nsISpeechTaskCallback

Review of attachment 8652174 [details] [diff] [review]:
-----------------------------------------------------------------

This is great! How about a test?

::: dom/media/webspeech/synth/nsISpeechService.idl
@@ +30,5 @@
>     */
>    void onCancel();
> +
> +  /**
> +   * The user or applicatioln has changed the volume of this speech.

typo, application.
Attachment #8652174 - Flags: review?(eitan) → review+
Comment on attachment 8652175 [details] [diff] [review]
Part 2. Call onVolumeChanged when changing volume

Review of attachment 8652175 [details] [diff] [review]:
-----------------------------------------------------------------

Not sure why this is a separate patch, but this is good too.
Attachment #8652175 - Flags: review?(eitan) → review+
Created attachment 8652708 [details] [diff] [review]
Part 3. Call NotifyStartedPlaying to show audio indicator
Comment on attachment 8652708 [details] [diff] [review]
Part 3. Call NotifyStartedPlaying to show audio indicator

I forget additional fix.

I think that bug 1191814's fix is still incorrect.  To show audio indicator, we have to call NotifyStartedPlaying().

Also, WindowVolumeChanged() has a bug (see bug 1197673), so to work correctly, we have to apply it too.
Attachment #8652708 - Flags: review?(eitan)
Attachment #8652708 - Flags: review?(eitan) → review+

Comment 10

2 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/cf29589b47c8
https://hg.mozilla.org/integration/mozilla-inbound/rev/c55b38a5ee09
https://hg.mozilla.org/integration/mozilla-inbound/rev/c92a7a24d757
https://hg.mozilla.org/mozilla-central/rev/cf29589b47c8
https://hg.mozilla.org/mozilla-central/rev/c55b38a5ee09
https://hg.mozilla.org/mozilla-central/rev/c92a7a24d757
Status: NEW → RESOLVED
Last Resolved: 2 years ago
status-firefox43: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
Depends on: 1212366
Depends on: 1214149
You need to log in before you can comment on or make changes to this bug.