Commit Graph

46761 Commits

Author SHA1 Message Date
Robert Phillips
a865a3aedb Improve DDLTileHelper
TileData now gets a pointer to the final surface
   This allows the tile to, once rendered, compose itself into
   the final surface

DDLTileHelper now stores the TileData in a dumb array
   SkTArray is overkill and, since TileData*s are being doled
   out to threads, we never want reallocation

Added DDLTileHelper::kickOffThreadedWork
   The old code only performed DDL creation in parallel. This
   entry point also replays the DDLs and composes them into the
   final surface in parallel

Change-Id: I66e02ef7f8291b4d402e22bee0ad3546e930609e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270796
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2020-02-14 18:48:50 +00:00
Mike Reed
528998dfd5 Fix impl for OverdrawColorFilter to not rely on details of pmcolor,
esp. during serialization. We now store/serialize SkColor, which is
stable.

Change-Id: Ib453920a9a06647f44b33c9ae8af33936d6ead33
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270997
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2020-02-14 18:38:18 +00:00
Brian Salomon
b3779f53f5 Remove GrTextureEffect::MakeTexelSubset.
Originally there was a distinction WRT half pixel insetting, but as I
learned more about what the call sites expected the distinction was
erased. Callers with a SkIRect can just convert to SkRect.

Change-Id: Ib1e117baffdb532ba09a668da7f851d02c2c5206
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270941
Commit-Queue: Brian Salomon <bsalomon@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2020-02-14 18:32:05 +00:00
Greg Daniel
3a36511f21 Remove origin from GrSurfaceProxy.
Bug: skia:9556
Change-Id: Ic95a3a6b11e1ff8a6f6b2f5c5aeb9037b72aae90
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270840
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2020-02-14 16:52:58 +00:00
skia-autoroll
20228946c9 Roll third_party/externals/swiftshader ac4e1d236088..f9f999f5a2eb (6 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/ac4e1d236088..f9f999f5a2eb

git log ac4e1d236088..f9f999f5a2eb --date=short --first-parent --format='%ad %ae %s'
2020-02-13 jonahr@google.com Implement HostMappedForeignMemory DeviceMemory
2020-02-13 bclayton@google.com Update Marl to a047dd0bb
2020-02-13 bclayton@google.com third_party/marl: Add mips64 support to BUILD.gn
2020-02-13 swiftshader.regress@gmail.com Regres: Update test lists @ ac4e1d23
2020-02-13 amaiorano@google.com Kokoro: build and run rr::Print unit tests
2020-02-13 amaiorano@google.com Fix rr::Print and add unit tests

Created with:
  gclient setdep -r third_party/externals/swiftshader@f9f999f5a2eb

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/+/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
Tbr: stani@google.com
Change-Id: Ibb24607d60d723135d283483abb23c427391d969
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270904
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-14 16:20:58 +00:00
Brian Salomon
64f4206fe9 Remove unique_ptr_address_as_pointer_address
std::unique_ptr is not always the same size as a pointer (shame! shame!).
AFAICT I added this terrible hack just to be able to make GrProcessorSet
store unique_ptrs of const GrFP rather than non-const FP, which is in no
way important.

Bug: skia:9908

Change-Id: I6e7eb0c0a7ad3473489e549909fa0b0a9eeec49b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270938
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2020-02-14 16:09:28 +00:00
Ben Wagner
06265e017f [presubmit] Use bin/gn rather than depot_tools gn
Change-Id: I649f07e036f184e6dbb3a335bdd979dedea27ec8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270876
Commit-Queue: Eric Boren <borenet@google.com>
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
2020-02-14 15:51:38 +00:00
Ben Wagner
f88dabbb4d [infra] Move Swiftshader to MEDIUM GCE machines
Change-Id: I9d9c1ee0aacba8598869fb702436a7c6bf668323
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270838
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Ben Wagner aka dogben <benjaminwagner@google.com>
2020-02-14 15:48:30 +00:00
Robert Phillips
3c1efd4909 Carve some helper functions off of GPUSink (take 2)
I'm adding a new DDL Sink and would like to reuse this functionality.

TBR=egdaniel@google.com
Change-Id: I17ae929557400be4edd8df78ab6580872024bc15
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270799
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2020-02-14 13:55:18 +00:00
Brian Salomon
f46f19b98c Add support for implementing ShaderMode::kRepeat with MIPs in GrTextureEffect.
Change-Id: I12ea00b35967f13e81410c584e34b62eea6c2ffe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270445
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2020-02-14 13:52:27 +00:00
skia-recreate-skps
ddad4c60ae Update Go Deps
Change-Id: I9e07b2ac6cb5e493bf725bcc612383a94f87d5b2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270907
Reviewed-by: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Commit-Queue: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2020-02-14 05:25:57 +00:00
skia-autoroll
9b65d44dcc Roll third_party/externals/angle2 74ab0bffb526..d5861a68d9f7 (9 commits)
74ab0bffb5..d5861a68d9

git log 74ab0bffb526..d5861a68d9f7 --date=short --first-parent --format='%ad %ae %s'
2020-02-13 ynovikov@chromium.org Fix ASAN errors in end2end tests.
2020-02-13 cnorthrop@google.com Vulkan: Update more bug numbers for ES 3.1
2020-02-13 cclao@google.com Vulkan: Fold glClear into draw call when command graph is disabled
2020-02-13 cnorthrop@google.com Capture/Replay: Track and restore mapped buffer data
2020-02-13 lexa.knyazev@gmail.com Vulkan: expose ANGLE_compressed_texture_etc
2020-02-13 julien.isorce@chromium.org Provide default implementation of rx::DisplayEGL
2020-02-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/vulkan-tools/src 45b9d01815d9..db0a1553991d (1 commits)
2020-02-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/vulkan-validation-layers/src d439b17da022..30794ac2f91b (12 commits)
2020-02-13 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader 6cbb02e0dc93..ac4e1d236088 (2 commits)

Created with:
  gclient setdep -r third_party/externals/angle2@d5861a68d9f7

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/+/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian9-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
Change-Id: Icb947ebb5b45da4dfd4a04a91681b61bb3f4dff3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270903
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-14 05:13:07 +00:00
skia-autoroll
7a175ef2c6 Roll ../src 07e508f15134..57a7afeb42f5 (388 commits)
07e508f151..57a7afeb42


Created with:
  gclient setdep -r ../src@57a7afeb42

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/+/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
Bug: None
Tbr: stani@google.com
Change-Id: I758cedf739baa7ee1d73fa76c7e6accba8e98cf9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270905
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-14 05:03:27 +00:00
Brian Salomon
53c909e05f Support bilerp filtering for all ShaderModes in GrTextureEffect.
Support MIP map for all but kRepeat.

Update texel_subset_ GMs to exercise newly supported modes.

Also makes GrTextureEffect do shader wrap modes for rectangle/
external textures even when not subsetted.

Change-Id: Ie2d299106120b5c6cc40365e8f300cc426dd5489
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/268163
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2020-02-14 01:49:35 +00:00
Jarrett Phillips
f9734c39b8 Adding fmls instruction
Change-Id: Ia1752196fd50ade2c3160dc401a36618433420d8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270822
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 22:55:53 +00:00
Bryce Thomas
475def0059 Update Skia build instructions in build.md
Adds a brief discussion of supported compiler versions, and how to pull
changes and rebuild.

Bug: NONE
Change-Id: Ibd26e623c1435953969f9e69b00612fdff601881
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270296
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 22:39:23 +00:00
Florin Malita
f3f225443b Undo suspect gn format
[1] formatted modules/skottie/BUILD.gn, as prompted by git cl upload,
but that doesn't sit well with a bot [2].

Let's try reverting.

[1] https://skia-review.googlesource.com/c/skia/+/270450
[2] https://logs.chromium.org/logs/skia/4a5923ca1d5a5511/+/steps/compare_diffs/0/logs/python.inline/0

Change-Id: I6ee74f5038b4f62f978cfe2fa77e7214d34d8b63
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270836
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Florin Malita <fmalita@chromium.org>
Reviewed-by: Mike Klein <mtklein@google.com>
2020-02-13 22:17:23 +00:00
recipe-roller
334d6f70ce Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (recipe_engine) into this repository.

recipe_engine:
  https://crrev.com/33fed4343ba9723f8d4e16dd04978f27490f0a57 (gbeaty@chromium.org)
    Report run steps in the order they were run.

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ieefbbaf6f85644c1f387d3bfed7815807d2e6723
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270770
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2020-02-13 21:05:33 +00:00
Mike Klein
87e5832c6b move clamp until just before store
By moving this clamp until just before the store,
we're minimizing the chance we'd do something between
the clamp and store that undoes the clamp's guarantee,
e.g. unpremul().

It also means we can now try thinking of ways to do
the clamp and store simultaneously in an integrated
way if that makes things faster or more safe somehow.
E.g. to_unorm() could do the clamp itself.

Change-Id: If07d09b4b59a8a20b236b4954ca79c660d6be85b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270614
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2020-02-13 21:01:52 +00:00
Mike Klein
748b757652 skvm support for 888x, 1010102, 101010x
Pretty straightforward, but needs the relaxed
asserts CL on the relation chain to draw all
GMs without asserting.

Change-Id: Ibe45922f9f5bc796117059b2bc73e83a90dc06a6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270402
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 20:58:33 +00:00
Greg Daniel
b8d84f8916 Remove all remaining uses of origin getter on proxy.
Bug: skia:9556
Change-Id: Id8a1ba9e46f4df9bb181d6b0e9248fe4bfc5b5a0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270716
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-02-13 20:56:43 +00:00
Ben Wagner
1a97683ddc [infra] Pin iOS tasks to old libimobiledevice
The iPhone11 doesn't work with the old version, but our recipes don't
yet work on the new version, so I'm pinning the version in order to
stage the rollout of the new version.

Change-Id: I778c664aee7fbd33442d57d1b36607c8bc0f43e5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270443
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Weston Tracey <westont@google.com>
Commit-Queue: Ben Wagner aka dogben <benjaminwagner@google.com>
2020-02-13 20:43:13 +00:00
recipe-roller
8b0dfd83cb Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (depot_tools) into this repository.

depot_tools:
  https://crrev.com/ca9a5ebcc400ae48c12a1323294689e313426882 (ehmaldonado@chromium.org)
    Revert "gerrit-util: Fix GCE check from behind proxy."

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Icd4e90ec4da9fa4ba74bad4bb92bd1d40b5b269b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270762
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2020-02-13 20:27:33 +00:00
Robert Phillips
45f37c3795 Revert "Carve some helper functions off of GPUSink"
This reverts commit 7b2fcfbc5a.

Reason for revert: Need to loosen up error handling

Original change's description:
> Carve some helper functions off of GPUSink
> 
> I'm adding a new DDL Sink and would like to reuse this functionality.
> 
> Change-Id: I9f4535ca5e0f36925bf896cb0076eab73fe60fd1
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270639
> Commit-Queue: Robert Phillips <robertphillips@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

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

Change-Id: I97968834b5719c2061d53caff0dcf08a80917beb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270798
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2020-02-13 20:27:23 +00:00
Greg Daniel
242536fe8b Store render target dirty msaa rect in real dst space.
The stored rect will already be adjusted for origin and actual backing
surface height.

This is needed since proxy doesn't store origin anymore, it doesn't
make sense for it to hold onto a rect which itself is dependent on
origin.

Bug: skia:9556
Change-Id: I41a2755970b9d5d1518dfa16a61a78af7c8ae2c0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270448
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2020-02-13 20:19:32 +00:00
Kevin Lubick
c499ec8227 Remove chromecast jobs
If we need to support the Ultras, I vote we use taskdrivers instead of
these old recipes.

Bug: skia:9899
Change-Id: I9a3adedde5e7b28d90d3f836ccab0c7fe40abd38
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270440
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2020-02-13 19:51:12 +00:00
Robert Phillips
7b2fcfbc5a Carve some helper functions off of GPUSink
I'm adding a new DDL Sink and would like to reuse this functionality.

Change-Id: I9f4535ca5e0f36925bf896cb0076eab73fe60fd1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270639
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2020-02-13 19:40:33 +00:00
recipe-roller
f23fd48ac1 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (depot_tools) into this repository.

depot_tools:
  https://crrev.com/0c4a5eb705f5dd01c7b60534fab2cd524d67880a (sque@google.com)
    roll out new goma client binary (VERSION=190)
  https://crrev.com/e9ed65aa190482e1d259b1c49d3b02bf139a6039 (sque@google.com)
    Add tikuta, <user>@chromium.org to GOMA_OWNERS
  https://crrev.com/9ee86e5a4697d34a90d096e7f40fb25feca76568 (ehmaldonado@google.com)
    gerrit-util: Fix GCE check from behind proxy.

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: I9f598b6455b48582ee63ae5f0ac13aa6f3e57661
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270696
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2020-02-13 19:29:32 +00:00
Robert Phillips
b3c061aa4f Add createBackendFormat and createFBO0 helper methods to SkSurfaceCharacterization
These make it easier for clients to create new surface characterizations that differ only a little from an existing surface characterization.

Change-Id: Iebd0b32ae941d3f91427927108d092cb5864b09f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270444
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2020-02-13 18:55:22 +00:00
Florin Malita
b24f3b150c [skottie] Refactor keyframe encoding
For each Lottie keyframe, we currently store interpolation
*segments*:

 {
   t0, v0
   t1, v1
   cubic_mapper
 }

This is quite redundant:

 - kf(n).t1 == kf(n+1).t0 for all keyframes
 - kf(n).v1 == kf(n+1).v0 for all non-constant keyframes

Refactor to store single keyframe records:

  {
    t, v
    mapping
  }

To identify constant keyframes, since we no longer store
explicit hard stops, we now tag each record with a "mapping"
selector:

    0 -> constant keyframe
    1 -> linear keyframe
  > 1 -> cubic keyframe (adjusted cubic mapper index)


This reduces the storage size by 2/5, and yields overall cleaner
logic (as we're no longer back-filling info as we parse).

Also add a handful of unit tests to lock down limit semantics
(keyframe segments are left-inclusive/right-exclusive).

Change-Id: I3ab0e5568b83ab8536a7d326dbc07c4c455e978d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270450
Commit-Queue: Florin Malita <fmalita@chromium.org>
Reviewed-by: Mike Reed <reed@google.com>
2020-02-13 18:54:32 +00:00
Brian Salomon
16033c9cc1 Update texel_subset_* GMs.
Draw placeholder gray rectangles rather than omitting cols/rows.

Swap x and y mode iteration so they correspond with GM layout.

Change-Id: I3c2d95bcd5d684f5a5a99cb677c326864e13f252
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270641
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2020-02-13 18:50:05 +00:00
Robert Phillips
edf3f38b56 Add makeNotCurrent to TestContext
I find this useful for managing which context is active on threads.

Change-Id: I655955a2351f273751681f080190ca684d29db4e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270642
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2020-02-13 18:40:52 +00:00
Mike Reed
146722ed8b threshold rtshader
Change-Id: Ia1a0e35f2cb7cf2f7fd1a58b88dc81ec59eced0b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/268943
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2020-02-13 18:00:22 +00:00
Mike Klein
921236bfe4 more sophisticated opacity in SkImageShader
The tricky bit here is tracking when we care if the image is opaque,
and when we care if the shader output is opaque. These are usually
the same, except for decal tiling modes.

We can exploit both of these properties:
   - if the shader output is opaque, set alpha to 1.0f after all
     sampling and interpolation to retroactively skip any the unpacking
     and interpolation we did to calculate alpha.
   - if the input is opaque, set alpha to 1.0f after each sample to skip
     unpacking it.  This mostly just helps decal modes, as this will
     itself all be skipped when the output is opaque.

Change-Id: Ie2954e59f0f9da8be7ad5d11f30fdfd4635c4b70
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270656
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2020-02-13 17:54:32 +00:00
Mike Klein
94708c2777 relax asserts to what we'd clamp to
At head we're asserting that our post-blend color is premul and alpha is in range
[0,1], which I think is still something we could assert if we were
dealing with real numbers.  But we've got floats, with rounding,
precision loss, etc, and these asserts keep triggering oh so very
slightly, usually by 1 ulp.

We're using these asserts to check that we can skip a clamp to [0,1]
across all channels (notably, not r,g,b to alpha) for sane conversion to
packed fixed point.  So first thing to try is relaxing the asserts to
exactly what they're enforcing, from asserting the color is premul and
in-gamut to just every channel is in [0,1].

I've never seen one of these small errors show up by the time we've
convert to fixed point to store the pixel, so perhaps we can move these
checks there instead somehow?

Change-Id: I2062dad8f9477d7e1a72063dc55fe185c7233384
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270612
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 17:33:42 +00:00
Mike Klein
46874efa12 extend opacity tests in SkVM blits
- Have SkVMBlitter also check the color type for opacity,
  and commit to this opacity as a guarantee rather than optional
  optimization.
- Have SkImageShader do the same when sampling.

This will make it easier to work with opaque formats like 888x, 101010x,
and should mean sampling from opaque images is a bit cheaper, skipping
any work to unpack and convert alpha.

Change-Id: I0d20418f8335bd07c8b1a80b042636424854df18
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270607
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 17:32:42 +00:00
Brian Osman
ee16e57351 Harden runtime shader/colorfilter CreateProc against bad child counts
Change-Id: I7d2f32a8cd4d373afddb2f1bfdb736e2979ec000
Bug: oss-fuzz:19883
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270637
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2020-02-13 16:25:22 +00:00
Ben Wagner
d38f00a12a Skip degenerate contours in glyphs.
Stroking in Skia follows the SVG rules of adding end caps to degenerate
contours. Skip all degenerate contours and degenerate curves on contours
to avoid this.

Bug: skia:9820
Change-Id: I320beeeb3728f39c764729454dcb128a05524d35
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/268166
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2020-02-13 16:22:42 +00:00
Mike Klein
2979f95e11 more MSAN dbg->rel cycling
Remove old Debug jobs that I added Release mirrors to
earlier today.  The release jobs look fine and faster,
taking between 50-80% the time of the debug jobs.

Add SwiftShader release MSAN jobs to try the same there.

Change-Id: I2a40e079bc95edc318d4da02299273fb0dd736af
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270537
Reviewed-by: Ben Wagner aka dogben <benjaminwagner@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-02-13 16:20:19 +00:00
Greg Daniel
55f040bcb9 Revert "Pass origins through the flushSurfaces calls."
This reverts commit ec3408169b.

Reason for revert: This change actually isn't needed since a follow on change removes the use of origin from flushSurface anyways

Original change's description:
> Pass origins through the flushSurfaces calls.
> 
> Bug: skia:9556
> Change-Id: Ie4a0b33dd35e50b93c30cb0010f60c2893140661
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270439
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Greg Daniel <egdaniel@google.com>

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

Change-Id: I4ea086d13d0bbef16c59e0abe2c42eb1eb6bf747
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:9556
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270640
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2020-02-13 15:38:52 +00:00
Greg Daniel
ec3408169b Pass origins through the flushSurfaces calls.
Bug: skia:9556
Change-Id: Ie4a0b33dd35e50b93c30cb0010f60c2893140661
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270439
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2020-02-13 15:34:22 +00:00
Mike Reed
7c81245a18 check for non-finite values in point3 case
Bug: oss-fuzz:20581
Bug: 1050296
Change-Id: I3059bc95fc9f54d1cb2f228101065b03167762a0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270636
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2020-02-13 15:11:52 +00:00
Brian Osman
3bf3b92dfa Guard runtime shader/colorfilter against SkSL that doesn't compile
Bug: oss-fuzz:20555
Bug: chromium:1051911
Change-Id: If40137e6cf3c0d398a86023c2399ddb7df10e209
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270442
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
2020-02-13 13:59:23 +00:00
skia-autoroll
1d1333fced Roll third_party/externals/angle2 e1ccac7ff9f0..74ab0bffb526 (10 commits)
e1ccac7ff9..74ab0bffb5

git log e1ccac7ff9f0..74ab0bffb526 --date=short --first-parent --format='%ad %ae %s'
2020-02-12 jmadill@chromium.org Vulkan: Disable command graph by default.
2020-02-12 jmadill@chromium.org Fix vpython caching in trigger.py script.
2020-02-12 jmadill@chromium.org Test Runner: Increase default timeouts.
2020-02-12 lexa.knyazev@gmail.com Move dither from blend state to rasterizer state
2020-02-12 courtneygo@google.com Roll deqp to get some test fixes
2020-02-12 amaiorano@google.com Update comment to reflect changes in ea0dcd4bda188
2020-02-12 lexa.knyazev@gmail.com Fix compressed formats validation with TEXTURE_3D
2020-02-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/spirv-tools/src fe10239f92f4..6c218ec60b5f (3 commits)
2020-02-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/vulkan-validation-layers/src b60b35843e66..d439b17da022 (38 commits)
2020-02-12 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader b3b2a4fc756f..6cbb02e0dc93 (11 commits)

Created with:
  gclient setdep -r third_party/externals/angle2@74ab0bffb526

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/+/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian9-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
Change-Id: I91b377af2a9edf858bc5d8fe70042c25492f83d9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270406
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-13 05:36:58 +00:00
skia-recreate-skps
ea8ba19cfc Update Go Deps
Change-Id: Id37a3ba3adbe1fe45ef12209a791f124e0d710f4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270412
Reviewed-by: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
Commit-Queue: <skia-recreate-skps@skia-swarming-bots.iam.gserviceaccount.com>
2020-02-13 05:27:28 +00:00
skia-autoroll
c8bd3650f7 Roll third_party/externals/swiftshader 6cbb02e0dc93..ac4e1d236088 (2 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/6cbb02e0dc93..ac4e1d236088

git log 6cbb02e0dc93..ac4e1d236088 --date=short --first-parent --format='%ad %ae %s'
2020-02-12 gmouse@google.com Add missed symbol __aeabi_idivmod for Android.
2020-02-12 swiftshader.regress@gmail.com Regres: Update test lists @ 6cbb02e0

Created with:
  gclient setdep -r third_party/externals/swiftshader@ac4e1d236088

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/+/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
Tbr: stani@google.com
Change-Id: I4e857356eea2cd8ecd3baaa48f40d546b65a5548
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270407
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-13 04:37:08 +00:00
skia-autoroll
1a733b5b76 Roll ../src b4a3bf71d776..07e508f15134 (402 commits)
b4a3bf71d7..07e508f151


Created with:
  gclient setdep -r ../src@07e508f151

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/+/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
Bug: None
Tbr: stani@google.com
Change-Id: I3980965b5101e1ba769543a14ee7c41d48617b0f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270408
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-02-13 04:33:28 +00:00
recipe-roller
6029cbd560 Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (depot_tools) into this repository.

depot_tools:
  https://crrev.com/da4b6c6e041ecde317f38943b977830f829d2af7 (ehmaldonado@google.com)
    git-cl: Use mock.patch instead of custom mock.
  https://crrev.com/15a9b8cc5ddc0262ef293b2c419d609875c32b22 (ehmaldonado@google.com)
    git-cl: Use scm.GIT.FetchUpstreamTuple.

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Ibe0647e96ee6fdddccd6f11dd8182030682024a9
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270500
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2020-02-13 01:44:26 +00:00
recipe-roller
092930f7ae Roll recipe dependencies (trivial).
This is an automated CL created by the recipe roller. This CL rolls recipe
changes from upstream projects (depot_tools) into this repository.

depot_tools:
  https://crrev.com/da8eec5db306642b0f959b419fd10e0051763a75 (vapier@chromium.org)
    repo: update to 2.3 launcher

More info is at https://goo.gl/zkKdpD. Use https://goo.gl/noib3a to file a bug.

TBR=borenet@google.com

Recipe-Tryjob-Bypass-Reason: Autoroller
Bugdroid-Send-Email: False
Change-Id: Id7c3138888d3a2414cb4929da79d18299d0b49d1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270497
Reviewed-by: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
Commit-Queue: Recipe Roller <recipe-mega-autoroller@chops-service-accounts.iam.gserviceaccount.com>
2020-02-13 00:49:56 +00:00
Herb Derby
9102c86a81 Refcount SkStrikeCache Nodes
Change-Id: I3566345b8518b15603d6089626a7c3b493f8af17
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/270438
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2020-02-12 23:19:16 +00:00