p5实现线条曲线渐变螺旋动画效果代码
代码语言:html
所属分类:动画
代码描述:p5实现线条曲线渐变螺旋动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
</head>
<body >
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/p5.1.4.0.js"></script>
<script >
// experimenting based off of Cassie Tarakajian's GitHub Satellite 2020 Talk on Creative Coding in p5.js https://www.youtube.com/watch?v=sRLWIAPaiRI
let x, y;
let speedX = 3;
let speedY = 5;
function setup() {
// called one time
let lavendar = color(246, 246, 255);
createCanvas(windowWidth, windowHeight);
background(lavendar);
x = random(0, widt.........完整代码请登录后点击上方下载按钮下载查看
网友评论0