/cts/tests/tests/media/audio/src/android/media/audio/cts/ |
D | AudioTrackNative.java | 43 public boolean open(int numChannels, int sampleRate, boolean useFloat, int numBuffers) { in open() argument 44 return open(numChannels, 0, sampleRate, useFloat, numBuffers); in open() 47 public boolean open(int numChannels, int channelMask, int sampleRate, in open() argument 50 sampleRate, useFloat, numBuffers) == STATUS_OK) { in open() 115 public static boolean test(int numChannels, int sampleRate, boolean useFloat, in test() argument 117 return test(numChannels, 0, sampleRate, useFloat, msecPerBuffer, numBuffers); in test() 120 public static boolean test(int numChannels, int channelMask, int sampleRate, boolean useFloat, in test() argument 122 return nativeTest(numChannels, channelMask, sampleRate, useFloat, msecPerBuffer, numBuffers) in test() 151 int sampleRate, boolean useFloat, int numBuffers); in nativeOpen() argument 168 int numChannels, int channelMask, int sampleRate, in nativeTest() argument
|
D | AudioRecordNative.java | 41 public boolean open(int numChannels, int sampleRate, boolean useFloat, int numBuffers) { in open() argument 42 return open(numChannels, 0, sampleRate, useFloat,numBuffers); in open() 45 public boolean open(int numChannels, int channelMask, int sampleRate, in open() argument 48 sampleRate, useFloat, numBuffers) == STATUS_OK) { in open() 113 public static boolean test(int numChannels, int sampleRate, boolean useFloat, in test() argument 115 return test(numChannels, 0, sampleRate, useFloat, msecPerBuffer, numBuffers); in test() 118 public static boolean test(int numChannels, int channelMask, int sampleRate, boolean useFloat, in test() argument 120 return nativeTest(numChannels, channelMask, sampleRate, useFloat, msecPerBuffer, numBuffers) in test() 149 int sampleRate, boolean useFloat, int numBuffers); in nativeOpen() argument 167 int numChannels, int channelMask, int sampleRate, in nativeTest() argument
|
D | AudioTrackSurroundTest.java | 193 private static AudioTrack createAudioTrack(int sampleRate, int encoding, int channelConfig) { in createAudioTrack() argument 196 sampleRate, channelConfig, in createAudioTrack() 201 sampleRate, channelConfig, in createAudioTrack() 235 void checkIndividualTimestamps(int sampleRate) { in checkIndividualTimestamps() argument 258 / sampleRate; in checkIndividualTimestamps() 267 + ", srate = " + sampleRate in checkIndividualTimestamps() 326 SamplePlayerBase(int sampleRate, int encoding, int channelConfig) { in SamplePlayerBase() argument 327 mSampleRate = sampleRate; in SamplePlayerBase() 417 SamplePlayerShorts(int sampleRate, int encoding, int channelConfig) { in SamplePlayerShorts() argument 418 super(sampleRate, encoding, channelConfig); in SamplePlayerShorts() [all …]
|
D | DirectAudioProfilesForAttributesTest.kt | 115 sampleRates.map { sampleRate -> in <lambda>() method 119 .setSampleRate(sampleRate) in <lambda>() 126 .setSampleRate(sampleRate) in <lambda>()
|
D | AudioNativeTest.java | 351 int numChannels, int sampleRate, boolean useFloat, in doRecordTest() argument 356 assertTrue(TEST_NAME, record.open(numChannels, sampleRate, useFloat, in doRecordTest() 361 (int)((long)sampleRate * segmentDurationMs * numChannels / 1000); in doRecordTest() 409 public boolean open(int numChannels, int sampleRate, boolean useFloat, int numBuffers) { in open() argument 410 if (super.open(numChannels, sampleRate, useFloat, numBuffers)) { in open() 411 if (!mTrack.open(numChannels, sampleRate, useFloat, 2 /* numBuffers */)) { in open()
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/ |
D | AudioRecordHelper.java | 28 private final int sampleRate; field in AudioRecordHelper 56 sampleRate = tmpSampleRate; in AudioRecordHelper() 58 Log.d(TAG, "Sample rate = " + sampleRate + "Hz, Source = " in AudioRecordHelper() 76 audioRecord = new AudioRecord(source, sampleRate, CHANNEL, ENCODING, bufferSize); in start() 121 return sampleRate; in getSampleRate()
|
D | WavAnalyzer.java | 15 private final int sampleRate; // Recording sampling rate. field in WavAnalyzer 27 public WavAnalyzer(byte[] byteData, int sampleRate, Listener listener) { in WavAnalyzer() argument 29 this.sampleRate = sampleRate; in WavAnalyzer() 137 + Util.toLength(Common.PREFIX_LENGTH_S + Common.PAUSE_AFTER_PREFIX_DURATION_S, sampleRate); in measurePipStrength() 139 listener.sendMessage("Prefix starts at " + (double) dataStartI / sampleRate + " s \n"); in measurePipStrength() 140 if (dataStartI > Math.round(sampleRate * (Common.PREFIX_LENGTH_S in measurePipStrength() 163 -2.0 * Math.PI * freq / sampleRate).exp(); in measurePipStrength() 191 + Util.toLength(i * (Common.PIP_DURATION_S + Common.PAUSE_DURATION_S), sampleRate); in measurePipStrength() 200 -2.0 * Math.PI * Common.FREQUENCIES[i] / sampleRate).exp(); in measurePipStrength() 226 int fftSize = Util.nextPowerOfTwo((int) Math.round(sampleRate * (Common.PREFIX_LENGTH_S in alignData()
|
/cts/apps/CtsVerifier/src/org/hyphonate/megaaudio/player/ |
D | NativeAudioSource.java | 37 public void setSampleRate(int sampleRate) { in setSampleRate() argument 38 setSampleRateN(mNativeSourcePtr, sampleRate); in setSampleRate() 66 private native void setSampleRateN(long nativeSourcePtr, int sampleRate); in setSampleRateN() argument
|
D | AudioSource.java | 29 public void setSampleRate(int sampleRate) {} in setSampleRate() argument
|
/cts/tests/tests/systemui/AudioRecorderTestApp_AudioRecord/src/android/systemui/cts/audiorecorder/audiorecord/ |
D | AudioRecorderService.java | 49 final int sampleRate = 32000; in run() local 51 … final int bufferSizeInBytes = 2 * AudioRecord.getMinBufferSize(sampleRate, channelConfig, in run() 58 .setSampleRate(sampleRate) in run()
|
/cts/tests/tests/media/common/src/android/media/cts/ |
D | AudioHelper.java | 66 public static byte[] createSoundDataInByteArray(int bufferSamples, final int sampleRate, in createSoundDataInByteArray() argument 68 final double rad = 2 * Math.PI * frequency / sampleRate; in createSoundDataInByteArray() 70 sweep = Math.PI * sweep / ((double)sampleRate * vai.length); in createSoundDataInByteArray() 79 public static short[] createSoundDataInShortArray(int bufferSamples, final int sampleRate, in createSoundDataInShortArray() argument 81 final double rad = 2 * Math.PI * frequency / sampleRate; in createSoundDataInShortArray() 83 sweep = Math.PI * sweep / ((double)sampleRate * vai.length); in createSoundDataInShortArray() 90 public static float[] createSoundDataInFloatArray(int bufferSamples, final int sampleRate, in createSoundDataInFloatArray() argument 92 final double rad = 2 * Math.PI * frequency / sampleRate; in createSoundDataInFloatArray() 94 sweep = Math.PI * sweep / ((double)sampleRate * vaf.length); in createSoundDataInFloatArray() 111 final int sampleRate, final double frequency, double sweep) { in createSoundDataInShortByteBuffer() argument [all …]
|
D | NonBlockingAudioTrack.java | 62 public NonBlockingAudioTrack(int sampleRate, int channelCount, boolean hwAvSync, in NonBlockingAudioTrack() argument 81 sampleRate, in NonBlockingAudioTrack() 90 sampleRate, in NonBlockingAudioTrack() 105 .setSampleRate(sampleRate) in NonBlockingAudioTrack() 111 mSampleRate = sampleRate; in NonBlockingAudioTrack()
|
/cts/apps/CtsVerifier/src/org/hyphonate/megaaudio/duplex/ |
D | DuplexAudioManager.java | 89 public void setPlayerSampleRate(int sampleRate) { in setPlayerSampleRate() argument 90 mPlayerSampleRate = sampleRate; in setPlayerSampleRate() 93 public void setRecordererSampleRate(int sampleRate) { in setRecordererSampleRate() argument 94 mPlayerSampleRate = sampleRate; in setRecordererSampleRate() 126 public void setRecorderSampleRate(int sampleRate) { in setRecorderSampleRate() argument 127 mRecorderSampleRate = sampleRate; in setRecorderSampleRate()
|
/cts/tests/tests/nativemedia/aaudio/jni/ |
D | test_aaudio.cpp | 142 const int64_t frameTimeDelta = (frameIndexDelta * NANOS_PER_SECOND) / actual().sampleRate; in getLatency() 149 const int32_t frames = actual().sampleRate; in testTimestamp() 222 const int32_t framesPerMsec = actual().sampleRate / MILLIS_PER_SECOND; in SetUp() 246 const int32_t framesToRecord = actual().sampleRate; // 1 second in TEST_P() 269 const int32_t framesToRecord = actual().sampleRate / 8; in TEST_P() 296 const int32_t framesToRecord = actual().sampleRate / 10; // 1/10 second in TEST_P() 423 writeLoops = 1 * actual().sampleRate / framesPerBurst(); // 1 second in TEST_P() 426 actual().sampleRate); // N bursts in TEST_P() 525 writeLoops = 1 * actual().sampleRate / framesPerBurst(); // 1 second in TEST_P() 531 actual().sampleRate); in TEST_P() [all …]
|
D | utils.cpp | 99 aaudio_direction_t direction, int32_t sampleRate, in StreamBuilderHelper() argument 103 mRequested{sampleRate, channelCount, dataFormat, sharingMode, perfMode}, 122 AAudioStreamBuilder_setSampleRate(mBuilder, mRequested.sampleRate); in initBuilder() 153 mActual.sampleRate = AAudioStream_getSampleRate(mStream); in createAndVerifyStream() 154 ASSERT_GE(mActual.sampleRate, kMinValidSampleRate); in createAndVerifyStream() 155 ASSERT_LE(mActual.sampleRate, kMaxValidSampleRate); in createAndVerifyStream() 190 mActual.sampleRate * sMaxFramesPerBurstMs.at(mActual.perfMode) / MILLIS_PER_SECOND; in createAndVerifyStream()
|
/cts/apps/CtsVerifier/src/org/hyphonate/megaaudio/recorder/ |
D | Recorder.java | 87 public static int calcMinBufferFramesStatic(int channelCount, int sampleRate) { in calcMinBufferFramesStatic() argument 90 AudioRecord.getMinBufferSize (sampleRate, in calcMinBufferFramesStatic()
|
/cts/apps/CtsVerifier/src/org/hyphonate/megaaudio/common/ |
D | BuilderBase.java | 121 public BuilderBase setSampleRate(int sampleRate) { in setSampleRate() argument 122 mSampleRate = sampleRate; in setSampleRate()
|
/cts/tests/mediapc/src/android/mediapc/cts/ |
D | AudioPlaybackLoad.java | 71 final int sampleRate = format.getInteger(MediaFormat.KEY_SAMPLE_RATE); in createAudioTrack() local 74 .setSampleRate(sampleRate) in createAudioTrack() 81 final int minBufferSize = AudioTrack.getMinBufferSize(sampleRate, channelMask, encoding); in createAudioTrack()
|
/cts/tests/media/src/android/mediav2/cts/ |
D | AudioEncoderTest.java | 71 int sampleRate, int channelCount, int pcmEncoding) { in getAudioEncoderCfgParams() argument 73 .setSampleRate(sampleRate) in getAudioEncoderCfgParams() 93 for (int sampleRate : sampleRates) { in flattenParams() 97 testArgs[1] = getAudioEncoderCfgParams(mediaType, qualityPreset, sampleRate, in flattenParams() 103 "kbps", sampleRate / 1000, channelCount, in flattenParams()
|
/cts/tests/tests/media/audio/modules/audiorecordpermissiontests/lib/src/android/media/audio/cts/audiorecordpermissiontests/common/ |
D | RecordService.kt | 115 val sampleRate = 32000 in record() constant 117 val bufferSizeInBytes = 2 * AudioRecord.getMinBufferSize(sampleRate, channelConfig, in record() 123 .setSampleRate(sampleRate) in record()
|
/cts/tests/media/common/src/android/mediav2/common/cts/ |
D | RawResource.java | 87 public Builder setSampleRate(int sampleRate) { in setSampleRate() argument 88 this.mSampleRate = sampleRate; in setSampleRate()
|
/cts/tests/tests/media/audio/jni/ |
D | audio-record-native.cpp | 82 uint32_t sampleRate, in open() argument 125 pcm.sampleRate = sampleRate * 1000; in open() 173 mBufferSize = (BUFFER_SIZE_MSEC * sampleRate / 1000) in open() 468 jint numChannels, jint channelMask, jint sampleRate, in Java_android_media_audio_cts_AudioRecordNative_nativeTest() argument 472 const size_t framesPerBuffer = msecPerBuffer * sampleRate / 1000; in Java_android_media_audio_cts_AudioRecordNative_nativeTest() 477 res = record.open(numChannels, channelMask, sampleRate, useFloat, numBuffers); in Java_android_media_audio_cts_AudioRecordNative_nativeTest() 515 jint numChannels, jint channelMask, jint sampleRate, jboolean useFloat, jint numBuffers) in Java_android_media_audio_cts_AudioRecordNative_nativeOpen() argument 521 return (jint) record->open(numChannels, channelMask, sampleRate, useFloat == JNI_TRUE, in Java_android_media_audio_cts_AudioRecordNative_nativeOpen()
|
D | audio-track-native.cpp | 74 jint sampleRate, jboolean useFloat, jint numBuffers) { in open() argument 110 pcm.sampleRate = sampleRate * 1000; in open() 379 jint numChannels, jint channelMask, jint sampleRate, jboolean useFloat, in Java_android_media_audio_cts_AudioTrackNative_nativeTest() argument 384 const size_t framesPerBuffer = msecPerBuffer * sampleRate / 1000; in Java_android_media_audio_cts_AudioTrackNative_nativeTest() 389 res = track.open(numChannels, channelMask, sampleRate, useFloat, numBuffers); in Java_android_media_audio_cts_AudioTrackNative_nativeTest() 428 jint numChannels, jint channelMask, jint sampleRate, in Java_android_media_audio_cts_AudioTrackNative_nativeOpen() argument 437 sampleRate, in Java_android_media_audio_cts_AudioTrackNative_nativeOpen()
|
/cts/apps/CtsVerifier/jni/megaaudio/player/ |
D | WaveTableSource.cpp | 28 void WaveTableSource::setSampleRate(int sampleRate) { in setSampleRate() argument 29 mSampleRate = sampleRate; in setSampleRate()
|
/cts/apps/CtsVerifier/jni/audio_loopback/analyzer/ |
D | LatencyAnalyzer.h | 165 void setSampleRate(int32_t sampleRate) { in setSampleRate() argument 166 mSampleRate = sampleRate; in setSampleRate() 352 virtual void setSampleRate(int32_t sampleRate) { in setSampleRate() argument 353 mSampleRate = sampleRate; in setSampleRate() 447 void setSampleRate(int32_t sampleRate) override { in setSampleRate() argument 448 LoopbackProcessor::setSampleRate(sampleRate); in setSampleRate() 449 mAudioRecording.setSampleRate(sampleRate); in setSampleRate()
|