giovannibedetti / bach_stress_test

a p5.js experiment with Web Audio API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bach Stress Test

code: http://www.giovannibedetti.com/ illustration: https://www.behance.net/monocolo

README!

This is a stress test (originally written for Processing) for p5.js and Web Audio API. At mouse click the image will be divided in 4 images. Also the audio file will be split in 4 parts and these will be played together. Parts 1 and 3 will play forward, while parts 2 and 4 will play backwards.

You'll see and hear 1, 4, 16, 64, 256, 1024 images and sounds together. (256 seems to be the highest value on Chrome 55.0.2883.95 64-bit)

The theme is the famous J.S. Bach canon 1 à 2 from the "Musical Offering" (1747) This piece is a "crab canon", so it can be played at the same time forward and backward. See here (http://www2.nau.edu/tas3/MOcancrizans.pdf) for the full story. This test was made just to find out if it can be combined in other ways.

Check out the magic of math.

Desktop only: for your pleasure you can stop the sounds pressing ’p’, and enable/disable the random image change pressing 's'.

Warning: as I said, this is a stress test. Try it at your own risk! (your browser can hang a little bit)

If your browser supports Web Audio API, you will hear the full Bach theme on load. On iOS devices, this could not be true, because autoplay is disabled.

02/2015

About

a p5.js experiment with Web Audio API


Languages

Language:JavaScript 73.4%Language:HTML 26.6%