Sound
Grab the following from my PROJECT directory
- my RUN script - I have altered it to point to the correct sound server, and new sound directory
- sound folder
- sound scenes from scene folder
We use the Bergen Sound Server, note
- Bergen is a the client library (libbergen) and a server (snerd).
- in the RUN script we now start snerd as well as ygdrasil
- snerd can play aiff, aifc and wav files
- default sample rate is 32000
- you can change this by adding -srate to the command in the RUN script
- eg snerd -srate 22050
- you can change this by adding -srate to the command in the RUN script
- sfinfo = command line tool for viewing sound file info
- eg. sfinfo nameoffile
- play = command line tool for listening to sounds
We add Sound Nodes to our scene files, with the following messages:
- file:///home/dms/jranstey/PROJECTS/TRAIL/version4_S07/yg_0.4.1/doc/ygSound.html
- file(nameoffile)
- loop
- play
- stop
- amplitude(float between 0-1)
- NOTE amplitude of sounds playing simultaneously cannot exceed 1
Sound Node has following events:
- start
- stop
- eg. when(stop, someothernode.doSomething)