- From: Glen Shires <gshires@google.com>
- Date: Tue, 11 Sep 2012 03:02:20 -0700
- To: Dominic Mazzoni <dmazzoni@google.com>
- Cc: Hans Wennborg <hwennborg@google.com>, olli@pettay.fi, public-speech-api@w3.org
- Message-ID: <CAEE5bcj4WVyRm37Awnp3X3_LSYyrh803Zkw-GiS4czJAu=V=fA@mail.gmail.com>
I propose the following definitions for the SpeechSynthesis IDL: SpeechSynthesis Attributes pending attribute: This attribute is true if the queue contains any utterances which have not completed playback. speaking attribute: This attribute is true if playback is in progress. paused attribute: **** How is this different than (pending && !speaking) ? **** SpeechSynthesis Methods The speak method This method appends the utterance to the end of a playback queue. If playback is not in progress, it also begins playback of the next item in the queue. The cancel method This method removes the first matching utterance (if any) from the playback queue. If playback is in progress and the utterance removed is being played, playback ceases for the utterance and the next utterance in the queue (if any) begins playing. The pause method This method pauses the playback mid-utterance. If playback is not in progress, it does nothing. The continue method This method continues the playback at the point in the utterance and queue in which it was paused. If playback is in progress, it does nothing. The stop method. This method stops playback mid-utterance and flushes the queue. SpeechSynthesisUtterance attributes text attribute: The text to be synthesized for this utterance. This attribute must not be changed after onstart fires. lang attribute: [no change] serviceURI attribute: [ no change] speaking attribute: This attribute is true if this specific utterance is currently being played back. paused attribute: This attribute is true if this specific utterance is in the queue and has not completed playback. ended attribute: This attribute is true if this specific utterance has completed playback. SpeechSynthesisUtterance events onstart event: Fired when this utterance has begun playback. onend event: Fired when this utterance has completed playback. On Tue, Sep 11, 2012 at 2:58 AM, Glen Shires <gshires@google.com> wrote: > I've updated the spec with the IDL and Examples: > https://dvcs.w3.org/hg/speech-api/rev/ac45dde583b1 > > As always, the current draft spec is at: > http://dvcs.w3.org/hg/speech-api/raw-file/tip/speechapi.html > > > On Mon, Aug 20, 2012 at 7:56 AM, Dominic Mazzoni <dmazzoni@google.com>wrote: > >> On Mon, Aug 20, 2012 at 2:48 AM, Hans Wennborg <hwennborg@google.com> >> wrote: >> > (Which makes me wonder if we should do the same for speech recognition >> too?) >> >> Makes sense! Let's keep them symmetrical either way. >> >> > I wonder if we could come up with a less verbose name than >> > stopAndFlushQueue, but that's just a minor detail. >> >> You could just call is stop() or silence() and add a comment saying it >> flushes the queue. >> >> >>>> attribute DOMString serviceURI; >> > >> > What does serviceURI do in this context? >> >> It should be possible to have multiple utterances that go to different >> speech services - for example two different voices. >> >> - Dominic >> >> >
Received on Tuesday, 11 September 2012 10:03:30 UTC