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

Side by Side Diff: ui/ozone/platform/drm/gpu/gbm_surface_factory.h

Issue 1381133002: ozone: Implement support for CreateGpuMemoryBufferFromHandle for OzoneNativePixmap backed GMBs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@gmb-factory-create-from-handle
Patch Set: rebase Created 5 years, 2 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_ 5 #ifndef UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_
6 #define UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_ 6 #define UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/threading/thread_checker.h" 10 #include "base/threading/thread_checker.h"
(...skipping 29 matching lines...) Expand all
40 gfx::AcceleratedWidget widget) override; 40 gfx::AcceleratedWidget widget) override;
41 scoped_ptr<ui::SurfaceOzoneEGL> CreateEGLSurfaceForWidget( 41 scoped_ptr<ui::SurfaceOzoneEGL> CreateEGLSurfaceForWidget(
42 gfx::AcceleratedWidget w) override; 42 gfx::AcceleratedWidget w) override;
43 scoped_ptr<SurfaceOzoneEGL> CreateSurfacelessEGLSurfaceForWidget( 43 scoped_ptr<SurfaceOzoneEGL> CreateSurfacelessEGLSurfaceForWidget(
44 gfx::AcceleratedWidget widget) override; 44 gfx::AcceleratedWidget widget) override;
45 scoped_refptr<ui::NativePixmap> CreateNativePixmap( 45 scoped_refptr<ui::NativePixmap> CreateNativePixmap(
46 gfx::AcceleratedWidget widget, 46 gfx::AcceleratedWidget widget,
47 gfx::Size size, 47 gfx::Size size,
48 gfx::BufferFormat format, 48 gfx::BufferFormat format,
49 gfx::BufferUsage usage) override; 49 gfx::BufferUsage usage) override;
50 scoped_refptr<NativePixmap> CreateNativePixmapFromHandle(
51 const gfx::NativePixmapHandle& handle) override;
50 52
51 private: 53 private:
52 scoped_refptr<GbmDevice> GetGbmDevice(gfx::AcceleratedWidget widget); 54 scoped_refptr<GbmDevice> GetGbmDevice(gfx::AcceleratedWidget widget);
53 55
54 DrmDeviceManager* drm_device_manager_; // Not owned. 56 DrmDeviceManager* drm_device_manager_; // Not owned.
55 ScreenManager* screen_manager_; // Not owned. 57 ScreenManager* screen_manager_; // Not owned.
56 58
57 base::ThreadChecker thread_checker_; 59 base::ThreadChecker thread_checker_;
58 60
59 std::map<gfx::AcceleratedWidget, GbmSurfaceless*> widget_to_surface_map_; 61 std::map<gfx::AcceleratedWidget, GbmSurfaceless*> widget_to_surface_map_;
60 62
61 DISALLOW_COPY_AND_ASSIGN(GbmSurfaceFactory); 63 DISALLOW_COPY_AND_ASSIGN(GbmSurfaceFactory);
62 }; 64 };
63 65
64 } // namespace ui 66 } // namespace ui
65 67
66 #endif // UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_ 68 #endif // UI_OZONE_PLATFORM_DRM_GPU_GBM_SURFACE_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698