BotanicalGlitches
For this week's Creative Code Challenge by @sableraph: "Botanical", BotanicalGlitches takes SonicPi, Hydra,playertdfgcvbxyz & Locomotion Code to build a glitchy Botanical Garden.
Poem
There is no Warden
In this Garden
As the Flowers
ignite their own powers
within the glitches
that switches
Video
Code
Playertdfgcvb
/**
@author illestpreacha
@title Coordinates: GlitchyBotanical
@desc Glitchfied Flowers , remix of coordinates: x, y
*/
const density = '๐ฅ๐น๐ชท๐ชป๐ท๐ผ\n๐ฎ๐ธ๐๐บ๐ป\n ๐๐ชด๐ต๐ฟโ๏ธ๐ฑ๐บ๐ท๐ชป๐ป๐ชป\n๐งโ๏ธ๐\n๐ป๐ชป๐ \n๐ต๐ชท๐ฎ๐๐ท๐ฑ๐ธโ๏ธ \n ๐ฅ๐น๐ง๐ฆ๐๐ชท๐ชป'
const density1 = '๐ฅ๐น๐ชท\n๐ชป๐ท๐ผ\n๐ฎ๐ธ๐๐บ๐ป\n ๐๐ชด๐ต๐ฟโ๏ธ\n๐ฑ๐บ๐ท๐ชป๐ป๐ชป\n๐งโ๏ธ๐\n๐ป๐ชป๐ \n๐ต๐ชท๐ฎ\n๐๐ท๐ฑ\n๐ธโ๏ธ \n ๐ฅ๐น๐ง\n๐ฆ๐๐ชท๐ชป'
export var settings = {
backgroundColor : 'black',
lineHeight : 0.15,
cellWidth : 5,
fps : 6
}
export function main(coord, context, cursor, buffer) {
// Shortcuts for frame, cols and coord (x, y)
const {cols, frame } = context
const {x, y} = coord
const sign = ( y/x + y % frame)
const index = (cols + y + x * sign + frame) % density.length
return density[index]
}
Hydra
s0.initScreen()
s1.initScreen()
s2.initScreen()
s3.initScreen()
src(s0).repeat(()=> (time % 10 +1)/10, [0.5,1,2,4].fast(0.04)).scale([0.25,0.5,0.75,1,3].smooth()).pixelate([5000,10000,500,250,120000],[1,2,3,1000,5000,10000]).blend(s1).modulateScale(
s2,0.5).add(src(S3).scale(2)).out()
SonicPi - Slowed Down 20%
live_loop :bassflow do
use_bpm 5
if one_in(2)
sample :loop_drone_g_97 if spread(7,12).tick
sleep [0.5,0.25].choose
else
sample :elec_bong if spread(9,12).tick
sleep 0.25
end
end
with_fx :reverb, mix: 0.6 do
live_loop :start do
use_bpm 5
if one_in(3)
sample :loop_garzul if spread(17,24).tick
sleep (1.0/24)
else one_in(2)
sample :elec_twang if spread(5,12).tick
sleep (1.0/24)
sample :drum_tom_lo_soft if spread(7,12).tick
sleep (1.0/24)
end
end
end
live_loop :bding, amp: 1 do
use_bpm 5
sample :loop_weirdo, rate: 0.5 if spread(5,12).tick
sleep (1.0/24)
sample :loop_mika if spread(7,12).tick
sleep(1.0/24)
end
ย