js实现二进制数据1与0滚动墙动画效果代码

代码语言:html

所属分类:动画

代码描述:js实现二进制数据1与0滚动墙动画效果代码

代码标签: js 二进制 数据 1 0 滚动 动画

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en" >

<head>

  <meta charset="UTF-8">
  

  
  
  
  
<style>
* { margin:0; padding:0; } 
html, body { width:100%; height:100%; overflow: hidden; background:black;} 
canvas { display:block; }
</style>



</head>

<body>
  <div id="controls"></div>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/p5.1.4.0.js"></script>
      <script>
function setup (){
  pixelDensity(1);
  createCanvas();
  colorMode(HSB, 1, 1, 1);
  windowResized();
}

let gw, gh;
let c1, offset;
let updatesPerFrame;
let xSpan = 15;
let ySpan = xSpan*1.5;
let init = () => {
  gw = floor(width/xSpan)+1;
  gh = floor(height/ySpan)+1;
  updatesPerFrame =.........完整代码请登录后点击上方下载按钮下载查看

网友评论0