/frameworks/native/libs/ui/ |
D | FrameStats.cpp | 41 size_t frameCount = desiredPresentTimesNano.size(); in flatten() local 46 memcpy(timestamps, desiredPresentTimesNano.array(), frameCount * timestampSize); in flatten() 47 timestamps += frameCount; in flatten() 49 memcpy(timestamps, actualPresentTimesNano.array(), frameCount * timestampSize); in flatten() 50 timestamps += frameCount; in flatten() 52 memcpy(timestamps, frameReadyTimesNano.array(), frameCount * timestampSize); in flatten() 65 size_t frameCount = (size - timestampSize) / (3 * timestampSize); in unflatten() local 70 desiredPresentTimesNano.resize(frameCount); in unflatten() 71 memcpy(desiredPresentTimesNano.editArray(), timestamps, frameCount * timestampSize); in unflatten() 72 timestamps += frameCount; in unflatten() [all …]
|
/frameworks/av/services/audioflinger/ |
D | FastCapture.cpp | 93 const size_t frameCount = current->mFrameCount; in onStateChange() local 129 if ((!Format_isEqual(mFormat, previousFormat)) || (frameCount != previous->mFrameCount)) { in onStateChange() 133 if (frameCount > 0 && mSampleRate > 0) { in onStateChange() 137 size_t bufferSize = frameCount * Format_frameSize(mFormat); in onStateChange() 140 mPeriodNs = (frameCount * 1000000000LL) / mSampleRate; // 1.00 in onStateChange() 141 mUnderrunNs = (frameCount * 1750000000LL) / mSampleRate; // 1.75 in onStateChange() 142 mOverrunNs = (frameCount * 500000000LL) / mSampleRate; // 0.50 in onStateChange() 143 mForceNs = (frameCount * 950000000LL) / mSampleRate; // 0.95 in onStateChange() 144 mWarmupNsMin = (frameCount * 750000000LL) / mSampleRate; // 0.75 in onStateChange() 145 mWarmupNsMax = (frameCount * 1250000000LL) / mSampleRate; // 1.25 in onStateChange() [all …]
|
D | FastMixer.cpp | 223 const size_t frameCount = current->mFrameCount; in onStateChange() local 261 if ((!Format_isEqual(mFormat, previousFormat)) || (frameCount != previous->mFrameCount)) { in onStateChange() 269 if (frameCount > 0 && mSampleRate > 0) { in onStateChange() 273 mMixer = new AudioMixer(frameCount, mSampleRate); in onStateChange() 276 params.frameCount = frameCount; in onStateChange() 281 mMixerBufferSize = mixerFrameSize * frameCount; in onStateChange() 286 mSinkBufferSize = sinkFrameSize * frameCount; in onStateChange() 289 mPeriodNs = (frameCount * 1000000000LL) / mSampleRate; // 1.00 in onStateChange() 290 mUnderrunNs = (frameCount * 1750000000LL) / mSampleRate; // 1.75 in onStateChange() 291 mOverrunNs = (frameCount * 500000000LL) / mSampleRate; // 0.50 in onStateChange() [all …]
|
D | Tracks.cpp | 86 size_t frameCount, in TrackBase() argument 112 mFrameCount(frameCount), in TrackBase() 137 size_t minBufferSize = buffer == NULL ? roundup(frameCount) : frameCount; in TrackBase() 139 if (minBufferSize < frameCount // roundup rounds down for values above UINT_MAX / 2 in TrackBase() 289 mTee.write(buffer->raw, buffer->frameCount); in releaseBuffer() 293 buf.mFrameCount = buffer->frameCount; in releaseBuffer() 295 buffer->frameCount = 0; in releaseBuffer() 315 uint64_t mixBufferNs = ((uint64_t)2 * thread.frameCount() * 1000000000) / in PatchTrackBase() 623 size_t frameCount, in Track() argument 636 : TrackBase(thread, client, attr, sampleRate, format, channelMask, frameCount, in Track() [all …]
|
/frameworks/av/media/libnbaio/ |
D | SourceAudioBufferProvider.cpp | 50 ALOG_ASSERT(buffer != NULL && buffer->frameCount > 0 && mGetCount == 0); in getNextBuffer() 54 if (mRemaining < buffer->frameCount) { in getNextBuffer() 55 buffer->frameCount = mRemaining; in getNextBuffer() 58 mGetCount = buffer->frameCount; in getNextBuffer() 62 if (buffer->frameCount > mSize) { in getNextBuffer() 67 mAllocated = calloc(buffer->frameCount, mFrameSize); in getNextBuffer() 72 mSize = buffer->frameCount; in getNextBuffer() 76 ssize_t actual = mSource->read(mAllocated, buffer->frameCount); in getNextBuffer() 78 ALOG_ASSERT((size_t) actual <= buffer->frameCount); in getNextBuffer() 82 buffer->frameCount = actual; in getNextBuffer() [all …]
|
D | AudioBufferProviderSource.cpp | 46 return mBuffer.raw != NULL ? mBuffer.frameCount - mConsumed : 0; in availableToRead() 55 mBuffer.frameCount = count; in read() 63 size_t available = mBuffer.frameCount - mConsumed; in read() 70 if (CC_UNLIKELY((mConsumed += count) >= mBuffer.frameCount)) { in read() 101 mBuffer.frameCount = count; in readVia() 104 ALOG_ASSERT(mBuffer.raw != NULL && mBuffer.frameCount <= count); in readVia() 115 size_t available = mBuffer.frameCount - mConsumed; in readVia() 131 if (CC_LIKELY((mConsumed += ret) < mBuffer.frameCount)) { in readVia()
|
/frameworks/av/media/libaudioprocessing/ |
D | BufferProviders.cpp | 57 mBuffer.frameCount = 0; in CopyBufferProvider() 63 __func__, this, mBuffer.frameCount, mTrackBufferProvider, mLocalBufferData); in ~CopyBufferProvider() 64 if (mBuffer.frameCount != 0) { in ~CopyBufferProvider() 77 copyFrames(pBuffer->raw, pBuffer->raw, pBuffer->frameCount); in getNextBuffer() 81 if (mBuffer.frameCount == 0) { in getNextBuffer() 82 mBuffer.frameCount = pBuffer->frameCount; in getNextBuffer() 89 ALOG_ASSERT(res == OK || mBuffer.frameCount == 0); in getNextBuffer() 90 if (res != OK || mBuffer.frameCount == 0) { // not needed by API spec, but to be safe. in getNextBuffer() 92 pBuffer->frameCount = 0; in getNextBuffer() 97 ALOG_ASSERT(mConsumed < mBuffer.frameCount); in getNextBuffer() [all …]
|
D | AudioResampler.cpp | 283 mBuffer.frameCount = 0; in AudioResampler() 314 mBuffer.frameCount = 0; in reset() 356 while (mBuffer.frameCount == 0) { in resampleStereo16() 357 mBuffer.frameCount = inFrameCount; in resampleStereo16() 364 if (mBuffer.frameCount > inputIndex) break; in resampleStereo16() 366 inputIndex -= mBuffer.frameCount; in resampleStereo16() 367 mX0L = mBuffer.i16[mBuffer.frameCount*2-2]; in resampleStereo16() 368 mX0R = mBuffer.i16[mBuffer.frameCount*2-1]; in resampleStereo16() 390 if (inputIndex + 2 < mBuffer.frameCount) { in resampleStereo16() 395 maxInIdx = mBuffer.frameCount - 2; in resampleStereo16() [all …]
|
D | AudioResamplerCubic.cpp | 67 if (mBuffer.frameCount == 0) { in resampleStereo16() 68 mBuffer.frameCount = inFrameCount; in resampleStereo16() 95 if (inputIndex == mBuffer.frameCount) { in resampleStereo16() 98 mBuffer.frameCount = inFrameCount; in resampleStereo16() 134 if (mBuffer.frameCount == 0) { in resampleMono16() 135 mBuffer.frameCount = inFrameCount; in resampleMono16() 163 if (inputIndex == mBuffer.frameCount) { in resampleMono16() 166 mBuffer.frameCount = inFrameCount; in resampleMono16()
|
D | AudioMixerBase.cpp | 795 int32_t* out, size_t frameCount, int32_t* temp, int32_t* aux) in volumeRampStereo() argument 822 } while (--frameCount); in volumeRampStereo() 830 } while (--frameCount); in volumeRampStereo() 838 int32_t* out, size_t frameCount, int32_t* temp, int32_t* aux) in volumeStereo() argument 854 } while (--frameCount); in volumeStereo() 862 } while (--frameCount); in volumeStereo() 867 int32_t* out, size_t frameCount, int32_t* temp __unused, int32_t* aux) in track__16BitsStereo() argument 896 } while (--frameCount); in track__16BitsStereo() 917 } while (--frameCount); in track__16BitsStereo() 936 } while (--frameCount); in track__16BitsStereo() [all …]
|
D | AudioResamplerDyn.cpp | 670 ALOG_ASSERT(inputIndex <= mBuffer.frameCount, "inputIndex%zu > frameCount%zu", in resample() 671 inputIndex, mBuffer.frameCount); in resample() 674 while (mBuffer.frameCount == 0 && inFrameCount > 0) { in resample() 675 mBuffer.frameCount = inFrameCount; in resample() 683 inFrameCount -= mBuffer.frameCount; in resample() 691 if (inputIndex >= mBuffer.frameCount) { in resample() 705 const size_t frameCount = mBuffer.frameCount; in resample() local 732 if (inputIndex >= frameCount) { in resample() 744 ALOG_ASSERT(inputIndex == frameCount, "inputIndex(%zu) != frameCount(%zu)", in resample() 745 inputIndex, frameCount); // must have been fully read. in resample() [all …]
|
/frameworks/av/media/libeffects/testlibs/ |
D | AudioBiquadFilter.cpp | 66 int frameCount) { in process() argument 67 (this->*mCurProcessFunc)(in, out, frameCount); in process() 121 int frameCount) { in updateCoefs() argument 122 int64_t maxDelta = mMaxDelta * frameCount; in updateCoefs() 141 int frameCount) { in process_bypass() argument 144 memcpy(out, in, frameCount * mNumChannels * sizeof(audio_sample_t)); in process_bypass() 150 int frameCount) { in process_normal_mono() argument 151 size_t nFrames = frameCount; in process_normal_mono() 184 int frameCount) { in process_transition_normal_mono() argument 185 if (updateCoefs(mTargetCoefs, frameCount)) { in process_transition_normal_mono() [all …]
|
D | AudioBiquadFilter.h | 79 int frameCount); 98 int frameCount); 154 bool updateCoefs(const audio_coef_t coefs[NUM_COEFS], int frameCount); 158 int frameCount); 161 int frameCount); 164 audio_sample_t * out, int frameCount); 167 audio_sample_t * out, int frameCount); 170 int frameCount); 173 audio_sample_t * out, int frameCount); 176 audio_sample_t * out, int frameCount);
|
/frameworks/av/media/libaudioprocessing/tests/fuzzer/ |
D | libaudioprocessing_fuzz_utils.h | 39 if (buffer->frameCount > mNumFrames - mNextFrame) { in getNextBuffer() 40 buffer->frameCount = mNumFrames - mNextFrame; in getNextBuffer() 42 mUnrel = buffer->frameCount; in getNextBuffer() 43 if (buffer->frameCount > 0) { in getNextBuffer() 52 if (buffer->frameCount > mUnrel) { in releaseBuffer() 56 mNextFrame += buffer->frameCount; in releaseBuffer() 57 mUnrel -= buffer->frameCount; in releaseBuffer() 59 buffer->frameCount = 0; in releaseBuffer()
|
/frameworks/av/media/libaaudio/src/flowgraph/ |
D | FlowGraphNode.cpp | 26 int32_t frameCount = numFrames; in pullData() local 34 frameCount = port.get().pullData(callCount, frameCount); in pullData() 37 if (frameCount > 0) { in pullData() 38 frameCount = onProcess(frameCount); in pullData() 40 mLastFrameCount = frameCount; in pullData() 42 frameCount = mLastFrameCount; in pullData() 44 return frameCount; in pullData()
|
/frameworks/base/graphics/java/android/graphics/ |
D | Interpolator.java | 29 public Interpolator(int valueCount, int frameCount) { in Interpolator() argument 31 mFrameCount = frameCount; in Interpolator() 32 native_instance = nativeConstructor(valueCount, frameCount); in Interpolator() 49 public void reset(int valueCount, int frameCount) { in reset() argument 51 mFrameCount = frameCount; in reset() 52 nativeReset(native_instance, valueCount, frameCount); in reset() 157 private static native long nativeConstructor(int valueCount, int frameCount); in nativeConstructor() argument 159 private static native void nativeReset(long native_instance, int valueCount, int frameCount); in nativeReset() argument
|
/frameworks/av/media/libaaudio/tests/ |
D | test_block_adapter.cpp | 38 void fillSequence(int32_t *indexBuffer, int32_t frameCount) { in fillSequence() argument 39 ASSERT_LE(frameCount, TEST_BUFFER_SIZE); in fillSequence() 40 for (int i = 0; i < frameCount; i++) { in fillSequence() 45 int checkSequence(const int32_t *indexBuffer, int32_t frameCount) { in checkSequence() argument 47 for (int i = 0; i < frameCount; i++) { in checkSequence() 75 int32_t frameCount = numBytes / sizeof(int32_t); in onProcessFixedBlock() local 76 return checkSequence((int32_t *) buffer, frameCount); in onProcessFixedBlock() 102 int32_t frameCount = numBytes / sizeof(int32_t); in onProcessFixedBlock() local 103 fillSequence((int32_t *) buffer, frameCount); in onProcessFixedBlock()
|
/frameworks/av/media/libaudioprocessing/tests/ |
D | test_utils.h | 124 size_t requestedFrames = buffer->frameCount; 126 buffer->frameCount = mNumFrames - mNextFrame; 131 mNextIdx-1, provided, buffer->frameCount); 132 if (provided < buffer->frameCount) { 133 buffer->frameCount = provided; 141 requestedFrames, mNumFrames - mNextFrame, buffer->frameCount); 142 mUnrel = buffer->frameCount; 143 if (buffer->frameCount > 0) { 154 if (buffer->frameCount > mUnrel) { 156 "to release", buffer->frameCount, mUnrel); [all …]
|
D | test-resampler.cpp | 277 size_t requestedFrames = buffer->frameCount; in main() 279 buffer->frameCount = mNumFrames - mNextFrame; in main() 283 printf("mPvalue[%zu]=%zu not %zu\n", mNextPidx-1, provided, buffer->frameCount); in main() 284 if (provided < buffer->frameCount) { in main() 285 buffer->frameCount = provided; in main() 294 requestedFrames, (size_t) (mNumFrames - mNextFrame), buffer->frameCount); in main() 296 mUnrel = buffer->frameCount; in main() 297 if (buffer->frameCount > 0) { in main() 306 if (buffer->frameCount > mUnrel) { in main() 308 "to release\n", buffer->frameCount, mUnrel); in main() [all …]
|
/frameworks/av/media/libaudiohal/impl/ |
D | EffectBufferHalHidl.cpp | 60 mHidlBuffer.frameCount = 0; 106 void EffectBufferHalHidl::setFrameCount(size_t frameCount) { in setFrameCount() argument 107 mHidlBuffer.frameCount = frameCount; in setFrameCount() 108 mAudioBuffer.frameCount = frameCount; in setFrameCount()
|
/frameworks/av/include/private/media/ |
D | AudioTrackShared.h | 291 Proxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, size_t frameSize, bool isOut, 302 size_t frameCount() const { return mFrameCount; } 326 ClientProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, size_t frameSize, 447 AudioTrackClientProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, 449 : ClientProxy(cblk, buffers, frameCount, frameSize, true /*isOut*/, 504 StaticAudioTrackClientProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, 560 AudioRecordClientProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, 562 : ClientProxy(cblk, buffers, frameCount, frameSize, 582 ServerProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, size_t frameSize, 664 AudioTrackServerProxy(audio_track_cblk_t* cblk, void *buffers, size_t frameCount, [all …]
|
/frameworks/av/media/libeffects/hapticgenerator/ |
D | EffectHapticGenerator.cpp | 146 processingChain.push_back([filter](float *out, const float *in, size_t frameCount) { in addBiquadFilter() argument 147 filter->process(out, in, frameCount); in addBiquadFilter() 177 processingChain.push_back([ramp](float *out, const float *in, size_t frameCount) { in HapticGenerator_buildProcessingChain() argument 178 ramp->process(out, in, frameCount); in HapticGenerator_buildProcessingChain() 208 processingChain.push_back([slowEnv](float *out, const float *in, size_t frameCount) { in HapticGenerator_buildProcessingChain() argument 209 slowEnv->process(out, in, frameCount); in HapticGenerator_buildProcessingChain() 226 processingChain.push_back([distortion](float *out, const float *in, size_t frameCount) { in HapticGenerator_buildProcessingChain() argument 227 distortion->process(out, in, frameCount); in HapticGenerator_buildProcessingChain() 236 config->inputCfg.buffer.frameCount != config->outputCfg.buffer.frameCount) { in HapticGenerator_Configure() 351 float* buf1, float* buf2, size_t frameCount) { in HapticGenerator_runProcessingChain() argument [all …]
|
D | Processors.cpp | 61 void Ramp::process(float *out, const float *in, size_t frameCount) { in process() argument 64 size_t sampleCount = frameCount * mChannelCount; in process() 73 for (; i < frameCount * mChannelCount; ++i) { in process() 93 void SlowEnvelope::process(float* out, const float* in, size_t frameCount) { in process() argument 94 size_t sampleCount = frameCount * mChannelCount; in process() 102 mLpf->process(mLpfOutBuffer.data(), mLpfInBuffer.data(), frameCount); in process() 133 void Distortion::process(float *out, const float *in, size_t frameCount) { in process() argument 134 size_t sampleCount = frameCount * mChannelCount; in process() 142 mLpf->process(out, mLpfInBuffer.data(), frameCount); // Reduce 3*F components. in process()
|
/frameworks/av/media/libaudioclient/tests/ |
D | test_create_audiotrack.cpp | 65 size_t frameCount; in testTrack() local 83 &frameCount, ¬ificationFrames, &useSharedBuffer, in testTrack() 93 audio_bytes_per_sample(format) * frameCount; in testTrack() 96 frameCount = 0; in testTrack() 118 frameCount, in testTrack()
|
/frameworks/base/libs/hwui/ |
D | SkiaInterpolator.cpp | 103 void SkiaInterpolatorBase::reset(int elemCount, int frameCount) { in reset() argument 106 fFrameCount = SkToS16(frameCount); in reset() 211 SkiaInterpolator::SkiaInterpolator(int elemCount, int frameCount) { in SkiaInterpolator() argument 213 this->reset(elemCount, frameCount); in SkiaInterpolator() 216 void SkiaInterpolator::reset(int elemCount, int frameCount) { in reset() argument 217 INHERITED::reset(elemCount, frameCount); in reset() 218 fStorage = sk_malloc_throw((sizeof(float) * elemCount + sizeof(SkTimeCode)) * frameCount); in reset() 220 fValues = (float*)((char*)fStorage + sizeof(SkTimeCode) * frameCount); in reset()
|