threejs实现三维图片卷起动画效果代码
代码语言:html
所属分类:三维
代码描述:threejs实现三维图片卷起动画效果代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
@import url('https://fonts.googleapis.com/css2?family=Lora&display=swap');
canvas {
display: block;
width: 100%;
height: 100vh;
background: black;
font-family: lora, serif;
cursor: -webkit-grab;
cursor: grab;
}
#el_hero {
color: white;
position: fixed; top: 0; left: 0;;
font: 1em lora, serif;
mix-blend-mode: difference;
}
a {
color: white;
}
</style>
</head>
<body >
<div id='el_hero'>
</div>
<!-- -->
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/es-module-shims.js"></script>
<script type='importmap-shim'>
{
"imports": {
"three": "https://unpkg.com/three@0.139.0/build/three.module.js",
"three/": "https://unpkg.com/three@0.139.0/"
}
}
</script>
<script defer .........完整代码请登录后点击上方下载按钮下载查看
网友评论0