Reinstate the trace events for Skia canvas flush and eglSwapBuffers (flutter/engine#3107)
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#include "gpu_surface_gl.h"
|
||||
|
||||
#include "flutter/flow/gl_connection.h"
|
||||
#include "flutter/glue/trace_event.h"
|
||||
#include "lib/ftl/arraysize.h"
|
||||
#include "lib/ftl/logging.h"
|
||||
#include "third_party/skia/include/core/SkSurface.h"
|
||||
@@ -132,7 +133,10 @@ bool GPUSurfaceGL::PresentSurface(SkCanvas* canvas) {
|
||||
return false;
|
||||
}
|
||||
|
||||
canvas->flush();
|
||||
{
|
||||
TRACE_EVENT0("flutter", "SkCanvas::Flush");
|
||||
canvas->flush();
|
||||
}
|
||||
|
||||
delegate_->GLContextPresent();
|
||||
|
||||
|
||||
@@ -245,6 +245,7 @@ bool AndroidContextGL::ClearCurrent() {
|
||||
}
|
||||
|
||||
bool AndroidContextGL::SwapBuffers() {
|
||||
TRACE_EVENT0("flutter", "AndroidContextGL::SwapBuffers");
|
||||
return eglSwapBuffers(environment_->Display(), surface_);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user