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

Side by Side Diff: content/browser/gpu/browser_native_pixmap_manager_ozone.cc

Issue 1134993003: ozone: Implement zero/one-copy texture for Ozone GBM. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase to new crrev.com/1128113011 Created 5 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 unified diff | Download patch
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 "content/browser/gpu/browser_native_pixmap_manager_ozone.h" 5 #include "content/browser/gpu/browser_native_pixmap_manager_ozone.h"
6 6
7 #include "base/memory/singleton.h" 7 #include "base/memory/singleton.h"
8 #include "base/posix/eintr_wrapper.h" 8 #include "base/posix/eintr_wrapper.h"
9 #include "content/common/gpu/native_pixmap_manager_ozone_messages.h" 9 #include "content/common/gpu/native_pixmap_manager_ozone_messages.h"
10 #include "content/public/browser/browser_message_filter.h" 10 #include "content/public/browser/browser_message_filter.h"
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 DCHECK_CURRENTLY_ON(BrowserThread::IO); 111 DCHECK_CURRENTLY_ON(BrowserThread::IO);
112 base::SequencedWorkerPool* pool = content::BrowserThread::GetBlockingPool(); 112 base::SequencedWorkerPool* pool = content::BrowserThread::GetBlockingPool();
113 pool->PostWorkerTask( 113 pool->PostWorkerTask(
114 FROM_HERE, base::Bind(&DupVirtualDeviceFd, device_fd_.fd, callback)); 114 FROM_HERE, base::Bind(&DupVirtualDeviceFd, device_fd_.fd, callback));
115 } 115 }
116 116
117 BrowserMessageFilter* BrowserNativePixmapManager::CreateMessageFilter() { 117 BrowserMessageFilter* BrowserNativePixmapManager::CreateMessageFilter() {
118 return new BrowserNativePixmapManagerMessageFilter(this); 118 return new BrowserNativePixmapManagerMessageFilter(this);
119 } 119 }
120 120
121 scoped_refptr<ui::NativePixmap>
122 BrowserNativePixmapManager::CreateFromFileDescriptor(
123 base::FileDescriptor handle,
124 gfx::Size size,
125 ui::SurfaceFactoryOzone::BufferFormat format,
126 ui::SurfaceFactoryOzone::BufferUsage usage) {
127 return pixmap_manager_->CreateFromFileDescriptor(handle, size, format, usage);
128 }
129
121 } // namespace content 130 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698