speechd-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] Update protocols to support tone generation.


From: Christopher Brannon
Subject: [PATCH] Update protocols to support tone generation.
Date: Thu, 21 Oct 2010 17:13:07 -0500

Andrei.Kholodnyi at gmail.com writes:

>    Could you please provide a couple of use cases showing advantages of
>    using tones versus sound icons.

Emacspeak's speech servers use them, and that's the use case I had in mind.
I really can't think of too many advantages over sound icons.

>    how do you plan to generate those tones?

Here's a (very) rough sketch.  It's just a sine wave generator.

#define MULTIPLIER 8192
size_t num_samples = duration * SAMPLE_RATE / MILLISECONDS_PER_SECOND;
size_t i;
double sine_input = 0.0;
  double sine_step = 2 * PI / (SAMPLE_RATE / frequency);
for (i = 0; i < numsamples; i++) {
  samples[i] = (short) (sin(sine_input) * MULTIPLIER);
  sine_input += sine_step;
}

>    How it could be mapped to SSML?

There's no obvious way to do it.  A good candidate would be the src
attribute of the <audio> tag, but how do you represent a tone with a
URI?

-- Chris
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: 
<http://lists.freebsoft.org/pipermail/speechd/attachments/20101021/5b7e053b/attachment-0001.pgp>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]