----- Original Message -----
From: "Richter Decorações Ltda" <[EMAIL PROTECTED]>
To: "Multiple recipients of list delphi" <[EMAIL PROTECTED]>
Sent: Wednesday, December 13, 2000 3:59 AM
Subject: Re: [DUG]: Playing a string

Thanks, Corey

All you wrote is real, only my Delphi experience isn't.
 
What?  With a surname like that, I'd have thought Delphi was in the blood!!
If you have a code to do your suggestion, i'll be very happy.

TIA

Joao Alberto Licht Teixeira


----- Original Message -----
From: Corey Murtagh <
[EMAIL PROTECTED]>
To: Multiple recipients of list delphi <
[EMAIL PROTECTED]>
Sent: Tuesday, December 12, 2000 2:46 AM
Subject: Re: [DUG]: Playing a string


João Alberto wrote:
>
> I wrote a peace of code that do this :
>
> 1 - The user writes a number
> 2 - That number is converted to its soundable equivalent
> 3 - The resulting string is broken in peaces of text
> 4 - To each peace of text we have a file named 'PeaceOfText.Wav', like
>     ONE.WAV, HUNDRED.WAV, CENT.WAV, CENTS.WAV and so.
> 5 - This several 'PeacesOfText.wav' are loaded to a
>     MediaPlayer's FileName Property and then played

There's part of the problem right there.  Using the media player for
anything more complex than playing a single sound is A Bad Idea(tm) in my
opionion.

Have a look at the waveOutXxx functions in the multimedia API.  It's not
that difficult to get a sound playing through the APIs, and it'll sound a
hell of a lot better.  When you go direct to the API you get a lot more
control - like being able to pre-queue a list of wavs rather than waiting on
one to end before loading the next.


Another option is to create a temporary wav file by concatenating the sound
pieces together to create a file containing the entire string.  This is a
little simpler than handling waveOut yourself, and should give approximately
the same results.

--
Corey Murtagh
The Electric Monk
"Quidquid latine dictum sit, altum viditur!"
---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List -
[EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"


---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List -
[EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED]
with body of "unsubscribe delphi"

Reply via email to