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

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

Issue 371813004: ozone: gbm: Add overlay support (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix test build Created 6 years, 5 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_DRI_SCANOUT_SURFACE_H_ 5 #ifndef UI_OZONE_PLATFORM_DRI_SCANOUT_SURFACE_H_
6 #define UI_OZONE_PLATFORM_DRI_SCANOUT_SURFACE_H_ 6 #define UI_OZONE_PLATFORM_DRI_SCANOUT_SURFACE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 namespace gfx { 10 namespace gfx {
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 class ScanoutSurface { 52 class ScanoutSurface {
53 public: 53 public:
54 virtual ~ScanoutSurface() {} 54 virtual ~ScanoutSurface() {}
55 55
56 // Used to allocate all necessary buffers for this surface. If the 56 // Used to allocate all necessary buffers for this surface. If the
57 // initialization succeeds, the device is ready to be used for drawing 57 // initialization succeeds, the device is ready to be used for drawing
58 // operations. 58 // operations.
59 // Returns true if the initialization is successful, false otherwise. 59 // Returns true if the initialization is successful, false otherwise.
60 virtual bool Initialize() = 0; 60 virtual bool Initialize() = 0;
61 61
62 // Prepare the surface to be displayed.
63 virtual void PreSwapBuffers() = 0;
64
62 // Swaps the back buffer with the front buffer. 65 // Swaps the back buffer with the front buffer.
63 virtual void SwapBuffers() = 0; 66 virtual void SwapBuffers() = 0;
64 67
65 // Returns the ID of the current backbuffer. 68 // Returns the ID of the current backbuffer.
66 virtual uint32_t GetFramebufferId() const = 0; 69 virtual uint32_t GetFramebufferId() const = 0;
67 70
68 // Returns the handle of the current backbuffer. 71 // Returns the handle of the current backbuffer.
69 virtual uint32_t GetHandle() const = 0; 72 virtual uint32_t GetHandle() const = 0;
70 73
71 // Returns the surface size. 74 // Returns the surface size.
72 virtual gfx::Size Size() const = 0; 75 virtual gfx::Size Size() const = 0;
73 }; 76 };
74 77
75 class ScanoutSurfaceGenerator { 78 class ScanoutSurfaceGenerator {
76 public: 79 public:
77 virtual ~ScanoutSurfaceGenerator() {} 80 virtual ~ScanoutSurfaceGenerator() {}
78 81
79 virtual ScanoutSurface* Create(const gfx::Size& size) = 0; 82 virtual ScanoutSurface* Create(const gfx::Size& size) = 0;
80 }; 83 };
81 84
82 } // namespace ui 85 } // namespace ui
83 86
84 #endif // UI_OZONE_PLATFORM_DRI_SCANOUT_SURFACE_H_ 87 #endif // UI_OZONE_PLATFORM_DRI_SCANOUT_SURFACE_H_
OLDNEW
« no previous file with comments | « ui/ozone/platform/dri/ozone_platform_gbm.cc ('k') | ui/ozone/platform/dri/test/mock_dri_wrapper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698