OLD | NEW |
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_DRM_BUFFER_H_ | 5 #ifndef UI_OZONE_PLATFORM_DRM_GPU_DRM_BUFFER_H_ |
6 #define UI_OZONE_PLATFORM_DRM_GPU_DRM_BUFFER_H_ | 6 #define UI_OZONE_PLATFORM_DRM_GPU_DRM_BUFFER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "skia/ext/refptr.h" | 12 #include "third_party/skia/include/core/SkRefCnt.h" |
13 #include "third_party/skia/include/core/SkSurface.h" | |
14 #include "ui/ozone/platform/drm/gpu/scanout_buffer.h" | 13 #include "ui/ozone/platform/drm/gpu/scanout_buffer.h" |
15 | 14 |
| 15 class SkCanvas; |
| 16 struct SkImageInfo; |
| 17 class SkSurface; |
| 18 |
16 namespace ui { | 19 namespace ui { |
17 | 20 |
18 class DrmDevice; | 21 class DrmDevice; |
19 | 22 |
20 // Wrapper for a DRM allocated buffer. Keeps track of the native properties of | 23 // Wrapper for a DRM allocated buffer. Keeps track of the native properties of |
21 // the buffer and wraps the pixel memory into a SkSurface which can be used to | 24 // the buffer and wraps the pixel memory into a SkSurface which can be used to |
22 // draw into using Skia. | 25 // draw into using Skia. |
23 class DrmBuffer : public ScanoutBuffer { | 26 class DrmBuffer : public ScanoutBuffer { |
24 public: | 27 public: |
25 DrmBuffer(const scoped_refptr<DrmDevice>& drm); | 28 DrmBuffer(const scoped_refptr<DrmDevice>& drm); |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 68 |
66 // Wrapper around the native pixel memory. | 69 // Wrapper around the native pixel memory. |
67 sk_sp<SkSurface> surface_; | 70 sk_sp<SkSurface> surface_; |
68 | 71 |
69 DISALLOW_COPY_AND_ASSIGN(DrmBuffer); | 72 DISALLOW_COPY_AND_ASSIGN(DrmBuffer); |
70 }; | 73 }; |
71 | 74 |
72 } // namespace ui | 75 } // namespace ui |
73 | 76 |
74 #endif // UI_OZONE_PLATFORM_DRM_GPU_DRM_BUFFER_H_ | 77 #endif // UI_OZONE_PLATFORM_DRM_GPU_DRM_BUFFER_H_ |
OLD | NEW |