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

Side by Side Diff: ui/ozone/platform/headless/headless_surface_factory.cc

Issue 2039813002: Add format modifier IDs for EGL_EXT_image_dma_buf_import extension (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add format modifier IDs for EGL_EXT_image_dma_buf_import extension Created 4 years, 5 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 unified diff | Download patch
« no previous file with comments | « ui/ozone/platform/drm/gpu/gbm_surface_factory.cc ('k') | ui/ozone/public/native_pixmap.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/ozone/platform/headless/headless_surface_factory.h" 5 #include "ui/ozone/platform/headless/headless_surface_factory.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 class TestPixmap : public ui::NativePixmap { 69 class TestPixmap : public ui::NativePixmap {
70 public: 70 public:
71 TestPixmap(gfx::BufferFormat format) : format_(format) {} 71 TestPixmap(gfx::BufferFormat format) : format_(format) {}
72 72
73 void* GetEGLClientBuffer() const override { return nullptr; } 73 void* GetEGLClientBuffer() const override { return nullptr; }
74 bool AreDmaBufFdsValid() const override { return false; } 74 bool AreDmaBufFdsValid() const override { return false; }
75 size_t GetDmaBufFdCount() const override { return 0; } 75 size_t GetDmaBufFdCount() const override { return 0; }
76 int GetDmaBufFd(size_t plane) const override { return -1; } 76 int GetDmaBufFd(size_t plane) const override { return -1; }
77 int GetDmaBufPitch(size_t plane) const override { return 0; } 77 int GetDmaBufPitch(size_t plane) const override { return 0; }
78 int GetDmaBufOffset(size_t plane) const override { return 0; } 78 int GetDmaBufOffset(size_t plane) const override { return 0; }
79 uint64_t GetDmaBufModifier(size_t plane) const override { return 0; }
79 gfx::BufferFormat GetBufferFormat() const override { return format_; } 80 gfx::BufferFormat GetBufferFormat() const override { return format_; }
80 gfx::Size GetBufferSize() const override { return gfx::Size(); } 81 gfx::Size GetBufferSize() const override { return gfx::Size(); }
81 bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget, 82 bool ScheduleOverlayPlane(gfx::AcceleratedWidget widget,
82 int plane_z_order, 83 int plane_z_order,
83 gfx::OverlayTransform plane_transform, 84 gfx::OverlayTransform plane_transform,
84 const gfx::Rect& display_bounds, 85 const gfx::Rect& display_bounds,
85 const gfx::RectF& crop_rect) override { 86 const gfx::RectF& crop_rect) override {
86 return true; 87 return true;
87 } 88 }
88 void SetProcessingCallback( 89 void SetProcessingCallback(
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 125
125 scoped_refptr<NativePixmap> HeadlessSurfaceFactory::CreateNativePixmap( 126 scoped_refptr<NativePixmap> HeadlessSurfaceFactory::CreateNativePixmap(
126 gfx::AcceleratedWidget widget, 127 gfx::AcceleratedWidget widget,
127 gfx::Size size, 128 gfx::Size size,
128 gfx::BufferFormat format, 129 gfx::BufferFormat format,
129 gfx::BufferUsage usage) { 130 gfx::BufferUsage usage) {
130 return new TestPixmap(format); 131 return new TestPixmap(format);
131 } 132 }
132 133
133 } // namespace ui 134 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/gpu/gbm_surface_factory.cc ('k') | ui/ozone/public/native_pixmap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698