Skip to content

Repository files navigation

Welcome

To see the final product, visit nvioli.github.io.

Other Versions

There are several other versions containing pieces of the complete functionality, and requiring less code, so that the underlying principles might be more easily understood.

NameDescriptionURLs
Complete demoThe complete implementationLive demo:https://nvioli.github.io
code:https://github.com/nvioli/variations/tree/master/src
Audio testA small test showing how to load and play audio samplesLive demo:https://nvioli.github.io/audiotest.html
code:https://github.com/nvioli/variations/tree/master/src/audiotest
BackgroundA fullscreen version of the visualization only. Click to begin, click again to stop. (May be clipped depending on device / browser dimensions.)Live demo:https://nvioli.github.io/background.html
code:https://github.com/nvioli/variations/tree/master/src/background/
Draw NotesIntroduction visualization showing generation of the notes, but not playing the entire pieceLive demo:https://nvioli.github.io/drawNotes.html
code:https://github.com/nvioli/variations/tree/master/src/drawNotes/
RepeatThe complete implementation without intro material; auto-refreshesLive demo:https://nvioli.github.io/repeat.html
code:https://github.com/nvioli/variations/tree/master/src/repeat/

Running locally

Building and running the local server

$ git clone https://github.com/nvioli/variations.git
$ cd variations
$ npm install
$ npm run dev

This builds the contents of the app into the dist directory, starts a local webserver, and starts a watch task which will re-build the app when you change any file in the src directory. Visit http://localhost:8080 (or any of the pages listed above) to see the piece.

Hosting audio files locally

By default, the audio files are all loaded from Nick's github pages demo. If you want to serve them locally (which is much faster!), download the Sonatina Symphonic Orchestra sample library and extract in to the Samples directory, then change the localSampleLibrary variable in each of the audioUtils.js files to true.

Related

About

An implementation of John Cage's Variations I in the browser, built by Nick Violi in 2017.

Topics

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages