# WCCChallenge: TinyIsland

·

## TinyIslandMultiversing

For this week's Creative Code challenge by @sableRalph : Tiny Island, I decided to have an interactive mouse experience coded in Hydra. The audio is coded in SonicPi

To fit in the theme, I decided to take the following countries and territory and their respective coordinates and rainfall data to control the visuals and sound.

### Poem

Being Tiny doesn't explain the soul
Or the way you can glow
The way the tide can harness your flow
As if you are gliding into space
In space

### Visuals/Hydra Code

• I decided to only use the 8 coordinate numbers found from those countries and territory

• Then in the Hydra code, I gave them all their own section that only contains numbers from them but are able to communicate through the following functions:

• osc,pixelate, diff, blend, add, noise, modulateRotate, modulateScale, voronoi, scale, mouse.x, mouse.y, color and shape

• Video is also played backwards in the final Edition

 Country/Territory Latitude Longitude Guam 13.4443° N 144.7937° E Palau 7.5150° N 144.7937° E Nauru 0.5228° S 166.9315° E Federated States of Micronesia 7.4256° N 150.5508° E
``````/*

Location of the Four Countries
13.4443° N, 144.7937° E - Guam
7.5150° N, 144.7937° E - Palau
0.5228° S, 166.9315° E Nauru
7.4256° N, 150.5508° E Federated States of Micronesia

*/
//Gave the first two functions the coordinates of Nauru

//Gave this section the numbers from Guam
noise(134.5825,7.515).modulateRotate(o3).diff(o2).modulateScale(o0).out(o1)

//Palau Coordinates

//Micronesia
shape(()=> mouse.x / 150.5508).color(()=> mouse.y / 7.4256).modulateRotate(o1).out(o3)
``````

### Audio / SonicPi Code

• For the audio decided to play with the data found in the monthly rainfall section of the following sites:

``````require 'csv'

#Parsing the Data for the Tiny Island Creative Code Challenge
#For today, I am parsing the Rainfall of the Following Four Countries : Nauru, Palau, Micronesia, Guam

#doing the months as the index instead of an integer

January = 0
February = 1
March = 2
April = 3
May = 4
June = 5
July = 6
August = 7
September = 8
October = 9
November = 10
December = 11

def weathering(looping,country1,country2,looping2)

months = ["January", "February", "March", "April", "May", "June","July", "August", "September", "October", "November", "December"]

i = 0
live_loop looping do

#since it is read as a strong got to put it as float

#taking the millimeters per month and taking the difference between them
use_synth [:bass_foundation,:piano,:chipbass].choose
#play (country1[i]['Millimeters'].to_f - country2[i]['Millimeters'].to_f).abs / 2 + 1 #- Making sure the loop is functioning right
play chord((country1[i]['Millimeters'].to_f - country2[i]['Millimeters'].to_f).abs / 2 + 1 , :minor), release: country1[i]['Inches'].to_f
play_pattern_timed chord((country1[i]['Millimeters'].to_f - country2[i]['Millimeters'].to_f).abs / 2 + 1 , :minor), country1[i]['Inches'].to_f / country2[i]['Inches'].to_f  * 2
#taking the addition of the rainy days and dividing them by 10
sample :guit_e_slide , rate: (country1[i]['Days'].to_f + country2[i]['Days'].to_f).abs / 10

if i >= months.length - 1
i = 0
end

#taking the inches of rain seen by the countries and dividing them
sleep [(country1[i]['Inches'].to_f / country2[i]['Inches'].to_f).abs + 0.5,(country1[i]['Days'].to_f + country2[i]['Days'].to_f).abs / 10].choose

i += 1
end

live_loop looping2 do
sample :tabla_ghe2 , pitch: (country1[i]['Days'].to_f + country2[i]['Days'].to_f).abs / 10
sample :perc_impact1, pitch: (country1[i]['Inches'].to_f + country2[i]['Inches'].to_f).abs / 2
sleep (country1[i]['Inches'].to_f + country2[i]['Inches'].to_f).abs / 2

if i >= months.length - 1
i = 0
end
i += 1
end

end

weathering(:weather1,Guam,Nauru,:weather1b)
weathering(:weather2,Palau,Micronesia,:weather2b)
weathering(:weather3,Micronesia,Guam,:weather3b)
weathering(:weather4,Nauru,Palau,:weather4b)
``````