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

Unified Diff: components/exo/display.cc

Issue 2046743002: exo: Add support for importing YVU_420 buffers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@yv12-test
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
Index: components/exo/display.cc
diff --git a/components/exo/display.cc b/components/exo/display.cc
index 2accab24cb1b2ac053d0a415f0e747ba14d1a10d..083461b761eef1a4cf832b96345e8fa994cc7cb0 100644
--- a/components/exo/display.cc
+++ b/components/exo/display.cc
@@ -63,7 +63,8 @@ std::unique_ptr<Buffer> Display::CreateLinuxDMABufBuffer(
base::ScopedFD fd,
const gfx::Size& size,
gfx::BufferFormat format,
- int stride) {
+ const std::vector<int>& strides,
+ const std::vector<int>& offsets) {
TRACE_EVENT1("exo", "Display::CreateLinuxDMABufBuffer", "size",
size.ToString());
@@ -71,8 +72,8 @@ std::unique_ptr<Buffer> Display::CreateLinuxDMABufBuffer(
handle.type = gfx::OZONE_NATIVE_PIXMAP;
handle.native_pixmap_handle.fds.emplace_back(
base::FileDescriptor(std::move(fd)));
- handle.native_pixmap_handle.strides.push_back(stride);
- handle.native_pixmap_handle.offsets.push_back(0);
+ handle.native_pixmap_handle.strides = strides;
+ handle.native_pixmap_handle.offsets = offsets;
std::unique_ptr<gfx::GpuMemoryBuffer> gpu_memory_buffer =
aura::Env::GetInstance()

Powered by Google App Engine
This is Rietveld 408576698