|
|
The Sound Server FAQ UPDATE Feb 21, 2004
It wants NDS sound
files (or own invention, we have a reason, maybe?. They are 22050Hz sampling
rate and 16 bit and may contain any number of channels.
First you have to
make sure, that your files use 22050 Hz sampling rate and 16 bit. Many sound
files you’ll find out there in the world-wild spaghetti bowl will be something
else. So you need to make sure, that you convert the format first. A good
program to do this is Goldwave (http://www.goldwave.com).
Well, first load the
sound file you want to convert. Then make sure, that the sample rate is 22050.
For that you should click on menu "Effects/Resample? and change it to
22050. Then "Save as? and select "Save as type:" to be "Sun
(*.au)" and "File attributes:" to be "16-bit, mono, signed,
byte-swapped" and save it. Goldwave can do a lot more for you, like
trimming and manipulating your sounds. (Check out all those fun toys in
"Effects".
Then you need to
convert your file to NDS format. Run the command-line program snd2nds on your
file. Should look like this: snd2nds
yourfilename.au yourfilename.nds
The default place,
the sound server looks for files is a directory on the server machine, but
you’re probably shouldn’t save your files there. Instead you should just put
them into: "S:\DisplayWall\Sounds\cs495\" where S:\ is
hopefully mapped to \\newfs\shrimpNT. There are already a few sound examples in "S:\DisplayWall\Sounds\cs495\examples".
Try: playsound S:\DisplayWall\Sounds\cs495\mysound.nds playsound will play
your sound file on the sound server. If the file is stereo, the left channel is
mapped to all the left speakers and the right channel to all the right. Both
channels go into the sub-woofers. Of the sound file is something else (mono or
more than 2 channels) the first channel will be played in all speakers.
This is more tricky.
You’ll have to create a sound-table file (just a simple text file) that
contains the following line for each sound file you want to play: mysoundfile.nds
<volume> <map1> <map2> ?/P> Where <volume>
is a number between 0.0 and 1.0 (silence to loud). And <mapN> maps
this sound file into the speaker with this mapping number. You can play the
sound table by using: playsoundtable S:\DisplayWall\Sounds\mysoundtable.txt
Grab them from this
picture:
(This
picture was adapted from a picture by Perry Cook.)
Well, you might look into S:\DisplayWall\Sounds\sources\.
There is example programs in there which use the NDSoundServerStub-interface to
the sound server. If you have some C or C++, you might just be able to do (your
favorite fancy idea). You can also bug me (gessl@cs.princeton.edu). Where do I get a more technical background? Just read on?/P> What if I don’t want that background? Stop reading here! (Continue on webpage: displayw.html#SoundServer) |
|
last edited 04/28/2008 |