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

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

Issue 2354883002: Add new Camera2Enumerator.isSupported with Context parameter. (Closed)
Patch Set: Cleanup. Created 4 years, 3 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 2015 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2015 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 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 logAndToast(getString(R.string.missing_url)); 225 logAndToast(getString(R.string.missing_url));
226 Log.e(TAG, "Incorrect room ID in intent!"); 226 Log.e(TAG, "Incorrect room ID in intent!");
227 setResult(RESULT_CANCELED); 227 setResult(RESULT_CANCELED);
228 finish(); 228 finish();
229 return; 229 return;
230 } 230 }
231 231
232 boolean loopback = intent.getBooleanExtra(EXTRA_LOOPBACK, false); 232 boolean loopback = intent.getBooleanExtra(EXTRA_LOOPBACK, false);
233 boolean tracing = intent.getBooleanExtra(EXTRA_TRACING, false); 233 boolean tracing = intent.getBooleanExtra(EXTRA_TRACING, false);
234 234
235 boolean useCamera2 = Camera2Enumerator.isSupported() 235 boolean useCamera2 = Camera2Enumerator.isSupported(this)
236 && intent.getBooleanExtra(EXTRA_CAMERA2, true); 236 && intent.getBooleanExtra(EXTRA_CAMERA2, true);
237 237
238 peerConnectionParameters = new PeerConnectionParameters( 238 peerConnectionParameters = new PeerConnectionParameters(
239 intent.getBooleanExtra(EXTRA_VIDEO_CALL, true), 239 intent.getBooleanExtra(EXTRA_VIDEO_CALL, true),
240 loopback, 240 loopback,
241 tracing, 241 tracing,
242 useCamera2, 242 useCamera2,
243 intent.getIntExtra(EXTRA_VIDEO_WIDTH, 0), 243 intent.getIntExtra(EXTRA_VIDEO_WIDTH, 0),
244 intent.getIntExtra(EXTRA_VIDEO_HEIGHT, 0), 244 intent.getIntExtra(EXTRA_VIDEO_HEIGHT, 0),
245 intent.getIntExtra(EXTRA_VIDEO_FPS, 0), 245 intent.getIntExtra(EXTRA_VIDEO_FPS, 0),
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after
729 } 729 }
730 } 730 }
731 }); 731 });
732 } 732 }
733 733
734 @Override 734 @Override
735 public void onPeerConnectionError(final String description) { 735 public void onPeerConnectionError(final String description) {
736 reportError(description); 736 reportError(description);
737 } 737 }
738 } 738 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698