mediabunny实现浏览器中将lottie动画转成mp4视频代码
代码语言:html
所属分类:多媒体
代码描述:mediabunny实现浏览器中将lottie动画转成mp4视频代码
代码标签: mediabunny 浏览器 lottie 动画 转成 mp4 视频 代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="zh-CN"> <head> <meta charset="UTF-8" /> <title>Lottie → MP4(MediaBunny 转码)</title> <style> html, body { margin: 0; width: 100%; height: 100%; background: #222; color: #eee; font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif; } #toolbar { position: fixed; left: 12px; top: 12px; right: 12px; z-index: 10; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; } button { padding: 8px 14px; background: #4f46e5; color: #fff; border: 0; border-radius: 8px; cursor: pointer; font-weight: 600; } button:disabled { opacity: .6; cursor: not-allowed; } .progress { flex: 1 1 240px; height: 10px; background: #333; border-radius: 6px; overflow: hidden; display: none; } .bar { height: 100%; width: 0%; background: linear-gradient(90deg, #4f46e5, #8b5cf6); transition: width .25s; } #status { min-width: 220px; color: #9aa0a6; } #dlMp4 { display: none; padding: 8px 14px; background: #10b981; color: #fff; border-radius: 8px; text-decoration: none; font-weight: 700; } #container { width: 720px; height: 720px; margin: 70px auto 24px; background:#333; overflow: hidden; border-radius: 12px; } #preview { display:block; width: 720px; height: auto; margin: 0 auto 40px; background:#000; border-radius: 12px; } </style> </head> <body translate="no"> <div id=&quo.........完整代码请登录后点击上方下载按钮下载查看
网友评论0