Add OpenSL ES enable setting to AppRTCDemo (part 2).

It is now possible to enable OpenSL ES on devices that supports it.

Fix for https://codereview.webrtc.org/1449083002/

Review URL: https://codereview.webrtc.org/1455563002

Cr-Commit-Position: refs/heads/master@{#10678}
This commit is contained in:
henrika
2015-11-17 10:12:39 -08:00
committed by Commit bot
parent 2be7c54b13
commit 5c489c9d3e
2 changed files with 5 additions and 2 deletions

View File

@ -309,8 +309,11 @@ public class PeerConnectionClient {
// Enable/disable OpenSL ES playback.
if (!peerConnectionParameters.useOpenSLES) {
Log.d(TAG, "Disable OpenSL ES audio");
Log.d(TAG, "Disable OpenSL ES audio even if device supports it");
WebRtcAudioManager.setBlacklistDeviceForOpenSLESUsage(true /* enable */);
} else {
Log.d(TAG, "Allow OpenSL ES audio if device supports it");
WebRtcAudioManager.setBlacklistDeviceForOpenSLESUsage(false);
}
// Create peer connection factory.