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

Unified Diff: ui/gfx/mojo/buffer_types.mojom

Issue 2298003002: gfx: Struct traits for GpuMemoryBufferHandle. (Closed)
Patch Set: . Created 4 years, 3 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
« no previous file with comments | « ui/gfx/ipc/gfx_param_traits_macros.h ('k') | ui/gfx/mojo/buffer_types.typemap » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/mojo/buffer_types.mojom
diff --git a/ui/gfx/mojo/buffer_types.mojom b/ui/gfx/mojo/buffer_types.mojom
index 3a352df62957959989b1522a5631400398a48c48..4398e09ed8af48eaf1a919441fd881788c58721e 100644
--- a/ui/gfx/mojo/buffer_types.mojom
+++ b/ui/gfx/mojo/buffer_types.mojom
@@ -49,3 +49,29 @@ enum GpuMemoryBufferType {
struct GpuMemoryBufferId {
int32 id;
};
+
+// gfx::NativePixmapPlane
+struct NativePixmapPlane {
+ uint32 stride;
+ int32 offset;
+ uint64 modifier;
+};
+
+// gfx::NativePixmapHandle
+struct NativePixmapHandle {
+ // A file descriptor for the underlying memory object (usually dmabuf).
+ array<handle> fds;
+
+ array<NativePixmapPlane> planes;
+};
+
+// gfx::GpuMemoryBufferHandle
+struct GpuMemoryBufferHandle {
+ GpuMemoryBufferType type;
+ GpuMemoryBufferId id;
+ handle shared_memory_handle;
+ uint32 offset;
+ uint32 stride;
+ NativePixmapHandle? native_pixmap_handle;
+ // TODO: Add support for mach_port on mac.
+};
« no previous file with comments | « ui/gfx/ipc/gfx_param_traits_macros.h ('k') | ui/gfx/mojo/buffer_types.typemap » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698