Commit Graph

44837 Commits

Author SHA1 Message Date
Brian Osman
6e1d51a2c7 Print out a warning if trying to use a cross context image on two contexts
Change-Id: Ie4611b4aae65aed5aa45be8841fbb7326bcfbf0b
Bug: skia:9581
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251773
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-10-30 20:07:48 +00:00
Herb Derby
c7a8df8b1c Swap SkPackedGlyphID bitfields around
Change-Id: Ic286357dc637edf0c8df003422a43252590250f5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251768
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-30 19:20:28 +00:00
Ben Wagner
9fa8a909dd [docs] Add skolo-builder to swarmingbots.md
Also fix a link and a typo.

No-Try: true
Docs-Preview: https://skia.org/?cl=251765
Change-Id: I9204887fb4c07af1e07f3e7c5d24ef6029bf8d00
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251765
Commit-Queue: Ravi Mistry <rmistry@google.com>
Auto-Submit: Ben Wagner aka dogben <benjaminwagner@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
2019-10-30 19:06:48 +00:00
Mike Klein
65e6ee7f7e quick switch to disable SkVM JIT
Change-Id: I4d4a8409163c2b2d1773e395a73857626c45d406
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251752
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-30 19:01:18 +00:00
Mike Klein
c746cdffa9 assume no color filters in SkVMBlitter
We'll lean on them being folded away before choosing blitters.
That happens everywhere but in Google3 now, and there's no use
of SkVMBlitter outside our own testing, certainly not Google3.

Change-Id: Ic9725ffbad5f2226d5f030e82bd72500a624b1ff
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251740
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-30 18:32:28 +00:00
Mike Klein
e1e1971862 clean up unorm8 helpers
- add scale for mul->div255
   - rename mix lerp
   - remove inv
   - add _unorm8 suffix

Just refactoring, nothing interesting.

Change-Id: I8f6e35cbd5cb9458a8149ca89cf5213d9233d950
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251751
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-30 18:31:28 +00:00
Herb Derby
77c99946e0 Faster remote glyph cache
Change RemoteStrikes to hold a very small summary of what has been
sent for each glyph, and only maintain full glyph information
until the next serialization. This greatly reduces memory used,
and improves average performance by 10% as measured by traces from
the top 10 websites.

BUG=chromium:881505

Change-Id: Id5c5d974e3c35a63d232bb62fc605e8472d926fc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251237
Reviewed-by: Khushal Sagar <khushalsagar@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-30 18:05:08 +00:00
Brian Osman
7df14d0557 YUV Cleanup: Trim comments, derive Cr/Cb from Kr/Kb
The conversion math for a given space can be fully derived
from the Kr and Kb terms (plus the headroom/footroom), so
avoid redundant values that can be wrong.

And, no need to list every possible value of an enum param,
especially when the generated doxygen links to the type's
documentation, which has all the values listed.

Change-Id: I64ce8cfd5ec7ff74dc3b878202b13d0d483e1db6
Bug: skia:9543
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251764
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-10-30 17:19:16 +00:00
Herb Derby
7820da3db5 Use shifts for all fields in SkPackedGlyphID
This should allow the bit field positions to be moved
around in the SkPackedGlyphID.

Change-Id: I85390f594a017b9df779f0a12e1f24c4d9e077dd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251761
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2019-10-30 16:26:16 +00:00
Chris Dalton
8a64a44244 Rename sampleVariablesSupport() to sampleMaskSupport()
We have only implemented support for the sample mask. This CL renames
the cap to reflect that.

It also replaces sampleVariablesStencilSupport() with the more aptly
named canOnlyUseSampleMaskWithStencil(), to make it more clear that
this is a driver workaround.

Change-Id: Ibf54092c63181232fb3b94cad7ddb16e3a15e3d1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251580
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2019-10-30 16:20:47 +00:00
Herb Derby
a9ac8a51fd Change uses of code to glyphID
Change-Id: I596bf0be9bf479a26f7bd00bea3c431b534164ce
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251758
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-30 15:19:16 +00:00
Stephen White
3cc8d4fb7f Dawn: s/dawn::/wgpu::/g.
The new webgpu_cpp.h hotness for native apps brings with it a new
namespace: wgpu. This is a straight substitution.

Note: no Skia API changes.
Change-Id: I12b26417e76838cd8fa2b39b8161cbaa2cd8fa78
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251660
Commit-Queue: Stephen White <senorblanco@chromium.org>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2019-10-30 14:29:46 +00:00
Stephen White
d2baa3d0f8 Dawn: roll to ToT.
Change-Id: Iaf6b4ba01ae208b28167cafbd19a5d0958b30aaa
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251659
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2019-10-30 14:29:26 +00:00
Robert Phillips
bbd459d82c Allocate all vertex data in one go w/in GrTextureOp
This will hopefully reduce the overhead of prePreparing the vertex data (i.e., only one memcpy to use the precomputed data) and set us up for using the full extent of the index buffers.

Note this CL also contains a refactoring to share more code between onPrePrepareDraws and onPrepareDraws (i.e., the FillInData method).

Change-Id: Ia0e482332c8108e24b82743b82fdf53840c9b009
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250800
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-10-30 14:18:16 +00:00
Jim Van Verth
7da048b5e8 Use texture for shadow falloff
Bug: b/142333639
Change-Id: I5c5bf4da0e2bb5f1b4233681dee305cf381c3e2a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250096
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-10-30 13:40:16 +00:00
skia-autoroll
ebdae11449 Roll third_party/externals/angle2 95a736bd3347..bb35bb4e5379 (18 commits)
95a736bd33..bb35bb4e53

git log 95a736bd3347..bb35bb4e5379 --date=short --no-merges --format='%ad %ae %s'
2019-10-29 jmadill@chromium.org Vulkan: Implement simple case ANGLE_get_image.
2019-10-29 tobine@google.com Fix Renderbuffer support for unsized DS formats
2019-10-29 courtneygo@google.com Update docs for recent dEQP / VK-GL-CTS update
2019-10-29 courtneygo@google.com Print the testConfig in dEQP tests.
2019-10-29 ianelliott@google.com Vulkan Android: Remove support for EGLConfig's with GL_RGB10_A2 & GL_RGBA16F
2019-10-29 courtneygo@google.com Roll dEQP to VK-GL-CTS
2019-10-29 timvp@google.com Vulkan: Enable forceOldRewriteStructSamplers for all Android ICDs
2019-10-29 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/spirv-tools/src ec12de913124..42f885238114 (3 commits)
2019-10-29 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader 1737a30e3e34..f8f6103eb89f (2 commits)
2019-10-29 jmadill@chromium.org Vulkan: Clean up redundant vk:: prefixes.
2019-10-29 jmadill@chromium.org Vulkan: Move readPixels logic to ImageHelper.
2019-10-28 mmynttinen@mozilla.com Fix MinGW include: s/VersionHelpers.h/versionhelpers.h/
2019-10-28 jmadill@chromium.org Plumb more logic for ANGLE_get_image.
2019-10-28 jmadill@chromium.org GN: Don't expose glslang when unused.
2019-10-28 jmadill@chromium.org Don't cc angle-team on Chromium DEPS rolls.
2019-10-28 jmadill@chromium.org Fixups to ANGLE_get_image boilerplate.
2019-10-28 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader f44f7c066a67..1737a30e3e34 (1 commits)
2019-10-28 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/spirv-tools/src b34fa731931b..ec12de913124 (2 commits)

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

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 jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

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

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

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
TBR=jcgregorio@google.com
Change-Id: Ie8376bffd08230b7b45c6d84013407042a66fea3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251619
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-10-30 06:07:48 +00:00
skia-autoroll
c3a51a5e47 Roll third_party/externals/swiftshader f8f6103eb89f..e1cda3916cee (2 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/f8f6103eb89f..e1cda3916cee

git log f8f6103eb89f..e1cda3916cee --date=short --no-merges --format='%ad %ae %s'
2019-10-29 sugoi@google.com vkGetPhysicalDeviceFeatures2 fix
2019-10-29 sugoi@google.com Provoking vertex fixes

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

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 jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

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

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

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
TBR=jcgregorio@google.com
Change-Id: I37e7b90f352e8c6444808b70452d645cf8ecabfe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251618
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-10-30 04:37:48 +00:00
Chris Dalton
1ae54bc22f Add sampleVariablesStencilSupport to sksl standalone caps
TBR=ethannicholas@google.com

Change-Id: I53c2896470fd202f01f51c5aaddf3087b2cbb5ce
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251556
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2019-10-29 23:12:13 +00:00
Mike Klein
07c6c6668c work around x11/X.h #define pollution
Some nerve those folks have to #define None 0L.

Cq-Include-Trybots: skia.primary:Build-Debian9-Clang-x86_64-Debug-SwiftShader
Change-Id: I0c84f78ec72672648d1c0bde69b6e05433b80d56
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251516
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-29 22:52:23 +00:00
Hal Canary
014f540f70 BotsCfg/Perf/RemoteGlyphCache: bots to download and use traces
This runs the following benches in Perf-Android-*-CPU-* bots:
  - SkDiffBench-amazon
  - SkDiffBench-espn
  - SkDiffBench-googlecat
  - SkDiffBench-qq
  - SkDiffBench-taobao
  - SkDiffBench-wikicat
  - SkDiffBench-yahoo
  - SkDiffBench-youtube

CQ_INCLUDE_TRYBOTS=skia.primary:Perf-Android-Clang-NVIDIA_Shield-CPU-TegraX1-arm64-Release-All-Android

Change-Id: If8b51bd09cfb0bfcc04258bc68a94e1e4e24de90
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251205
Commit-Queue: Hal Canary <halcanary@skia.org>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2019-10-29 22:24:54 +00:00
Nigel Tao
2777cd37bf Have SkWuffsCodec use two Wuffs decoders
This allows onGetFrameCount to advance the stream (and return a higher
frame count), even when in the middle of a onIncrementalDecode sequence.

Such behavior is expected by Chromium's
TestResumePartialDecodeAfterClearFrameBufferCache:

https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/image-decoders/image_decoder_test_helpers.cc?l=365&rcl=23787ba147959ebf4ad168c595d5ec87919fdbd2

Bug: skia:8235
Change-Id: Iba7267468b02ce73455b362e50d8878f53b0ff88
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250937
Commit-Queue: Nigel Tao <nigeltao@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
2019-10-29 22:17:43 +00:00
Stephen White
e662695654 Roll to ToT Dawn.
Change-Id: Iff890f62f8ecae29ce7024f2bba206a2770c2600
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251365
Commit-Queue: Stephen White <senorblanco@chromium.org>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-10-29 22:06:23 +00:00
Mike Klein
f6a89fde46 hold a ref on Key effects
This ensures we never confuse a dead effect pointer in our cache for a
different live effect that happens to be allocated at the same address
as the old one.  Never seen it happen yet, but it's possible.

Change-Id: If8aff141fb6d0a4e10f13a153b154bb14f5a8c1a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251442
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-10-29 21:59:33 +00:00
Mike Klein
e4522dcf9a rough sketch of shaders in SkVMBlitter
Change-Id: I5f96475a6dec26dde0bdf883153a1fd7c7e3b148
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251409
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2019-10-29 21:41:53 +00:00
Mike Klein
bfdab5f027 support 3D masks in SkVMBlitter
Nothing too tricky, all spun off the other CL.

Diffs on the new emboss GM look good.

Change-Id: Ia46f106491e92c0cee4020200474ea5de2ca270d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251440
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-29 21:17:52 +00:00
Mike Klein
278615afb4 add a paint-color string to gm/emboss
I'm not hitting SkVMBlitter with a 3D mask
without also implementing support for SkColorShader.

Adding this green "World" tests that path with
a paint color, and should let me test and land 3D
mask support before adding shader support.

Change-Id: I9020a14a8a77dd2946c094308e5ad04beea20068
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251439
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-29 21:12:22 +00:00
Chris Dalton
b0fd4b12a1 Reland "Revert "Revert "Rename gl_SampleMask to sk_SampleMask"""
This is a reland of 4ac37632a8

Original change's description:
> Revert "Revert "Rename gl_SampleMask to sk_SampleMask""
> 
> This reverts commit 40b815db97.
> 
> Bug: skia:
> Change-Id: I454d3e86219276996d0b4f9e7fcf177bb6dc45e7
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251004
> Reviewed-by: Chris Dalton <csmartdalton@google.com>
> Commit-Queue: Ethan Nicholas <ethannicholas@google.com>

Bug: skia:
Change-Id: Ia343e9e1008ca2354e1d300030e763f3c578d71c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251441
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2019-10-29 21:01:52 +00:00
Stephen White
ebe2ac5f95 Dawn: workaround X11 #defines for Always, Success, None.
Dawn uses symbols in its API which Xlib.h #defines, which causes
compile-time conflicts. However, they do need to work in Chrome, so we
work around them the way Chrome does: by redefining them as static
constants (see https://cs.chromium.org/chromium/src/ui/gfx/x/x11.h).

Change-Id: Ibef0fd9976503cd606aa0fa646998df54675efb2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250998
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2019-10-29 20:20:37 +00:00
Nigel Tao
a1cc9f6b84 Test Codec::getFrameCount updates with more data
This mimics Chromium's
TestResumePartialDecodeAfterClearFrameBufferCache, which expects the
frame count to increase as more data comes in, even if the decoder is in
the middle of an incremental decode:

https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/image-decoders/image_decoder_test_helpers.cc?l=365&rcl=23787ba147959ebf4ad168c595d5ec87919fdbd2

Bug: skia:8235
Change-Id: Icc19ebea6d77f6b6fb62e3b2ff0c2ffb1ef0950d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250476
Reviewed-by: Leon Scroggins <scroggo@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2019-10-29 20:15:36 +00:00
Jim Van Verth
352f4f7800 If drawing an image as tiled fails, fallback to other methods.
When rendering cross-context images, we can end up with a situation
where the image thinks it should be tiled because it won't fit in the
cache, but we can't tile it because getROPixels fails. In this case,
the image should be backed by the client, so we should be able to
render it through a TextureProducer.

Bug: skia:9562
Change-Id: I172e1008ca423f46b0c7b445bdf3eb573215adfb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251458
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2019-10-29 20:15:35 +00:00
Brian Osman
5f95519d54 Use GPU special images in two GPU image filter tests
We were always testing the CPU backend.

Bug: skia:9582
Change-Id: I25ff1dc151c1be8a31ab09008393430a1fa85221
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251457
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-10-29 19:59:49 +00:00
Greg Daniel
baf8d992e6 Remove outputSwizzle from GrRenderTargetProxy.
Bug: skia:9556
Change-Id: Icbcc56c0eb0d0de0886874e0ed8c3f03c7318d02
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/249883
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2019-10-29 18:51:20 +00:00
Brian Osman
650f40d39b SkMorphologyImageFilter: Avoid integer overflow with large radii
We later compute the "width" of the filter as (2*radius)+1, so fail
early if that will overflow.

Bug: chromium:1018190
Change-Id: I6554693067be4b52b1304d9f6fd0376ce4b3be19
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251364
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-10-29 18:38:45 +00:00
Robert Phillips
b69001f36f Make GrFillRectOp and GrTextureOp consistent re AA-upgrading and size checks
I believe GrFillRectOp wasn't handling AA-upgrading correctly. Both ops now also check that they aren't exceeding the index buffer limits for both AA and non-AA draws.

Change-Id: Iae586b92e1f27a908a54ae881f2b1db21ec1afc8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251360
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2019-10-29 17:25:45 +00:00
Greg Daniel
793c9e8c98 Cache simple descriptor sets on GrVkTexture.
We add a small cache of descriptor sets on each texture which only contain
one descriptor which a a texture/sampler using the given texture.

This helps to reduce the overhead of finding a new descriptor and re-writing
data to it every frame we want to use it.

Seeing about 25% gpu main thread performance win on linux vulkan
css_opacity_plus_n_layers.html?layer_count=1000&visible_layers=1000 test

Bug: skia:9574
Change-Id: I9979d7d874350e12caae0e5e70113c9347228e8a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251243
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-10-29 17:04:10 +00:00
Kevin Lubick
77d9b5c58e [canvaskit] Add tentative support for savelayerrec
It was easier to just add a few saveLayer overrides rather
than try to expose the struct of pointers. SkRect*
was hard/impossible because we have it as a value_object,
which does not support pointers in enscriptem.

Change-Id: Iad702593cca19f80d6ef9a319f8c80a087135e38
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250996
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
2019-10-29 16:46:43 +00:00
Greg Daniel
16f5c65a0a Use GrSurfaceProxyView in RenderTasks.
Bug: skia:9556
Change-Id: Ibe0ae6981e87909848e5af73fc716aac7c8a591f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/249232
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-10-29 15:53:59 +00:00
Kevin Lubick
15b40236bd [canvaskit] Add various ImageFilters
We are pretty comfy exposing this set for the long-term.

CanvasKit will generally support chains of image filters,
not necessarily arbitrary DAGs, just to simplify the
points needed to expose.

Change the naming around MaskFilters also, I like having
the factories be a class function, just to keep things
a bit better organized and minimize the amount of things
we want to keep on the top level CanvasKit object.

Change-Id: If32c630efa2fd8bc4bac84d0c3461ac3c0d21263
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/250758
Reviewed-by: Robert Phillips <robertphillips@google.com>
2019-10-29 14:48:33 +00:00
Greg Daniel
c10bb6aa30 Some cleanup of unneeded code/objects in GrVkPipelineState.
I wanted to cleanup this file as much as possible before starting to add
caching logic to make the changes simpler.

Bug: skia:9574
Change-Id: I8280a81f17372680a488f7f7d28d78d68121b235
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251201
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2019-10-29 14:35:55 +00:00
Brian Salomon
998937c035 Reland "Make GrFillInData use SkRasterPipeline"
This is a reland of 620154a7dc

Now handles kGray_8.

Original change's description:
> Make GrFillInData use SkRasterPipeline
>
> Makes it easier to add new color types.
>
> Bug: skia:6718
> Change-Id: Id0e6974ec87fd06587b2ccd7a9b99ceb1b6284f1
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251236
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

Bug: skia:6718
Change-Id: Id8b632242b87957f5b1e1a130eb26dafdf82a1cc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251359
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2019-10-29 14:29:32 +00:00
Robert Phillips
ee08d523f6 Move creation of AAQuadIndexBuffer to GrResourceProvider
This CL also increases the AAQuadIndexBuffer's size and centralizes the handling of index buffer constants.

Change-Id: I4fb679a1c5e4076cf249b612f798e9bf5a38cd0b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251244
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-10-29 13:51:22 +00:00
Robert Phillips
d4b95d213d Revert "Implement refPinnedTextureProxy for SkImage_Lazy."
This reverts commit 1e0f2f389f.

Reason for revert: I suspect this is blocking the Chrome roll

Original change's description:
> Implement refPinnedTextureProxy for SkImage_Lazy.
> 
> Creating a cross-context texture exposed a hole in our lazyproxy
> texture generation. Despite having a wrapped texture we were falling
> back to drawing in tiled mode, which is incorrect. Filling in these
> methods allows us to draw with the wrapped texture.
> 
> Bug: skia:9562
> Change-Id: Ia26c5d75b202aefdf720e6d1f7a201af23e40676
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251214
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Jim Van Verth <jvanverth@google.com>

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

Change-Id: I2dd6f2cbe13dd3ac1f65890da366171572fb84e2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:9562
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251356
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2019-10-29 12:40:06 +00:00
Joe Gregorio
7a6986b7b3 Revert "Make GrFillInData use SkRasterPipeline"
This reverts commit 620154a7dc.

Reason for revert: Breaks Win10. 

Original change's description:
> Make GrFillInData use SkRasterPipeline
> 
> Makes it easier to add new color types.
> 
> Bug: skia:6718
> Change-Id: Id0e6974ec87fd06587b2ccd7a9b99ceb1b6284f1
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251236
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Brian Salomon <bsalomon@google.com>

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

Change-Id: I77b400fcb9a74b56f5b480c88e3d2340f26a6cf2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:6718
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251349
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
2019-10-29 11:04:06 +00:00
skia-autoroll
76d22d1ee8 Roll third_party/externals/swiftshader 1737a30e3e34..f8f6103eb89f (2 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/1737a30e3e34..f8f6103eb89f

git log 1737a30e3e34..f8f6103eb89f --date=short --no-merges --format='%ad %ae %s'
2019-10-28 sugoi@google.com VK_EXT_provoking_vertex support
2019-10-28 jonahr@google.com Fix vulkan builds in ANGLE on MacOS

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

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 jcgregorio@google.com on the revert to ensure that a human
is aware of the problem.

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

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

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
Bug: None
TBR=jcgregorio@google.com
Change-Id: Id62ed71170fafab4fa3574df0ad028f84089efd6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251337
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2019-10-29 04:41:23 +00:00
Florin Malita
512eb94916 [skottie] Fix layer blend modes under mattes
The layer blend mode should be applied post-masking (after compositing
with the matte layer).

TBR=
Change-Id: Ie84760526cd9be95f08bc68bc5a8dbfb635ca905
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251316
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2019-10-29 01:49:26 +00:00
Florin Malita
f22dda9601 [skottie] Fix skottie2movie after async API change
TBR=
Change-Id: I4793d3540f3b5f5fa06ce7a3d1ce2a281660fb72
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251255
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2019-10-28 23:28:25 +00:00
Herb Derby
d898cc3f26 Small cleanups
Change-Id: Id5fbfa48868d4aa48901835f8618c4297d5cdc88
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251240
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-28 22:29:25 +00:00
Herb Derby
9e1909f03d Inline fallback code
Change-Id: I49adc018dc4b486edb7be8aa55f86f248bb39c83
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251212
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-28 22:25:05 +00:00
Herb Derby
aacbd44cad Only send needed glyph images
Only send the glyph images that will be used by the GPU process. If the image
is too big to fit in that atlas, it will never be placed in the strike cache.
So, don't send it.

Change-Id: I8b3c3138555cf73b370784b37360b0a283bb3e41
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251239
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2019-10-28 22:10:25 +00:00
Michael Ludwig
b987862c86 Blacklist bulkrect benchmarks on chorizo
Change-Id: I487fb2e68de683301ce3d7ad19465b71d48c28e4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/251249
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2019-10-28 22:04:15 +00:00