Marmoset Viewer
在 Marmoset Toolbag 中构建场景,只需单击按钮即可导出高质量的 3D 演示文稿 .mview 文件。Toolbag 会自动将各种内容工作流转换为优化的可 Web 渲染包文件,以便于托管和嵌入。
接口演示
接口说明
http://mt3d.blans.top/f.php?autoStart=是否自动加载(true/false)&f1= 模型URL(http协议)
1、f1参数为mview格式模型文件链接(链接文件名需省略.mview后缀),
2、autoStart参数控制是否自动播放和加载模型,值为true或false
例:
接口解释
前端网页代码:
<!DOCTYPE html>
<meta name="viewport" content="user-scalable=0"/>
<meta charset="utf-8">
<html>
<head>
<title>Marmoset Viewer by ONE_Blog 一个博客</title>
//js库
<script src="marmoset.js"></script>
</head>
<body>
<?php
// 读取GET数据并赋值给变量
// 例 http://mt3d.blans.top/f.php?autoStart=true&f1=link1
$f1 = $_GET['f1'];
$autoStart = $_GET['autoStart'];
?>
<script>
marmoset.embed( '<?php echo $f1; ?>.mview', { width: 800, height: 600, autoStart: <?php echo $autoStart; ?>, fullFrame: true, pagePreset: false } );
</script>
</body>
</html>
