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

Side by Side Diff: webrtc/examples/androidapp/src/org/appspot/apprtc/PeerConnectionClient.java

Issue 2625903005: Reland of Android: Add field trial for Intel HW Vp8 encoder (Closed)
Patch Set: Ignore field trials when jingle_peerconnection_so is not available Created 3 years, 11 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
« no previous file with comments | « no previous file | webrtc/sdk/android/api/org/webrtc/MediaCodecVideoEncoder.java » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2014 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 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 public static final String AUDIO_TRACK_ID = "ARDAMSa0"; 66 public static final String AUDIO_TRACK_ID = "ARDAMSa0";
67 public static final String VIDEO_TRACK_TYPE = "video"; 67 public static final String VIDEO_TRACK_TYPE = "video";
68 private static final String TAG = "PCRTCClient"; 68 private static final String TAG = "PCRTCClient";
69 private static final String VIDEO_CODEC_VP8 = "VP8"; 69 private static final String VIDEO_CODEC_VP8 = "VP8";
70 private static final String VIDEO_CODEC_VP9 = "VP9"; 70 private static final String VIDEO_CODEC_VP9 = "VP9";
71 private static final String VIDEO_CODEC_H264 = "H264"; 71 private static final String VIDEO_CODEC_H264 = "H264";
72 private static final String AUDIO_CODEC_OPUS = "opus"; 72 private static final String AUDIO_CODEC_OPUS = "opus";
73 private static final String AUDIO_CODEC_ISAC = "ISAC"; 73 private static final String AUDIO_CODEC_ISAC = "ISAC";
74 private static final String VIDEO_CODEC_PARAM_START_BITRATE = "x-google-start- bitrate"; 74 private static final String VIDEO_CODEC_PARAM_START_BITRATE = "x-google-start- bitrate";
75 private static final String VIDEO_FLEXFEC_FIELDTRIAL = "WebRTC-FlexFEC-03/Enab led/"; 75 private static final String VIDEO_FLEXFEC_FIELDTRIAL = "WebRTC-FlexFEC-03/Enab led/";
76 private static final String VIDEO_VP8_INTEL_HW_ENCODER_FIELDTRIAL = "WebRTC-In telVP8/Enabled/";
76 private static final String AUDIO_CODEC_PARAM_BITRATE = "maxaveragebitrate"; 77 private static final String AUDIO_CODEC_PARAM_BITRATE = "maxaveragebitrate";
77 private static final String AUDIO_ECHO_CANCELLATION_CONSTRAINT = "googEchoCanc ellation"; 78 private static final String AUDIO_ECHO_CANCELLATION_CONSTRAINT = "googEchoCanc ellation";
78 private static final String AUDIO_AUTO_GAIN_CONTROL_CONSTRAINT = "googAutoGain Control"; 79 private static final String AUDIO_AUTO_GAIN_CONTROL_CONSTRAINT = "googAutoGain Control";
79 private static final String AUDIO_HIGH_PASS_FILTER_CONSTRAINT = "googHighpassF ilter"; 80 private static final String AUDIO_HIGH_PASS_FILTER_CONSTRAINT = "googHighpassF ilter";
80 private static final String AUDIO_NOISE_SUPPRESSION_CONSTRAINT = "googNoiseSup pression"; 81 private static final String AUDIO_NOISE_SUPPRESSION_CONSTRAINT = "googNoiseSup pression";
81 private static final String AUDIO_LEVEL_CONTROL_CONSTRAINT = "levelControl"; 82 private static final String AUDIO_LEVEL_CONTROL_CONSTRAINT = "levelControl";
82 private static final String DTLS_SRTP_KEY_AGREEMENT_CONSTRAINT = "DtlsSrtpKeyA greement"; 83 private static final String DTLS_SRTP_KEY_AGREEMENT_CONSTRAINT = "DtlsSrtpKeyA greement";
83 private static final int HD_VIDEO_WIDTH = 1280; 84 private static final int HD_VIDEO_WIDTH = 1280;
84 private static final int HD_VIDEO_HEIGHT = 720; 85 private static final int HD_VIDEO_HEIGHT = 720;
85 private static final int BPS_IN_KBPS = 1000; 86 private static final int BPS_IN_KBPS = 1000;
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 if (peerConnectionParameters.tracing) { 365 if (peerConnectionParameters.tracing) {
365 PeerConnectionFactory.startInternalTracingCapture( 366 PeerConnectionFactory.startInternalTracingCapture(
366 Environment.getExternalStorageDirectory().getAbsolutePath() + File.sep arator 367 Environment.getExternalStorageDirectory().getAbsolutePath() + File.sep arator
367 + "webrtc-trace.txt"); 368 + "webrtc-trace.txt");
368 } 369 }
369 Log.d(TAG, 370 Log.d(TAG,
370 "Create peer connection factory. Use video: " + peerConnectionParameters .videoCallEnabled); 371 "Create peer connection factory. Use video: " + peerConnectionParameters .videoCallEnabled);
371 isError = false; 372 isError = false;
372 373
373 // Initialize field trials. 374 // Initialize field trials.
375 String fieldTrials = "";
374 if (peerConnectionParameters.videoFlexfecEnabled) { 376 if (peerConnectionParameters.videoFlexfecEnabled) {
375 PeerConnectionFactory.initializeFieldTrials(VIDEO_FLEXFEC_FIELDTRIAL); 377 fieldTrials += VIDEO_FLEXFEC_FIELDTRIAL;
376 Log.d(TAG, "Enable FlexFEC field trial."); 378 Log.d(TAG, "Enable FlexFEC field trial.");
377 } else {
378 PeerConnectionFactory.initializeFieldTrials("");
379 } 379 }
380 fieldTrials += VIDEO_VP8_INTEL_HW_ENCODER_FIELDTRIAL;
381 PeerConnectionFactory.initializeFieldTrials(fieldTrials);
380 382
381 // Check preferred video codec. 383 // Check preferred video codec.
382 preferredVideoCodec = VIDEO_CODEC_VP8; 384 preferredVideoCodec = VIDEO_CODEC_VP8;
383 if (videoCallEnabled && peerConnectionParameters.videoCodec != null) { 385 if (videoCallEnabled && peerConnectionParameters.videoCodec != null) {
384 if (peerConnectionParameters.videoCodec.equals(VIDEO_CODEC_VP9)) { 386 if (peerConnectionParameters.videoCodec.equals(VIDEO_CODEC_VP9)) {
385 preferredVideoCodec = VIDEO_CODEC_VP9; 387 preferredVideoCodec = VIDEO_CODEC_VP9;
386 } else if (peerConnectionParameters.videoCodec.equals(VIDEO_CODEC_H264)) { 388 } else if (peerConnectionParameters.videoCodec.equals(VIDEO_CODEC_H264)) {
387 preferredVideoCodec = VIDEO_CODEC_H264; 389 preferredVideoCodec = VIDEO_CODEC_H264;
388 } 390 }
389 } 391 }
(...skipping 864 matching lines...) Expand 10 before | Expand all | Expand 10 after
1254 public void onCreateFailure(final String error) { 1256 public void onCreateFailure(final String error) {
1255 reportError("createSDP error: " + error); 1257 reportError("createSDP error: " + error);
1256 } 1258 }
1257 1259
1258 @Override 1260 @Override
1259 public void onSetFailure(final String error) { 1261 public void onSetFailure(final String error) {
1260 reportError("setSDP error: " + error); 1262 reportError("setSDP error: " + error);
1261 } 1263 }
1262 } 1264 }
1263 } 1265 }
OLDNEW
« no previous file with comments | « no previous file | webrtc/sdk/android/api/org/webrtc/MediaCodecVideoEncoder.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698