| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2016 Google Inc. | 3 * Copyright 2016 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 #ifndef VulkanTestContext_DEFINED | 8 #ifndef VulkanTestContext_DEFINED |
| 9 #define VulkanTestContext_DEFINED | 9 #define VulkanTestContext_DEFINED |
| 10 | 10 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 30 delete ctx; | 30 delete ctx; |
| 31 return nullptr; | 31 return nullptr; |
| 32 } | 32 } |
| 33 return ctx; | 33 return ctx; |
| 34 } | 34 } |
| 35 | 35 |
| 36 SkSurface* getBackbufferSurface(); | 36 SkSurface* getBackbufferSurface(); |
| 37 void swapBuffers(); | 37 void swapBuffers(); |
| 38 | 38 |
| 39 bool makeCurrent() { return true; } | 39 bool makeCurrent() { return true; } |
| 40 int getStencilBits() { return 0; } | |
| 41 int getSampleCount() { return 0; } | |
| 42 | 40 |
| 43 bool isValid() { return SkToBool(fBackendContext.get()); } | 41 bool isValid() { return SkToBool(fBackendContext.get()); } |
| 44 | 42 |
| 45 void resize(uint32_t w, uint32_t h) { | 43 void resize(uint32_t w, uint32_t h) { |
| 46 this->createSwapchain(w, h); | 44 this->createSwapchain(w, h); |
| 47 } | 45 } |
| 48 | 46 |
| 49 GrBackendContext getBackendContext() { return (GrBackendContext)fBackendCont
ext.get(); } | 47 GrBackendContext getBackendContext() { return (GrBackendContext)fBackendCont
ext.get(); } |
| 50 | 48 |
| 51 private: | 49 private: |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 VkImageLayout* fImageLayouts; // layouts of these images when not color
attachment | 105 VkImageLayout* fImageLayouts; // layouts of these images when not color
attachment |
| 108 sk_sp<SkSurface>* fSurfaces; // wrapped surface for those images | 106 sk_sp<SkSurface>* fSurfaces; // wrapped surface for those images |
| 109 VkCommandPool fCommandPool; | 107 VkCommandPool fCommandPool; |
| 110 BackbufferInfo* fBackbuffers; | 108 BackbufferInfo* fBackbuffers; |
| 111 uint32_t fCurrentBackbufferIndex; | 109 uint32_t fCurrentBackbufferIndex; |
| 112 }; | 110 }; |
| 113 | 111 |
| 114 #endif // SK_VULKAN | 112 #endif // SK_VULKAN |
| 115 | 113 |
| 116 #endif | 114 #endif |
| OLD | NEW |