Merge pull request #2134 from drhill/dev-v2_passthroughChannelFix
fix 6.1 channel passthrough failing
This commit is contained in:
commit
efc8f6fe42
@ -443,6 +443,19 @@ public final class AudioTrack {
|
|||||||
default:
|
default:
|
||||||
throw new IllegalArgumentException("Unsupported channel count: " + channelCount);
|
throw new IllegalArgumentException("Unsupported channel count: " + channelCount);
|
||||||
}
|
}
|
||||||
|
if (Util.SDK_INT <= 23 && "foster".equals(Util.DEVICE) && "NVIDIA".equals(Util.MANUFACTURER)) {
|
||||||
|
switch(channelCount) {
|
||||||
|
case 7:
|
||||||
|
channelConfig = C.CHANNEL_OUT_7POINT1_SURROUND;
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
case 5:
|
||||||
|
channelConfig = AudioFormat.CHANNEL_OUT_5POINT1;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
boolean passthrough = !MimeTypes.AUDIO_RAW.equals(mimeType);
|
boolean passthrough = !MimeTypes.AUDIO_RAW.equals(mimeType);
|
||||||
@C.Encoding int sourceEncoding;
|
@C.Encoding int sourceEncoding;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user