求解live-player直播组件在ios上stop方法不生效等问题
发布于 6 年前 作者 jing71 2808 次浏览 来自 问答

一、文档上提供的接口不生效:

ios手机上无法停止播放,代码如下:

onReady() {
  this.playerContext = wx.createLivePlayerContext('myLive');
},
handleStop() {
  if (this.data.isPlay) {
    this.playerContext.stop({
      success(){
        console.log("stop success!");
      },
      fail(){
        console.log("stop fail!");
      }
    });
  }
}

手机调试无法打印stop success!和stop fail!

调试用的URL:“rtmp://live.hkstv.hk.lxdns.com/live/hks

全屏看直播时,会出现概率性无法停止播放,点击停止按钮,停不下来

调试用苹果10系统

二、用安卓机全屏后再退出全屏,video组件出现样式错乱

css就是使用了基本的flex布局。

机型:乐视2、华为荣耀V8

回到顶部