Reinstate the trace events for Skia canvas flush and eglSwapBuffers (flutter/engine#3107)

This commit is contained in:
Jason Simmons
2016-10-07 14:01:22 -07:00
committed by GitHub
parent 86501e442b
commit fec82b04a1
2 changed files with 6 additions and 1 deletions

View File

@@ -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();

View File

@@ -245,6 +245,7 @@ bool AndroidContextGL::ClearCurrent() {
}
bool AndroidContextGL::SwapBuffers() {
TRACE_EVENT0("flutter", "AndroidContextGL::SwapBuffers");
return eglSwapBuffers(environment_->Display(), surface_);
}