Re: Win32Lib: PlaySound/setVisible solution
- Posted by Dan Moyer <DanMoyer at PRODIGY.NET> Nov 03, 1999
- 554 views
Brian, Oh, ok, I'll give your demo a re-look & re-think! BTW, I have tentativly concluded that the problem with setVisible is really WITH setVisible, not with playSound interacting with it, see my demo in post: Win32Lib: setVisible (true) problem ? The timer I used there, instead of giving setVisible time to finish, actually causes/allows/demos the problem. Dan On Wed, 3 Nov 1999 09:57:50 -0800, Brian K. Broker <bkb at CNW.COM> wrote: >On Wed, 3 Nov 1999, Dan Moyer wrote: > >> I took your demo solution & simplified it, from a "play list" orientation >> into just a "while" test loop of the SND_NOSTOP return (see below for >> snippet), so I could just feed PlaySound a series of wave files & the while >> loop would test to see if the preceding was finished & then when it was it >> would play the next & so forth till it did all of them. (This would be >> simpler to integrate into my application.) > >This is the approach I first took and found that the 'busy-waiting' >produced the same result as SYNC. That's why I took the timer-based >approach. You need to give the system time to think about performing the >setVisible. My approach only requires an additional onTimer routine so I >don't see why this method won't work for you. > ><snip> >-- Brian