Commit Graph

53106 Commits

Author SHA1 Message Date
Brian Salomon
b60255033d Push SkYUVAInfo into GrYUVToRGBEffect.
Wrap up SkYUVAInfo and proxies into new type GrYUVATextureProxies.

Bug: skia:10632
Change-Id: Ic907d78a1a40af3c8ef838021749839c422d62dc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353042
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2021-01-13 19:32:45 +00:00
John Stiles
3c1917983b Update VectorConstructor unit test with mixed-type ctors.
GLSL allows mixed types inside a vector constructor, but SkSL currently
doesn't handle it well; some cases don't compile, and others generate
bad code. This will be fixed in a followup CL.

Change-Id: Ia98b498f320b8fa91595404730f6cdc836615140
Bug: skia:11164
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353577
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-01-13 19:09:16 +00:00
Jason Simmons
d8e9436a78 Cache ICU break iterators in SkUnicode_icu
Gate this behind an ifdef that can be disabled in environments where
the ICU ubrk_safeClone API is not available.

Change-Id: Ia1a3f677271622f2b7ae478b4d1ce76c74eed057
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352876
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Jason Simmons <jsimmons@google.com>
2021-01-13 18:35:24 +00:00
Ethan Nicholas
67a0a8a787 Fixed error reporting on invalid SkSL assignments
Change-Id: I9859081a14b110731f943e09fdd94dc10e0c9dfc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353580
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2021-01-13 18:34:44 +00:00
John Stiles
56a9105ac9 Reland "Scrub memory released from a GrMemoryPool in debug mode."
This is a reland of c0315a72d9

Original change's description:
> Scrub memory released from a GrMemoryPool in debug mode.
>
> In debug mode, we now overwrite released memory with 0xDD. This is
> intended to make use-after-free errors easier to catch while debugging.
>
> Change-Id: I04a4c5abcfef5f3f604a2430da15a8b5125239af
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352956
> Auto-Submit: John Stiles <johnstiles@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

Change-Id: Id79cadb196868b467fb6d9107eb313bdc147b4f0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353419
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-01-13 18:27:54 +00:00
Tyler Denniston
7bb85dbb5e [svg] Add plumbing for color-interpolation-filters property
The default colorspace for filter effects is linear RGB, as specified in
https://www.w3.org/TR/SVG11/painting.html#ColorInterpolationProperties.
Currently we perform all filtering in the destination colorspace. This
CL adds the new presentation attribute with the default setting
(according to the spec) of linear RGB.

This CL does not actually implement any colorspace transformations for
filters.

Bug: skia:10841
Change-Id: Id778ad3fa5cb6e0aed756584a50880edd9d82e2b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352738
Commit-Queue: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2021-01-13 18:07:14 +00:00
Mike Klein
bd747cb1e7 support 7 args in skvm::Program::eval()
On x86_64 we cap out at 6 arguments for JITing, but on arm64 we support
up to 7.  This change avoids the assert when running SkSLInterpreter
unit tests that do hit 7 arguments.

Cq-Include-Trybots: luci.skia.skia.primary:Test-Android-Clang-Pixel-CPU-Snapdragon821-arm64-Debug-All-Android,Test-Android-Clang-Pixel-CPU-Snapdragon821-arm64-Debug-All-Android_ASAN
Change-Id: I17383679fb9bce2e4ce052bcac3c694e5af77124
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353537
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2021-01-13 17:24:44 +00:00
Florin Malita
836c2ca6a1 [svg] Initial mask plumbing
Introduce SkSVGMask and plumb related attributes.

Also consolidate the clip/mask/filter property types - they all support
the same values: <funciri>|none|inherit.

Bug: skia:10842
Change-Id: If45a75cccc19b84d6547237336fe5d562a85d594
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353436
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Tyler Denniston <tdenniston@google.com>
2021-01-13 17:23:24 +00:00
Ethan Nicholas
92969f2656 SkSL DSL operator overloading
This adds basic operator overloading (everything but array indexing) and
related tests to the SkSL DSL.

Change-Id: Ic9fdc9a02a5496e2706d18fb435d838b4ee53ad7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353103
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-01-13 16:18:14 +00:00
John Stiles
1242b3fb29 Add guard-rails to Constructor constant-value fetchers.
Previously, we blindly trusted that the scalars inside a compile-time-
constant vector Constructor would be of matching type. (e.g. the scalars
inside a half3 constructor would always be of type half) This *should*
be true if we've done all our type-checking homework correctly, but we
would ABORT if anything went wrong. Now, we are less trusting and will
actually verify types and do the right thing if the scalar inside turns
out to be an int somehow. In practice, there's no real downside to
doing the conservative type-checks.

Change-Id: If0a255eb96a0ccfec7d0a261caad542cae93d078
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353556
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-01-13 15:53:54 +00:00
John Stiles
059bea1380 Simplify IRGenerator::coerce.
I started unpacking the mechanics of type coercion, and realized that
the second half of the function was looking up the Symbol for a Type
based on its name (Types are already Symbols), converting that Symbol
back into a Type (we started with a Type anyway), wrapping that Type
in a TypeReference, then calling that TypeReference (which always
calls convertConstructor).

This CL cuts out the middle steps and simply calls convertConstructor
directly. A test was added to confirm that an earlier error encountered
on the CQ is no longer occurring.

Change-Id: I76aae455a301afe4e67ef989d9dfe11f47ed36ae
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353105
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-01-13 15:43:44 +00:00
Brian Salomon
7f296c421e Revert "Reland "asyncRescaleAndRead supports unpremul results on GPU""
This reverts commit 0d7de6bc9a.

Reason for revert:  new test failing on pixels

Original change's description:
> Reland "asyncRescaleAndRead supports unpremul results on GPU"
>
> This is a reland of 70fa84a9bf
>
> Bug: skia:11019
>
> Original change's description:
> > asyncRescaleAndRead supports unpremul results on GPU
> >
> > GrSurfaceContext::rescale uses GrSurfaceFillContext instead of
> > GrSurfaceDrawContext.
> > Change-Id: I9c2d647d8f221c129ec4485a4ed936202aee6362
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/351923
> > Reviewed-by: Robert Phillips <robertphillips@google.com>
> > Commit-Queue: Brian Salomon <bsalomon@google.com>
>
> Cq-Include-Trybots: luci.chromium.try:android-marshmallow-arm64-rel
> Change-Id: I7b696c37edea8f755ec03431d026ea78556e5844
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353099
> Commit-Queue: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Robert Phillips <robertphillips@google.com>

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

Change-Id: I20523adc2a94185be4802c3802c23531e6e7546f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:11019
Cq-Include-Trybots: luci.chromium.try:android-marshmallow-arm64-rel
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353557
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-01-13 14:57:13 +00:00
Florin Malita
fc0ea0a4a5 [svg] TextPath support
- introduce SkSVGTextPath and update the text render logic to
    instantiate new SkSVGTextContexts in onRenderText() overrides
    instead of renderText() root -- this is to observe spec semantics
    [1] requiring <text> and <textPath> to always start a new chunk,
    regardless of their relative nesting.
  - expand SkSVGTextContext to also store PathData when used in the
    scope of a textPath
  - PathData caches SkContourMeasures, for path position lookup
  - update flushChunk() to apply path glyph adjustments [2]:

    * the horizontal glyph position (including relative offset dx),
      adjusted for the glyph center yields a path offset
    * if the offset is outside the path range, the glyph is skipped
    * otherwise the position is determined based on the path matrix
      at the computed offset

   - to support the logic above, the chunk starting position is no
     longer used as a global blob offset but instead is folded into
     individual glyph RSXforms (and the blob always draws at {0,0})

[1] https://www.w3.org/TR/SVG11/text.html#TextLayout
[2] https://www.w3.org/TR/SVG11/text.html#TextpathLayoutRules

Bug: skia:10840
Change-Id: I462eada7c086646afdc1bc84f08ec2368613f1c0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/349397
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Tyler Denniston <tdenniston@google.com>
2021-01-13 14:37:39 +00:00
Mike Reed
3a61906e94 Allow chrome to be nearest until it can rebaseline
No changes expected -- only if chrome decides to opt into nearest

Change-Id: Ie493b6c814f3e1e603a116e59a777e5f6b16b370
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353358
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Reed <reed@google.com>
2021-01-13 14:23:39 +00:00
John Stiles
7ce175117f Split apart SkRuntimeInvalid tests into multiple functions.
This will help us narrow down the failing test from
http://review.skia.org/353097

Change-Id: Ida3bbecb09c278913cfb302ba7e7766f1a2cbcb0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353418
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-01-13 14:11:42 +00:00
Brian Salomon
0d7de6bc9a Reland "asyncRescaleAndRead supports unpremul results on GPU"
This is a reland of 70fa84a9bf

Bug: skia:11019

Original change's description:
> asyncRescaleAndRead supports unpremul results on GPU
>
> GrSurfaceContext::rescale uses GrSurfaceFillContext instead of
> GrSurfaceDrawContext.
> Change-Id: I9c2d647d8f221c129ec4485a4ed936202aee6362
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/351923
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

Cq-Include-Trybots: luci.chromium.try:android-marshmallow-arm64-rel
Change-Id: I7b696c37edea8f755ec03431d026ea78556e5844
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353099
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2021-01-13 13:48:09 +00:00
skia-autoroll
be2a8614c5 Roll Chromium from b9b9a8a5022a to 8aca3b4d64f2 (503 revisions)
b9b9a8a502..8aca3b4d64

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 ethannicholas@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: ethannicholas@google.com
Change-Id: If03af0114469192dd392ff8bdab2420ed50f8908
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353458
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-13 05:37:19 +00:00
skia-autoroll
cc3e936e6e Roll ANGLE from 5b8dec52b68f to 2ed9671a0ddd (8 revisions)
5b8dec52b6..2ed9671a0d

2021-01-12 cnorthrop@google.com State: Provide reference to image unit binding vector
2021-01-12 jmadill@chromium.org Vulkan: Add YUV G8_B8_R8_3PLANE_420_UNORM format.
2021-01-12 cnorthrop@google.com Allow GL_OES_shader_image_atomic when non-conformant
2021-01-12 jmadill@chromium.org Vulkan: Index mandatory support table by ANGLE format.
2021-01-12 syoussefi@chromium.org Vulkan: Increment buffer view serials only when used
2021-01-12 syoussefi@chromium.org Vulkan: Notify ContextVk when UtilsVk binds compute pipelines
2021-01-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 348ba200aa29 to 3549479dc4cc (3 revisions)
2021-01-12 jonahr@google.com GL: Clean up Display code related to multithreading

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 ethannicholas@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: ethannicholas@google.com
Test: Test: Aztec Ruins MECTest: Test: Fortnite on ANGLE
Change-Id: If50aae6eaf50ad6f9f2619d03fb7007b882e7b20
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353457
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-13 04:45:59 +00:00
skia-autoroll
38ca513408 Roll Dawn from 9ff83f6c957f to 424fd828893e (13 revisions)
https://dawn.googlesource.com/dawn.git/+log/9ff83f6c957f..424fd828893e

2021-01-13 enga@chromium.org Update DepthStencilStateTests to use WGSL
2021-01-12 shrekshao@google.com Fix SamplerFilterAnisotropicTests mipmap
2021-01-12 dsinclair@chromium.org Convert WGSL comments to //
2021-01-12 cwoffenden@gmail.com Fixes to build with MSVC 2019
2021-01-12 cwallez@chromium.org Add the correct rpath to use Swiftshader / Vulkan on macOS
2021-01-12 bryan.bernhart@intel.com D3D12: Add HLSL compiler version to key
2021-01-12 cwallez@chromium.org Rolling 3 dependencies
2021-01-12 cwallez@chromium.org cr-buildbucket.cfg: Use Windows 10 only for CQ
2021-01-12 cwallez@chromium.org Add new third-party dependencies to .gitignore
2021-01-12 bclayton@google.com ShaderModule: Enable the prettier tint diagnostic formatter
2021-01-12 cwoffenden@gmail.com Minor fix to build with MSVC: Removes switch with only default case
2021-01-12 bclayton@google.com ShaderModule: Refactor ParseWGSL() to take a File*
2021-01-12 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from c3c70f848a71 to 987376cd21a8 (7 revisions)

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from c3c70f848a71 to 987376cd21a8

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 dsinclair@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: dsinclair@google.com
Change-Id: I80fa578d874ead14912dbd44425084536a497f69
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353459
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-13 04:42:29 +00:00
Mike Klein
9fd75e96d7 Revert "sketch Half in skvm"
This reverts commit 9b0fc9c9c1.

Something ain't right here, so clear it all out to start fresh.

Change-Id: I22d1b4285db415ebd360c61fc5ecf890aa193e51
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353296
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2021-01-12 21:55:27 +00:00
skia-autoroll
0a69b4bb07 Roll ANGLE from 2c65da28a2ee to 5b8dec52b68f (3 revisions)
2c65da28a2..5b8dec52b6

2021-01-12 syoussefi@chromium.org Reland "Use is_apple instead of is_mac and is_ios everywhere"
2021-01-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 734de1a6b288 to 2a7e78c75a37 (67 revisions)
2021-01-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 193bb22c8c9d to 734de1a6b288 (311 revisions)

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 ethannicholas@google.com,syoussefi@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: ethannicholas@google.com,syoussefi@google.com
Change-Id: If6f5ee8ac3812c4fd09669f470cf01b4e5ebe0f3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353035
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-01-12 20:22:27 +00:00
Chris Dalton
47114db2e0 Move GrAATriangulator into its own file
Bug: skia:10419
Change-Id: Ib517c52bf2ed9e7dc9d1fa8491dd39dae99a6f77
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/350492
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2021-01-12 19:49:36 +00:00
John Stiles
f92f89bd31 Add flag to force skslc to compile one test file at a time.
Set `batchCompile = False` to compile each input file individually. This
is slower, but can be useful when attempting to pinpoint which input
file is causing a crash in skslc.

Change-Id: I464996b130c57b988c3e53ea27b2bb102d3a3980
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353098
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-01-12 19:49:00 +00:00
Chris Dalton
24472afdb6 Move various static GrTriangulator functions into structs
Bug: skia:10419
Change-Id: I43fc724de1476cbfda95b9ddd3611ec2ec547a37
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352900
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2021-01-12 19:48:57 +00:00
Brian Osman
ace3f2939f Remove SkEffectBinding feature from particle system
This is no longer used, and the current design is fairly incompatible
with skvm.

Change-Id: Ibebb9b42a0f4277c333839c3d1e9cf0f691b37cc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353079
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-01-12 19:36:27 +00:00
Jim Van Verth
73032ff974 Reland "Fix issues with MTLPixelFormatBGR10A2Unorm on older OSes."
This is a reland of e931b838d3

Original change's description:
> Fix issues with MTLPixelFormatBGR10A2Unorm on older OSes.
>
> MTLPixelFormatBGR10A2Unorm isn't supported on older MacOS or iOS
> versions, but we still want to build those. This CL adds some
> availability checks, and works around array initialization by using a
> internally defined constant.
>
> Bug: skia:11160
> Change-Id: Ife04b0a467a5e0aa27f081cabb1936c5771b5679
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352742
> Commit-Queue: Jim Van Verth <jvanverth@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

Bug: skia:11160
Change-Id: I0d39bab3edeeb50315251be68744ac71ef7c194e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353077
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2021-01-12 19:33:47 +00:00
John Stiles
4b7fdc493e Construct IntLiterals with type fIntLiteral.
Change-Id: I96a6ef80849f93bba593116fd482f69ff787de5f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353039
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-01-12 19:14:21 +00:00
Brian Osman
56ff5de8c3 Add is_apple (= is_mac || is_ios) to our GN files
Unblocks an incoming ANGLE roll

Change-Id: I7b1c69cda26cead4e9656c3da969c7b3263aaf14
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353041
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-01-12 19:10:58 +00:00
Brian Osman
fb79f9faa4 Remove all particle examples that use SkEffectBinding
I'm going to remove this feature to simplify migration to skvm.
fireworks was updated to work without it. raincloud is fairly complex,
and not that attractive, so it's just being deleted.

Change-Id: Id2d5cd490baa7bae627002f41edf7522c8bdfcd8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353076
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-01-12 19:09:18 +00:00
John Stiles
e60dcb1d74 Revert "Scrub memory released from a GrMemoryPool in debug mode."
This reverts commit c0315a72d9.

Reason for revert: breaks 
Test-Debian10-GCC-GCE-CPU-AVX2-x86-Debug-All-Docker

Original change's description:
> Scrub memory released from a GrMemoryPool in debug mode.
>
> In debug mode, we now overwrite released memory with 0xDD. This is
> intended to make use-after-free errors easier to catch while debugging.
>
> Change-Id: I04a4c5abcfef5f3f604a2430da15a8b5125239af
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352956
> Auto-Submit: John Stiles <johnstiles@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

TBR=brianosman@google.com,michaelludwig@google.com,johnstiles@google.com

Change-Id: I78096b49fcc0781b33a49fc12aa7f657f2430fed
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353097
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-01-12 18:58:29 +00:00
Florin Malita
23c93bc749 Bump SkXMLParser buffer size
Current release value is smallish (512) and debug is terribly
inefficient (5).  Bump to 4K for both release/debug builds.

(I think the small debug value was meant to artificially stress Expat
streaming, but it seems unnecessary nowadays).

Change-Id: I459afce5dde9789da84baaa68c4db9164911ffa1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/351200
Reviewed-by: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
2021-01-12 18:29:56 +00:00
Ethan Nicholas
4d2bbbba21 Changed signature of IRGenerator::convertIndex
The new signature is more amenable to being called from outside code,
in particular the DSL.

Change-Id: I4c7650b71f02471f27e348b0c44abe8511691db1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353038
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2021-01-12 18:15:56 +00:00
John Stiles
1497527c6f Improve handling of SkSL literal types.
Previously, the only way to detect a literal Type was to explicitly
check against the values fFloatLiteral/fIntLiteral or compare the name
against $floatLiteral or $intLiteral.

Now, you can call type.isLiteral() to see if the type corresponds to a
literal, or call type.scalarTypeForLiteral() to promote to the
equivalent non-literal type (fFloat/fInt). Calling
type.scalarTypeForLiteral() on a non-literal type is safe and will just
return the input type unscathed.

Change-Id: Ib939dda9bcd43b3ef4159211c5349d71fc857b95
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353037
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-01-12 17:35:56 +00:00
Jim Van Verth
5251c8275e Revert "Fix issues with MTLPixelFormatBGR10A2Unorm on older OSes."
This reverts commit e931b838d3.

Reason for revert: Failing tests on iOS bots

Original change's description:
> Fix issues with MTLPixelFormatBGR10A2Unorm on older OSes.
>
> MTLPixelFormatBGR10A2Unorm isn't supported on older MacOS or iOS
> versions, but we still want to build those. This CL adds some
> availability checks, and works around array initialization by using a
> internally defined constant.
>
> Bug: skia:11160
> Change-Id: Ife04b0a467a5e0aa27f081cabb1936c5771b5679
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352742
> Commit-Queue: Jim Van Verth <jvanverth@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

TBR=egdaniel@google.com,jvanverth@google.com

Change-Id: I3e98529c249e235b53cd4da8dea764d5b9b71ceb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:11160
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/353040
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2021-01-12 17:34:58 +00:00
Greg Daniel
c8e16bbe32 Add recycled gpu resource ref counting and use it in GrVkCommandBuffer.
Bug: skia:11136
Change-Id: I31ed877be89bfa34f1fe258d90dfe73ace8618cf
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/351198
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2021-01-12 16:32:26 +00:00
Tyler Denniston
187d8117cb [svg] Implement feGaussianBlur
This filter implementation should be complete, but note we are still
not quite passing the W3C filters-gauss-* tests because our filters
currently operate in sRGB and not linear RGB (which is quite noticable
in some of the blur tests).

Bug: skia:10841
Change-Id: I706cde879ef6eb47ce586279999536cf67237f13
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352506
Commit-Queue: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2021-01-12 16:26:16 +00:00
Jim Van Verth
e931b838d3 Fix issues with MTLPixelFormatBGR10A2Unorm on older OSes.
MTLPixelFormatBGR10A2Unorm isn't supported on older MacOS or iOS
versions, but we still want to build those. This CL adds some
availability checks, and works around array initialization by using a
internally defined constant.

Bug: skia:11160
Change-Id: Ife04b0a467a5e0aa27f081cabb1936c5771b5679
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352742
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2021-01-12 16:25:16 +00:00
Brian Salomon
0c0b5a6bb2 Remove SkYUVASizeInfo, make SkYUVAIndex a private part of SkYUVAInfo
Bug: skia:10632
Change-Id: If4dd7779b0856f6d0b441381bf7f2f51527cdb9d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352497
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-01-12 15:06:26 +00:00
Tyler Denniston
3a92f776b0 [svg] Implement onObjectBoundingBox for circle and path
Also removed an erroneous call to mapToRect() when returning bounds
for SkSVGContainer. The contexts in which we access object bounds are
always such that any transforms have already been applied.

Change-Id: Ieac488e1699d3ebff56038d6ada36737291671eb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/345117
Commit-Queue: Tyler Denniston <tdenniston@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2021-01-12 15:05:16 +00:00
Ethan Nicholas
bffe80a29d Add SkSL DSLVar
Change-Id: I1093aa6bbdb481c98ea3dab10c06bfcf323b2a75
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352058
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2021-01-12 14:36:26 +00:00
John Stiles
c0315a72d9 Scrub memory released from a GrMemoryPool in debug mode.
In debug mode, we now overwrite released memory with 0xDD. This is
intended to make use-after-free errors easier to catch while debugging.

Change-Id: I04a4c5abcfef5f3f604a2430da15a8b5125239af
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352956
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2021-01-12 14:24:21 +00:00
Brian Salomon
b0d2b09200 Revert "asyncRescaleAndRead supports unpremul results on GPU"
This reverts commit 70fa84a9bf.

Reason for revert: Guessing this is causing the Chrome roll failures.

Original change's description:
> asyncRescaleAndRead supports unpremul results on GPU
>
> GrSurfaceContext::rescale uses GrSurfaceFillContext instead of
> GrSurfaceDrawContext.
> Change-Id: I9c2d647d8f221c129ec4485a4ed936202aee6362
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/351923
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

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

Change-Id: Ia70a49d7789a5c4be7135e827c49a8c42aa49114
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352957
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2021-01-12 14:21:17 +00:00
John Stiles
b30151eb73 Add a reference to the ErrorReporter to the SkSL Context.
This will allow errors to be reported outside of the IRGenerator more
easily (without passing around an ErrorReporter object).

Change-Id: I4bcb59fcd526599fa593fcb3b1de0a5ae64ab901
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352737
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
2021-01-12 14:19:16 +00:00
Brian Osman
c92df39de0 Convert interpreter "compound types" test to SkVM
This is the first test that used uniform data, so fix up how uniforms
work in the generic SkSL-to-SkVM function.

Bug: skia:11094
Bug: skia:11096
Change-Id: Ie391c1a6b8b68f0f4f014d7e767d7b5101341fab
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352739
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2021-01-12 13:58:46 +00:00
skia-autoroll
a55af2311a Roll Chromium from 9da1d76d9cd4 to b9b9a8a5022a (443 revisions)
9da1d76d9c..b9b9a8a502

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 ethannicholas@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: ethannicholas@google.com
Change-Id: I3709e95da9e09611dce4271e9c8fbe9d417ec98f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352903
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-12 05:30:25 +00:00
skia-autoroll
f301535cc2 Roll ANGLE from 0b90eef09f60 to 2c65da28a2ee (13 revisions)
0b90eef09f..2c65da28a2

2021-01-12 natsu@google.com Default roll_aosp.sh to copy artifacts to vendor partition
2021-01-12 jmadill@chromium.org Vulkan: Use angle::FormatID instead of VkFormat.
2021-01-11 stha09@googlemail.com libstdc++: fix incomplete type for FramebufferCache
2021-01-11 vantablack@google.com Reland "Created test and fixed texture storage bug in d3d11"
2021-01-11 lfy@google.com Vulkan: Prefer host cached memory for Buffers
2021-01-11 ynovikov@chromium.org Fix iOS build
2021-01-11 ynovikov@chromium.org Enable building angle_white_box_tests on Fuchsia
2021-01-11 ianelliott@google.com dEQP: Avoid undefined right-shift behavior for GLhalf
2021-01-11 jmadill@chromium.org Remove obsolete build flag.
2021-01-11 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 29d2d6a2d436 to 193bb22c8c9d (106 revisions)
2021-01-11 angle-autoroll@skia-public.iam.gserviceaccount.com Roll vulkan-deps from e395b66ed41c to e59ae1af7571 (5 revisions)
2021-01-11 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 937395c1ed5d to 348ba200aa29 (6 revisions)
2021-01-11 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Chromium from 28ecef438c2c to 29d2d6a2d436 (82 revisions)

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 ethannicholas@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: ethannicholas@google.com
Test: Test:Test: Test: ./scripts/roll_aosp.sh and build in AOSP
Change-Id: I3545c6d63c3b78ff24e659546d37faf09e3fe6ed
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352906
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-12 04:50:06 +00:00
skia-autoroll
a314baaa05 Roll SwiftShader from 348ba200aa29 to 3549479dc4cc (3 revisions)
https://swiftshader.googlesource.com/SwiftShader.git/+log/348ba200aa29..3549479dc4cc

2021-01-11 srisser@google.com Define static constexpr members in .cpp files
2021-01-11 srisser@google.com Add VK_EXT_host_query_reset
2021-01-11 srisser@google.com Implement VK_EXT_separate_stencil_usage

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 ethannicholas@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: None
Tbr: ethannicholas@google.com
Change-Id: I2242457875b9d6ad1b9bca86b64be990d57f1f56
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352904
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-12 04:49:16 +00:00
skia-autoroll
a4bd6ae596 Roll Dawn from 3a0405597374 to 9ff83f6c957f (8 revisions)
https://dawn.googlesource.com/dawn.git/+log/3a0405597374..9ff83f6c957f

2021-01-12 hao.x.li@intel.com Query API: Non-precise occlusion query on D3D12
2021-01-11 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from f51d965befa1 to c3c70f848a71 (22 revisions)
2021-01-11 cwoffenden@gmail.com Minor fix to build with MSVC: Gets content address instead of iterator
2021-01-11 cwallez@chromium.org Remove obsolete build flag.
2021-01-11 yunchao.he@intel.com Add more constants for max texture sizes
2021-01-11 senorblanco@chromium.org Add ANGLE to Dawn build.
2021-01-11 dawn-autoroll@skia-public.iam.gserviceaccount.com Roll Tint from 9bacbe1b34a3 to f51d965befa1 (1 revision)
2021-01-11 stha09@googlemail.com IWYU: add missing include for size_t

Also rolling transitive DEPS:
  https://dawn.googlesource.com/tint from 9bacbe1b34a3 to c3c70f848a71

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 dsinclair@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: dsinclair@google.com
Change-Id: I5adc7a42075bbedd2d71632ebf30ccba6cea680b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/352905
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2021-01-12 04:43:56 +00:00
Chris Dalton
93c2d81f19 Move the outer mesh into a member of GrAATriangulator
Bug: skia:10419
Change-Id: I547e7c63b9d7ad9abeb6377f4a31d6d671bb5030
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/350482
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2021-01-12 03:48:35 +00:00
Chris Dalton
7cf3addb1b Extract a GrAATriangulator class
Bug: skia:10419
Change-Id: I0394697fdc292cabeb81da508e1acdc74e2127ff
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/350257
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2021-01-12 02:31:05 +00:00