Home | History | Annotate | Download | only in libaudioclient

Lines Matching full:samplerate

56 static inline nsecs_t framesToNanoseconds(ssize_t frames, uint32_t sampleRate, float speed)
58 return ((double)frames * 1000000000) / ((double)sampleRate * speed);
85 static inline uint32_t adjustSampleRate(uint32_t sampleRate, float pitch)
87 return kFixPitch ? (sampleRate * pitch + 0.5) : sampleRate;
104 uint32_t sampleRate, float speed /*, uint32_t notificationsPerBufferReq*/)
119 "sampleRate %u speed %f minBufCount: %u" /*" notificationsPerBufferReq %u"*/,
120 afLatencyMs, afFrameCount, afSampleRate, sampleRate, speed, minBufCount
123 sampleRate, afFrameCount, afSampleRate, speed);
130 uint32_t sampleRate)
166 *frameCount = calculateMinFrameCount(afLatency, afFrameCount, afSampleRate, sampleRate, 1.0f
170 // AudioTrack.SAMPLE_RATE_HZ_MIN <= sampleRate <= AudioTrack.SAMPLE_RATE_HZ_MAX.
173 ALOGE("AudioTrack::getMinFrameCount failed for streamType %d, sampleRate %u",
174 streamType, sampleRate);
202 uint32_t sampleRate,
226 mStatus = set(streamType, sampleRate, format, channelMask,
234 uint32_t sampleRate,
258 mStatus = set(streamType, sampleRate, format, channelMask,
294 uint32_t sampleRate,
313 ALOGV("set(): streamType %d, sampleRate %u, format %#x, channelMask %#x, frameCount %zu, "
315 streamType, sampleRate, format, channelMask, frameCount, flags, notificationFrames,
450 if (sampleRate == 0 && (flags & AUDIO_OUTPUT_FLAG_DIRECT) != 0) {
453 mSampleRate = sampleRate;
454 mOriginalSampleRate = sampleRate;
855 // pitch is emulated by adjusting speed and sampleRate
877 uint32_t sampleRate = 0;
878 status_t status = AudioSystem::getSamplingRate(mOutput, &sampleRate);
880 mSampleRate = sampleRate;
907 // pitch is emulated by adjusting speed and sampleRate
1974 uint32_t sampleRate = mSampleRate;
2122 const nsecs_t estimatedNs = framesToNanoseconds(minFrames, sampleRate, speed);
2181 nsecs_t myns = framesToNanoseconds(mRemainingFrames - avail, sampleRate, speed);
2223 framesToNanoseconds(mRemainingFrames - avail, sampleRate, speed);
2273 return ((double)mRemainingFrames * 1100000000) / ((double)sampleRate * speed);
2401 bool AudioTrack::isSampleRateSpeedAllowed_l(uint32_t sampleRate, float speed)
2409 calculateMinFrameCount(mAfLatency, mAfFrameCount, mAfSampleRate, sampleRate, speed
2414 "mAfLatency:%u mAfFrameCount:%zu mAfSampleRate:%u sampleRate:%u speed:%f "
2416 mAfLatency, mAfFrameCount, mAfSampleRate, sampleRate, speed,
2783 ALOGD("computedSampleRate:%u sampleRate:%u",