@@ -72,7 +72,7 @@ public final class AudioCapabilities {
72
72
new ImmutableMap .Builder <Integer , Integer >()
73
73
.put (C .ENCODING_AC3 , 6 )
74
74
.put (C .ENCODING_AC4 , 6 )
75
- .put (C .ENCODING_DTS , 6 )
75
+ .put (C .ENCODING_DTS , 10 )
76
76
.put (C .ENCODING_E_AC3_JOC , 6 )
77
77
.put (C .ENCODING_E_AC3 , 8 )
78
78
.put (C .ENCODING_DTS_HD , 8 )
@@ -211,7 +211,8 @@ public Pair<Integer, Integer> getEncodingAndChannelConfigForPassthrough(Format f
211
211
return null ;
212
212
}
213
213
int channelCount ;
214
- if (format .channelCount == Format .NO_VALUE || encoding == C .ENCODING_E_AC3_JOC ) {
214
+ if (format .channelCount == Format .NO_VALUE || encoding == C .ENCODING_E_AC3_JOC
215
+ || encoding == C .ENCODING_DTS ) {
215
216
// In HLS chunkless preparation, the format channel count and sample rate may be unset. See
216
217
// https://github.com/google/ExoPlayer/issues/10204 and b/222127949 for more details.
217
218
// For E-AC3 JOC, the format is object based so the format channel count is arbitrary.
@@ -220,13 +221,7 @@ public Pair<Integer, Integer> getEncodingAndChannelConfigForPassthrough(Format f
220
221
channelCount = getMaxSupportedChannelCountForPassthrough (encoding , sampleRate );
221
222
} else {
222
223
channelCount = format .channelCount ;
223
- if (format .sampleMimeType == MimeTypes .AUDIO_DTS_X ) {
224
- if (channelCount > 10 ) {
225
- // To fix wrong reporting from device. ChannelCount is reported as 8 for DTS:X P2
226
- // on some devices.
227
- return null ;
228
- }
229
- } else if (channelCount > maxChannelCount ) {
224
+ if (channelCount > maxChannelCount ) {
230
225
return null ;
231
226
}
232
227
}
0 commit comments