OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef GrVkBuffer_DEFINED | 8 #ifndef GrVkBuffer_DEFINED |
9 #define GrVkBuffer_DEFINED | 9 #define GrVkBuffer_DEFINED |
10 | 10 |
11 #include "vk/GrVkInterface.h" | |
12 #include "GrVkResource.h" | 11 #include "GrVkResource.h" |
| 12 #include "vk/GrVkDefines.h" |
13 | 13 |
14 class GrVkGpu; | 14 class GrVkGpu; |
15 | 15 |
16 /** | 16 /** |
17 * This class serves as the base of GrVk*Buffer classes. It was written to avoid
code | 17 * This class serves as the base of GrVk*Buffer classes. It was written to avoid
code |
18 * duplication in those classes. | 18 * duplication in those classes. |
19 */ | 19 */ |
20 class GrVkBuffer : public SkNoncopyable { | 20 class GrVkBuffer : public SkNoncopyable { |
21 public: | 21 public: |
22 ~GrVkBuffer() { | 22 ~GrVkBuffer() { |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 void vkRelease(const GrVkGpu* gpu); | 79 void vkRelease(const GrVkGpu* gpu); |
80 | 80 |
81 private: | 81 private: |
82 void validate() const; | 82 void validate() const; |
83 bool vkIsMapped() const; | 83 bool vkIsMapped() const; |
84 | 84 |
85 Desc fDesc; | 85 Desc fDesc; |
86 const Resource* fResource; | 86 const Resource* fResource; |
87 void* fMapPtr; | 87 void* fMapPtr; |
88 | 88 |
89 typedef SkRefCnt INHERITED; | 89 typedef SkNoncopyable INHERITED; |
90 }; | 90 }; |
91 | 91 |
92 #endif | 92 #endif |
OLD | NEW |