收藏
回答

camera在iPhone下录像没有声音

很无语,希望快点解决。

回答关注问题邀请回答
收藏

5 个回答

  • 黄思程
    黄思程
    2017-11-06

    你好,请提供一下出现问题的机型和微信版本,以及能复现问题的简单代码示例。

    2017-11-06
    有用
    回复
  • 舒紫鹏
    舒紫鹏
    2018-06-21

    到现在都没有解决

    2018-06-21
    有用
    回复
  • G.
    G.
    2018-03-14

    题主, 可以用chooseVideo API , 我都服了 自己写了个, 原来就有


    2018-03-14
    有用
    回复
  • G.
    G.
    2018-03-14
    _this.cameraCtx.startRecord({
                        success() {
                          //添加流 控制时间
                          let stream = xs
                            .periodic(1000)
                            .endWhen(xs.periodic(11000).take(1));
     
                          stream.addListener({
                            next: i => {
                              _this.countDownTip = "还剩 " + (10 - i) + " 秒";
                              _this.$apply();
                            },
                            error: err => console.error(err),
                            complete: () => {
                              //录制时间到,停止录制
                              _this.countDownTip = "还剩 0 秒";
                              _this.$apply();
                              _this.cameraCtx.stopRecord({
                                success(res) {
                                  wx.showLoading({
                                    title: "请稍后……",
                                    mask: true
                                  });
                                  //处理视频
                                  _this.$preload(
                                    "tempThumbPath",
                                    res.tempThumbPath
                                  );
                                  _this.$preload(
                                    "tempVideoPath",
                                    res.tempVideoPath
                                  );
                                  _this.$redirect({
                                    url: "playvideo"
                                  });
                                  wx.hideLoading();
                                  console.log(res);
                                },
                                fail(res) {
                                  wx.showToast({
                                    title: "无法结束录像!" + res.errMessage,
                                    icon: "none"
                                  });
                                }
                              });
                            }
                          });
                        },
                        fail(res) {
                          wx.showToast({
                            title: "无法开始录像!" + res.errMessage,
                            icon: "none"
                          });
                        }
                      });

    当中用到了xstream(http://staltz.github.io/xstream/)的库

    2018-03-14
    有用
    回复
  • G.
    G.
    2018-03-14

    不止是Iphone

    我android也是 我以为是故意静音的,

    微信版本6.6.5

    基础库1.9.9

    手机 华为畅玩6x 权限都给了

    复现代码



    2018-03-14
    有用
    回复
登录 后发表内容