babylon实现宇宙戴森球三维模型动画代码
代码语言:html
所属分类:三维
代码描述:babylon实现宇宙戴森球三维模型动画代码,可以缩放旋转进入能量球内部。
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en">
<head>
<style>
#renderCanvas {
position: absolute;
width: 100%;
height: 100%;
touch-action: none;
left: 0%;
right: 0%;
bottom:0%;
top: 0%;
}
html, body {
overflow: hidden;
width: 100%;
height: 100%;
margin: 0;
padding: 0;
font-family: 'Rajdhani', sans-serif;
color: white;
font-size: large;
}
a:link, a:visited {
background-color: #f44336;
color: white;
padding: 14px 25px;
text-align: center;
text-decoration: none;
display: inline-block;
}
.container {
position: relative;
height: 100%;
width: 100%;
}
.header {
position: absolute;
left:0;
right:0;
top:0;
padding-left:10px;
text-align: center;
}
.footer {
position: absolute;
right:0;
bottom:0;
margin:5px;
padding:5px;
}
a:hover, a:active {
background-color: red;
}
.center {
position: absolute;
background-color: #00bfa5;
left: 0%;
right: 0%;
bottom:0%;
top: 0%;
margin:10px;
padding:10px;
}
#fps {
position: absolute;
background-color: black;
border: 2px solid red;
text-align: center;
font-size: 16px;
color: white;
top: 15px;
right: 10px;
width: 60px;
height: 20px;
}
</style>
<link href="https://fonts.googleapis.com/css2?family=Rajdhani:wght@500&display=swap" rel="stylesheet">
<!-- Babylon.js -->
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/dat.gui-min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/ammo.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/cannon.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/Oimo.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/earcut.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylon.5.2.0.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylonjs.materials.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylonjs.proceduralTextures.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylonjs.postProcess.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylonjs.loaders.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylonjs.serializers.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylon.gui.min.js"></script>
<script type="text/javascript" src="//repo.bfw.wiki/bfwrepo/js/babylon.inspector.bundle.js"></script>
</head>
<body>
<div class="container">
<div class="container"><canvas id="renderCanvas" class="container" /></div>
</div>
<div id="fps">0</div>
<script>
const TEXTURE_.........完整代码请登录后点击上方下载按钮下载查看
网友评论0