Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!asuvax!mcdphx!hrc!gtephx!corfmanr From: corfmanr@gtephx.UUCP (Russ Corfman) Newsgroups: comp.windows.ms.programmer Subject: Sound/Music in Windows Apps Keywords: SetVoice Message-ID: <199@maillot_.gtephx.UUCP> Date: 12 Feb 91 20:50:19 GMT Organization: gte Lines: 43 I want to start writing some windows applications that make use of the speaker. I'm planning on starting off with something simple like a cuckoo clock/alarm clock. I've read what is in the reference manual for all the music/sound functions such as SetVoiceNote, SetVoicePitch, OpenSound, etc. I am left with a number of questions. 1. How does windows allocate the sound resource? I know that there is only one speaker so I assume only one application can be using it at a time. How does that application reserve the speaker? How does the application know if the speaker is already being used? 2. Voice queues are used to place different notes and frequencies and such in. In one of the function descripions in the reference manual, it said the first queue is queue "1". How many voice queues can there be? Is it unlimited? Another question, are the queues a system wide resource such as timers or are they just a single application's resource? 3. I could more or less follow what the documentation meant for (how to use) functions such as SetVoiceNote and SetVoicePitch, but I was lost on how to use SetVoiceFrequency. Is there an easy way to figure out how the passed frequencies affect the sound? I guess a table of what frequencies to use for common sounds such as sirens or bubbling water would be nice. Something to point me in the right direction. 4. The "Guide to Programming" and "Programming Windows" by Petzold have no mention or examples of making sounds. Does anybody know of a book or article that discusses this topic? Some example source code would be very helpful too. Thanks, -- Russell Corfman AG Communication Systems; Phoenix, AZ UUCP: ...!{ncar!noao!asuvax | uunet!zardoz!hrc}!gtephx!corfmanr Internet: gtephx!corfmanr@asuvax.eas.asu.edu (602) 581-4403