2

以前は org.webrtc:google-webrtc:1.0.26885 を使用していましたが、問題はありませんでしたが、最新バージョンの 1.0.27225 に切り替えました。26885 バージョンの PeerConnectionFactory のメソッド createPeerConnection を使用して PeerConnection インスタンスを作成したところ、問題なく動作しましたが、最新バージョン 27225 に切り替えた後、メソッド createPeerConnection は常に null を返します。誰かがこの問題を解決するのを手伝ってくれますか?

ルーム サーバーはhttps://github.com/webrtc/apprtcから、Signal サーバーは collider から、apprtc/src/collider から、NAT サーバーはhttps://github.com/coturn/coturnからです。すべての Android クライアント コードはhttps://github.com/Piasy/webrtc/tree/hack_webrtc/examples/androidapp/src/org/appspot/apprtcからのものです。

    PeerConnection.RTCConfiguration rtcConfig = new PeerConnection.RTCConfiguration(signalingParameters.iceServers);
    // TCP candidates are only useful when connecting to a server that supports
    // ICE-TCP.
    rtcConfig.tcpCandidatePolicy = PeerConnection.TcpCandidatePolicy.DISABLED;
    rtcConfig.bundlePolicy = PeerConnection.BundlePolicy.MAXBUNDLE;
    rtcConfig.rtcpMuxPolicy = PeerConnection.RtcpMuxPolicy.REQUIRE;
    rtcConfig.continualGatheringPolicy = PeerConnection.ContinualGatheringPolicy.GATHER_CONTINUALLY;

    // Use ECDSA encryption.
    rtcConfig.keyType = PeerConnection.KeyType.ECDSA;
    // Enable DTLS for normal calls and disable for loopback calls.
    rtcConfig.enableDtlsSrtp = !peerConnectionParameters.loopback;
    rtcConfig.sdpSemantics = PeerConnection.SdpSemantics.UNIFIED_PLAN;

    peerConnection = factory.createPeerConnection(rtcConfig, pcObserver);
4

1 に答える 1