Back

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
  • 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:

Sound Node has following events:

  • start
  • stop
    • eg. when(stop, someothernode.doSomething)