Lines Matching refs:bufferIndex
32 bool enqueueInput(size_t bufferIndex) override;
33 bool dequeueOutput(size_t bufferIndex, AMediaCodecBufferInfo* bufferInfo) override;
106 bool NativeCodecUnitTest::enqueueInput(size_t bufferIndex) { in enqueueInput() argument
107 (void)bufferIndex; in enqueueInput()
111 bool NativeCodecUnitTest::dequeueOutput(size_t bufferIndex, AMediaCodecBufferInfo* info) { in dequeueOutput() argument
115 CHECK_STATUS(AMediaCodec_releaseOutputBuffer(mCodec, bufferIndex, false), in dequeueOutput()
700 int bufferIndex = mIsCodecInAsyncMode ? mAsyncHandle.getInput().bufferIndex in testGetInputBufferInRunningState() local
702 uint8_t* buf = AMediaCodec_getInputBuffer(mCodec, bufferIndex, &bufSize); in testGetInputBufferInRunningState()
707 if (!enqueueEOS(bufferIndex)) return false; in testGetInputBufferInRunningState()
846 int bufferIndex = 0; in testGetOutputBufferInRunningState() local
851 bufferIndex = element.bufferIndex; in testGetOutputBufferInRunningState()
852 if (element.bufferIndex >= 0) { in testGetOutputBufferInRunningState()
853 if (!AMediaCodec_getOutputBuffer(mCodec, bufferIndex, &buffSize)) { in testGetOutputBufferInRunningState()
857 isOk = dequeueOutput(element.bufferIndex, &element.bufferInfo); in testGetOutputBufferInRunningState()
860 bufferIndex = AMediaCodec_dequeueOutputBuffer(mCodec, &outInfo, kQDeQTimeOutUs); in testGetOutputBufferInRunningState()
861 if (bufferIndex >= 0) { in testGetOutputBufferInRunningState()
862 if (!AMediaCodec_getOutputBuffer(mCodec, bufferIndex, &buffSize)) { in testGetOutputBufferInRunningState()
866 isOk = dequeueOutput(bufferIndex, &outInfo); in testGetOutputBufferInRunningState()
874 if (AMediaCodec_getOutputBuffer(mCodec, bufferIndex, &bufSize) != nullptr) { in testGetOutputBufferInRunningState()
1184 int bufferIndex = mIsCodecInAsyncMode ? mAsyncHandle.getInput().bufferIndex in testQueueInputBufferWithBadSize() local
1187 uint8_t* buf = AMediaCodec_getInputBuffer(mCodec, bufferIndex, &bufSize); in testQueueInputBufferWithBadSize()
1212 int bufferIndex = mIsCodecInAsyncMode ? mAsyncHandle.getInput().bufferIndex in testQueueInputBufferWithBadBuffInfo() local
1215 uint8_t* buf = AMediaCodec_getInputBuffer(mCodec, bufferIndex, &bufSize); in testQueueInputBufferWithBadBuffInfo()
1303 int bufferIndex = 0; in testReleaseOutputBufferInRunningState() local
1309 bufferIndex = element.bufferIndex; in testReleaseOutputBufferInRunningState()
1310 if (element.bufferIndex >= 0) { in testReleaseOutputBufferInRunningState()
1311 if (!AMediaCodec_getOutputBuffer(mCodec, bufferIndex, &buffSize)) { in testReleaseOutputBufferInRunningState()
1315 isOk = dequeueOutput(element.bufferIndex, &element.bufferInfo); in testReleaseOutputBufferInRunningState()
1318 bufferIndex = AMediaCodec_dequeueOutputBuffer(mCodec, &outInfo, kQDeQTimeOutUs); in testReleaseOutputBufferInRunningState()
1319 if (bufferIndex >= 0) { in testReleaseOutputBufferInRunningState()
1320 if (!AMediaCodec_getOutputBuffer(mCodec, bufferIndex, &buffSize)) { in testReleaseOutputBufferInRunningState()
1324 isOk = dequeueOutput(bufferIndex, &outInfo); in testReleaseOutputBufferInRunningState()
1332 if (AMEDIA_OK == AMediaCodec_releaseOutputBuffer(mCodec, bufferIndex, false)) { in testReleaseOutputBufferInRunningState()
1407 int bufferIndex = 0; in testGetBufferFormatInRunningState() local
1412 bufferIndex = element.bufferIndex; in testGetBufferFormatInRunningState()
1413 if (element.bufferIndex >= 0) { in testGetBufferFormatInRunningState()
1414 dupFormat = AMediaCodec_getBufferFormat(mCodec, bufferIndex); in testGetBufferFormatInRunningState()
1422 isOk = dequeueOutput(element.bufferIndex, &element.bufferInfo); in testGetBufferFormatInRunningState()
1425 bufferIndex = AMediaCodec_dequeueOutputBuffer(mCodec, &outInfo, kQDeQTimeOutUs); in testGetBufferFormatInRunningState()
1426 if (bufferIndex >= 0) { in testGetBufferFormatInRunningState()
1427 dupFormat = AMediaCodec_getBufferFormat(mCodec, bufferIndex); in testGetBufferFormatInRunningState()
1435 isOk = dequeueOutput(bufferIndex, &outInfo); in testGetBufferFormatInRunningState()
1443 dupFormat = AMediaCodec_getBufferFormat(mCodec, bufferIndex); in testGetBufferFormatInRunningState()