Re: life of audio thread

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



I have removed it from my testing and from any idea of keeping it. Thanks,
Alexander.
--------------
"Alexander Grigoriev" <alegr@xxxxxxxxxxxxx> wrote in message
news:Oz7wyRBwGHA.1512@xxxxxxxxxxxxxxxxxxxxxxx
SuspendThread cannot be used reliably for any synchronization. It's only a
debugging function.

"Chris P. [MVP]" <msdn@xxxxxxxxxxxx> wrote in message
news:fb3n0jrs3sed$.1ngd9w8g4z45b.dlg@xxxxxxxxxxxxx
On Sat, 12 Aug 2006 10:15:43 -0400, Steve Russell wrote:

Now I am (apparently) successfully running both my single buffer waveOut
and
my double buffer streaming waveOut by calling ResumeThread within the
while
loop of their respective pesistent threads. Is this technique
inherently a
mistake, or is it about as good as any other?

I don't know if I would bother with SuspendThread. My preference is to
have the thread block while it is waiting for work through an event, i.e.
WaitForSingleObject().

Creating the thread each time isn't necessarily a problem, but it can
cause
a very slight delay. The Windows PlaySound() method creates a thread
each
time you call it in non-blocking mode.

--
http://www.chrisnet.net/code.htm
http://www.avdevforum.com/AV




.