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 | 8 |
9 #ifndef GrVkTextureRenderTarget_DEFINED | 9 #ifndef GrVkTextureRenderTarget_DEFINED |
10 #define GrVkTextureRenderTarget_DEFINED | 10 #define GrVkTextureRenderTarget_DEFINED |
(...skipping 10 matching lines...) Expand all Loading... |
21 | 21 |
22 class GrVkImageView; | 22 class GrVkImageView; |
23 struct GrVkTextureInfo; | 23 struct GrVkTextureInfo; |
24 | 24 |
25 class GrVkTextureRenderTarget: public GrVkTexture, public GrVkRenderTarget { | 25 class GrVkTextureRenderTarget: public GrVkTexture, public GrVkRenderTarget { |
26 public: | 26 public: |
27 static GrVkTextureRenderTarget* CreateNewTextureRenderTarget(GrVkGpu*, const
GrSurfaceDesc&, | 27 static GrVkTextureRenderTarget* CreateNewTextureRenderTarget(GrVkGpu*, const
GrSurfaceDesc&, |
28 GrGpuResource::
LifeCycle, | 28 GrGpuResource::
LifeCycle, |
29 const GrVkImage
::ImageDesc&); | 29 const GrVkImage
::ImageDesc&); |
30 | 30 |
31 static GrVkTextureRenderTarget* CreateWrappedTextureRenderTarget(GrVkGpu*, | 31 static GrVkTextureRenderTarget* CreateWrappedTextureRenderTarget(GrVkGpu*, |
32 const GrSur
faceDesc&, | 32 const GrSur
faceDesc&, |
33 GrGpuResour
ce::LifeCycle, | 33 GrGpuResour
ce::LifeCycle, |
34 VkFormat, | 34 VkFormat, |
35 const GrVkT
extureInfo*); | 35 const GrVkT
extureInfo*); |
36 | 36 |
37 protected: | 37 protected: |
38 void onAbandon() override { | 38 void onAbandon() override { |
39 GrVkRenderTarget::onAbandon(); | 39 GrVkRenderTarget::onAbandon(); |
40 GrVkTexture::onAbandon(); | 40 GrVkTexture::onAbandon(); |
41 } | 41 } |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
81 VkFormat format, | 81 VkFormat format, |
82 const GrVkImage::Resource* imageResou
rce); | 82 const GrVkImage::Resource* imageResou
rce); |
83 | 83 |
84 // GrGLRenderTarget accounts for the texture's memory and any MSAA renderbuf
fer's memory. | 84 // GrGLRenderTarget accounts for the texture's memory and any MSAA renderbuf
fer's memory. |
85 size_t onGpuMemorySize() const override { | 85 size_t onGpuMemorySize() const override { |
86 return GrVkRenderTarget::onGpuMemorySize(); | 86 return GrVkRenderTarget::onGpuMemorySize(); |
87 } | 87 } |
88 }; | 88 }; |
89 | 89 |
90 #endif | 90 #endif |
OLD | NEW |