aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/vk
Commit message (Collapse)AuthorAge
* Remove GrPrimitiveType::kTriangleFanGravatar Brian Salomon2018-04-30
| | | | | | | Change-Id: Ia121198ebcdc34e32a3ff99b0821047256df282d Reviewed-on: https://skia-review.googlesource.com/124503 Reviewed-by: Chris Dalton <csmartdalton@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Add GrCap check for whether we can do a copy or not, and implement in Vk backendGravatar Greg Daniel2018-04-25
| | | | | | | | | | | | | | Today, we only know if we fail a copy during the flush so we have no way to cleanly handle a failed copy. This will allow us to know if we'll fail a copy during recording and allow us to do some appropriate fallback and/or dropping of the draw. Bug: skia: Change-Id: I38f209dbd4ebb4e762210b4609147d4b0a1b01b1 Reviewed-on: https://skia-review.googlesource.com/123560 Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Compile with latest clang 7.Gravatar Ben Wagner2018-04-24
| | | | | | | | | | | | | Changes to warnings in clang introduced by https://reviews.llvm.org/D43322 and https://reviews.llvm.org/D44883 cause warning as error failures when building Skia. In particular this addresses return-std-move-in-c++11 and self-assign-overloaded. Change-Id: I680318098d8af1b64fba464585c7cdfcfcf39d66 Reviewed-on: https://skia-review.googlesource.com/123582 Reviewed-by: Greg Daniel <egdaniel@google.com> Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Add discard check when deciding if we should execute op list or not.Gravatar Greg Daniel2018-04-20
| | | | | | | | Bug: skia:7828 Change-Id: I339ba64b6312cd9444cd4faffd426d91852774e9 Reviewed-on: https://skia-review.googlesource.com/122784 Commit-Queue: Greg Daniel <egdaniel@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* When creating testing backendTexture take colorspace into account.Gravatar Greg Daniel2018-04-19
| | | | | | | | | Bug: skia: Change-Id: Ifa8dbad3eca81790648476f9a6d3fa5a088fede9 Reviewed-on: https://skia-review.googlesource.com/122341 Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* No long require copy as draw for vulkan wrapped resources.Gravatar Greg Daniel2018-04-17
| | | | | | | | | | | | | | With the recent changes to GrBackendTexture and the atomic ref counted GrVkImageLayout, this should not longer be an issue for cross context images. There still is the requirement that they need to manually synchronize the submission of work involving the image on two threads, but that is a requirement regardless of layout issues. Bug: skia: Change-Id: Ia86e51fda8606838dabd1bc36cf14c7679b46d49 Reviewed-on: https://skia-review.googlesource.com/121349 Commit-Queue: Greg Daniel <egdaniel@google.com> Reviewed-by: Brian Osman <brianosman@google.com>
* Revert "Delete getRenderTargetHandle call on SkSurface."Gravatar Greg Daniel2018-04-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit c828109ebd1519134b1c3fa168519ac07a31fe05. Reason for revert: Need to fix flutter Original change's description: > Delete getRenderTargetHandle call on SkSurface. > > All clients and internal code should be switched (once changes land soon) > to the new getBackendRenderTarget call instead. > > Bug: skia: > Change-Id: I6f490b6d26a72f37f97216be04e541483206510d > Reviewed-on: https://skia-review.googlesource.com/121103 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: skia: Change-Id: I571298f839757fcdedcd8117519e740ac7ef1344 Reviewed-on: https://skia-review.googlesource.com/121480 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Don't create lazy proxys if their width/height is greater than max tex sizeGravatar Greg Daniel2018-04-12
| | | | | | | | | Bug: skia: Change-Id: I53508c4e3bbd4c315be4b29a66716e0c5e7f25bf Reviewed-on: https://skia-review.googlesource.com/121161 Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Delete getRenderTargetHandle call on SkSurface.Gravatar Greg Daniel2018-04-12
| | | | | | | | | | | All clients and internal code should be switched (once changes land soon) to the new getBackendRenderTarget call instead. Bug: skia: Change-Id: I6f490b6d26a72f37f97216be04e541483206510d Reviewed-on: https://skia-review.googlesource.com/121103 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Add SK_SUPPORT_LEGACY_BACKEND_OBJECTSGravatar Robert Phillips2018-04-12
| | | | | | | | | This relies on the Chrome CL: https://chromium-review.googlesource.com/c/chromium/src/+/999796 (Add SK_SUPPORT_LEGACY_BACKEND_OBJECTS to SkUserConfig.h) landing first. Change-Id: Ie0a2b7b84cc02e46957765a0a7d6444a5320769d Reviewed-on: https://skia-review.googlesource.com/119140 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Get ViaDDL working with VulkanGravatar Robert Phillips2018-04-11
| | | | | | | Change-Id: Iab5ab689529227d2c8a6dbea89e555b73622a99c Reviewed-on: https://skia-review.googlesource.com/118989 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Move GrBackendRenderTarget over to new system of getting backed infosGravatar Greg Daniel2018-04-11
| | | | | | | | Bug: skia: Change-Id: I3927390894715e8424b3d0240dad3ee6cd03dc38 Reviewed-on: https://skia-review.googlesource.com/120181 Commit-Queue: Greg Daniel <egdaniel@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Remove extra Vulkan submitCommandBuffer from deleteTestingOnlyBackendTextureGravatar Robert Phillips2018-04-10
| | | | | | | Change-Id: I6e2fd012d1c2af72a34be2d1971e210d7373fe21 Reviewed-on: https://skia-review.googlesource.com/120080 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Update getBackendInfo calls on GrBackendTexture to support VkImageLayout better.Gravatar Greg Daniel2018-04-10
| | | | | | | | | | | | | | | The big api level change here is that the getBackendInfo calls now return by value instead of a pointer. These changes are being made in support of Vulkan so that the client can update the VkImageLayout on the GrBackendTexture and have that update get reflected in our internal tracking of the image. This is done by storing a ref counted GrVkImageLayout object on the GrBackendTexture and the GrVkImage. Bug: skia: Change-Id: I8c6158fd3a66eb61fef97ebf09ea5364bca3f1ae Reviewed-on: https://skia-review.googlesource.com/119101 Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* vulkan: Fix an optimus-related failure with vkEnumeratePhysicalDevicesGravatar Chris Dalton2018-04-06
| | | | | | | | Bug: skia: Change-Id: I44be948b2e3ce925ff539de279db04bf8df7137c Reviewed-on: https://skia-review.googlesource.com/119060 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Revert "Revert "Make SkSL GLSL generator declare sk_FragColor inout when EXT ↵Gravatar Brian Salomon2018-04-04
| | | | | | | | | | | | fb fetch is used."" This reverts commit d40133092ae138b3d47a1158101faec3c53c6b1f. Bug: skia: Change-Id: I236505da047d5ad29e4952d8955eb7aa1bfb870b Reviewed-on: https://skia-review.googlesource.com/118621 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Revert "Make SkSL GLSL generator declare sk_FragColor inout when EXT fb ↵Gravatar Brian Salomon2018-04-04
| | | | | | | | | | | | | | | | | | | | | | | | | | fetch is used." This reverts commit 7e1dd2017a59a748c6cb10160868780d2dffdbc0. Reason for revert: breaking fp compilation Original change's description: > Make SkSL GLSL generator declare sk_FragColor inout when EXT fb fetch is used. > > Change-Id: I5e6e3263bb49febc757cd63d5d6c1518f174322d > Reviewed-on: https://skia-review.googlesource.com/118420 > Reviewed-by: Greg Daniel <egdaniel@google.com> > Commit-Queue: Brian Salomon <bsalomon@google.com> TBR=egdaniel@google.com,bsalomon@google.com Change-Id: I2aedfaff93150ba8cd1ed9fed22f3cfdd509695a No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/118600 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Make SkSL GLSL generator declare sk_FragColor inout when EXT fb fetch is used.Gravatar Brian Salomon2018-04-04
| | | | | | | Change-Id: I5e6e3263bb49febc757cd63d5d6c1518f174322d Reviewed-on: https://skia-review.googlesource.com/118420 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* ccpr: Normalize homogeneous coords with frexp/ldexpGravatar Chris Dalton2018-04-02
| | | | | | | | | | | | Hopefully increases cubic accuracy by manipulating exponents instead of calling normalize(). Bug: skia: Change-Id: I8d3596e858a2fbb6650c158753133c5a2e01e166 Reviewed-on: https://skia-review.googlesource.com/117009 Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Remove specVersion check on vk extensions.Gravatar Greg Daniel2018-04-02
| | | | | | | | | | | | | Unlike the specVersion parameter on the layers, specVersion on extensions does not mean what vulkan spec version the extensions work with but just what version of the extension it is. Thus we don't want to compare it to the version of the spec we are making. Bug: skia: Change-Id: If47c249b4cca0b9a10bfb3b8ce88db6bda1e12ed Reviewed-on: https://skia-review.googlesource.com/117634 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Revert "vulkan: Blacklist MSAA path renderer on Qualcomm drivers"Gravatar Chris Dalton2018-03-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 03616574024a7f321e885e5ab6fc575746573109. Reason for revert: Caused more bad golds than it fixed Original change's description: > vulkan: Blacklist MSAA path renderer on Qualcomm drivers > > Bug: skia:7758 > Change-Id: I96b5c259352949d67f5e0263a7164cdce54b3269 > Reviewed-on: https://skia-review.googlesource.com/117152 > Reviewed-by: Derek Sollenberger <djsollen@google.com> > Reviewed-by: Greg Daniel <egdaniel@google.com> > Commit-Queue: Chris Dalton <csmartdalton@google.com> TBR=djsollen@google.com,egdaniel@google.com,csmartdalton@google.com Change-Id: I80714a4cba7d495bc6ad89616b6c5f6eb8492bdb No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia:7758 Reviewed-on: https://skia-review.googlesource.com/117340 Reviewed-by: Chris Dalton <csmartdalton@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* vulkan: Blacklist MSAA path renderer on Qualcomm driversGravatar Chris Dalton2018-03-29
| | | | | | | | | Bug: skia:7758 Change-Id: I96b5c259352949d67f5e0263a7164cdce54b3269 Reviewed-on: https://skia-review.googlesource.com/117152 Reviewed-by: Derek Sollenberger <djsollen@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* Remove legacy GrContext factories function and supporting code/types.Gravatar Brian Salomon2018-03-23
| | | | | | | Change-Id: I437a4a0a58bf70ea1b8b0659b099a2af2bfa64fe Reviewed-on: https://skia-review.googlesource.com/116197 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Move a bunch of internal types from GrTypes to GrTypesPrivGravatar Brian Salomon2018-03-23
| | | | | | | Change-Id: I9fe1297ae7d185957c76681305bcf22cc972e53b Reviewed-on: https://skia-review.googlesource.com/116189 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Support GL_RGB textures and render targets.Gravatar Brian Salomon2018-03-22
| | | | | | | | | Bug= skia:7533 Change-Id: Iba30e90dbf2574368b773bb5cf2ebd5219559717 Reviewed-on: https://skia-review.googlesource.com/108188 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Fix version check for vulkan layersGravatar Greg Daniel2018-03-21
| | | | | | | | Bug: skia: Change-Id: I9520899c4b86d6436e3697d0cc6358c2b8641169 Reviewed-on: https://skia-review.googlesource.com/114686 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Revert "Revert "New read pixels implementation that is simpler but does all ↵Gravatar Brian Salomon2018-03-19
| | | | | | | | | | | | conversions on CPU."" This reverts commit be5947c2f38a79b7c709accfb1047d8fd06a0227. Bug: skia: Change-Id: I06dc15b31042d7827511d0ac2a7f4262c3f09622 Reviewed-on: https://skia-review.googlesource.com/115079 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Revert "New read pixels implementation that is simpler but does all ↵Gravatar Brian Salomon2018-03-19
| | | | | | | | | | | | | | | | | | | | | | | | | | conversions on CPU." This reverts commit c9a642edf2d1c7f5380fe829adbb1a692f9969a6. Reason for revert: 1010102 gms broke Original change's description: > New read pixels implementation that is simpler but does all conversions on CPU. > > Change-Id: Ia548cd24a8544b35a233311706faf48de353b7cf > Reviewed-on: https://skia-review.googlesource.com/109902 > Commit-Queue: Brian Salomon <bsalomon@google.com> > Reviewed-by: Robert Phillips <robertphillips@google.com> TBR=bsalomon@google.com,robertphillips@google.com,brianosman@google.com Change-Id: I7724a6eef79885ba2a32c1ac871e5b2a9a3c0c12 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/115140 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* New read pixels implementation that is simpler but does all conversions on CPU.Gravatar Brian Salomon2018-03-19
| | | | | | | Change-Id: Ia548cd24a8544b35a233311706faf48de353b7cf Reviewed-on: https://skia-review.googlesource.com/109902 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Make sure we set stencil layout when doing copy as drawGravatar Greg Daniel2018-03-19
| | | | | | | | Bug: skia: Change-Id: Ifa52e97d36a7008b670a1b69f1cd45df5c090f91 Reviewed-on: https://skia-review.googlesource.com/115008 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Don't emit empty command buffers in vulkanGravatar Greg Daniel2018-03-17
| | | | | | | | | | This may just cause use to do unneed loading and storing of memory. Bug: skia: Change-Id: I3f23d91df95f6e79b834fbb595ad9e9fb4371f9a Reviewed-on: https://skia-review.googlesource.com/114793 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Correctly discard or load RT when doing copies as draws in VulkanGravatar Greg Daniel2018-03-16
| | | | | | | | | | | This fixes all the copy as draw issues we've had with certain devices and the cap is no longer needed. Bug: skia: Change-Id: Id0b750849c4c920beae2d8cb3eda5f402018f194 Reviewed-on: https://skia-review.googlesource.com/114860 Commit-Queue: Greg Daniel <egdaniel@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* Make sure we do a render pass load if we copied to a surface before handGravatar Greg Daniel2018-03-16
| | | | | | | | Bug: skia: Change-Id: I4858e0774956f6283122bf71c84f3c6161e1d349 Reviewed-on: https://skia-review.googlesource.com/114790 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Fix vulkan layout barriers when we are doing in line uploads.Gravatar Greg Daniel2018-03-16
| | | | | | | | Bug: skia: Change-Id: I0842a4eebba8cfa8310d0680941d59f1e363e574 Reviewed-on: https://skia-review.googlesource.com/114760 Reviewed-by: Jim Van Verth <jvanverth@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Fix Vulkan Copy as draw shaderGravatar Greg Daniel2018-03-16
| | | | | | | | Bug: skia:7663 Change-Id: I745900ccc56c697e4abb982e921d99bc28502b33 Reviewed-on: https://skia-review.googlesource.com/114687 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Fix initialLayout update in Vk createTestingOnlyImageGravatar Greg Daniel2018-03-15
| | | | | | | | Bug: skia: Change-Id: I5d4321e68c065e3775266994c65a4abf18360731 Reviewed-on: https://skia-review.googlesource.com/114497 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Revert "ccpr: Unblacklist vulkan"Gravatar Greg Daniel2018-03-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 30ce2a3620ffe428762de08be50f3a62462524a2. Reason for revert: Crashing drivers on intel and powerVR. Possible SPIR-V error Original change's description: > ccpr: Unblacklist vulkan > > All issues have been resolved. > > Bug: skia: > Change-Id: Id63d63ad081725885cb0225b410b0d3972abd8f7 > Reviewed-on: https://skia-review.googlesource.com/113060 > Commit-Queue: Chris Dalton <csmartdalton@google.com> > Reviewed-by: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,csmartdalton@google.com Change-Id: Ibb9ea75cc0fbe2db0ff11a8b22bac8f47242f775 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/114540 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* ccpr: Unblacklist vulkanGravatar Chris Dalton2018-03-15
| | | | | | | | | | All issues have been resolved. Bug: skia: Change-Id: Id63d63ad081725885cb0225b410b0d3972abd8f7 Reviewed-on: https://skia-review.googlesource.com/113060 Commit-Queue: Chris Dalton <csmartdalton@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Revert "Improve handling of GrPixelConfig in GrBackendTex/RT ctors"Gravatar Greg Daniel2018-03-14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 7d2b16ad13fd3262c776ae75ae35da4ad69df690. Reason for revert: Maybe breaking chrome? Original change's description: > Improve handling of GrPixelConfig in GrBackendTex/RT ctors > > Make sure that no client facing code was relying on what we set as the > default value for fConfig by making in kUnkown. > > Bug: skia: > Change-Id: Ie52ff08ba8deeacc16fe06eb0dd0c7292b2edf91 > Reviewed-on: https://skia-review.googlesource.com/114261 > Reviewed-by: Robert Phillips <robertphillips@google.com> > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com Change-Id: I91e190d72407f9c4bee93a031a557f740bb49b66 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/114423 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Ensure that GrGpu state tracking is initialized before making a backend ↵Gravatar Brian Salomon2018-03-14
| | | | | | | | | RT/Tex in tests Change-Id: Ie5692d97678705306f514d5911bf331f784e7a40 Reviewed-on: https://skia-review.googlesource.com/114288 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Improve handling of GrPixelConfig in GrBackendTex/RT ctorsGravatar Greg Daniel2018-03-14
| | | | | | | | | | | | Make sure that no client facing code was relying on what we set as the default value for fConfig by making in kUnkown. Bug: skia: Change-Id: Ie52ff08ba8deeacc16fe06eb0dd0c7292b2edf91 Reviewed-on: https://skia-review.googlesource.com/114261 Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Add testing-only backend render target support to GrVkGpu.Gravatar Brian Salomon2018-03-13
| | | | | | | | | | | | | Update unit tests to use backend render targets on non-GL contexts Add named DM configs for rendering to Vulkan backend render targets and textures. Make src data ptr param to createTestingOnlyBackendTexture be const. Change-Id: I17f5375ed9bb08422006698956469d3151c4954c Reviewed-on: https://skia-review.googlesource.com/113276 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Add GrMockRenderTarget and mock backend render targetsGravatar Brian Salomon2018-03-09
| | | | | | | Change-Id: I59673dd7d0015471b7a81aa0c237c67043892454 Reviewed-on: https://skia-review.googlesource.com/113427 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Make GrGpu::deleteTestingOnlyBackendTexture() take const GrBackendTexture&Gravatar Brian Salomon2018-03-09
| | | | | | | Change-Id: Ibd00d0dc6d8c73628f26851e102defdbafab149b Reviewed-on: https://skia-review.googlesource.com/113164 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Vulkan backend render targets don't allow client to specify stencil bitsGravatar Brian Salomon2018-03-09
| | | | | | | | | | | We already always create the stencil buffer even for wrapped RTs. Make VulkanWindowContext use SkSurface::MakeFromBackendRenderTarget. Change-Id: I5df429d347331801954ec17cb9d75e323a7af345 Reviewed-on: https://skia-review.googlesource.com/113206 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Add GM configs that test rendering to a GL backend texture and render targetGravatar Brian Salomon2018-03-09
| | | | | | | | | This also adds GrGpu::create/deleteTestingOnlyBackendRenderTarget. Implemented in GL only for now. Change-Id: I9e5fdc953c4a249959af89e08332f520cefe9d90 Reviewed-on: https://skia-review.googlesource.com/113305 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Add testing only helper to flush and sync gpu.Gravatar Greg Daniel2018-03-08
| | | | | | | | | | | | The use case for this is mostly for Vulkan where we need to make sure the gpu is done with resources before we delete or use them in some way. Previously we used readPixels to do this which was just an ugly hack. Bug: skia: Change-Id: I7949ebc695032533675133aabca0e32840b417ba Reviewed-on: https://skia-review.googlesource.com/113122 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* Make Vulkan testing-only backend textures have optimal layoutGravatar Brian Salomon2018-03-07
| | | | | | | Change-Id: I984a6a657417565c36687d32e41b5f7d9bbc39f8 Reviewed-on: https://skia-review.googlesource.com/112800 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Initial texture data is never flipped when uploaded.Gravatar Brian Salomon2018-03-07
| | | | | | | | | The first bytes of the data always refer to the pixel accessed by texture coord (0, 0). Change-Id: I708702d90f35b3bc896a48c3c3fd6a0be73f505a Reviewed-on: https://skia-review.googlesource.com/112261 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Remove abandon param from GrGpu::deleteTestingOnlyBackendTexture.Gravatar Brian Salomon2018-03-07
| | | | | | | | | Prior to the existence of GrBackendTexture this was required to delete a backend-specific blob. Now it's a no-op. Change-Id: Iba0e4233e4d07235626f0ae14b0f7e77c073d8c0 Reviewed-on: https://skia-review.googlesource.com/112569 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>