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()
438 AudioBufferProvider::Buffer *pBuffer) in getNextBuffer() argument
441 this, pBuffer, pBuffer->frameCount); in getNextBuffer()
447 if (pBuffer->frameCount <= mRemaining) { in getNextBuffer()
449 pBuffer->raw = mLocalBufferData; in getNextBuffer()
454 if (pBuffer->frameCount > mLocalBufferFrameCount) { in getNextBuffer()
456 if (posix_memalign(&newmem, 32, pBuffer->frameCount * mFrameSize) == OK) { in getNextBuffer()
462 mLocalBufferFrameCount = pBuffer->frameCount; in getNextBuffer()
467 const size_t outputDesired = pBuffer->frameCount - mRemaining; in getNextBuffer()
479 pBuffer->raw = NULL; in getNextBuffer()
480 pBuffer->frameCount = 0; in getNextBuffer()
483 pBuffer->raw = mLocalBufferData; in getNextBuffer()
484 pBuffer->frameCount = mRemaining; in getNextBuffer()
503 pBuffer->raw = mLocalBufferData; in getNextBuffer()
504 pBuffer->frameCount = mRemaining; in getNextBuffer()
509 void TimestretchBufferProvider::releaseBuffer(AudioBufferProvider::Buffer *pBuffer) in releaseBuffer() argument
512 this, pBuffer, pBuffer->frameCount); in releaseBuffer()
518 if (pBuffer->frameCount < mRemaining) { in releaseBuffer()
520 (uint8_t*)mLocalBufferData + pBuffer->frameCount * mFrameSize, in releaseBuffer()
521 (mRemaining - pBuffer->frameCount) * mFrameSize); in releaseBuffer()
522 mRemaining -= pBuffer->frameCount; in releaseBuffer()
523 } else if (pBuffer->frameCount == mRemaining) { in releaseBuffer()
527 pBuffer->frameCount, mRemaining); in releaseBuffer()
530 pBuffer->raw = NULL; in releaseBuffer()
531 pBuffer->frameCount = 0; in releaseBuffer()
655 status_t AdjustChannelsBufferProvider::getNextBuffer(AudioBufferProvider::Buffer* pBuffer) in getNextBuffer() argument
660 if (outFramesLeft < pBuffer->frameCount) { in getNextBuffer()
662 pBuffer->frameCount = outFramesLeft; in getNextBuffer()
665 return CopyBufferProvider::getNextBuffer(pBuffer); in getNextBuffer()