OLD | NEW |
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 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
278 true, /* videoCodecHwAcceleration */ | 278 true, /* videoCodecHwAcceleration */ |
279 false, /* captureToToTexture */ | 279 false, /* captureToToTexture */ |
280 // Audio codec parameters. | 280 // Audio codec parameters. |
281 0, /* audioStartBitrate */ | 281 0, /* audioStartBitrate */ |
282 "OPUS", /* audioCodec */ | 282 "OPUS", /* audioCodec */ |
283 false, /* noAudioProcessing */ | 283 false, /* noAudioProcessing */ |
284 false, /* aecDump */ | 284 false, /* aecDump */ |
285 false /* useOpenSLES */, | 285 false /* useOpenSLES */, |
286 false /* disableBuiltInAEC */, | 286 false /* disableBuiltInAEC */, |
287 false /* disableBuiltInAGC */, | 287 false /* disableBuiltInAGC */, |
288 false /* disableBuiltInNS */); | 288 false /* disableBuiltInNS */, |
| 289 false /* enableLevelControl */); |
289 return peerConnectionParameters; | 290 return peerConnectionParameters; |
290 } | 291 } |
291 | 292 |
292 private PeerConnectionParameters createParametersForVideoCall( | 293 private PeerConnectionParameters createParametersForVideoCall( |
293 String videoCodec, boolean captureToTexture) { | 294 String videoCodec, boolean captureToTexture) { |
294 final boolean useCamera2 = captureToTexture && Camera2Enumerator.isSupported
(); | 295 final boolean useCamera2 = captureToTexture && Camera2Enumerator.isSupported
(); |
295 | 296 |
296 PeerConnectionParameters peerConnectionParameters = | 297 PeerConnectionParameters peerConnectionParameters = |
297 new PeerConnectionParameters( | 298 new PeerConnectionParameters( |
298 true, /* videoCallEnabled */ | 299 true, /* videoCallEnabled */ |
299 true, /* loopback */ | 300 true, /* loopback */ |
300 false, /* tracing */ | 301 false, /* tracing */ |
301 // Video codec parameters. | 302 // Video codec parameters. |
302 useCamera2, /* useCamera2 */ | 303 useCamera2, /* useCamera2 */ |
303 0, /* videoWidth */ | 304 0, /* videoWidth */ |
304 0, /* videoHeight */ | 305 0, /* videoHeight */ |
305 0, /* videoFps */ | 306 0, /* videoFps */ |
306 0, /* videoStartBitrate */ | 307 0, /* videoStartBitrate */ |
307 videoCodec, /* videoCodec */ | 308 videoCodec, /* videoCodec */ |
308 true, /* videoCodecHwAcceleration */ | 309 true, /* videoCodecHwAcceleration */ |
309 captureToTexture, /* captureToToTexture */ | 310 captureToTexture, /* captureToToTexture */ |
310 // Audio codec parameters. | 311 // Audio codec parameters. |
311 0, /* audioStartBitrate */ | 312 0, /* audioStartBitrate */ |
312 "OPUS", /* audioCodec */ | 313 "OPUS", /* audioCodec */ |
313 false, /* noAudioProcessing */ | 314 false, /* noAudioProcessing */ |
314 false, /* aecDump */ | 315 false, /* aecDump */ |
315 false /* useOpenSLES */, | 316 false /* useOpenSLES */, |
316 false /* disableBuiltInAEC */, | 317 false /* disableBuiltInAEC */, |
317 false /* disableBuiltInAGC */, | 318 false /* disableBuiltInAGC */, |
318 false /* disableBuiltInNS */); | 319 false /* disableBuiltInNS */, |
| 320 false /* enableLevelControl */); |
319 return peerConnectionParameters; | 321 return peerConnectionParameters; |
320 } | 322 } |
321 | 323 |
322 @Override | 324 @Override |
323 public void setUp() { | 325 public void setUp() { |
324 signalingExecutor = Executors.newSingleThreadExecutor(); | 326 signalingExecutor = Executors.newSingleThreadExecutor(); |
325 if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) { | 327 if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.JELLY_BEAN_MR1) { |
326 eglBase = EglBase.create(); | 328 eglBase = EglBase.create(); |
327 } | 329 } |
328 } | 330 } |
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
664 assertTrue("Remote video frames were not rendered after capture format cha
nge.", | 666 assertTrue("Remote video frames were not rendered after capture format cha
nge.", |
665 remoteRenderer.waitForFramesRendered(WAIT_TIMEOUT)); | 667 remoteRenderer.waitForFramesRendered(WAIT_TIMEOUT)); |
666 } | 668 } |
667 | 669 |
668 pcClient.close(); | 670 pcClient.close(); |
669 assertTrue(waitForPeerConnectionClosed(WAIT_TIMEOUT)); | 671 assertTrue(waitForPeerConnectionClosed(WAIT_TIMEOUT)); |
670 Log.d(TAG, "testCaptureFormatChange done."); | 672 Log.d(TAG, "testCaptureFormatChange done."); |
671 } | 673 } |
672 | 674 |
673 } | 675 } |
OLD | NEW |