OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2016 Google Inc. | 2 * Copyright 2016 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 GrSurfaceProxy_DEFINED | 8 #ifndef GrSurfaceProxy_DEFINED |
9 #define GrSurfaceProxy_DEFINED | 9 #define GrSurfaceProxy_DEFINED |
10 | 10 |
11 #include "GrGpuResource.h" | 11 #include "GrGpuResource.h" |
12 #include "SkRect.h" | |
13 | 12 |
14 class GrTextureProxy; | 13 class GrTextureProxy; |
15 class GrRenderTargetProxy; | 14 class GrRenderTargetProxy; |
16 | 15 |
17 class GrSurfaceProxy : public GrIORef<GrSurfaceProxy> { | 16 class GrSurfaceProxy : public GrIORef<GrSurfaceProxy> { |
18 public: | 17 public: |
19 const GrSurfaceDesc& desc() const { return fDesc; } | 18 const GrSurfaceDesc& desc() const { return fDesc; } |
20 | 19 |
21 GrSurfaceOrigin origin() const { | 20 GrSurfaceOrigin origin() const { |
22 SkASSERT(kTopLeft_GrSurfaceOrigin == fDesc.fOrigin || | 21 SkASSERT(kTopLeft_GrSurfaceOrigin == fDesc.fOrigin || |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 void notifyAllCntsAreZero(CntType) const { delete this; } | 82 void notifyAllCntsAreZero(CntType) const { delete this; } |
84 bool notifyRefCountIsZero() const { return true; } | 83 bool notifyRefCountIsZero() const { return true; } |
85 | 84 |
86 typedef GrIORef<GrSurfaceProxy> INHERITED; | 85 typedef GrIORef<GrSurfaceProxy> INHERITED; |
87 | 86 |
88 // to access notifyAllCntsAreZero and notifyRefCntIsZero. | 87 // to access notifyAllCntsAreZero and notifyRefCntIsZero. |
89 friend class GrIORef<GrSurfaceProxy>; | 88 friend class GrIORef<GrSurfaceProxy>; |
90 }; | 89 }; |
91 | 90 |
92 #endif | 91 #endif |
OLD | NEW |