version bump webrtc to m117
This commit is contained in:
parent
5371b100de
commit
05c79ff29d
|
@ -80,7 +80,7 @@ dependencies {
|
|||
|
||||
implementation 'com.google.guava:guava:31.1-android'
|
||||
quicksyImplementation 'io.michaelrocks:libphonenumber-android:8.12.49'
|
||||
implementation 'im.conversations.webrtc:webrtc-android:104.0.0'
|
||||
implementation 'im.conversations.webrtc:webrtc-android:117.1.0'
|
||||
}
|
||||
|
||||
ext {
|
||||
|
|
|
@ -2624,6 +2624,10 @@ public class JingleRtpConnection extends AbstractJingleConnection
|
|||
if (port < 0 || port > 65535) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if (Arrays.asList("stun", "stuns", "turn", "turns")
|
||||
.contains(type)
|
||||
&& Arrays.asList("udp", "tcp").contains(transport)) {
|
||||
|
@ -2635,20 +2639,22 @@ public class JingleRtpConnection extends AbstractJingleConnection
|
|||
+ ": skipping invalid combination of udp/tls in external services");
|
||||
continue;
|
||||
}
|
||||
// TODO Starting on milestone 110, Chromium will perform
|
||||
// stricter validation of TURN and STUN URLs passed to the
|
||||
// constructor of an RTCPeerConnection. More specifically,
|
||||
// STUN URLs will not support a query section, and TURN URLs
|
||||
// will support only a transport parameter in their query
|
||||
// section.
|
||||
|
||||
// STUN URLs do not support a query section since M110
|
||||
final String uri;
|
||||
if (Arrays.asList("stun","stuns").contains(type)) {
|
||||
uri = String.format("%s:%s%s", type, IP.wrapIPv6(host),port);
|
||||
} else {
|
||||
uri = String.format(
|
||||
"%s:%s:%s?transport=%s",
|
||||
type,
|
||||
IP.wrapIPv6(host),
|
||||
port,
|
||||
transport);
|
||||
}
|
||||
|
||||
final PeerConnection.IceServer.Builder iceServerBuilder =
|
||||
PeerConnection.IceServer.builder(
|
||||
String.format(
|
||||
"%s:%s:%s?transport=%s",
|
||||
type,
|
||||
IP.wrapIPv6(host),
|
||||
port,
|
||||
transport));
|
||||
PeerConnection.IceServer.builder(uri);
|
||||
iceServerBuilder.setTlsCertPolicy(
|
||||
PeerConnection.TlsCertPolicy
|
||||
.TLS_CERT_POLICY_INSECURE_NO_CHECK);
|
||||
|
|
|
@ -33,12 +33,12 @@ import org.webrtc.SdpObserver;
|
|||
import org.webrtc.SessionDescription;
|
||||
import org.webrtc.VideoTrack;
|
||||
import org.webrtc.audio.JavaAudioDeviceModule;
|
||||
import org.webrtc.voiceengine.WebRtcAudioEffects;
|
||||
|
||||
import java.util.LinkedList;
|
||||
import java.util.List;
|
||||
import java.util.Queue;
|
||||
import java.util.Set;
|
||||
import java.util.concurrent.Callable;
|
||||
import java.util.concurrent.ExecutorService;
|
||||
import java.util.concurrent.Executors;
|
||||
import java.util.concurrent.atomic.AtomicBoolean;
|
||||
|
@ -260,9 +260,7 @@ public class WebRTCWrapper {
|
|||
Preconditions.checkNotNull(media);
|
||||
Preconditions.checkArgument(
|
||||
media.size() > 0, "media can not be empty when initializing peer connection");
|
||||
final boolean setUseHardwareAcousticEchoCanceler =
|
||||
WebRtcAudioEffects.canUseAcousticEchoCanceler()
|
||||
&& !HARDWARE_AEC_BLACKLIST.contains(Build.MODEL);
|
||||
final boolean setUseHardwareAcousticEchoCanceler = !HARDWARE_AEC_BLACKLIST.contains(Build.MODEL);
|
||||
Log.d(
|
||||
Config.LOGTAG,
|
||||
String.format(
|
||||
|
@ -574,11 +572,7 @@ public class WebRTCWrapper {
|
|||
new SetSdpObserver() {
|
||||
@Override
|
||||
public void onSetSuccess() {
|
||||
final SessionDescription description =
|
||||
peerConnection.getLocalDescription();
|
||||
Log.d(EXTENDED_LOGGING_TAG, "set local description:");
|
||||
logDescription(description);
|
||||
future.set(description);
|
||||
future.setFuture(getLocalDescriptionFuture());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -592,6 +586,15 @@ public class WebRTCWrapper {
|
|||
MoreExecutors.directExecutor());
|
||||
}
|
||||
|
||||
private ListenableFuture<SessionDescription> getLocalDescriptionFuture() {
|
||||
return Futures.submit(() -> {
|
||||
final SessionDescription description = requirePeerConnection().getLocalDescription();
|
||||
Log.d(EXTENDED_LOGGING_TAG, "local description:");
|
||||
logDescription(description);
|
||||
return description;
|
||||
},executorService);
|
||||
}
|
||||
|
||||
public static void logDescription(final SessionDescription sessionDescription) {
|
||||
for (final String line :
|
||||
sessionDescription.description.split(
|
||||
|
|
Loading…
Reference in a new issue