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

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

Merge "Fix texture leak"

parents 43142804 3053ac7f
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -503,6 +503,10 @@ void CanvasContext::destroyHardwareResources(TreeObserver* observer) {
        for (const sp<RenderNode>& node : mRenderNodes) {
            node->destroyHardwareResources(observer);
        }
        Caches& caches = Caches::getInstance();
        // Make sure to release all the textures we were owning as there won't
        // be another draw
        caches.textureCache.resetMarkInUse(this);
        mRenderPipeline->onDestroyHardwareResources();
    }
}
+0 −4
Original line number Diff line number Diff line
@@ -163,10 +163,6 @@ bool OpenGLPipeline::isContextReady() {
}

void OpenGLPipeline::onDestroyHardwareResources() {
    Caches& caches = Caches::getInstance();
    // Make sure to release all the textures we were owning as there won't
    // be another draw
    caches.textureCache.resetMarkInUse(this);
    mRenderThread.renderState().flush(Caches::FlushMode::Layers);
}