纯html前端实现三维大数据动画

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

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>大数据3D背景</title>
    <link rel="stylesheet" href="css/style.css">
</head>
<body style="background:url(img/bg.png)">
    <div class="main">
        <div class="total">
            <div class="cicle3"></div>
            <div class="cicle4"></div>
        </div>
        <div class="image-container">
            <img class="imagesdong1" src="img/a.png" alt="Descriptive text">
            <img class="imagesdong2" src="img/b.png" alt="Descriptive text">
            <img class="imagesdong3" src="img/c.png" alt="Descriptive text">
            <img class="imagesdong4" src="img/a.png" alt="Descriptive text">
            <img class="imagesdong5" src="img/b.png" alt="Descriptive text">
            <img class="imagesdong6" src="img/c.png" alt="Descriptive text">
          </div>
       </div>

</body>

</html>
.main {
    width: 100%;
    height: 100%;
    box-sizing: border-box;
}

.main .total {
    width: 100%;
    height: 100%;
    position: relative;
}



/*旋转圆环3*/
.main .total .cicle3 {
    width: 800px;
    height: 800px;
    background: url(../img/circle.png) no-repeat center;
    background-size: 100%;
    background-position: bottom;
    position: absolute;
    top: 450px;
    left: 50%;
    right: 50%;
    transform-style: preserve-3d;
    transform: translateX(-50%) rotateX(75deg);
    animation: rotate3 10s linear infinite;
}

@keyframes rotate3 {
    0% {
        transform: translateX(-50%) rotateX(75deg) rotateZ(0);
    }

    100% {
        transform: translateX(-50%) rotateX(75deg) rotateZ(360deg);
    }
}

/*旋转圆环4*/
.main .total .cicle4 {
    width: 500px;
    height: 500px;
    background: url(../img/orange.png) no-repeat center;
    background-size: 100%;
    background-position: bottom;
    position: absolute;
    top: 200px;
    left: 50%;
    transform-style: preserve-3d;
    transform: translateX(-50%) rotateX(75deg);
    animation: rotate4 10s linear infinite;
}

@keyframes rotate4 {
    0% {
        transform: translateX(-50%) rotateX(75deg) rotateZ(360deg);
    }

    100% {
        transform: translateX(-50%) rotateX(75deg) rotateZ(0);
    }
}


/*上升弹幕*/
.image-container {
    position: relative;
    width: 1800px;
    /* 或你需要的宽度 */
    height: 900px;
    /* 或你需要的高度 */
    overflow: hidden;
}

.image-container .imagesdong1 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 300px;
    animation: rise-and-fade1 16s infinite;
}

.image-container .imagesdong2 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 1500px;
    top: 100px;
    animation: rise-and-fade2 15s infinite;
}

.image-container .imagesdong3 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 1400px;
    top: -200px;
    animation: rise-and-fade3 10s infinite;
}

.image-container .imagesdong4 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 390px;
    top: -80px;
    animation: rise-and-fade1 4s infinite;
}

.image-container .imagesdong5 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 1600px;
    top: 300px;
    animation: rise-and-fade2 12s infinite;
}

.image-container .imagesdong6 {
    position: absolute;
    width: 30px;
    height: 150px;
    left: 480px;
    top: -150px;
    animation: rise-and-fade3 8s infinite;
}

@keyframes rise-and-fade1 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    50% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

@keyframes rise-and-fade2 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    30% {
        opacity: 1;
        transform: translateY(900px);
    }

    60% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    90% {
        opacity: 0.6;
        transform: translateY(20px);
        /* 移出容器 */
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

@keyframes rise-and-fade3 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    20% {
        opacity: 0.8;
        transform: translateY(900px);
    }

    50% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    80% {
        opacity: 0.5;
        transform: translateY(300px);
        /* 移出容器 */
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

@keyframes rise-and-fade4 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    15% {
        opacity: 0.5;
        transform: translateY(900px);
    }

    50% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    85% {
        opacity: 0.9;
        transform: translateY(100px);
        /* 移出容器 */
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

@keyframes rise-and-fade5 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    40% {
        opacity: 1;
        transform: translateY(900px);
    }

    50% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    60% {
        opacity: 0.6;
        transform: translateY(100px);
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

@keyframes rise-and-fade6 {
    0% {
        opacity: 0;
        transform: translateY(900px);
    }

    10% {
        opacity: 0.5;
        transform: translateY(900px);
    }

    50% {
        opacity: 1;
        transform: translateY(450px);
        /* 向上移动 */
    }

    90% {
        opacity: 0.8;
        transform: translateY(30px);
        /* 移出容器 */
    }

    100% {
        opacity: 0;
        transform: translateY(0px);
        /* 移出容器 */
    }
}

  • 3
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值