Prototyping 19 November 2012: Difference between revisions

From XPUB & Lens-Based wiki
No edit summary
No edit summary
Line 1: Line 1:
[http://prototypingfutures.net/aa/resources/2/ The origin and theory of the cut-up, annotated audio], [http://www.ubu.com/papers/burroughs_gysin.html essay on ubuweb].
[http://prototypingfutures.net/aa/resources/2/ The origin and theory of the cut-up, annotated audio], [http://www.ubu.com/papers/burroughs_gysin.html essay on ubuweb].


Shuffle function... stackoverflow!
== Shuffle ==


Double Hot Seat ?
Javascript doesn't include a built-in function to shuffle an array, but there are lots of "recipes" to do it.


> Possible example of [http://hackaday.com/2011/05/29/hidden-device-distorts-news-on-wireless-networks-brews-beer-is-time-machine/ NewsTweek][https://vimeo.com/18637790 video]
For instance: http://stackoverflow.com/questions/6274339/how-can-i-shuffle-an-array-in-javascript
 
<source lang="javascript">
var shuffle = function (o) {
    for (var j,x,i=o.length; i; j=parseInt(Math.random()*i), x=o[--i], o[i] = o[j], o[j] = x);
    return o;
}
</source>


== Audio cut-up ==
== Audio cut-up ==

Revision as of 11:48, 19 November 2012

The origin and theory of the cut-up, annotated audio, essay on ubuweb.

Shuffle

Javascript doesn't include a built-in function to shuffle an array, but there are lots of "recipes" to do it.

For instance: http://stackoverflow.com/questions/6274339/how-can-i-shuffle-an-array-in-javascript

var shuffle = function (o) {
    for (var j,x,i=o.length; i; j=parseInt(Math.random()*i), x=o[--i], o[i] = o[j], o[j] = x);
    return o;
}

Audio cut-up

  • HTML5 media events (timeupdate, durationchange, seeked)

Headline scrambler

  • DOM (childNodes, nodeType, nodeValue, nodeName?)
  • Recursive tree / search

Example of "walking the tree"