Commit Graph

50533 Commits

Author SHA1 Message Date
skia-autoroll
6f0d302d33 Roll dawn from eff9ef0f2212 to e8dc820fbc1e (6 revisions)
https://dawn.googlesource.com/dawn.git/+log/eff9ef0f2212..e8dc820fbc1e

2020-08-21 enga@chromium.org Skip TextureSubresourceTest.MipmapLevelsTest on Vulkan w/ validation
2020-08-20 bryan.bernhart@intel.com D3D12: check if resource manager exists before releasing
2020-08-20 jiawei.shao@intel.com Workaround Intel Mesa driver issue about T2B copy with stencil aspects
2020-08-20 cwallez@chromium.org Remove MapRead/WriteAsync and CreateBufferMapped
2020-08-20 tommek@google.com Refactoring Queue::WriteTexture implementation
2020-08-20 tommek@google.com Fixing offset alignments when using DynamicUploader

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: Id34411804e883c22a2b59b0b9b8c035eff02760a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312421
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-21 04:30:39 +00:00
John Stiles
b9af723001 Fix thread-unsafe writes to function declarations in the symbol table.
This changes the semantics *slightly* as `fIsBuiltinCode` is used
to identify functions which are assumed to not have side effects.
Previously the heuristic for side-effects was the presence of a function
body. In practical terms this does not seem to affect any results. (I
also tried other approaches which all subtly altered the results of
codegen/inlining.)

Change-Id: I9fea820968a60360fb622dfa70aa8876a1782e6a
Bug: skia:10589
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312336
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-08-20 20:47:12 +00:00
Ethan Nicholas
7018bcfbc9 Reland "SkSL now supports uniform array types"
This is a reland of 284f2c4bea

Original change's description:
> SkSL now supports uniform array types
> 
> Change-Id: I809e9c424ee92b05f0a87d75d1384c92849e1474
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308498
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>

Change-Id: I176f7fbdcbf3700e51e2303b06a4e906d22b2300
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312244
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2020-08-20 20:39:12 +00:00
Heather Miller
481ff13d15 add M86 branch release notes
Bug: skia:
Change-Id: I62331cab6cfadbaf9ab2f74e316cb7a2515249d0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312305
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Heather Miller <hcm@google.com>
2020-08-20 20:38:02 +00:00
Florin Malita
3f45e4b322 [skottie] Custom prop manager updates
Currently we use a hard-coded name prefix ('$') and the properties are
"namespaced" (the tree hierarchy is part of the key name).

This doesn't work well for most clients looking to test property
manipulation, as they would rather handle similarly named props in
bulk.

E.g. instead of

  precomp1.layer1.Group1.COLOR_01
  precomp1.layer1.Group1.COLOR_02
  precomp1.layer2.Group1.COLOR_01
  precomp1.layer2.Group2.COLOR_02

the UI should simply present

  COLOR_01
  COLOR_02

To support this, introduce a new operation mode for
CustomPropertyManager (kCollapseProperties), and keep the old behavior
around as kNamespacedProperties.

Also drop filtering for markers as anyone interested in markers would
want to see all of them.

Plumb these options all the way into CK (to be added to the player
later).

Change-Id: I57ec78c669f3870939d48fbfc492b97f63ea600d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312301
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
2020-08-20 19:59:22 +00:00
Julia Lavrova
d279cee2f2 Fixing incorrect boundaries calculations + 3 ways of drawing a paragraph
Bug: skia:10620
Change-Id: I70086013130b23435d4e7c5ba375731760deb174
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311447
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-08-20 18:47:42 +00:00
Ethan Nicholas
6e0fa409e6 replaced SkSL nodeCount with visitor
Change-Id: I2c58505be6e9005804a11fbeabe35df52b64714d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312241
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2020-08-20 18:43:02 +00:00
Nathaniel Nifong
642a10b1f2 Add origin visualization, add support for Concat44
bug:skia:10211

Change-Id: Ia1a6da784096c1e655ec6198206de879ffbb556b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311605
Commit-Queue: Nathaniel Nifong <nifong@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2020-08-20 17:49:32 +00:00
Ethan Nicholas
2a479a53b5 Reland "SkSL CPP and H backends no longer emitted in non-dev builds"
This is a reland of bc6fb279fe

Original change's description:
> SkSL CPP and H backends no longer emitted in non-dev builds
> 
> As these backends are never used at runtime, it's pointless to include
> them in the Skia binaries. We still include them in GR_TEST_UTILS mode
> to support unit tests.
> 
> Change-Id: I9ec9cc9300b74c501985656323ec894008255a70
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311454
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

Change-Id: I214d6d952befbe77f301cf252fe4795f8c411a76
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312242
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2020-08-20 17:48:32 +00:00
John Stiles
403a363c2e Migrate additional casts to as<T>.
These changes shook out a few const-correctness issues and make me
wonder about constness within the symbol table. Please check the
review notes!

Change-Id: Ic204a7b639caab08b9de92fe8d1d029b0ffb6582
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312082
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-08-20 17:42:32 +00:00
Kevin Lubick
2eabdf5b07 Remove webgl from public.bzl
A bit speculative. Not sure if this will break the
WASM build in Google3, but the goal is to fix the G3
roller.

Change-Id: I0936e12291861943c58c147c98a43d11f60c6d72
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312239
Reviewed-by: Nathaniel Nifong <nifong@google.com>
Reviewed-by: Stan Iliev <stani@google.com>
2020-08-20 17:40:54 +00:00
Chris Dalton
71e2126a83 Add new tests to trickycubicstrokes
Adds cusps and flat beziers with 180 degree turns that confuse the
new tessellator.

Bug: skia:10419
Change-Id: I2529780da596fe365c1d2825e29145beedf5cb01
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312118
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2020-08-20 16:36:02 +00:00
John Stiles
29f2a1eaca Remove sk_TextureSamplers from SkSL.
These were not used anywhere.

Change-Id: I42e2cc96a1a1fae7db5fd41c8a1e60d41b284988
Bug: skia:10629
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312236
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-08-20 16:19:42 +00:00
Ben Wagner
9742f7c111 Notify when SkFontMetrics bounds are bogus.
OpenType and many other font formats have the concept of pre-computed
metrics for the union of all glyph bounding boxes. This allows for fast
though course quick rejecting of bounds, since the glyphs themselves may
potentially be quite a bit larger than the EM. With the introduction of
variable fonts OpenType does not vary these bounds, so the bounds are
only valid for the default non-varied font.

As a result the fTop, fBottom, fXMax, and fXMin reported in
SkFontMetrics may be bogus. Since simply always setting them to empty
zeros may be disruptive, provide a way forward for new users to check if
the bounds are valid.

This is a continuation which implements this in the DirectWrite and
CoreText ports.

Change-Id: I50812e78f31ee06fedf8ab1f005837d673a8f2ad
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311976
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2020-08-20 15:22:32 +00:00
Kevin Lubick
2f9a098439 [canvaskit] Remove getproc when creating WebGL interface
This saves about 15kb of wasm code size (4kb gzipped), 11kb
of JS code size (2kb gzipped) and about 10ms
when creating a new surface (~35ms -> 25ms in a local test).

This also gates the webgl code more strongly (off unless you
really request it), since the headers won't be available
except in an emscripten environment.

Change-Id: I303f6c342c72e7cfe29be241f55ae8f5631a3f75
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311916
Reviewed-by: Brian Salomon <bsalomon@google.com>
2020-08-20 14:55:50 +00:00
Kevin Lubick
204c3be1cd [canvaskit] Remove fringe EGL dependency.
This removes about 5 kb of wasm code size (2 kb gzipped),
20 kb of js code size (4kb gzipped).
I think I can remove getproc (which is a somewhat large
function made up of a lot of string data) with some clever
adjustments of macros in a follow-on CL.

Change-Id: If3a4b30681e13abddea8e84d62297e90316ed7cf
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311817
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2020-08-20 14:55:50 +00:00
Kevin Lubick
157577b866 [canvaskit,pathkit] Update to emsdk 2.0
There was a break that was solved by adding -lGL to our link
steps. I discovered a few extra flags to aid in debugging builds
and I've left those in (they aren't too noisy IMO).

This changes the base dockerfile to use the official emscripten one.

Code size delta for full build is +5 kb

For future reference, emsdk decides which "library JS" files to
pull in using a83ba99d60/tools/building.py (L1553)
Those JS files live in src (e.g. a83ba99d60/src/library_html5_webgl.js (L222))
and define functions that the C++ code can call.

I'd like to follow-up on what -lEGL is doing.

Also, since the new image no longer has depot_tools, we need
to make docker/skia-wasm-release/Dockerfile install it.

Change-Id: I5a38e61e5080e9c4cb1e0a7e031509bcb107ff86
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311726
Reviewed-by: Nathaniel Nifong <nifong@google.com>
2020-08-20 14:55:50 +00:00
Nikolay Igotti
7e9b563179 Search ICU data on Windows relative to the current module.
Bug: n/a
Change-Id: If2fc09f6fc0a24915b4938c62451c693a9712586
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311136
Commit-Queue: Derek Sollenberger <djsollen@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Reviewed-by: Heather Miller <hcm@google.com>
Reviewed-by: Jim Sproch <jsproch@google.com>
2020-08-20 14:51:42 +00:00
John Stiles
3dc0da6c6d Add as<ProgramElementSubclass> to downcast ProgramElements more safely.
The as<T>() function asserts that the ProgramElement is of the correct
kind before performing the downcast, and is also generally easier to
read as function calls flow naturally from left-to-right, and C-style
casts don't.

This CL updates several downcasts throughout SkSL to the as<T>
syntax, but is not intended to exhaustively replace them all (although
that would be ideal). In places where we SkASSERTed the element's
fKind immediately before a cast, the assert has been removed because it
would be redundant with the behavior of as<T>().

Change-Id: I89a487aeaf56e56c720479fee0c2633377a202f1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312020
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-08-20 13:48:52 +00:00
Ethan Nicholas
f3c8f5df31 Reland "Added support for the 'inline' hint on SkSL functions"
This reverts commit 1394f71ff0.

Reason for revert: doesn't seem to have been the culprit

Original change's description:
> Revert "Added support for the 'inline' hint on SkSL functions"
> 
> This reverts commit 338e57d4b1.
> 
> Reason for revert: maybe breaking Chrome roll
> 
> Original change's description:
> > Added support for the 'inline' hint on SkSL functions
> > 
> > Change-Id: Ib78e0ad9fd1cc15e7afeb2a9ddd6b1249828fbe7
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311603
> > Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
> > Reviewed-by: John Stiles <johnstiles@google.com>
> 
> TBR=brianosman@google.com,ethannicholas@google.com,johnstiles@google.com
> 
> Change-Id: Ifd199db94a78e4cb389576b9ff282f54a582c421
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312078
> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

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

# Not skipping CQ checks because this is a reland.

Change-Id: I241f6bf16602bb5e011a2a5879a2df515fa0953b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312097
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2020-08-20 13:42:02 +00:00
Heather Miller
2f2658506c Update Skia milestone to 87
Change-Id: Ic755236e56a0b8064c5539c0a483fffbd4d9f334
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312156
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Heather Miller <hcm@google.com>
2020-08-20 12:50:02 +00:00
Mike Reed
4aac2f95c6 Can we remove this flag to picture-recording?
Change-Id: I08b75bee4d86b8539ee4374c699a3a1003b67784
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311725
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2020-08-20 12:29:42 +00:00
skia-autoroll
e1e2408042 Roll Chromium from ff3c275665f9 to e45f0c4dce5a (503 revisions)
ff3c275665..e45f0c4dce

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 stani@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: stani@google.com
Change-Id: Ia1d214df545521311ca0b34a0305bc61bc199d1d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312132
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-20 06:01:08 +00:00
skia-autoroll
aa79155984 Roll dawn from b54c82ed3948 to eff9ef0f2212 (2 revisions)
https://dawn.googlesource.com/dawn.git/+log/b54c82ed3948..eff9ef0f2212

2020-08-20 hao.x.li@intel.com Query API: QuerySet on Vulkan
2020-08-19 cwallez@chromium.org Add wgpu::TextureFormat::RGB9E5Ufloat

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: Ic131d5c8693af5c717c4a0f926dae5036a970451
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312130
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-20 05:56:04 +00:00
skia-autoroll
91eda460cd Roll ANGLE from 699bcde0b729 to 5dff6075d29f (19 revisions)
699bcde0b7..5dff6075d2

2020-08-20 ynovikov@chromium.org Roll chromium_revision c8c2c64629..84714fcf81 (796654:799900)
2020-08-20 jmadill@chromium.org Re-land "Feedback Loop Redesign 2/3: Track bound FBOs in Texture."
2020-08-20 sugoi@google.com Silence Control Flow Integrity (cfi) errors
2020-08-20 ynovikov@chromium.org Fix manual roll mode of roll_chromium_deps.py
2020-08-20 ynovikov@chromium.org Fix manual, disable automatic rolling of googletest and jsoncpp
2020-08-19 khushalsagar@chromium.org Revert "Feedback Loop Redesign 2/3: Track bound FBOs in Texture."
2020-08-19 ynovikov@chromium.org Adjust roll_chromium_deps.py to work with autoroller.
2020-08-19 jonahr@google.com Fix language inclusivity for SurfaceMtl.mm
2020-08-19 reveman@google.com Vulkan: Enable VK_KHR_bind_memory2 extension
2020-08-19 jonahr@google.com Fix typo in test harness README
2020-08-19 lehoangq@gmail.com Metal: autogen for EXT_draw_buffers & ANGLE_framebuffer_blit
2020-08-19 amy.liu@arm.com Delete extra initialization in spirv shader.
2020-08-19 jmadill@chromium.org Vulkan: Check aggregate barrier feature instead of caching.
2020-08-19 jmadill@chromium.org Vulkan: Name image layouts.
2020-08-19 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-Tools from 1590d46aaaeb to eceb318c06a2 (1 revision)
2020-08-19 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from 6f74415e2f74 to cbfd396756c6 (1 revision)
2020-08-19 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-ValidationLayers from 9d431ae2eeb4 to c97acd1d3e07 (1 revision)
2020-08-19 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SPIRV-Tools from e28436f2b8a2 to 3434cb0b006d (2 revisions)
2020-08-19 jmadill@chromium.org Vulkan: Track RP's read/write access for depth/stencil.

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 stani@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
Bug: chromium:1116053
Tbr: stani@google.com
Change-Id: Idbdbe302888a98cec249abbe48a8113f8d4a41b3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312131
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-20 05:56:03 +00:00
Mike Klein
dc594f21c0 Revert "Add utilities to SkGeometry for quad and cubic rotation angles"
This reverts commit 26766ad427.

Reason for revert: Pixel & Nexus 5 failing with

Failures:
	../../../../../../skia/tests/GeometryTest.cpp:424	 [Geometry]: SkScalarNearlyEqual(leftRotation, expectedChoppedRotation)
	../../../../../../skia/tests/GeometryTest.cpp:424	 [Geometry]: SkScalarNearlyEqual(leftRotation, expectedChoppedRotation)


Original change's description:
> Add utilities to SkGeometry for quad and cubic rotation angles
> 
> Adds methods to measure the rotation angles of quadratics and cubics,
> and to chop curves at locations that divide the rotation angle in half.
> 
> Bug: skia:10419
> Change-Id: I840e12034fc66e1a459de875fefda07a27a78335
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308880
> Reviewed-by: Jim Van Verth <jvanverth@google.com>
> Commit-Queue: Chris Dalton <csmartdalton@google.com>

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

Change-Id: Ic3d5c1ae35b74aa340757e92132bb2c1b8910cc6
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10419
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312119
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-20 01:46:24 +00:00
Mike Klein
853d4ed2ff Revert "remove sksl interpreter guards"
This reverts commit 7f1117e886.

Reason for revert: Seems like Clang gets stuck allocating registers on ARM,

[2477/38027] CXX obj/skia/skia/SkSLByteCode.o
FAILED: obj/skia/skia/SkSLByteCode.o
/b/s/w/ir/cache/goma/client/gomacc ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF...(too long)
fatal error: error in backend: Error while trying to spill LR from class GPR: Cannot scavenge register without an emergency spill slot!
PLEASE submit a bug report to https://crbug.com and run tools/clang/scripts/process_crashreports.py (only works inside Google) which will upload a report and include the crash backtrace, preprocessed source, and associated run script.
Stack dump:
0.	Program arguments: ../../third_party/llvm-build/Release+Asserts/bin/clang++ -MMD -MF obj/skia/ski...(too long)


Original change's description:
> remove sksl interpreter guards
> 
> This is only used by particles, benchmarks, and tests,
> and should be swept away by dead code elimination otherwise.
> 
> Change-Id: I10462d6ae0a08dd8219fc49325160ec6790632af
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311759
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

TBR=mtklein@google.com,brianosman@google.com

Change-Id: I1b6370d39285210267425f090235a4d80aebe4fa
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312034
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-20 00:41:15 +00:00
Ethan Nicholas
1394f71ff0 Revert "Added support for the 'inline' hint on SkSL functions"
This reverts commit 338e57d4b1.

Reason for revert: maybe breaking Chrome roll

Original change's description:
> Added support for the 'inline' hint on SkSL functions
> 
> Change-Id: Ib78e0ad9fd1cc15e7afeb2a9ddd6b1249828fbe7
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311603
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>

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

Change-Id: Ifd199db94a78e4cb389576b9ff282f54a582c421
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312078
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2020-08-20 00:13:17 +00:00
Ethan Nicholas
4fb12cfeda Revert "SkSL CPP and H backends no longer emitted in non-dev builds"
This reverts commit bc6fb279fe.

Reason for revert: maybe breaking Chrome roll

Original change's description:
> SkSL CPP and H backends no longer emitted in non-dev builds
> 
> As these backends are never used at runtime, it's pointless to include
> them in the Skia binaries. We still include them in GR_TEST_UTILS mode
> to support unit tests.
> 
> Change-Id: I9ec9cc9300b74c501985656323ec894008255a70
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311454
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

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

Change-Id: Ic3d871e2b17a41d3f5902674d1233517ad358f45
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312079
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2020-08-20 00:08:45 +00:00
Ethan Nicholas
95b24b9a9d Revert "SkSL now supports uniform array types"
This reverts commit 284f2c4bea.

Reason for revert: leak is angering ASAN

Original change's description:
> SkSL now supports uniform array types
> 
> Change-Id: I809e9c424ee92b05f0a87d75d1384c92849e1474
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308498
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>

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

Change-Id: I614f2f5cbe8bba7fc8678143fe059c7b69866254
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/312077
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
2020-08-20 00:08:14 +00:00
Chris Dalton
6b3c2f653b Move GrWangsFormula::nextlog2 to sk_float_nextlog2
Other code outside this namespace will want to use this method soon.

Bug: skia:10419
Change-Id: Ib155f224866fd333b8f9a4b78e6c9e51ac0600df
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311936
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2020-08-19 23:45:12 +00:00
John Stiles
da8588879b Remove final vestiges of sk_InColor.
Change-Id: Ic10676b76ec2ea93a280626a89ec8dadd7225bd6
Bug: skia:10619
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311996
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-08-19 22:12:22 +00:00
Ethan Nicholas
284f2c4bea SkSL now supports uniform array types
Change-Id: I809e9c424ee92b05f0a87d75d1384c92849e1474
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308498
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2020-08-19 21:50:56 +00:00
Chris Dalton
26766ad427 Add utilities to SkGeometry for quad and cubic rotation angles
Adds methods to measure the rotation angles of quadratics and cubics,
and to chop curves at locations that divide the rotation angle in half.

Bug: skia:10419
Change-Id: I840e12034fc66e1a459de875fefda07a27a78335
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/308880
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2020-08-19 21:39:44 +00:00
Mike Klein
f647dc752d update placeholder approx op count
Now that approxOpCount() can recurse into sub pictures,
adding ~0 will overflow its total count.

New tests fail at head, pass now.

Change-Id: Icdb7d8a062739724207c9a6369734510f00f2ffd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311774
Reviewed-by: John Stiles <johnstiles@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-19 21:33:54 +00:00
John Stiles
1f02286ea6 Remove sk_InColor from unit tests.
It's been replaced with a `uniform half4` in tests where it was needed,
which tends to generate similar code overall.

Change-Id: Iacc062efaeae37ebecf78505abe0fc563b69ceb0
Bug: skia:10619
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311099
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>
2020-08-19 21:26:54 +00:00
Adlai Holler
ed1bf120d9 Remove GrContext variant of SkImageGenerator::isValid
This method isn't used by anyone, and I needed to land SOMETHING
in the middle of banging my head against CL 310656 :-)

Bug: skia:104662
Change-Id: Iaf529ac7551b22213891eb4be78d7904938aa989
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311816
Auto-Submit: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2020-08-19 19:47:14 +00:00
John Stiles
9d944236e8 Fix simplification of switch statements with casts.
The original code assumed that the switch value and case value would
both be IntLiterals, and asserted if this were not true. However, in
sufficiently complicated cases, the switch value can sometimes be a
Constructor containing a scalar.

It's possible that there's a fix to constant propagation which would
flatten out this Constructor to just a scalar, but that has eluded me
for today, and this approach does seem to solve the issue. (Also, it's
surprising that the optimizer does not notice that it can simplify
`half4(1.0, 2.0, 3.0, 4.0).yyyy`.)

Change-Id: Id490b15c724dd174c448665a19242cc80cdce213
Bug: skia:10623
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311636
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-08-19 18:43:27 +00:00
Mike Reed
18305c3d36 pass 'nested' bool to approximateOpCount
Change-Id: I5b1baf2bc3aafa03c1d0cace4f7c09a09cf4a084
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311112
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2020-08-19 16:45:53 +00:00
Mike Klein
1a5b9b0628 clean up SK_LATE_DITHER
Change-Id: I2da0889ee34bf82a7ee0529cdff5107bb81c7d28
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311758
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-19 16:44:22 +00:00
Ethan Nicholas
338e57d4b1 Added support for the 'inline' hint on SkSL functions
Change-Id: Ib78e0ad9fd1cc15e7afeb2a9ddd6b1249828fbe7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311603
Commit-Queue: Ethan Nicholas <ethannicholas@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
2020-08-19 15:47:09 +00:00
Mike Klein
7f1117e886 remove sksl interpreter guards
This is only used by particles, benchmarks, and tests,
and should be swept away by dead code elimination otherwise.

Change-Id: I10462d6ae0a08dd8219fc49325160ec6790632af
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311759
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-19 14:44:09 +00:00
John Stiles
17c5b70242 Add as<SymbolSubclass> to downcast Symbols more safely.
The as<T>() function asserts that the Symbol is of the correct kind
before performing the downcast, and is also generally easier to read
as function calls flow naturally from left-to-right, and C-style casts
don't.

This CL updates several Symbol downcasts in SkSL to the as<T>
syntax, but is not intended to exhaustively replace them all (although
that would be ideal). In places where we SkASSERTed the expression's
fKind immediately before a cast, the assert has been removed because it
would be redundant with the behavior of as<T>().

Change-Id: I33cb2b9657dc410241dbc96be85c4ce182a1b391
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311436
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>
2020-08-19 14:21:40 +00:00
Ethan Nicholas
bc6fb279fe SkSL CPP and H backends no longer emitted in non-dev builds
As these backends are never used at runtime, it's pointless to include
them in the Skia binaries. We still include them in GR_TEST_UTILS mode
to support unit tests.

Change-Id: I9ec9cc9300b74c501985656323ec894008255a70
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311454
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2020-08-19 14:12:49 +00:00
Mike Klein
4a56f4c29e densify dump_record
I don't know why the meat is in a separate file.

Change-Id: I9bbc475d1644dd1d596cb7c98ae0e0292846e5d5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311585
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-08-19 13:35:09 +00:00
skia-autoroll
356838b9f8 Roll Chromium from 06c431ffe930 to ff3c275665f9 (515 revisions)
06c431ffe9..ff3c275665

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 stani@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: stani@google.com
Change-Id: Icd13238c7103cd1b5acc8c4ed2f1e90bc9cf0474
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311589
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-19 04:48:30 +00:00
skia-autoroll
da057238a2 Roll ANGLE from dceaabb18162 to 699bcde0b729 (17 revisions)
dceaabb181..699bcde0b7

2020-08-19 jmadill@chromium.org Feedback Loop Redesign 2/3: Track bound FBOs in Texture.
2020-08-19 jmadill@chromium.org Vulkan: Add overlay widget for RP buffer count.
2020-08-18 jmadill@chromium.org Feedback Loop Redesign 1/3: Framebuffer Serials.
2020-08-18 lehoangq@gmail.com Metal: autogen format caps from json
2020-08-18 jmadill@chromium.org Vulkan: Add DS ReadOnly mode to Framebuffer/RP caches.
2020-08-18 lehoangq@gmail.com Metal: Fix missing image view for texture from IOSurface.
2020-08-18 jmadill@chromium.org Auto-gen more Overlay code.
2020-08-18 jmadill@chromium.org Clean up Overlay code duplication.
2020-08-18 jmadill@chromium.org Vulkan: Clean up ImageLayout enum.
2020-08-18 cnorthrop@google.com Tests: Add COD:Mobile trace
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-Headers from 99638d8d7fc6 to 834673eaa34a (1 revision)
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll glslang from 758b30727efc to f257e0ea6b9a (2 revisions)
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SPIRV-Tools from b8de4f57e983 to e28436f2b8a2 (3 revisions)
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-Loader from 527e67e9d933 to 30b3f3857835 (13 revisions)
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-ValidationLayers from c1db3b8e7960 to 9d431ae2eeb4 (1 revision)
2020-08-18 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SwiftShader from abe07b943855 to 6f74415e2f74 (2 revisions)
2020-08-18 jmadill@chromium.org Vulkan: Clean up handleDirtyTexturesImpl.

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 stani@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
Bug: None
Tbr: stani@google.com
Test: Test: angle_perftests --gtest_filter=TracePerfTest.Run/*cod_mobile*
Change-Id: I9937cf6f9f6b6bd816e3fca6f5bdb4d83ef78a98
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311696
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-19 04:47:10 +00:00
skia-autoroll
b941277395 Roll SwiftShader from 6f74415e2f74 to cbfd396756c6 (1 revision)
https://swiftshader.googlesource.com/SwiftShader.git/+log/6f74415e2f74..cbfd396756c6

2020-08-18 sugoi@google.com Control Flow Integrity (cfi) fix

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 stani@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: stani@google.com
Change-Id: I99720f0048311d6a53b4db686b82cb1e4afb10be
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311588
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-19 04:33:39 +00:00
skia-autoroll
6004bcb3bd Roll dawn from d95180deded1 to b54c82ed3948 (4 revisions)
https://dawn.googlesource.com/dawn.git/+log/d95180deded1..b54c82ed3948

2020-08-18 enga@chromium.org Support depth-only/stencil-only COPY_SRC on OpenGL
2020-08-18 cwallez@chromium.org Metal: Remove usage of MTLTextureUsagePixelFormatView
2020-08-18 dpranke@google.com Fix visibility rules for configs enforced by latest GN.
2020-08-18 cwallez@chromium.org OpenGL: Unconditionally set glFrontFace

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: I0a922c8a0762fd8be730f1c3672371385be175d7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311656
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-08-19 04:29:09 +00:00
Ben Wagner
81eabce6a3 SkCustomTypefaceBuilder to set SkFontStyle
Allow the user of SkCustomTypefaceBuilder to set the SkFontStyle of the
resulting SkTypeface. This allows users to build font families.

Fix the Font_flatten test to actually work (instead of relying on the
magic behavior of nullptr for SkTypeface), add a test with the custom
typeface, and reduce the number of times the inner loop runs from
302,400 times to 4,032 times so that the test finishes in a reasonable
amount of time.

Bug: skia:10630
Change-Id: I0b5e939552ee4a9a1249eefbb7a7279a59b38e5a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/311596
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Xiao Yu <xster@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2020-08-19 00:09:55 +00:00