Lines Matching refs:pBuffer

70 status_t CopyBufferProvider::getNextBuffer(AudioBufferProvider::Buffer *pBuffer)  in getNextBuffer()  argument
75 status_t res = mTrackBufferProvider->getNextBuffer(pBuffer); in getNextBuffer()
77 copyFrames(pBuffer->raw, pBuffer->raw, pBuffer->frameCount); in getNextBuffer()
82 mBuffer.frameCount = pBuffer->frameCount; in getNextBuffer()
91 pBuffer->raw = NULL; in getNextBuffer()
92 pBuffer->frameCount = 0; in getNextBuffer()
99 count = std::min(count, pBuffer->frameCount); in getNextBuffer()
100 pBuffer->raw = mLocalBufferData; in getNextBuffer()
101 pBuffer->frameCount = count; in getNextBuffer()
102 copyFrames(pBuffer->raw, (uint8_t*)mBuffer.raw + mConsumed * mInputFrameSize, in getNextBuffer()
103 pBuffer->frameCount); in getNextBuffer()
107 void CopyBufferProvider::releaseBuffer(AudioBufferProvider::Buffer *pBuffer) in releaseBuffer() argument
112 mTrackBufferProvider->releaseBuffer(pBuffer); in releaseBuffer()
116 mConsumed += pBuffer->frameCount; // TODO: update for efficiency to reuse existing content in releaseBuffer()
121 pBuffer->raw = NULL; in releaseBuffer()
122 pBuffer->frameCount = 0; in releaseBuffer()
468 AudioBufferProvider::Buffer *pBuffer) in getNextBuffer() argument
471 this, pBuffer, pBuffer->frameCount); in getNextBuffer()
477 if (pBuffer->frameCount <= mRemaining) { in getNextBuffer()
479 pBuffer->raw = mLocalBufferData; in getNextBuffer()
484 if (pBuffer->frameCount > mLocalBufferFrameCount) { in getNextBuffer()
486 if (posix_memalign(&newmem, 32, pBuffer->frameCount * mFrameSize) == OK) { in getNextBuffer()
492 mLocalBufferFrameCount = pBuffer->frameCount; in getNextBuffer()
497 const size_t outputDesired = pBuffer->frameCount - mRemaining; in getNextBuffer()
509 pBuffer->raw = NULL; in getNextBuffer()
510 pBuffer->frameCount = 0; in getNextBuffer()
513 pBuffer->raw = mLocalBufferData; in getNextBuffer()
514 pBuffer->frameCount = mRemaining; in getNextBuffer()
533 pBuffer->raw = mLocalBufferData; in getNextBuffer()
534 pBuffer->frameCount = mRemaining; in getNextBuffer()
539 void TimestretchBufferProvider::releaseBuffer(AudioBufferProvider::Buffer *pBuffer) in releaseBuffer() argument
542 this, pBuffer, pBuffer->frameCount); in releaseBuffer()
548 if (pBuffer->frameCount < mRemaining) { in releaseBuffer()
550 (uint8_t*)mLocalBufferData + pBuffer->frameCount * mFrameSize, in releaseBuffer()
551 (mRemaining - pBuffer->frameCount) * mFrameSize); in releaseBuffer()
552 mRemaining -= pBuffer->frameCount; in releaseBuffer()
553 } else if (pBuffer->frameCount == mRemaining) { in releaseBuffer()
557 pBuffer->frameCount, mRemaining); in releaseBuffer()
560 pBuffer->raw = NULL; in releaseBuffer()
561 pBuffer->frameCount = 0; in releaseBuffer()
693 status_t AdjustChannelsBufferProvider::getNextBuffer(AudioBufferProvider::Buffer* pBuffer) in getNextBuffer() argument
698 if (outFramesLeft < pBuffer->frameCount) { in getNextBuffer()
700 pBuffer->frameCount = outFramesLeft; in getNextBuffer()
703 return CopyBufferProvider::getNextBuffer(pBuffer); in getNextBuffer()