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

Side by Side Diff: ui/ozone/platform/dri/gbm_surface_factory.h

Issue 490233002: VaapiVideoAccelerator: make Vaapi accelerator work with ozone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on ToT Created 6 years 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_DRI_GBM_SURFACE_FACTORY_H_ 5 #ifndef UI_OZONE_PLATFORM_DRI_GBM_SURFACE_FACTORY_H_
6 #define UI_OZONE_PLATFORM_DRI_GBM_SURFACE_FACTORY_H_ 6 #define UI_OZONE_PLATFORM_DRI_GBM_SURFACE_FACTORY_H_
7 7
8 #include "ui/ozone/platform/dri/dri_surface_factory.h" 8 #include "ui/ozone/platform/dri/dri_surface_factory.h"
9 9
10 struct gbm_device; 10 struct gbm_device;
11 11
12 namespace ui { 12 namespace ui {
13 13
14 class DriWindowDelegate; 14 class DriWindowDelegate;
15 class DriWindowDelegateManager; 15 class DriWindowDelegateManager;
16 class ScreenManager; 16 class ScreenManager;
17 17
18 class GbmSurfaceFactory : public DriSurfaceFactory { 18 class GbmSurfaceFactory : public DriSurfaceFactory {
19 public: 19 public:
20 GbmSurfaceFactory(bool allow_surfaceless); 20 GbmSurfaceFactory(bool allow_surfaceless);
21 ~GbmSurfaceFactory() override; 21 ~GbmSurfaceFactory() override;
22 22
23 void InitializeGpu(DriWrapper* dri, 23 void InitializeGpu(DriWrapper* dri,
24 gbm_device* device, 24 gbm_device* device,
25 ScreenManager* screen_manager, 25 ScreenManager* screen_manager,
26 DriWindowDelegateManager* window_manager); 26 DriWindowDelegateManager* window_manager);
27 27
28 // DriSurfaceFactory: 28 // DriSurfaceFactory:
29 intptr_t GetNativeDisplay() override; 29 intptr_t GetNativeDisplay() override;
30 virtual int GetDrmFd() override;
30 const int32_t* GetEGLSurfaceProperties(const int32_t* desired_list) override; 31 const int32_t* GetEGLSurfaceProperties(const int32_t* desired_list) override;
31 bool LoadEGLGLES2Bindings( 32 bool LoadEGLGLES2Bindings(
32 AddGLLibraryCallback add_gl_library, 33 AddGLLibraryCallback add_gl_library,
33 SetGLGetProcAddressProcCallback set_gl_get_proc_address) override; 34 SetGLGetProcAddressProcCallback set_gl_get_proc_address) override;
34 scoped_ptr<ui::SurfaceOzoneEGL> CreateEGLSurfaceForWidget( 35 scoped_ptr<ui::SurfaceOzoneEGL> CreateEGLSurfaceForWidget(
35 gfx::AcceleratedWidget w) override; 36 gfx::AcceleratedWidget w) override;
36 scoped_ptr<SurfaceOzoneEGL> CreateSurfacelessEGLSurfaceForWidget( 37 scoped_ptr<SurfaceOzoneEGL> CreateSurfacelessEGLSurfaceForWidget(
37 gfx::AcceleratedWidget widget) override; 38 gfx::AcceleratedWidget widget) override;
38 scoped_refptr<ui::NativePixmap> CreateNativePixmap( 39 scoped_refptr<ui::NativePixmap> CreateNativePixmap(
39 gfx::AcceleratedWidget widget, 40 gfx::AcceleratedWidget widget,
(...skipping 17 matching lines...) Expand all
57 ScreenManager* screen_manager_; // Not owned. 58 ScreenManager* screen_manager_; // Not owned.
58 gbm_device* device_; // Not owned. 59 gbm_device* device_; // Not owned.
59 bool allow_surfaceless_; 60 bool allow_surfaceless_;
60 61
61 DISALLOW_COPY_AND_ASSIGN(GbmSurfaceFactory); 62 DISALLOW_COPY_AND_ASSIGN(GbmSurfaceFactory);
62 }; 63 };
63 64
64 } // namespace ui 65 } // namespace ui
65 66
66 #endif // UI_OZONE_PLATFORM_DRI_GBM_SURFACE_FACTORY_H_ 67 #endif // UI_OZONE_PLATFORM_DRI_GBM_SURFACE_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698