Commit Graph

55253 Commits

Author SHA1 Message Date
Brian Osman
c23386ca39 Remove layout(override_coverage)
This was only used in the context of sk_SampleMask, which was removed
recently.

Change-Id: Id70d7af8b3a100ff157c2984bad4131f1b92f317
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/410056
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-05-18 19:39:54 +00:00
Florin Malita
a1304f513e [androidkit] Add SurfaceRenderer utility
Most samples use the same render thread boilerplate -- consolidate as
a utility base class.

Also add Canvas.getWidth/getHeight.

Change-Id: I27c9f51b4fd9d228a39593fbd4650a66d10240c2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409896
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Jorge Betancourt <jmbetancourt@google.com>
2021-05-18 19:37:44 +00:00
Chris Dalton
a9f759d022 Rewrite the path tessellation sample
Use the GrPathTessellators directly instead of going through
GrPathStencilFillOp. Add keyboard shortcuts to toggle between the
different path tessellators.

Bug: skia:10419
Change-Id: I5d80731d26c9a77fb0eca07a7023c50848e29f7c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409556
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Tyler Denniston <tdenniston@google.com>
2021-05-18 19:34:24 +00:00
Yegor Jbanov
3c429d05f9 make jline a JS object
Change-Id: Ib0e48868c77270f091c2d6ad857cd47278aff8a9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/410036
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Yegor Jbanov <yjbanov@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-05-18 19:25:54 +00:00
skia-autoroll
04192529f1 Roll SK Tool from 67f2438a6a3a to 8650dbaf6050
https://skia.googlesource.com/buildbot.git/+log/67f2438a6a3a..8650dbaf6050

2021-05-18 borenet@google.com [sk] Update release-branch to support last 4 Chrome branches

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/sk-tool-skia
Please CC jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Tbr: jcgregorio@google.com
Change-Id: I019ae70668ce98917d8dcf686fe10f442236784a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409960
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 18:51:14 +00:00
Brian Osman
3adc091af8 Remove layout(tracked) from SkSL
Change-Id: I6019418526def09c6c9f4b22567a2c76542d043c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409876
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-05-18 17:44:54 +00:00
skia-autoroll
d682b9f650 Roll SK Tool from a795b4c90da7 to 67f2438a6a3a
https://skia.googlesource.com/buildbot.git/+log/a795b4c90da7..67f2438a6a3a

2021-05-18 borenet@google.com Fix gazelle for @com_github_bazelbuild_buildtools//build
2021-05-18 borenet@google.com [autoroll] Fix skia -> lottie-ci roller
2021-05-18 kjlubick@google.com [gold] Fix issues with CL searching
2021-05-18 jcgregorio@google.com Move kube/attach.sh to presume ssh.cfg.
2021-05-18 kjlubick@google.com [gold] Don't use underscore in rubberstamp PS name
2021-05-18 kjlubick@google.com [gold] Use materialized views for by blame page
2021-05-18 kjlubick@google.com [gold] Make byblame respect public params
2021-05-18 kjlubick@google.com [gold] Properly apply blame when new trace begins
2021-05-17 kjlubick@google.com [gold] Use simple CIS for chrome internal tryjob data
2021-05-17 kjlubick@google.com [goldctl] Force timestamps of upload to be UTC
2021-05-17 jcgregorio@google.com [docsy] Move tests to Large.
2021-05-17 jcgregorio@google.com Make gazelle.
2021-05-17 jcgregorio@google.com Add revportforward package and cli.
2021-05-17 borenet@google.com [autoroll] Increase disk size for nearby-connections -> chromium roller
2021-05-17 borenet@google.com [cq] Update cq package to handle new starlark format
2021-05-17 jcgregorio@google.com Remove repo-sync code.
2021-05-17 kjlubick@google.com [gold] Update images
2021-05-17 jcgregorio@google.com [skolo] Start on ansible scripts usable from the desktop.
2021-05-17 rmistry@google.com [Autororollers] Change SwiftShader->Android reviewer
2021-05-17 kjlubick@google.com [gold] Add frontend option for by blame

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/sk-tool-skia
Please CC jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Tbr: jcgregorio@google.com
Change-Id: I34710e50c9819ab1d13ff4f338d765ef6cf280d4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409805
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 17:15:14 +00:00
Robert Phillips
9e42ec3058 Remove usage of GrImageInfo from SkBaseGpuDevice
Change-Id: I536c922d72a2e674e364f685d828acd6af5414f9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409496
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2021-05-18 17:13:34 +00:00
Brian Osman
fb8d20befa Stop using layout(tracked) in .fp files
Change-Id: Ia202cad02b5977511b1b9b36fdf8dcbc8b8058d7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409776
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-05-18 15:40:43 +00:00
Mike Reed
bdfd776161 Optimize reading from a JS array
Grants read-access to a JS array, either ...
- direct peek into the (malloc'd buffer)
- quick copy (the src was a typed_array)
- slow copy (had to perform a per-element lookup)

Change-Id: Id389f244039d35aefd84e0d95d598cbe15cd28c4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409397
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2021-05-18 15:25:37 +00:00
Ethan Nicholas
55a63afc5f Make it possible to use the DSL from within the compiler itself
The DSL would not previously function within the compiler, because it
expected to be in charge of everything itself. The compiler and DSL also
disagreed about how to handle some things, such as the DSL not
respecting the compiler's override flags.

This CL moves responsibility for much of the setup process into
DSL::Start(), which the compiler now invokes. DSL::Start() now also
takes a ProgramSettings instead of DSL-specific flags, and the
externalFunctions vector has been moved into ProgramSettings.

Change-Id: I283ed8366e25d67f02c43833743c5f8afdedaefc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408136
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-05-18 15:10:53 +00:00
Florin Malita
5e8d88ef29 [androidkit] Add support for Skottie animations
Change-Id: Ibba2c0c8ad5b10d90f0bb30a3a859dacb94a03ad
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409400
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Jorge Betancourt <jmbetancourt@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2021-05-18 14:49:43 +00:00
Stephen White
24a358e20f Remove wgpu::Fence object from Dawn backend.
(It was unused.)

Bug: dawn:22
Change-Id: Ibcb31d35044c9875ab99304282bcbac584251257
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409498
Commit-Queue: Stephen White <senorblanco@google.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
2021-05-18 14:44:53 +00:00
Jorge Betancourt
a5654567f6 [androidkit] use cube face normals to prioritize cube face draws
Change-Id: I595a11c8cd5d9ba6ff64aee5ff91b9051ea8415e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409337
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Jorge Betancourt <jmbetancourt@google.com>
2021-05-18 14:23:44 +00:00
Brian Salomon
5696bcd0f7 GrColorTypeDesc -> GrColorFormatDesc
Want to also  use this to use this for texture formats so remove
"ColorType" from name.

Also class rather than struct.

Bug: chromium:1113801
Change-Id: Ieb08a3d81c465b92b956d9bc04b39c5783715ea8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409476
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-05-18 12:56:33 +00:00
Kevin Lubick
66125eac15 [canvaskit] Specify gold url and bucket for uploading
A previous change to goldctl removed the special-casing for
Skia, so we need to specify it ourselves.

Change-Id: If4d122daa4ee4bb865b628b7c6ee1cbe5d44d670
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409396
Reviewed-by: Ravi Mistry <rmistry@google.com>
2021-05-18 12:49:08 +00:00
skia-autoroll
3d854bade6 Roll Chromium from ecbf59478cb7 to 0a2ed03e195c (406 revisions)
ecbf59478c..0a2ed03e19

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/chromium-skia-autoroll
Please CC bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia/skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Tbr: bsalomon@google.com
Change-Id: Ie304eb60bd6a7060d08ea6c05cf3dff22374bd49
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409620
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 05:24:43 +00:00
skia-autoroll
419241b323 Roll Dawn from c2a281862153 to 880a3d631197 (13 revisions)
https://dawn.googlesource.com/dawn.git/+log/c2a281862153..880a3d631197

2021-05-18 hao.x.li@intel.com Fix query index of availability in timestamp shader
2021-05-17 senorblanco@chromium.org Split #defines for OpenGL and OpenGL ES backends.
2021-05-17 aleksi.sapon@builditsoftware.com CMake: add dependency to dawncpp_headers on dawn_common
2021-05-17 cwallez@chromium.org Use Tint as much as possible in fuzzers.
2021-05-17 yunchao.he@intel.com Rename some data structures in TextureCopySplitter
2021-05-16 jiajia.qin@intel.com Use the device maximum supported shader model
2021-05-14 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from df8b2783a446 to 31d761329a5f (4 revisions)
2021-05-14 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 222fae1c8c2f to df8b2783a446 (1 revision)
2021-05-14 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 26e0312de2da to 222fae1c8c2f (3 revisions)
2021-05-14 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 09587e1d862b to 26e0312de2da (3 revisions)
2021-05-13 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 688fe4477dff to 09587e1d862b (4 revisions)
2021-05-13 bajones@chromium.org Remove deprecated API surface, Pt. 1
2021-05-13 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 9b1ee6bdeafd to 688fe4477dff (1 revision)

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from 9b1ee6bdeafd to 31d761329a5f

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dawn-skia-autoroll
Please CC cwallez@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: cwallez@google.com
Change-Id: I5b24805b8c0cd1704a4bde04c1906e121dffcf08
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409621
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 04:59:13 +00:00
skia-autoroll
b35c4aa604 Roll ANGLE from 8328743a2ec3 to ac42dbf98772 (13 revisions)
8328743a2e..ac42dbf987

2021-05-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from 055e71b2a367 to 3d799e0e9b08 (25 revisions)
2021-05-18 syoussefi@chromium.org Vulkan: Optimize respecifying an image
2021-05-18 syoussefi@chromium.org Vulkan: Fix a bug releasing DynamicBuffer-owned buffer
2021-05-18 cnorthrop@google.com Tests: Add Pokemon Go trace
2021-05-18 cnorthrop@google.com Capture/Replay: Add const to string pointer
2021-05-18 cnorthrop@google.com Capture/Replay: Skip glGetActiveUniform
2021-05-18 cnorthrop@google.com Capture/Replay: Reset programs on loop
2021-05-17 cnorthrop@google.com Skip Texture2DTest.TextureSize on Linux+GL+TSAN
2021-05-17 jmadill@chromium.org ANGLETest: Skip test setup/teardown on major error.
2021-05-17 jonahr@google.com Fix out_of_range error in System_utils_posix
2021-05-17 syoussefi@chromium.org Vulkan: Cleanup texture image respecify
2021-05-17 syoussefi@chromium.org Vulkan: Fix desc set cache bug with xfb offset
2021-05-17 jmadill@chromium.org Gold Tests: Implement flaky retries and sharding.

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-skia-autoroll
Please CC bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Tbr: bsalomon@google.com
Test: Test: Pokemon Go MEC
Test: Test: angle_perftest --gtest_filter="*pokemon_go*"
Change-Id: Id021c816f2598532ddc10dfad0daa2a3efa927cb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409638
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 04:55:53 +00:00
skia-autoroll
454bf27e2c Roll SwiftShader from af907708adb3 to 0ca03fb2907c (1 revision)
https://swiftshader.googlesource.com/SwiftShader.git/+log/af907708adb3..0ca03fb2907c

2021-05-17 capn@google.com Update Android build files with license info

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/swiftshader-skia-autoroll
Please CC bsalomon@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian10-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: skia:11901
Tbr: bsalomon@google.com
Change-Id: I3a18a5071172779849b0499c8085eda2a8a64a7c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409622
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-18 04:50:53 +00:00
Mike Reed
e8cd0a5404 Don't need/want to pay attention to non-shaping attributes
Change-Id: I16d75c9d8fb3c61a4993fe216142e80884bc2ad1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409576
Reviewed-by: Mike Reed <reed@google.com>
2021-05-18 01:06:08 +00:00
Chris Dalton
e73c070911 Refactor stroke tessellation shaders
Splits the instanced and tessellation implementations into their own
separate files and merges their common code into a shared base class.
Renames GrStrokeTessellateShader to GrStrokeShader.

Bug: skia:10419
Change-Id: Ia731509858e682a605ee65c9ced1fd163e4c03f3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409036
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Tyler Denniston <tdenniston@google.com>
2021-05-17 23:18:10 +00:00
John Stiles
2fed9f62d2 Disable SkSLStaticSwitchInline_GPU on Adreno.
This appears to be a driver bug with improperly handling dead code.

Change-Id: I4925c1d2b8ed008ba3da6ceda0eed61d08b671ca
Bug: skia:12012
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409497
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-05-17 22:30:40 +00:00
John Stiles
325c808ebb Enable additional SkSL tests which require non-ES2 features.
Although these tests are simple, it ended up uncovering a legitimate
SPIR-V bug (skia:12009).

Change-Id: Ie89235157256b97626aa6ada4d9d6ba62abc57fa
Bug: skia:12009
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409299
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-05-17 20:24:50 +00:00
John Stiles
f2b08cc9c8 Fix SPIR-V code generation of dead return statements.
If we encounter code like `return 1; return 2;` we need to synthesize a
label, even though the second return statement isn't actually reachable.
This is harmless and satisfies the SPIR-V validator.

Ideally we'd eliminate the dead code entirely, but this case is rare and
isn't likely to cause any problems as-is.

Change-Id: I2d6219dff6868011353e19a662301bec44a015d6
Bug: skia:12009
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409402
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-05-17 20:23:40 +00:00
Robert Phillips
c2132ea18d Start retracting GrSurfaceDrawContext
The NGA probably won't have a GrSurfaceDrawContext. The endgame here is to have both SkSurface_Gpu and GrVkSecondaryCBDrawContext hold a SkBaseGpuDevice.

Change-Id: I4b90d7832d28f872a9417f766e441fc15460be90
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409399
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2021-05-17 20:15:20 +00:00
Chris Dalton
85edec6c9f Update stroke tessellation shader to match instanced
This CL is prep work for extracting a common base class from these two
shaders.

* Outset by [y,-x] instead of [-y,x]
* Scale the strokeOutset by miter_extent instead of the STROKE_RADIUS
* Clamp strokeOutset immediately for joins instead of stashing a
  "clamp" variable and clamping at the end.

Bug: skia:10419
Change-Id: Icc67d45d9a945b93b3a192d76ec6028432a1d1db
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408818
Reviewed-by: Tyler Denniston <tdenniston@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-05-17 20:12:21 +00:00
Adlai Holler
858fc99f0d Make GrRenderTask::numTargets non-virtual
Don't know why this was virtual, but it slowed down our clustering
substantially. Like, 25% slowdown on my desktop.

Bug: skia:10877
Change-Id: I67056d9c566c34562eb215d9abb7760a01baa3cb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409417
Commit-Queue: Adlai Holler <adlai@google.com>
Auto-Submit: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2021-05-17 20:02:50 +00:00
Adlai Holler
304f653e1d Optimize GrOpsTask::onIsUsed
Before this CL, the render task clustering algorithm was taking
a ton more CPU time than needed by visiting proxies every
time it needed to check for surface usage.

Note also, the fSampledProxies does indeed usually contain many
duplicates in our SKPs. Sometimes 3 or 4x. I may experiment with
using a hash set as suggested by a comment.

Bug: skia:10877
Change-Id: Iae01ed16d7b4c7cda343d37ab8fd6147ae6c65e7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409416
Reviewed-by: Robert Phillips <robertphillips@google.com>
Auto-Submit: Adlai Holler <adlai@google.com>
Commit-Queue: Adlai Holler <adlai@google.com>
2021-05-17 20:02:10 +00:00
Kevin Lubick
5b38536d76 [canvaskit] Add tests for getGlyphIntercepts
Change-Id: I115dafccb74bdf5a61f7ed25bf97fc1cec682c1d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409403
Reviewed-by: Mike Reed <reed@google.com>
2021-05-17 19:24:07 +00:00
Chris Dalton
489fa0b121 Reland "Delete the index buffer from middle-out tessellation"
This is a reland of 0d0b1b3b56

Original change's description:
> Delete the index buffer from middle-out tessellation
>
> This gives us more flexibility for customizing triangulations in
> future modes. It is also hopefully cheaper than the extra memory
> indirection from indexed draws.
>
> Bug: skia:10419
> Bug: chromium:1202607
> Change-Id: Iba41a35a634edf8f962c3d604c7e035e7a85801d
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407296
> Commit-Queue: Chris Dalton <csmartdalton@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

Bug: skia:10419
Bug: chromium:1202607
Change-Id: I73487087fba09d3ab95d8fa8bd4e2435ba802075
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408676
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-05-17 19:05:30 +00:00
Brian Osman
7069804621 Revert "Enable vertex ID support on Metal"
This reverts commit 6f520cd120.

Reason for revert: Mixed perf results (including Flutter). skbug.com/12010

Original change's description:
> Enable vertex ID support on Metal
>
> This allows the tessellated stroke renderer to run on Metal.
>
> Change-Id: Ia6bd4008a3310cd316abdc2715efcec3916c6bfa
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408358
> Reviewed-by: Chris Dalton <csmartdalton@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>

# Not skipping CQ checks because original CL landed > 1 day ago.

Change-Id: I8e01bcd6abf0ebcc80ba63194050cc70c53f43c6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409401
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-05-17 18:50:50 +00:00
Jorge Betancourt
ec978bbc4d expose canvas.localToDevice to androidKit
Change-Id: Ia6af3a06b9be078fd0b281a89fad0641082fd0ee
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409336
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Jorge Betancourt <jmbetancourt@google.com>
2021-05-17 18:41:20 +00:00
Chris Dalton
5bd3a5c351 Disable vertex ID support on SwiftShader
Once this is fixed we can hopefully check the version number before
disabling.

Bug: skia:11965
Bug: b/188239650
Change-Id: Idc29058e23c6e1750555165ba57b695a7cc0f925
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409338
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-05-17 18:11:50 +00:00
Eric Boren
5108c6848f [infra] Fix go.sum
https://skia-review.googlesource.com/c/skia/+/409277 didn't include a
"go mod download", which is causing rollers to fail.

Change-Id: Ieb82ab881a07bdc2ec21a2c7bd87c5ff57e5585b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409398
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2021-05-17 18:06:20 +00:00
John Stiles
191b4e2a00 Enable proper testing of matrix-scalar ops.
Now that the various Metal and SPIR-V bugs have been shaken out, we can
enable these tests. Knock on wood.

Change-Id: If4b4e302cfdd91464aaf00bc9639989de5e49aac
Bug: skia:11985
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408640
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-05-17 17:36:22 +00:00
Brian Salomon
4695312349 Reland "When running on ANGLE GL backend use the underlying GL driver info to setup caps."
This is a reland of bb006430ae

Disables client side arrays, not supported on ANGLE

Bug: chromium:1203705

Original change's description:
> When running on ANGLE GL backend use the underlying GL driver info
> to setup caps.
>
> Bug: 1203705
> Change-Id: Ia50dfc6aef44848d81c735dc98dafdc692e8da40
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/406117
> Reviewed-by: Greg Daniel <egdaniel@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

Bug: 1203705
Change-Id: Ie5fb28d817f8d85d205e5daaa6b1b9929abacb76
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407776
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-05-17 16:46:40 +00:00
Brian Salomon
6b5b7e71ba GrConvexPolyEffect skips all move-tos without assert.
The convexity checker in SkPath used to bar paths that have "empty"
move-tos. Now it doesn't. GrConvexPolyEffect had an assert against the
old behavior.

Bug: chromium:1209642
Change-Id: Ia793eb2a5d039b266f9ff6f266d09da36ff8815a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409296
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-05-17 16:39:30 +00:00
Brian Salomon
6bddf46375 Revert "Use SkImage_Raster's unique ID to cache textures."
This reverts commit 8005007e98.

Reason for revert: text drop outs on D3D???
https://gold.skia.org/diff?test=xfermodes&left=1521937fb71ceb0615e8d369096ac180&right=b262b21be69db7b55b46106c0f60e9d7

Original change's description:
> Use SkImage_Raster's unique ID to cache textures.
>
> SkImages can share SkBitmaps and have different unique IDs/mipmap
> status. Currently we cache the texture version using the bitmap's
> unique ID. Instead use the image's ID so different images produce
> different textures (e.g. mipped and nonmipped).
>
> Bug: skia:11983
> Change-Id: Ic37564186f675277e5a9de1bcf36b40a19c3a3de
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407356
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Robert Phillips <robertphillips@google.com>

TBR=bsalomon@google.com,robertphillips@google.com

Change-Id: I39422295840ecdf363d3541380e7a25ab91a198b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:11983
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409298
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-05-17 16:24:11 +00:00
John Stiles
bdf3bb7b5f Add support for componentwise matrix divide in SPIR-V.
All the pieces of the puzzle were already here to support componentwise
addition and subtraction of matrices. Division was just a forgotten gap
in the implementation and is now patched up to match + and -.

NOTE: if you read the SPIR-V output very closely, you may be surprised
that there are fewer FDiv operations than you'd expect from reading the
input SkSL. As it turns out, a preexisting optimization is rewriting
`mat / 4` into `mat * 0.25` (see line 2689), and this rewritten form can
use the dedicated MatrixTimesScalar op. So we only get componentwise
FDivs for the `4 / mat` lines in the source.

Change-Id: I011c859f5b3a031fbb95a2956f1194a5f3b3794b
Bug: skia:11985
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408639
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-05-17 16:01:10 +00:00
John Stiles
c1f6411045 Enable a handful of tests which require ES3.
Previously, these tests were commented out because Runtime Effects could
not compile ES3. More recently, the `enforceES2Restrictions` option flag
was added, which allows these tests to work inside a Runtime Effect.

Most of our commented-out tests can be supported this way; enabling them
a few at a time will make the inevitable debugging simpler when a driver
runs into issues with a test.

Change-Id: I1a7a377d392151df4b4789ed5062706717c5a41b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409280
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-05-17 15:02:50 +00:00
Brian Salomon
8005007e98 Use SkImage_Raster's unique ID to cache textures.
SkImages can share SkBitmaps and have different unique IDs/mipmap
status. Currently we cache the texture version using the bitmap's
unique ID. Instead use the image's ID so different images produce
different textures (e.g. mipped and nonmipped).

Bug: skia:11983
Change-Id: Ic37564186f675277e5a9de1bcf36b40a19c3a3de
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407356
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2021-05-17 14:55:50 +00:00
skia-autoroll
9b984bb149 Roll ANGLE from 3d082a102d72 to 8328743a2ec3 (5 revisions)
3d082a102d..8328743a2e

2021-05-17 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from c4d054c6ad41 to af907708adb3 (2 revisions)
2021-05-17 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 3b747dab7bb3 to 9b886afc6e79 (485 revisions)
2021-05-17 gert.wollny@collabora.com Capture/Replay: Add suffix to label for test file search
2021-05-17 gert.wollny@collabora.com Capture/Replay: Print context diff also with frame gaps
2021-05-17 gert.wollny@collabora.com Capture/Replay: track robustResourceInit

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-skia-autoroll
Please CC bsalomon@google.com,robertphillips@google.com on the revert to ensure that a human
is aware of the problem.

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Tbr: bsalomon@google.com,robertphillips@google.com
Change-Id: I927f2f91db64e3045aa22281bec3607860bc6488
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409221
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-05-17 14:44:50 +00:00
Corentin Wallez
19f8f27282 Fix usage of deprecated wgpu::TextureUsage::OutputAttachment
Fixed: dawn:788
Change-Id: I2ec810fdd177aff61519192c234d5cb8cabe68d6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409236
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Stephen White <senorblanco@google.com>
Reviewed-by: Stephen White <senorblanco@google.com>
2021-05-17 14:42:30 +00:00
Ravi Mistry
f0cb8da134 Update go.skia.org/infra in go.mod/go.sum
To pick up recent changes in buildbot repo for master-> main migration

Updated with:
$ go get go.skia.org/infra@1a8ff8585f
$ make -C infra/bots train

Bug: skia:11987
Change-Id: Iffa108dff585153c5bf47e709e99d3fa805d6d51
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/409277
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2021-05-17 14:32:20 +00:00
John Stiles
a91bf055ea Add support for matrix-scalar operations in SPIR-V.
Multiplication is handled just as before. Ops other than multiplication
are handled by splatting the scalar into a matrix, then performing the
op as a componentwise matrix-op-matrix binary expression.

Change-Id: I654715c45bf5c91b8e9660fdf1c1c6d6818b621a
Bug: skia:11985
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408637
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-05-17 14:19:10 +00:00
Kevin Lubick
ed0c0ed028 [canvaskit] Add initial implementation of generating TS
This adds some initial features for generating the ambient
namespace files (the TS equivalent of .h files) for the
C++ binding files. There are a few tests and it works on
the sample code in tskit.

I split the bindings/ folder into bindings/ and interface/
(for C++ and TS code, respectively).

This can be tested locally by running
make generate && make debug && make serve
and verifying that everything compiles and runs in the browser.

One thing I changed for easier parsing was making a @type
annotation required, with an @optional tag for making a field
or constant optional.

Change-Id: If9c5a664e84fac4c734277cddd7774989a1f7bf8
Bug: skia:11826
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407476
Reviewed-by: Nathaniel Nifong <nifong@google.com>
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
2021-05-17 13:56:31 +00:00
John Stiles
ab3e6394a0 Re-enable the nonsquare matrix test.
The mat4x2 portion of the test no longer checks its results, as there
are bugs in the Intel and Radeon GPU drivers that prevent mat4x2s
from being constructed properly.

The SkSL optimizer ends up eliminating the 4x2 matrix entirely because
it is unused by the rest of the code, as well at the 4x4 matrix which is
calculated from the 4x2. At this point, I'm OK with this.

Change-Id: If1464f9e4938b0a37b2ec180c686972389d94e83
Bug: skia:12003
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/408900
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-05-17 13:27:48 +00:00
Dominik Röttsches
2da029b28f [COLRv1] Map linear gradient extrema to [0, 1] range
Prepare data to Skia's linear gradient shader so that the extrema are
[0, 1] when the data in the font does not have them at these
positions. This is required for the shader to correctly compute repeat
modes.

Add the test font from the Google color fonts repo [1] with stops at [0,
1], [0.2, 0.8], [0, 1.5], [0.5, 1.5] respectively, compare[2].

[1] https://github.com/googlefonts/color-fonts/blob/main/fonts/more_samples-glyf_colr_1.ttf
[2] https://github.com/googlefonts/colr-gradients-spec/issues/281#issuecomment-828346428

Bug: skia:11922
Change-Id: Ic62a26911fa177af35ca16f183b5985d884237a5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/405717
Commit-Queue: Dominik Röttsches <drott@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-05-17 12:24:37 +00:00
Jim Van Verth
d2567de8bb Fix Metal MSAA in Viewer.
Sets the sample count so we create the MSAA color buffer, and
sets the manual MSAA resolve flag for the created rendertarget.

Change-Id: I577bc619ce0ce8490704135c72139ad7a05904e4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/407818
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2021-05-17 11:15:57 +00:00