Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function onGLC(glc) {
- glc.loop();
- glc.size(540, 540);
- glc.setDuration(2);
- glc.setFPS(30);
- glc.styles.backgroundColor = "black";
- // glc.setMode('single');
- // glc.setEasing(false);
- var list = glc.renderList,
- width = glc.w,
- height = glc.h,
- color = glc.color,
- TWO_PI = Math.PI*2;
- // your code goes here:
- var cols = 15,
- rows = cols,
- step = width/cols;
- for (var x = step/2*3; x<width-step; x+= step) {
- for (var y = step/2*3; y<height-step; y+= step) {
- list.addCube({
- x: x,
- y: y,
- size: [5, step/2],
- strokeStyle: "white",
- lineWidth: 1,
- rotationX: 45,
- rotationY: [-45,85],
- rotationZ: 45,
- phase: Math.pow(1 / (x / width + 0.9), 1 / (y / height + 0.1))
- });
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement