我正在尝试使用Sinch为IOS打电话给app。我已经成功实现了应用程序调用app,这意味着SDK已在我的应用程序中正确设置。然而,由于某种原因,手机应用程序无法正常工作:
在我的MainViewController.m中,我有以下内容:
- (id<SINClient>)client {
return [(JSQAppDelegate *)[[UIApplication sharedApplication] delegate] client];
}
然后,在alertView中:
if ([self.client isStarted]) {
id<SINCall> call = [self.client.callClient callPhoneNumber:@"+46000000000"]; //Testing the phone number as advised by Sinch!
[self showCallController:call appToAppCall:NO];
}
调用以下方法:
-(void)showCallController: (id<SINCall>)call appToAppCall: (BOOL)appToapp
{
MMLCallingViewController *callView = [self.storyboard instantiateViewControllerWithIdentifier:@"CallingView"];
callView.call = call;
callView.callReceiverName = _theRecipient;
callView.calleeID = _theRecipientId;
if (!appToapp) {
callView.typeOfCall = @"phone";
callView.callStateLbl.text = @"Phone";
}
else {
callView.typeOfCall = @"app";
}
[self presentViewController:callView animated:YES completion:nil];
}
现在每一次,我都试着测试一下这个电话 - 我有以下问题:
呼叫视图显示,然后突然停止,并在控制台中显示以下消息:
[appDelegate client:logMessage:area:severity:timestamp:] [Line 590] virtual void rebrtc::SetSDPObserver::OnFailure(const std::string &)Failed to set remote answer sdp: Offer and answer descriptions m-lines are not matching. Rejecting answer.
[appDelegate client:logMessage:area:severity:timestamp:] [Line 590] Failed to set remote answer sdp: Offer and answer descriptions m-lines are not matching. Rejecting answer.
我的Sinch SDK版本是:3.7.1-0313526 - 使用Xcode 6.3 - IOS SDK 8.3
我的Parse SDK版本是1.7.4
我试着到处寻找并阅读Sinch上的所有教程!关于打电话的网站,找不到任何帮助的线索。
任何帮助都将非常感激。 提前谢谢。