简体   繁体   English

Quickblox-视频通话中没有音频

[英]Quickblox - No Audio in Video Call

My app is using the Quickblox video chat with custom video and audio capture sessions. 我的应用程序正在使用Quickblox视频聊天以及自定义视频和音频捕获会话。 Everything was working great, however, in our login view controller (the view controller immediately proceeding the home view controller with Quickblox video chat), we added a video background (see code below). 一切都很好,但是,在我们的登录视图控制器中(视图控制器立即与Quickblox视频聊天进行主视图控制器),我们添加了视频背景(请参见下面的代码)。

Now, audio is only working sporadically in our video chat calls. 现在,音频仅在我们的视频聊天通话中起作用。 Usually the first call works fine, but after that, one of the users (or both) receives no audio output during the call. 通常,第一个呼叫可以正常运行,但是此后,一个用户(或两个用户)在呼叫过程中没有收到音频输出。

Below is the code we added to the login view controller. 下面是我们添加到登录视图控制器中的代码。 Is there anything here that would cause problems with Quickblox audio? 这里有什么会引起Quickblox音频问题的吗? Note that when the view disappears, I pause the player and remove the sublayer. 请注意,当视图消失时,我暂停播放器并删除子层。

NSString *filepath = [[NSBundle mainBundle] pathForResource:@"loginbg3" ofType:@"mp4"];
NSURL *fileURL = [NSURL fileURLWithPath:filepath];

player = [AVPlayer playerWithURL:fileURL];
layer = [AVPlayerLayer playerLayerWithPlayer:player];

[layer setVideoGravity:AVLayerVideoGravityResizeAspectFill];

player.actionAtItemEnd = AVPlayerActionAtItemEndNone;

layer.frame = CGRectMake(0, 0, 320, 600);

[_videoSuper.layer addSublayer: layer];

We recommend you to download the latest iOS SDK (2.3.0.4), it should have this issue fixed. 我们建议您下载最新的iOS SDK(2.3.0.4),此问题已修复。

You can download it and check out framework changes here: http://quickblox.com/developers/IOS 您可以在此处下载并查看框架更改: http : //quickblox.com/developers/IOS

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM