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

Commit a663c2bc authored by baocheng sun's avatar baocheng sun Committed by Marin Shalamanov
Browse files

Update sideband stream when BufferStateLayer has receive a buffer

This CL updates the sideband when a frame is queued.

Bug: 186383891
Test: b/186383891#comment10
Change-Id: I8d753ba47e06ca969606b0f8709990a097a8ad21
parent 5c234abd
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -622,7 +622,10 @@ void BufferStateLayer::setAutoRefresh(bool autoRefresh) {
}

bool BufferStateLayer::latchSidebandStream(bool& recomputeVisibleRegions) {
    if (mSidebandStreamChanged.exchange(false)) {
    // We need to update the sideband stream if the layer has both a buffer and a sideband stream.
    const bool updateSidebandStream = hasFrameUpdate() && mSidebandStream.get();

    if (mSidebandStreamChanged.exchange(false) || updateSidebandStream) {
        const State& s(getDrawingState());
        // mSidebandStreamChanged was true
        mSidebandStream = s.sidebandStream;