浏览器接入(通信测试demo)

快速接入demo(包含通信测试)【点击下载】

demo启动步骤

1、修改appKey(从已发布应用中获取发布链接参数) webrtc demo appKey

2、打开player.html,启动

3、左边是发送消息到应用端,右边是接收应用的消息(按F12,可以打开控制台看到详细的发送状态) webrtc demo send pic

浏览器直接接入代码参考

具体参考文档

<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/react.production.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/react-dom.production.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/react-is.production.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/rxjs.umd.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/styled-components.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/base64.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/qs.min.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/ray-streaming/2.6.2/ray-streaming.umd.js"></script>
<script src="https://3dcat-cms-img.oss-cn-shenzhen.aliyuncs.com/script/live-cat/0.2.9/live-cat.umd.js"></script>
<script>
  let Launcher = window.LiveCat.Launcher //公有化
  // let Launcher = window.LiveCat.LauncherPrivate //私有化
  let launcher = new Launcher({
    appKey: 'xxxxxxxxxx', 
    address: 'https://app.3dcat.live',
  })
  window.launch = launcher
  document.querySelector('body').style.width = '100vw'
  document.querySelector('body').style.height = '100vh'
  launcher.automata(document.querySelector('body'))
</script>
业务咨询:400-8037-298