Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(267)

Unified Diff: gpu/ipc/service/image_transport_surface_win.cc

Issue 2779643004: Add UMA histograms for DirectComposition overlays. (Closed)
Patch Set: rebase Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: gpu/ipc/service/image_transport_surface_win.cc
diff --git a/gpu/ipc/service/image_transport_surface_win.cc b/gpu/ipc/service/image_transport_surface_win.cc
index 600c7678cabc13da74688eb1b213c4aa2178555b..fcba271ece7ce7113b4d17fc3c01508aedfa45d2 100644
--- a/gpu/ipc/service/image_transport_surface_win.cc
+++ b/gpu/ipc/service/image_transport_surface_win.cc
@@ -6,6 +6,7 @@
#include <memory>
+#include "base/metrics/histogram_macros.h"
#include "base/win/windows_version.h"
#include "gpu/ipc/service/child_window_surface_win.h"
#include "gpu/ipc/service/direct_composition_surface_win.h"
@@ -49,7 +50,11 @@ scoped_refptr<gl::GLSurface> ImageTransportSurface::CreateNativeSurface(
vsync_provider.reset(new gl::VSyncProviderWin(surface_handle));
if (gl::GLSurfaceEGL::IsDirectCompositionSupported()) {
- if (DirectCompositionSurfaceWin::AreOverlaysSupported()) {
+ bool overlays_supported =
+ DirectCompositionSurfaceWin::AreOverlaysSupported();
+ UMA_HISTOGRAM_BOOLEAN("GPU.DirectComposition.OverlaysSupported",
+ overlays_supported);
+ if (overlays_supported) {
scoped_refptr<DirectCompositionSurfaceWin> egl_surface =
make_scoped_refptr(
new DirectCompositionSurfaceWin(delegate, surface_handle));

Powered by Google App Engine
This is Rietveld 408576698