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

Unified Diff: components/exo/display.cc

Issue 2110213002: Revert of 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: Created 4 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
« no previous file with comments | « components/exo/display.h ('k') | components/exo/display_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/exo/display.cc
diff --git a/components/exo/display.cc b/components/exo/display.cc
index f2ec5de5c0241e5335a6fce98a5a27e67d738ae5..03261baf3f1269b14b7534fb9d57a3e999c1e12a 100644
--- a/components/exo/display.cc
+++ b/components/exo/display.cc
@@ -62,7 +62,8 @@
std::unique_ptr<Buffer> Display::CreateLinuxDMABufBuffer(
const gfx::Size& size,
gfx::BufferFormat format,
- const std::vector<gfx::NativePixmapPlane>& planes,
+ const std::vector<int>& strides,
+ const std::vector<int>& offsets,
std::vector<base::ScopedFD>&& fds) {
TRACE_EVENT1("exo", "Display::CreateLinuxDMABufBuffer", "size",
size.ToString());
@@ -72,8 +73,11 @@
for (auto& fd : fds)
handle.native_pixmap_handle.fds.emplace_back(std::move(fd));
- for (auto& plane : planes)
- handle.native_pixmap_handle.planes.push_back(plane);
+ DCHECK_EQ(strides.size(), offsets.size());
+ for (size_t plane = 0; plane < strides.size(); ++plane) {
+ handle.native_pixmap_handle.strides_and_offsets.emplace_back(
+ strides[plane], offsets[plane]);
+ }
std::unique_ptr<gfx::GpuMemoryBuffer> gpu_memory_buffer =
aura::Env::GetInstance()
« no previous file with comments | « components/exo/display.h ('k') | components/exo/display_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698