Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Side by Side Diff: webrtc/api/android/jni/peerconnection_jni.cc

Issue 2107303003: Adding API for "presume writable when fully relayed" ICE option. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Merging with master. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2013 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 1571 matching lines...) Expand 10 before | Expand all | Expand 10 after
1582 jni, j_rtc_config_class, "iceBackupCandidatePairPingInterval", "I"); 1582 jni, j_rtc_config_class, "iceBackupCandidatePairPingInterval", "I");
1583 1583
1584 jfieldID j_continual_gathering_policy_id = 1584 jfieldID j_continual_gathering_policy_id =
1585 GetFieldID(jni, j_rtc_config_class, "continualGatheringPolicy", 1585 GetFieldID(jni, j_rtc_config_class, "continualGatheringPolicy",
1586 "Lorg/webrtc/PeerConnection$ContinualGatheringPolicy;"); 1586 "Lorg/webrtc/PeerConnection$ContinualGatheringPolicy;");
1587 jobject j_continual_gathering_policy = 1587 jobject j_continual_gathering_policy =
1588 GetObjectField(jni, j_rtc_config, j_continual_gathering_policy_id); 1588 GetObjectField(jni, j_rtc_config, j_continual_gathering_policy_id);
1589 1589
1590 jfieldID j_ice_candidate_pool_size_id = 1590 jfieldID j_ice_candidate_pool_size_id =
1591 GetFieldID(jni, j_rtc_config_class, "iceCandidatePoolSize", "I"); 1591 GetFieldID(jni, j_rtc_config_class, "iceCandidatePoolSize", "I");
1592 jfieldID j_presume_writable_when_fully_relayed_id = GetFieldID(
1593 jni, j_rtc_config_class, "presumeWritableWhenFullyRelayed", "Z");
1592 1594
1593 rtc_config->type = 1595 rtc_config->type =
1594 JavaIceTransportsTypeToNativeType(jni, j_ice_transports_type); 1596 JavaIceTransportsTypeToNativeType(jni, j_ice_transports_type);
1595 rtc_config->bundle_policy = 1597 rtc_config->bundle_policy =
1596 JavaBundlePolicyToNativeType(jni, j_bundle_policy); 1598 JavaBundlePolicyToNativeType(jni, j_bundle_policy);
1597 rtc_config->rtcp_mux_policy = 1599 rtc_config->rtcp_mux_policy =
1598 JavaRtcpMuxPolicyToNativeType(jni, j_rtcp_mux_policy); 1600 JavaRtcpMuxPolicyToNativeType(jni, j_rtcp_mux_policy);
1599 rtc_config->tcp_candidate_policy = 1601 rtc_config->tcp_candidate_policy =
1600 JavaTcpCandidatePolicyToNativeType(jni, j_tcp_candidate_policy); 1602 JavaTcpCandidatePolicyToNativeType(jni, j_tcp_candidate_policy);
1601 rtc_config->candidate_network_policy = 1603 rtc_config->candidate_network_policy =
1602 JavaCandidateNetworkPolicyToNativeType(jni, j_candidate_network_policy); 1604 JavaCandidateNetworkPolicyToNativeType(jni, j_candidate_network_policy);
1603 JavaIceServersToJsepIceServers(jni, j_ice_servers, &rtc_config->servers); 1605 JavaIceServersToJsepIceServers(jni, j_ice_servers, &rtc_config->servers);
1604 rtc_config->audio_jitter_buffer_max_packets = 1606 rtc_config->audio_jitter_buffer_max_packets =
1605 GetIntField(jni, j_rtc_config, j_audio_jitter_buffer_max_packets_id); 1607 GetIntField(jni, j_rtc_config, j_audio_jitter_buffer_max_packets_id);
1606 rtc_config->audio_jitter_buffer_fast_accelerate = GetBooleanField( 1608 rtc_config->audio_jitter_buffer_fast_accelerate = GetBooleanField(
1607 jni, j_rtc_config, j_audio_jitter_buffer_fast_accelerate_id); 1609 jni, j_rtc_config, j_audio_jitter_buffer_fast_accelerate_id);
1608 rtc_config->ice_connection_receiving_timeout = 1610 rtc_config->ice_connection_receiving_timeout =
1609 GetIntField(jni, j_rtc_config, j_ice_connection_receiving_timeout_id); 1611 GetIntField(jni, j_rtc_config, j_ice_connection_receiving_timeout_id);
1610 rtc_config->ice_backup_candidate_pair_ping_interval = GetIntField( 1612 rtc_config->ice_backup_candidate_pair_ping_interval = GetIntField(
1611 jni, j_rtc_config, j_ice_backup_candidate_pair_ping_interval_id); 1613 jni, j_rtc_config, j_ice_backup_candidate_pair_ping_interval_id);
1612 rtc_config->continual_gathering_policy = 1614 rtc_config->continual_gathering_policy =
1613 JavaContinualGatheringPolicyToNativeType( 1615 JavaContinualGatheringPolicyToNativeType(
1614 jni, j_continual_gathering_policy); 1616 jni, j_continual_gathering_policy);
1615 rtc_config->ice_candidate_pool_size = 1617 rtc_config->ice_candidate_pool_size =
1616 GetIntField(jni, j_rtc_config, j_ice_candidate_pool_size_id); 1618 GetIntField(jni, j_rtc_config, j_ice_candidate_pool_size_id);
1619 rtc_config->presume_writable_when_fully_relayed = GetBooleanField(
1620 jni, j_rtc_config, j_presume_writable_when_fully_relayed_id);
1617 } 1621 }
1618 1622
1619 JOW(jlong, PeerConnectionFactory_nativeCreatePeerConnection)( 1623 JOW(jlong, PeerConnectionFactory_nativeCreatePeerConnection)(
1620 JNIEnv *jni, jclass, jlong factory, jobject j_rtc_config, 1624 JNIEnv *jni, jclass, jlong factory, jobject j_rtc_config,
1621 jobject j_constraints, jlong observer_p) { 1625 jobject j_constraints, jlong observer_p) {
1622 rtc::scoped_refptr<PeerConnectionFactoryInterface> f( 1626 rtc::scoped_refptr<PeerConnectionFactoryInterface> f(
1623 reinterpret_cast<PeerConnectionFactoryInterface*>( 1627 reinterpret_cast<PeerConnectionFactoryInterface*>(
1624 factoryFromJava(factory))); 1628 factoryFromJava(factory)));
1625 1629
1626 PeerConnectionInterface::RTCConfiguration rtc_config; 1630 PeerConnectionInterface::RTCConfiguration rtc_config;
(...skipping 664 matching lines...) Expand 10 before | Expand all | Expand 10 after
2291 return JavaStringFromStdString( 2295 return JavaStringFromStdString(
2292 jni, 2296 jni,
2293 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->id()); 2297 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->id());
2294 } 2298 }
2295 2299
2296 JOW(void, RtpReceiver_free)(JNIEnv* jni, jclass, jlong j_rtp_receiver_pointer) { 2300 JOW(void, RtpReceiver_free)(JNIEnv* jni, jclass, jlong j_rtp_receiver_pointer) {
2297 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->Release(); 2301 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->Release();
2298 } 2302 }
2299 2303
2300 } // namespace webrtc_jni 2304 } // namespace webrtc_jni
OLDNEW
« no previous file with comments | « webrtc/api/android/java/src/org/webrtc/PeerConnection.java ('k') | webrtc/api/peerconnectioninterface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698