ep-413 DSP – week 12

Web Audio API

 

A good place to start

There are many links to Web Audio project right here on this blog: https://reactivemusic.net/?tag=web-audio

Technical reference manual

Comprehensive guide from Mozilla Developer Network https://developer.mozilla.org/en-US/docs/Web/API/Web_Audio_API

Quick tutorial

  • Open a javascript console in a Web browser. This example uses Chrome. From the Chrome menu, select View | Developer | Javascript console
  • Type the following commands (in the shaded blocks) into the console:

Assign an instance of the Web Audio class to the object: context

context = new AudioContext();

Make an oscillator node

osc = context.createOscillator();

Connect the oscillator to the audio output (speaker)

osc.connect(context.destination);

Turn on the oscillator at the current time and plays a tone.

osc.noteOn(0);

Turn of the oscillator

osc.noteOff(0);

For more basics, see: “Using the Web Audio API”, at the Mozilla Developer Network: https://developer.mozilla.org/en-US/docs/Web/API/Web_Audio_API/Using_Web_Audio_API

Basic html examples:

Demonstrated in class. Download from here: https://github.com/tkzic/web-audio-projects

  • Oscillator
  • Audio file player

HTML versions of examples from Boris Smus’s book: https://reactivemusic.net/?p=6094

Examples

Tutorials and references

Development (libraries, frameworks)

tz – examples

Assignment

Write a composition to induce magical effects.

Here is an example from Aseem Suri http://www.aseemsuri.com/journal/piece-of-mind-second-run-at-the-csound-conference 

The project was derived from computer technology, but the overall effect was that people would go into a mysterious room, for a minute, and when they emerged, they would be smiling and happy.

Due on December 15th (last class)

Interval signals online

“Interval signals, signature tunes, airchecks and identification announcementsfrom international, domestic and clandestine radio stations around the world.”

By David Kernick, in cooperation with Documentary Archives Radio Communications

http://www.intervalsignals.net

Radio Burkina: http://www.intervalsignals.net/countries/burkina_faso.htm

Azerbaijan Radio – Radio Respublika: http://www.intervalsignals.net/Files/aze-azr_respublika_281111.m3u

Python web server

Simple command line web server for Mac OS

Run this command, in a terminal window, from any directory:

python -m SimpleHTTPServer 8000

Then you can access web pages in that directory tree. For example, to load a page called index.html (in the same directory) type the following URL into a browser:

http://127.0.0.1:8000/index.html

More information here: http://lifehacker.com/start-a-simple-web-server-from-any-directory-on-your-ma-496425450

 

ep-413 DSP – week 11

Filters

fil5

Analog

fil12

Digital

Other

We usually think of filters in terms of frequency. Any process that removes information is a filter. Curation or abstraction, for example.

Reversability

examples