xxxxxxxxxx
40
let groteskFont;
let sample = 0.1;
let r = 20;
const fontSize = 100;
function preload() {
groteskFont = loadFont('https://cdn.glitch.com/5dd99b18-3ebb-45c5-90fb-b4b67dc2e128%2Fgrotesk.otf?v=1580943594863sk.otf');
}
function setup() {
createCanvas(400, 400);
textFont(groteskFont);
textSize(fontSize);
fill(186*osc, 255, 242);
stroke(186, 255, 242);
strokeWeight(1*osc);
}
function draw() {
background(0,255,255,10);
let cArray = groteskFont.textToPoints('clouds!', 60, 215, fontSize, { sampleFactor: sample});
for (let i = 0; i < cArray.length; i++){
push();
translate(cArray[i].x, cArray[i].y);
rotate(r);
r++;
line(0,0,5,5);
pop();
}
}
function osc(scale) {
if (!scale) {
scale = 10;
}
return abs(sin(frameCount*10 * scale));
}