mirror of
https://github.com/androidx/media.git
synced 2025-05-14 11:09:53 +08:00
Rename FloatResamplingAudioProcessor
to ToFloatPcmAudioProcessor
.
Resampling as a term is overloaded, however it was raised as a confusing term in a meeting recently, as the 1P team initially thought this would change the sample rate. The naming of this `AudioProcessor` now matches `ToInt16PcmAudioProcessor`. PiperOrigin-RevId: 503441019
This commit is contained in:
parent
bb11e0286e
commit
eda7cd2405
@ -545,7 +545,7 @@ public final class DefaultAudioSink implements AudioSink {
|
||||
toIntPcmAvailableAudioProcessors =
|
||||
ImmutableList.of(
|
||||
new ToInt16PcmAudioProcessor(), channelMappingAudioProcessor, trimmingAudioProcessor);
|
||||
toFloatPcmAvailableAudioProcessors = ImmutableList.of(new FloatResamplingAudioProcessor());
|
||||
toFloatPcmAvailableAudioProcessors = ImmutableList.of(new ToFloatPcmAudioProcessor());
|
||||
volume = 1f;
|
||||
audioAttributes = AudioAttributes.DEFAULT;
|
||||
audioSessionId = C.AUDIO_SESSION_ID_UNSET;
|
||||
|
@ -33,7 +33,7 @@ import java.nio.ByteBuffer;
|
||||
* <li>{@link C#ENCODING_PCM_FLOAT} ({@link #isActive()} will return {@code false})
|
||||
* </ul>
|
||||
*/
|
||||
/* package */ final class FloatResamplingAudioProcessor extends BaseAudioProcessor {
|
||||
/* package */ final class ToFloatPcmAudioProcessor extends BaseAudioProcessor {
|
||||
|
||||
private static final int FLOAT_NAN_AS_INT = Float.floatToIntBits(Float.NaN);
|
||||
private static final double PCM_32_BIT_INT_TO_PCM_32_BIT_FLOAT_FACTOR = 1.0 / 0x7FFFFFFF;
|
Loading…
x
Reference in New Issue
Block a user