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

Commit d7f726d9 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "CCodec: Detect pipeline fullness based on pending inputs" into qt-dev

parents 279cf4b9 7892ceab
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -121,6 +121,13 @@ bool PipelineWatcher::pipelineFull() const {
              sizeWithInputReleased);
        return true;
    }

    size_t sizeWithInputsPending = mFramesInPipeline.size() - sizeWithInputReleased;
    if (sizeWithInputsPending > mPipelineDelay + mInputDelay + mSmoothnessFactor) {
        ALOGV("pipelineFull: too many inputs pending (%zu) in pipeline, with inputs released (%zu)",
              sizeWithInputsPending, sizeWithInputReleased);
        return true;
    }
    ALOGV("pipeline has room (total: %zu, input released: %zu)",
          mFramesInPipeline.size(), sizeWithInputReleased);
    return false;