three+webgl实现鼠标跟随光子流动画效果代码
代码语言:html
所属分类:其他
代码描述:three+webgl实现鼠标跟随光子流动画效果代码
代码标签: three webgl 鼠标 跟随 光子 流 动画
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
body {
margin: 0;
background: black;
}
.root {
position: fixed;
top: 0;
left: 0;
height: 100vh;
width: 100vw;
padding: 0;
margin: 0;
z-index: 2;
}
</style>
</head>
<body translate="no">
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/es-module-shims.1.6.2.js"></script>
<script type="importmap">
{
"imports": {
"three": "//repo.bfw.wiki/bfwrepo/js/module/three/build/150/three.module.js",
"addons/": "//repo.bfw.wiki/bfwrepo/js/module/three/examples/150/jsm/"
}
}
</script>
<div class="root" id="root"></div>
<script type="module">
import * as THREE from 'three';
let scen.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0