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 GrVkGpu_DEFINED | 8 #ifndef GrVkGpu_DEFINED |
9 #define GrVkGpu_DEFINED | 9 #define GrVkGpu_DEFINED |
10 | 10 |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 | 85 |
86 GrBackendObject createTestingOnlyBackendTexture(void* pixels, int w, int h, | 86 GrBackendObject createTestingOnlyBackendTexture(void* pixels, int w, int h, |
87 GrPixelConfig config) overri
de; | 87 GrPixelConfig config) overri
de; |
88 bool isTestingOnlyBackendTexture(GrBackendObject id) const override; | 88 bool isTestingOnlyBackendTexture(GrBackendObject id) const override; |
89 void deleteTestingOnlyBackendTexture(GrBackendObject id, bool abandonTexture
) override; | 89 void deleteTestingOnlyBackendTexture(GrBackendObject id, bool abandonTexture
) override; |
90 | 90 |
91 GrStencilAttachment* createStencilAttachmentForRenderTarget(const GrRenderTa
rget*, | 91 GrStencilAttachment* createStencilAttachmentForRenderTarget(const GrRenderTa
rget*, |
92 int width, | 92 int width, |
93 int height) over
ride; | 93 int height) over
ride; |
94 | 94 |
95 void clearStencil(GrRenderTarget* target) override { | 95 void clearStencil(GrRenderTarget* target) override; |
96 SkDebugf("clearStencil not yet implemented for Vulkan\n"); | |
97 } | |
98 | 96 |
99 void drawDebugWireRect(GrRenderTarget*, const SkIRect&, GrColor) override { | 97 void drawDebugWireRect(GrRenderTarget*, const SkIRect&, GrColor) override { |
100 SkDebugf("drawDebugWireRect not yet implemented for Vulkan\n"); | 98 SkDebugf("drawDebugWireRect not yet implemented for Vulkan\n"); |
101 } | 99 } |
102 | 100 |
103 void addMemoryBarrier(VkPipelineStageFlags srcStageMask, | 101 void addMemoryBarrier(VkPipelineStageFlags srcStageMask, |
104 VkPipelineStageFlags dstStageMask, | 102 VkPipelineStageFlags dstStageMask, |
105 bool byRegion, | 103 bool byRegion, |
106 VkMemoryBarrier* barrier) const; | 104 VkMemoryBarrier* barrier) const; |
107 void addBufferMemoryBarrier(VkPipelineStageFlags srcStageMask, | 105 void addBufferMemoryBarrier(VkPipelineStageFlags srcStageMask, |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 SkDebugf("onWrapBackendTextureAsRenderTarget not yet implemented for Vul
kan\n"); | 140 SkDebugf("onWrapBackendTextureAsRenderTarget not yet implemented for Vul
kan\n"); |
143 return NULL; | 141 return NULL; |
144 } | 142 } |
145 | 143 |
146 GrVertexBuffer* onCreateVertexBuffer(size_t size, bool dynamic) override; | 144 GrVertexBuffer* onCreateVertexBuffer(size_t size, bool dynamic) override; |
147 GrIndexBuffer* onCreateIndexBuffer(size_t size, bool dynamic) override; | 145 GrIndexBuffer* onCreateIndexBuffer(size_t size, bool dynamic) override; |
148 GrTransferBuffer* onCreateTransferBuffer(size_t size, TransferType type) ove
rride; | 146 GrTransferBuffer* onCreateTransferBuffer(size_t size, TransferType type) ove
rride; |
149 | 147 |
150 void onClear(GrRenderTarget*, const SkIRect& rect, GrColor color) override; | 148 void onClear(GrRenderTarget*, const SkIRect& rect, GrColor color) override; |
151 | 149 |
152 void onClearStencilClip(GrRenderTarget*, const SkIRect& rect, bool insideCli
p) override { | 150 void onClearStencilClip(GrRenderTarget*, const SkIRect& rect, bool insideCli
p) override; |
153 SkDebugf("onClearStencilClip not yet implemented for Vulkan\n"); | |
154 } | |
155 | 151 |
156 void onDraw(const DrawArgs&, const GrNonInstancedVertices&) override; | 152 void onDraw(const DrawArgs&, const GrNonInstancedVertices&) override; |
157 | 153 |
158 bool onReadPixels(GrSurface* surface, | 154 bool onReadPixels(GrSurface* surface, |
159 int left, int top, int width, int height, | 155 int left, int top, int width, int height, |
160 GrPixelConfig, | 156 GrPixelConfig, |
161 void* buffer, | 157 void* buffer, |
162 size_t rowBytes) override; | 158 size_t rowBytes) override; |
163 | 159 |
164 bool onWritePixels(GrSurface* surface, | 160 bool onWritePixels(GrSurface* surface, |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
216 shaderc_compiler_t fCompiler; | 212 shaderc_compiler_t fCompiler; |
217 | 213 |
218 // This is only for our current testing and building. The client should be h
olding on to the | 214 // This is only for our current testing and building. The client should be h
olding on to the |
219 // VkInstance. | 215 // VkInstance. |
220 VkInstance fVkInstance; | 216 VkInstance fVkInstance; |
221 | 217 |
222 typedef GrGpu INHERITED; | 218 typedef GrGpu INHERITED; |
223 }; | 219 }; |
224 | 220 |
225 #endif | 221 #endif |
OLD | NEW |