Lines Matching refs:found

249         int* found) const {
280 *found = BufferQueueCore::INVALID_BUFFER_SLOT;
297 *found = mCore->mSharedBufferSlot;
303 *found = slot;
305 *found = getFreeSlotLocked();
311 *found = slot;
313 *found = getFreeBufferLocked();
319 // If no buffer is found, or if the queue has too many buffers
322 tryAgain = (*found == BufferQueueCore::INVALID_BUFFER_SLOT) ||
399 int found = BufferItem::INVALID_BUFFER_SLOT;
400 while (found == BufferItem::INVALID_BUFFER_SLOT) {
402 &found);
408 if (found == BufferQueueCore::INVALID_BUFFER_SLOT) {
413 const sp<GraphicBuffer>& buffer(mSlots[found].mGraphicBuffer);
421 if (mCore->mSharedBufferSlot == found) {
425 mCore->mFreeSlots.insert(found);
426 mCore->clearBufferSlotLocked(found);
427 found = BufferItem::INVALID_BUFFER_SLOT;
433 const sp<GraphicBuffer>& buffer(mSlots[found].mGraphicBuffer);
434 if (mCore->mSharedBufferSlot == found &&
442 if (mCore->mSharedBufferSlot != found) {
443 mCore->mActiveBuffers.insert(found);
445 *outSlot = found;
446 ATRACE_BUFFER_INDEX(found);
448 attachedByConsumer = mSlots[found].mNeedsReallocation;
449 mSlots[found].mNeedsReallocation = false;
451 mSlots[found].mBufferState.dequeue();
456 mSlots[found].mAcquireCalled = false;
457 mSlots[found].mGraphicBuffer = NULL;
458 mSlots[found].mRequestBufferCalled = false;
459 mSlots[found].mEglDisplay = EGL_NO_DISPLAY;
460 mSlots[found].mEglFence = EGL_NO_SYNC_KHR;
461 mSlots[found].mFence = Fence::NO_FENCE;
469 mCore->mBufferAge = mCore->mFrameCounter + 1 - mSlots[found].mFrameNumber;
475 if (CC_UNLIKELY(mSlots[found].mFence == NULL)) {
478 found, buffer->width, buffer->height, buffer->format);
481 eglDisplay = mSlots[found].mEglDisplay;
482 eglFence = mSlots[found].mEglFence;
486 mCore->mSharedBufferSlot == found) ?
487 Fence::NO_FENCE : mSlots[found].mFence;
488 mSlots[found].mEglFence = EGL_NO_SYNC_KHR;
489 mSlots[found].mFence = Fence::NO_FENCE;
495 mCore->mSharedBufferSlot = found;
496 mSlots[found].mBufferState.mShared = true;
661 int found = mCore->mFreeBuffers.front();
662 mCore->mFreeBuffers.remove(found);
663 mCore->mFreeSlots.insert(found);
665 BQ_LOGV("detachNextBuffer detached slot %d", found);
667 *outBuffer = mSlots[found].mGraphicBuffer;
668 *outFence = mSlots[found].mFence;
669 mCore->clearBufferSlotLocked(found);
720 int found;
721 status_t status = waitForFreeSlotThenRelock(FreeSlotCaller::Attach, &found);
727 if (found == BufferQueueCore::INVALID_BUFFER_SLOT) {
732 *outSlot = found;
744 mCore->mActiveBuffers.insert(found);