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

Side by Side Diff: content/browser/gpu/browser_client_native_pixmap_factory_ozone.h

Issue 1248713002: ozone: ClientPixmapManager passes VGEM fd from browser to renderer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rename to ClientNativePixmapFactory Created 5 years, 4 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_BROWSER_GPU_BROWSER_CLIENT_NATIVE_PIXMAP_FACTORY_OZONE_H_
6 #define CONTENT_BROWSER_GPU_BROWSER_CLIENT_NATIVE_PIXMAP_FACTORY_OZONE_H_
7
8 #include "base/file_descriptor_posix.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "ipc/ipc_sender.h"
11 #include "ui/ozone/public/client_native_pixmap_factory.h"
12
13 namespace content {
14
15 class BrowserClientNativePixmapFactory : public ui::ClientNativePixmapFactory {
reveman 2015/08/13 18:05:28 This class doesn't seem useful to me. Afaict, it's
dshwang 2015/08/14 12:40:03 Thank you for explaining. I removed (Browser|Child
16 public:
17 static BrowserClientNativePixmapFactory* GetInstance();
18 ~BrowserClientNativePixmapFactory() override;
19
20 // Send virtual device file descriptor to child process.
21 void SendVirtualDevice(IPC::Sender* sender);
22
23 // ui::ClientNativePixmapFactory:
24 std::vector<Configuration> GetSupportedConfigurations() const override;
25 scoped_ptr<ui::ClientNativePixmap> ImportNativePixmap(
26 const base::FileDescriptor& handle,
27 const gfx::Size& size,
28 gfx::BufferFormat format,
29 gfx::BufferUsage usage) override;
30
31 private:
32 friend struct BrowserClientNativePixmapFactoryTrait;
33 BrowserClientNativePixmapFactory();
34
35 void Initialize(const base::FileDescriptor& virtual_device) override;
36
37 scoped_ptr<ui::ClientNativePixmapFactory> pixmap_factory_;
38 base::FileDescriptor virtual_device_;
39
40 DISALLOW_COPY_AND_ASSIGN(BrowserClientNativePixmapFactory);
41 };
42
43 } // namespace content
44
45 #endif // CONTENT_BROWSER_GPU_BROWSER_CLIENT_NATIVE_PIXMAP_FACTORY_OZONE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698