|
|
@ -22,14 +22,14 @@ let points = [];
|
|
|
|
function setup() {
|
|
|
|
function setup() {
|
|
|
|
var mq = window.matchMedia( "(max-width: 600px)" );
|
|
|
|
var mq = window.matchMedia( "(max-width: 600px)" );
|
|
|
|
if (mq.matches) {
|
|
|
|
if (mq.matches) {
|
|
|
|
var cnv = createCanvas(innerWidth, windowHeight, WEBGL);
|
|
|
|
var cnv = createCanvas(innerWidth/2, windowHeight/2, WEBGL);
|
|
|
|
cnv.position(innerWidth/15);
|
|
|
|
cnv.position(innerWidth/4, innerHeight*0.1);
|
|
|
|
cnv.style('z-index','-10')
|
|
|
|
cnv.style('z-index','-10');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
else {
|
|
|
|
var cnv = createCanvas(innerWidth*0.9, windowHeight, WEBGL);
|
|
|
|
var cnv = createCanvas(innerWidth*0.9, windowHeight, WEBGL);
|
|
|
|
cnv.position(innerWidth*1.35);
|
|
|
|
cnv.position(innerWidth*1.35);
|
|
|
|
cnv.style('z-index','-10')
|
|
|
|
cnv.style('z-index','-10');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|