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

Unified Diff: ui/gl/x11_pixmap_tracker.h

Issue 331723003: gpu: Remove Create/DeleteImage IPC by adding an X11_PIXMAP_BUFFER GpuMemoryBuffer type. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: include x11 pixmap tracker Created 6 years, 6 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: ui/gl/x11_pixmap_tracker.h
diff --git a/ui/gl/x11_pixmap_tracker.h b/ui/gl/x11_pixmap_tracker.h
new file mode 100644
index 0000000000000000000000000000000000000000..09c1046c782f94c3d1132e0205d5a2f6dc2df7b1
--- /dev/null
+++ b/ui/gl/x11_pixmap_tracker.h
@@ -0,0 +1,28 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef UI_GL_X11_PIXMAP_TRACKER_H_
+#define UI_GL_X11_PIXMAP_TRACKER_H_
reveman 2014/06/13 16:45:11 Maybe move this into a ui/gl/x/ sub directory..
+
+#include "ui/gfx/x/x11_types.h"
+#include "ui/gl/gl_export.h"
+
+namespace gfx {
+
+// This interface is used to take ownership of preallocated pixmaps with
+// specific ids.
+class GL_EXPORT X11PixmapTracker {
+ public:
+ static X11PixmapTracker* GetInstance();
+ static void InitInstance(X11PixmapTracker* tracker);
+
+ virtual XID AcquirePixmap(int primary_id, int secondary_id) = 0;
+
+ protected:
+ virtual ~X11PixmapTracker() {}
+};
+
+} // namespace gfx
+
+#endif // UI_GL_X11_PIXMAP_TRACKER_H_

Powered by Google App Engine
This is Rietveld 408576698