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

Commit f832270a authored by Derek Sollenberger's avatar Derek Sollenberger Committed by Automerger Merge Worker
Browse files

Merge "CanvasContext::draw: flushAndSubmit when not drawing" into sc-dev am: 1171be08

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

Change-Id: I4af7f9ddde1273db6aefed5f14fdcaf2d8df36ec
parents 56d090cf 1171be08
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -482,6 +482,12 @@ nsecs_t CanvasContext::draw() {

    if (dirty.isEmpty() && Properties::skipEmptyFrames && !surfaceRequiresRedraw()) {
        mCurrentFrameInfo->addFlag(FrameInfoFlags::SkippedFrame);
        if (auto grContext = getGrContext()) {
            // Submit to ensure that any texture uploads complete and Skia can
            // free its staging buffers.
            grContext->flushAndSubmit();
        }

        // Notify the callbacks, even if there's nothing to draw so they aren't waiting
        // indefinitely
        waitOnFences();