grains.rst 5.62 KB
Newer Older
1
:title: Grains - we are sounds in the Universe
2
:data-transition-duration: 1000
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
:css: css/grains.css

----

:id: title

Grains
======

We are sounds in the universe
-----------------------------

* Dragica Kahlina (@gluggergames)
* Jens-Christian Fischer (@jcfischer)


19 20
----

21 22 23 24
:data-scale: 0.15
:data-x: r0
:data-y: r0

25 26 27 28 29 30 31 32 33
What & Why
==========

How far can we take the *Web Programming*, *Synthesis* and *Free
Improvisation*


----

34 35
Feedback
========
36

37 38
The Feedback between performer and audience is key to a musical
performance.
39

40
What happens when you as the audience really participate?
41

42 43 44 45
----

But first
---------
46

47 48
a bit of theory
===============
49

50 51 52 53 54
----

Sound Synthesis
===============

dkah's avatar
dkah committed
55 56 57

----

dkah's avatar
dkah committed
58 59 60 61 62
Additive
========

* 1822 Joseph Fourier showed that some functions can be written as a sum of sines
* Using harmonics we can build up a variety of timbres
dkah's avatar
dkah committed
63 64 65 66 67 68 69 70 71 72 73 74 75 76
* Theoretically we could use arbitrary many sines to reconstruct almost all sounds

----

:data-x: r0
:data-y: r500
:data-scale: 0.1

Saw Wave
========

.. image:: img/sawtooth.png
    :height: 350px
    :align: right
dkah's avatar
dkah committed
77 78 79

----

dkah's avatar
most in  
dkah committed
80 81 82 83 84 85 86 87 88 89 90 91
Envelopes
=========

* eternal sound vs defined notes
* most common ist ADSR (attack - delay - sustain - release)

.. image:: img/envelope.svg
    :height: 400px
    :align: right

----

dkah's avatar
dkah committed
92

dkah's avatar
dkah committed
93 94 95 96 97
Subtractive
===========

* Source with a broad spectrum -> noise
* Filter too thin out spectrum
dkah's avatar
most in  
dkah committed
98 99
* More "natural" sound
* Modular analog synthesizer
dkah's avatar
dkah committed
100
* Needs good filters
dkah's avatar
dkah committed
101

dkah's avatar
most in  
dkah committed
102 103 104

----

105 106
Some other Methods
==================
dkah's avatar
most in  
dkah committed
107

108 109 110
* Frequency Modulation
* Amplitude Modulation
* Physical Modelling
dkah's avatar
most in  
dkah committed
111 112 113 114 115 116

----

Granular Synthesis
==================

117
* A physical model of sound
dkah's avatar
most in  
dkah committed
118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144
* Denis Gabor 1947 : Acoustical quanta and the theory of hearing
* Based on grains or wave packages
* Analog to photons for light, proposed quanta for sound
* Psychoaccoustic : ear like the eye has resolution limits, granular synthesis plays with this

----

A grain
=======

.. image:: img/truax.gif
    :height: 200px
    :align: right

Has a source wave (with its own frequency), wraped in an envelope.

Both have various parameter that can be changed and influence the timbre.

----

Heaps of grains
===============

There is seldomly one grain, but mostly lots of grains.

How dense, homogenous, etc.  this grain clouds are changes the timbre and the way we perceive the sound.

145 146 147 148 149 150 151 152 153 154
----

Spectrum
========

.. image:: img/grains_spectrum.png
   :height: 200px
   :align: right


dkah's avatar
most in  
dkah committed
155 156 157 158 159 160 161 162 163 164
----

Pioneers of Granular Synthesis
==============================

* Curtis Roads : Microsound
* Iannis Xenakis
* Trevor Whishart
* B Truax
* Brandtsegg, Saue, Johansen : Partikkel Opcode in CSound
dkah's avatar
dkah committed
165 166 167 168 169

----

CSound
======
dkah's avatar
most in  
dkah committed
170

dkah's avatar
dkah committed
171 172 173 174 175 176 177
----

History
=======
* 1957 first computer sound synthesis at Bell Labs by Max Mathews -> MUSIC I
* Until 1970s MUSIC 11 by  Barry Vercoe
* Around 1986 Barry Vercoe wrote the first CSound based on C
dkah's avatar
most in  
dkah committed
178
* CSound constantly incorporates new ideas
dkah's avatar
dkah committed
179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201

----

Example Program
===============

----

.. image:: img/csound.png
    :height: 600px


----

CSound Alternatives
===================

Freeware
--------

* Sonic Pi
* Pure Data
* Supercollider
202

dkah's avatar
dkah committed
203 204 205 206 207
Commercial
----------

* Max/MSP

208 209
----

210 211 212 213 214
:data-scale: 1
:data-rotate-y: -90
:data-x: r0
:data-y: r0

215 216 217 218 219 220 221 222 223 224 225 226 227
What can we do with "run of the mill" technology?
=================================================

Constraints:
------------

* No specific network technologies
* No specific networking hardware
* No low level networking software

----


228
Experimental Setup
229
==================
230 231

Ingredients
232
-----------
233 234 235

* Elixir_ / Phoenix_ / Erlang_ VM
* WebSockets_
236
* Processing_ / P5_
237 238
* Open Sound Control (OSC_)
* CSound_
239
* A certain amount of crazyness
240 241 242 243 244 245 246 247
* You and your mobile phone

.. _Elixir: http://elixir-lang.org
.. _Phoenix: http://www.phoenixframework.org
.. _Erlang: http://www.erlang.org
.. _WebSockets: https://developer.mozilla.org/en-US/docs/Web/API/WebSockets_API
.. _OSC: https://en.wikipedia.org/wiki/Open_Sound_Control
.. _CSound: http://csound.github.io
248 249
.. _Processing: http://processing.org
.. _P5: http://p5js.org
250 251 252

----

253 254
:data-x: r1000

255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305
Overview
========


.. image:: img/overview.png

----

Server
======

* Ubuntu Server running on SWITCHengines in Zurich
* Elixir / Phoenix software
* Receiving data from mobile clients (30 msgs / second / client) via WebSockets
* Keeping state
* Sending data to Laptop on Stage

----

Visualisation Client
--------------------

* JavaScript receives position data from server
* Calculates visualisation (flocking behaviour) with Processing
* Generates OpenSoundControl (OSC) messages, sends them via Websocket
* Node.js Program translates OSC messages from Websocket to UDP
* CSound Software listens to OSC messages and generates grains
* Audio is sent via USB to Sound Laptop

----

Sound Laptop
------------

* Various MIDI Controllers connected
* MainStage software creates virtual mixing desk
* Software Synths / Digital Effects
* Mixes Audio from CSound with Effects
* Sends Audio to Conference Hall PA


----

iPad Pro
--------

* Played by Dragica in Lucerne, Switzerland who (hopefully) sees &
  hears what we are doing here
* Runs various musical software
* Sound via Video-Conference, patched to Conference Hall PA

306

307 308 309 310 311 312 313
----

What could possibly go wrong?
=============================

----

314 315 316 317 318 319 320 321 322
OpenSourced
===========

All code is available on http://gitlab.switch.ch/grains

(good luck in getting it working though ;) )

----

323 324 325 326
Audience Participation
======================

Go To http://grains.switch.ch
327
-----------------------------
328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352

----

:data-x: r0
:data-y: r800

Dragica Kahlina
===============

* Theoretical Physicist Uni Basel
* Lecturer Digital Ideation HSLU
* Sound Artist

@gluggergames

----

Jens-Christian Fischer
======================

* MscIT University Liverpool
* Lecturer Web ZHAW
* Product Manager SWITCHengines

@jcfischer