2016-02-10 90 views
0


我正在開發webrtc客戶端爲Android使用WebRTC演示應用程序。
雖然我使用org.webrtc庫來開發客戶端,但在運行自己的客戶端時遇到了問題。

當我跑我的客戶,下面是logcat的我得到WebRTC客戶端opensslidentity失敗使webrtc證書

2-10 18:32:49.260 7669-9530/org.appspot.apprtc I/libjingle: (opensslidentity.cc:47): Making key pair 
02-10 18:32:49.261 7669-9531/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1127): Signaling thread JavaCallback 
02-10 18:32:49.261 7669-9531/org.appspot.apprtc I/org.webrtc.Logging: PeerConnectionFactory: onSignalingThreadReady 
02-10 18:32:49.261 7669-9527/org.appspot.apprtc D/PCRTCClient: Peer connection factory created. 
02-10 18:32:49.263 7669-9527/org.appspot.apprtc D/PCRTCClient: Create peer connection. 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc D/PCRTCClient: PCConstraints: mandatory: [], optional: [DtlsSrtpKeyAgreement: true] 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc D/PCRTCClient: VideoConstraints: mandatory: [minWidth: 1280, maxWidth: 1280, minHeight: 720, maxHeight: 720, minFrameRate: 30, maxFrameRate: 30], optional: [] 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc D/PCRTCClient: EGLContext: [email protected] 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1382): Set EGL context for HW encoding. 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc I/MediaCodecVideo: MediaCodecVideo: MediaCodecVideoEncoderFactory::SetEGLContext 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1391): Set EGL context for HW decoding. 
02-10 18:32:49.264 7669-9527/org.appspot.apprtc I/MediaCodecVideo: MediaCodecVideo: MediaCodecVideoDecoderFactory::SetEGLContext 
02-10 18:32:49.265 7669-9527/org.appspot.apprtc A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 9527 (Thread-13274) 




當我運行的WebRTC演示應用(完整logcat中的一部分),我得到了下面的logcat:

02-10 18:34:44.849 9621-10486/org.appspot.apprtc D/de.tavendo.autobahn.WebSocketConnection: WebSocket connection created. 
02-10 18:34:44.850 9621-9621/org.appspot.apprtc D/CallRTCClient: Creating peer connection, delay=754ms 
02-10 18:34:44.858 9621-9621/org.appspot.apprtc D/CallRTCClient: Creating OFFER... 
02-10 18:34:45.031 9621-10500/org.appspot.apprtc I/libjingle: (opensslidentity.cc:88): Returning key pair 
02-10 18:34:45.031 9621-10500/org.appspot.apprtc I/libjingle: (opensslidentity.cc:95): Making certificate for WebRTC 
02-10 18:34:45.034 9621-10500/org.appspot.apprtc I/libjingle: (opensslidentity.cc:143): Returning certificate 
02-10 18:34:45.035 9621-10500/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1123): Worker thread JavaCallback 
02-10 18:34:45.035 9621-10500/org.appspot.apprtc I/org.webrtc.Logging: PeerConnectionFactory: onWorkerThreadReady 
02-10 18:34:45.037 9621-10501/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1127): Signaling thread JavaCallback 
02-10 18:34:45.037 9621-10501/org.appspot.apprtc I/org.webrtc.Logging: PeerConnectionFactory: onSignalingThreadReady 
02-10 18:34:45.037 9621-10498/org.appspot.apprtc D/PCRTCClient: Peer connection factory created. 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc I/org.webrtc.Logging: MediaCodecVideoEncoder: Found target encoder for mime video/x-vnd.on2.vp8 : OMX.qcom.video.encoder.vp8. Color: 0x15 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc D/PCRTCClient: Create peer connection. 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc D/PCRTCClient: PCConstraints: mandatory: [], optional: [DtlsSrtpKeyAgreement: true] 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc D/PCRTCClient: VideoConstraints: mandatory: [minWidth: 1280, maxWidth: 1280, minHeight: 720, maxHeight: 720], optional: [] 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc D/PCRTCClient: EGLContext: [email protected] 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1382): Set EGL context for HW encoding. 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc I/MediaCodecVideo: MediaCodecVideo: MediaCodecVideoEncoderFactory::SetEGLContext 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc I/libjingle: (peerconnection_jni.cc:1391): Set EGL context for HW decoding. 
02-10 18:34:45.040 9621-10498/org.appspot.apprtc I/MediaCodecVideo: MediaCodecVideo: MediaCodecVideoDecoderFactory::SetEGLContext 




我的CLIE NT崩潰的點

02-10 18:32:49.264 7669-9527/org.appspot.apprtc I/MediaCodecVideo: MediaCodecVideo: MediaCodecVideoDecoderFactory::SetEGLContext 
02-10 18:32:49.265 7669-9527/org.appspot.apprtc A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 9527 (Thread-13274) 

不過的WebRTC演示正常運行。
我觀察到的差異如下:
從logcat中可以看出,我的客戶端無法生成opensslidentitycertificate for WebRTC
我的客戶是停留在

2-10 18:32:49.260 7669-9530/org.appspot.apprtc I/libjingle: (opensslidentity.cc:47): Making key pair 


然而,演示程序能夠做到這一點。


我想知道爲什麼我的客戶端無法生成證書?

回答

0

當我沒有使用Ice Server時發生了這個問題。在將Ice服務器傳遞給PeerConnection後,該應用程序正常工作