Live Coding tools on Debian

How to install, setup and play

by: Joenio Marques da Costa
and Mari Moura

Joenio Marques da Costa

http://joenio.me/about

from Brazil living in France

  • Research Software Engineer
  • Work at Cortext.net Platform
  • Software Heritage Ambassador
  • Data Univ Eiffel Ambassador
  • Debian Contributor Developer
  • Computer Artist

Mari Moura

http://marimoura.4two.art

from Brazil living in France

  • Black Brazilian performer artist
  • PhD in art and technology
  • Undergraduate student in Systems Analysis and development
  • Python beginner

Schedule

  • Live coding introduction
  • Tools and languages
  • Install and setup Sonic Pi
  • Live coding practice šŸŽ§

Live coding is a new direction in electronic music and video: live coders expose and rewire the innards of software while it generates improvised music and/or visuals.

toplap.org

TOPLAP has been collectively developing, exploring and promoting live coding since it was formed in a smoky bar in Hamburg in 2004.

algorave.com

Algorave is made from ā€œsounds wholly or predominantly characterised by the emission of a succession of repetitive conditionalsā€.

Tools and languages

SuperCollider
supercollider.github.io

SuperCollider is an audio server, programming language, and IDE for sound synthesis and algorithmic composition.

Sonic Pi
sonic-pi.net

The Live Coding music synth for everyone, Sonic Pi has a Ruby-like syntax.

JACK
jackaudio.org

JACK is a professional sound server and pair of daemons to provide real-time, low-latency connections for audio and MIDI data.

PipeWire
pipewire.org

PipeWire improve handling of audio and video under Linux that can be used to support the use cases currently handled by both pulseaudio and JACK.

How to install and setup

Sonic Pi

Install Sonic Pi


Debian:


sudo apt install sonic-pi


Windows or Mac:


Download from http://sonic-pi.net

Key concepts

Sample vs Synthesizer


Sample

water-to-glass.wav

Synthesizer

Pitfall! - Atari 2600

Letā€™s Start

šŸŽ§

Sonic Pi language

Sample vs Synthesizer


Sample


sample :drum_cowbell


Synthesizer


play 60

Sonic Pi functions

Sample, Play and Sleep


sample :drum_cowbell
sleep 0.5
play 60
sleep 0.5
sample :drum_cowbell
sleep 0.5
play 60
sleep 0.5
sample :drum_cowbell

Sonic Pi functions

Live Loop


live_loop :myloop do
  sample :drum_cowbell
  sleep 0.5
  play 60
  sleep 0.5
end

Sonic Pi function parameters

Parameter ā€˜rateā€™


live_loop :myloop do
  sample :drum_cowbell, rate: 0.5
  sleep 0.5
  play 60
  sleep 0.5
end

  • Default rate is 1
  • Must not be 0 (zero)

Comments


live_loop :myloop do
  #sample :drum_cowbell, rate: 0.5
  sample :drum_cowbell, rate: 0.2
  sleep 0.5
  #play 60
  play 120
  sleep 0.5
end

  • Lines starting by # are not executed

Sonic Pi function parameters

Parameter ā€˜ampā€™ (Amplitude)


sample :drum_cowbell, amp: 0.5
sleep 0.5
play 60, amp: 0.5
sleep 0.5

  • amp = 0.5 means volume = 50%
  • Recommended values: 0 to 1

Sonic Pi function parameters

Parameter ā€˜panā€™ (Panning)


sample :drum_cowbell, pan: -1
sleep 0.5
play 60, pan: 1
sleep 0.5

  • Value -1 means 100% on the left side
  • Value 1 means 100% on the right side
  • Possible values between -1 to 1

Sonic Pi function parameters

Selecting the synthesizer


use_synth :saw
play 60

Challenge!

Create 2 live loops, each one with a different synthesizer, playing alternately.

šŸ§—

Sonic Pi language

Lists and the choose function


loop do
  play choose([60, 65, 72])
  sleep 1
end

Sonic Pi language

Other loop functions


3.times do
  play 60
  sleep 1
end


loop do
  play 60
  sleep 1
end

How to add custom sample files

How to record a Sonic Pi session

Sonic Pi alternatives

  • ChucK
  • FoxDot
  • Gibber
  • ORCĪ›
  • Pure Data
  • Tidal Cycles

See also: github.com/toplap/awesome-livecoding

Live coding videos and documentaries

Thanks!

joenio@joenio.me


This presentation is available at:

http://joenio.me/debconf24-live-coding-workshop

export presentation to pdf (require chromium browser)

(source-code: https://gitlab.com/joenio/joenio.gitlab.io)

LicenƧa Creative Commons

Presentation history

Where and when this presentation was done

  • 01 Aug 2024, PKNU, Busan, South Korea, DebConf24