Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f785bd68 authored by Wonsik Kim's avatar Wonsik Kim Committed by Automerger Merge Worker
Browse files

Merge "CCodecBufferChannel: skip output slot check if the block pool can...

Merge "CCodecBufferChannel: skip output slot check if the block pool can throttle" into udc-dev am: 01c19038

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/av/+/23298256



Change-Id: Iae559b24a9176a34b56886eeb3a1ef34e34d7e04
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 2a8d679d 01c19038
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -167,6 +167,7 @@ CCodecBufferChannel::CCodecBufferChannel(
        Mutexed<Output>::Locked output(mOutput);
        output->outputDelay = 0u;
        output->numSlots = kSmoothnessFactor;
        output->bounded = false;
    }
    {
        Mutexed<BlockPools>::Locked pools(mBlockPools);
@@ -727,7 +728,7 @@ void CCodecBufferChannel::feedInputBufferIfAvailableInternal() {
        Mutexed<Output>::Locked output(mOutput);
        if (!output->buffers ||
                output->buffers->hasPending() ||
                output->buffers->numActiveSlots() >= output->numSlots) {
                (!output->bounded && output->buffers->numActiveSlots() >= output->numSlots)) {
            return;
        }
    }
@@ -1509,6 +1510,7 @@ status_t CCodecBufferChannel::start(
        Mutexed<Output>::Locked output(mOutput);
        output->outputDelay = outputDelayValue;
        output->numSlots = numOutputSlots;
        output->bounded = bool(outputSurface);
        if (graphic) {
            if (outputSurface || !buffersBoundToCodec) {
                output->buffers.reset(new GraphicOutputBuffers(mName));
+3 −0
Original line number Diff line number Diff line
@@ -321,6 +321,9 @@ private:
        std::unique_ptr<OutputBuffers> buffers;
        size_t numSlots;
        uint32_t outputDelay;
        // true iff the underlying block pool is bounded --- for example,
        // a BufferQueue-based block pool would be bounded by the BufferQueue.
        bool bounded;
    };
    Mutexed<Output> mOutput;
    Mutexed<std::list<std::unique_ptr<C2Work>>> mFlushedConfigs;