Commit Graph

37008 Commits

Author SHA1 Message Date
Hal Canary
c9873a5f8b Document headers: IWYU
Change-Id: If0c5b7d540d9f5980b30ff4209c57f8c57421282
Reviewed-on: https://skia-review.googlesource.com/155761
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2018-09-20 16:07:02 +00:00
Joe Gregorio
e9326bebdf Use new build targets in continuous build of skottie and debugger.
The new targets were added here: https://skia-review.googlesource.com/c/buildbot/+/155820

Bug: skia:
Change-Id: Iac387fb033cf66dff353efb83f52a442b3441539
Reviewed-on: https://skia-review.googlesource.com/155841
Reviewed-by: Ravi Mistry <rmistry@google.com>
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
2018-09-20 15:26:18 +00:00
Brian Osman
653c6b5b8e Remove (unused) GrBlend.cpp, and some GrColor helpers
Bug: skia:
Change-Id: I9a99cb28fd239371ca21b4a918e802606afe9da0
Reviewed-on: https://skia-review.googlesource.com/155840
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2018-09-20 15:25:17 +00:00
Mike Klein
7b11354810 add a bot that oughta fail
Change-Id: Ifcd32b5cf4000c34567a7643dc294d39611d9f42
Reviewed-on: https://skia-review.googlesource.com/155780
Commit-Queue: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2018-09-20 14:39:02 +00:00
skia-autoroll
52c63fdabb Roll third_party/externals/swiftshader 25c541e51cbd..2ecc8b712b08 (1 commits)
https://swiftshader.googlesource.com/SwiftShader.git/+log/25c541e51cbd..2ecc8b712b08


git log 25c541e51cbd..2ecc8b712b08 --date=short --no-merges --format='%ad %ae %s'
2018-09-20 loganchien@google.com Add SWIFTSHADER prefix to Android.mk variables


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

The AutoRoll server is located here: https://autoroll.skia.org/r/swiftshader-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Debian9-Clang-GCE-GPU-SwiftShader-x86_64-Debug-All-SwiftShader
TBR=reed@google.com

Change-Id: I6e2ecab40c6c07842cc8d5f3a2696d0e605064a6
Reviewed-on: https://skia-review.googlesource.com/155720
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-20 02:51:32 +00:00
Florin Malita
4054351369 [skottie] Add support for external font loading
Web fonts are quite common in Lottie text assets.  Expand the
ResourceProvider interface to allow loading of external (web) font data.

Fonts are passed back to Skottie as opaque SkData, and instantiated
using SkFontMgr::makeFromData().

Change-Id: Ia4c994bd60e6a3bd47c90172c267ed5f897a38e4
Reviewed-on: https://skia-review.googlesource.com/155601
Commit-Queue: Florin Malita <fmalita@chromium.org>
Reviewed-by: Ben Wagner <bungeman@google.com>
2018-09-20 02:01:28 +00:00
skia-autoroll
6c1a7f2c78 Roll third_party/externals/angle2 5c72f28d1a3f..d511948b9f82 (6 commits)
5c72f28d1a..d511948b9f


git log 5c72f28d1a3f..d511948b9f82 --date=short --no-merges --format='%ad %ae %s'
2018-09-19 jmadill@chromium.org Use FastVector in angle::Subject.
2018-09-19 jmadill@chromium.org Fix FastVector::resize when count < size.
2018-09-19 oetuaho@nvidia.com Fix trying to clear nonexistent FBO attachments
2018-09-19 jmadill@chromium.org Re-land "Add FastVector for simple dynamic vector cases."
2018-09-19 tobine@google.com Remove writeResource down readPixels path
2018-09-19 oetuaho@nvidia.com Add ANGLE_multiview_multisample


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

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Perf-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE
TBR=reed@google.com

Change-Id: I71ae054407a86936af1082fb3cb7e0777ca929fc
Reviewed-on: https://skia-review.googlesource.com/155700
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-19 22:23:59 +00:00
Ben Wagner
d89e811684 SkImageGeneratorCG.h to only expose factory method.
Instead of requiring the implementation details of the SkImageGenerator
which backs the CG image generator to be present in the header, move the
class into the implementation and only expose the factory method.

Change-Id: I728276ffcfb6bb4e7302280459a79210e8d67475
Reviewed-on: https://skia-review.googlesource.com/155611
Commit-Queue: Ben Wagner <bungeman@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Hal Canary <halcanary@google.com>
2018-09-19 21:20:35 +00:00
Michael Ludwig
bf6bf39edb Increase precision for two point gradient coordinates.
This can be seen in these failing gold images:
https://gold.skia.org/detail?test=gradients_local_perspective_nodither&digest=52ef69138d81fcb58f4439b2d5903f45

Zooming in on the 2nd from the bottom, rightmost gradient shows a
solid red line in the blue border region (due to overflow and then
being clamped to the wrong border). The 2nd rightmost gradient in
the same row also shows extra red at the bottom from similar overflow.

The former error appears now because the GPU pipeline didn't previously
render that gradient at all. The latter appears now because the refactor
for gradients changed where clamping of texture coordinates occurred.

Bug: skia:
Change-Id: If2a886eaae4e8817a205d9bb77cf092b97d27c84
Reviewed-on: https://skia-review.googlesource.com/155610
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2018-09-19 21:20:05 +00:00
Hal Canary
92c500b111 SkPDF: draw persepctive text
This improves the gm output on several gms:
    dftext_blob_persp
    dftext
    glyph_pos_h_f
    glyph_pos_n_f
    poly2poly
    shadertext2

Bug: chromium:884150
Change-Id: I16899f32ac2a8e7afdd2452017de6d27656679e7
Reviewed-on: https://skia-review.googlesource.com/155609
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
2018-09-19 21:03:25 +00:00
Hal Canary
912cd3d2e4 SkImageGeneratorWIC: make the header compile without src/.
SkTScopedComPtr.h is located in src/utils/win/.

Change-Id: If2f3a28d7427e9a2e196272ce07f303de4d613ca
Reviewed-on: https://skia-review.googlesource.com/155562
Commit-Queue: Hal Canary <halcanary@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
2018-09-19 20:31:47 +00:00
Brian Osman
9369031fde GrColor -> SkColor in one GM
Bug: skia:
Change-Id: I71ea8f4275c2eb89dd88b7abf501b71e37469785
Reviewed-on: https://skia-review.googlesource.com/155605
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-09-19 20:05:22 +00:00
Herb Derby
cf370b1fc1 Clean up GPU strike sk_sp
Change-Id: Icece7d2e34307a52e58b195ba964d981999e15d1
Reviewed-on: https://skia-review.googlesource.com/155642
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2018-09-19 20:03:22 +00:00
Nodir Turakulov
473b40b7ca Populate repo_path_map
checkout/api.py populates patch_projects mapping which has no effect.
All of its usages were migrated to repo_path_map mapping.
Populate repo_path_map instead.

R=rmistry@chromium.org

Bug: 694348
Change-Id: I4fc6fe86565f75f4b4b5b5ca041f584d30fcd8a5
Reviewed-on: https://skia-review.googlesource.com/155632
Auto-Submit: Nodir Turakulov <nodir@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2018-09-19 19:59:21 +00:00
Mike Reed
5d032ecb8f Revert "always optimize third_party code"
This reverts commit c766370d86.

Reason for revert: speculative -- trying to fix Debian breaks (pdf?)

Original change's description:
> always optimize third_party code
> 
> Change-Id: I5b2244460a4760e9336640f597d0f74c374a0d04
> Reviewed-on: https://skia-review.googlesource.com/155641
> Commit-Queue: Mike Klein <mtklein@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>
> Auto-Submit: Mike Klein <mtklein@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

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

Change-Id: I5467c95f9487c31e6f538f13579e490cdaeeee2e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/155607
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-09-19 19:55:58 +00:00
Brian Osman
a5c578ff3d Add Short4 vertex attributes, and benchmark them as 4.12 colors
This reverts commit 90d2d9381e.

Updated to use float in the shader (many ES2 implementations
don't support integral types as attributes).

Bug: skia:
Change-Id: I0898f1730da60ff03f8165b2f1a3ee18a7b2fec8
Reviewed-on: https://skia-review.googlesource.com/155162
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-09-19 18:56:49 +00:00
Brian Osman
133823d9a7 Load SVGs into memory before parsing
On my Z840, Windows-Clang-Debug, this cuts the total time to construct
(parse) the 72 SVG sources from 66 seconds to 40 seconds. That's still
awful, but all the time is now spent in expat, so further improvements
will require higher level changes.

Bug: skia:
Change-Id: I0dca67ee18652f6fb8647fe8706716d9a01f7cdf
Reviewed-on: https://skia-review.googlesource.com/155603
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2018-09-19 18:35:59 +00:00
Brian Osman
4a3f5c8141 Remove hacks for UShort2 texture coords
Plumb GPU type down for binding of vertex attributes in GL. Use that
to select between float and int versions of VertexAttribPointer.

For client code that was relying on the strange behavior of UShort2,
use shader caps to pick the appropriate GrSLType.

Bug: skia:
Change-Id: If52ea49e0a5667246687e90e088d0823dbedb921
Reviewed-on: https://skia-review.googlesource.com/155401
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-09-19 18:10:55 +00:00
Mike Klein
c766370d86 always optimize third_party code
Change-Id: I5b2244460a4760e9336640f597d0f74c374a0d04
Reviewed-on: https://skia-review.googlesource.com/155641
Commit-Queue: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2018-09-19 18:09:55 +00:00
Hal Canary
8a00144035 test,tools: whitespace changes for clang-format
Change-Id: I67529f6c0ac26da603f60af22c620f8f603d8a19
Reviewed-on: https://skia-review.googlesource.com/155564
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
2018-09-19 17:50:51 +00:00
Mike Klein
8f6cd824d2 update clang_linux to Clang 7
Change-Id: I4f311b21de42b9f0689b9a0a488728e34ea4d332
Reviewed-on: https://skia-review.googlesource.com/155563
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2018-09-19 15:57:06 +00:00
Hal Canary
c2d0fb17de include: whitespace changes for clang-format
Change-Id: I76ab59d963cebf6cbb450e1873c3e0c63f3f2da0
Reviewed-on: https://skia-review.googlesource.com/155560
Commit-Queue: Hal Canary <halcanary@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2018-09-19 14:54:57 +00:00
Mike Klein
9e7f50435c Revert "Reland "implement SkPixmap::getPixel() with this->readPixels().""
This reverts commit 1d6281d4bb.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Reland "implement SkPixmap::getPixel() with this->readPixels()."
> 
> This is a reland of 0944ae8afb
> 
> Original change's description:
> > implement SkPixmap::getPixel() with this->readPixels().
> > 
> > Yet another big old switch statement I don't want to maintain.
> > 
> > Once again, I think this at least makes it explicit that we're
> > returning an SkColor in the colorspace of the pixmap.
> > 
> > Change-Id: I34aa7312c0a1670910586fc5a4b1951275e73e2e
> > Reviewed-on: https://skia-review.googlesource.com/154864
> > Reviewed-by: Brian Osman <brianosman@google.com>
> > Commit-Queue: Mike Klein <mtklein@google.com>
> 
> Change-Id: I07b0b11922a393072961edc7771d7a972ca1fd13
> Reviewed-on: https://skia-review.googlesource.com/155166
> Reviewed-by: Mike Klein <mtklein@google.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

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

Change-Id: I79bb37236a0a51097e1ab3bea9b5895adc974045
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/155561
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-09-19 14:39:31 +00:00
Hal Canary
27c8404d87 IWYU: three files
Change-Id: I7d4fefeafce06145818c607b28b30887a52acc74
Reviewed-on: https://skia-review.googlesource.com/155501
Auto-Submit: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2018-09-19 14:21:55 +00:00
Brian Salomon
f723264833 Revert "Revert "Reland "Add ability to specify different GP textures for each mesh in a draw."""
This reverts commit cd7907b57d.

Readds optimization to draw single texture quads using GrPrimitiveType::kTriangles, non-indexed.

Removes disable on NVIDIA/VK as bounds issue was fixed here:
https://skia.googlesource.com/skia/+/c525d4f7101715d728fca1b7fd7f170115994646

Change-Id: Icbea3de0382c68318db8ecffb2244bc4c5fe84ad
Reviewed-on: https://skia-review.googlesource.com/155500
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2018-09-19 13:42:06 +00:00
skia-autoroll
19b674c5d4 Roll third_party/externals/angle2 dc8fb9374e0a..5c72f28d1a3f (1 commits)
dc8fb9374e..5c72f28d1a


git log dc8fb9374e0a..5c72f28d1a3f --date=short --no-merges --format='%ad %ae %s'
2018-09-19 jgilbert@mozilla.com Remove unused include global_state.h from validationEGL.cpp.


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

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Perf-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE
TBR=reed@google.com

Change-Id: Ia85aae9d0407525ce034164a5774d04c99efcd73
Reviewed-on: https://skia-review.googlesource.com/155460
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-19 13:21:35 +00:00
skia-autoroll
0ff03808e3 Roll third_party/externals/angle2 0fdb956d9c24..dc8fb9374e0a (6 commits)
0fdb956d9c..dc8fb9374e


git log 0fdb956d9c24..dc8fb9374e0a --date=short --no-merges --format='%ad %ae %s'
2018-09-19 ynovikov@chromium.org Revert "Add FastVector for simple dynamic vector cases."
2018-09-19 jie.a.chen@intel.com Improve dirtybits for compute
2018-09-19 jie.a.chen@intel.com ParallelCompile: Parallelize shader translation
2018-09-18 jmadill@chromium.org Add FastVector for simple dynamic vector cases.
2018-09-18 jmadill@chromium.org Log Renderer string on Android displays.
2018-09-18 jmadill@chromium.org More binding inlining.


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

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Perf-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE
TBR=reed@google.com

Change-Id: Ic49081c0f227017ea562e8caed49b467e89cee54
Reviewed-on: https://skia-review.googlesource.com/155421
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-19 03:27:55 +00:00
Ben Wagner
774b566c13 Revert "Reland "implement SkPixmap::erase() with draws""
This reverts commit 4a9631c186.

Reason for revert: Chrome for Android in roll?
https://chromium-review.googlesource.com/c/chromium/src/+/1231494

Original change's description:
> Reland "implement SkPixmap::erase() with draws"
> 
> This is a reland of 42f29f1181
> 
> The original had to be reverted because of a buggy Chromium unit test,
> now fixed.  I also took the opportunity to implement this with SkDraw
> rather than SkCanvas.
> 
> Original change's description:
> > implement SkPixmap::erase() with draws
> >
> > I don't want to have to maintain yet another switch on SkColorType.
> >
> > This should also make color management a bit clearer?
> >
> > Change-Id: I1508e0c30670b1987972f7eeba2dd6d23591c531
> > Reviewed-on: https://skia-review.googlesource.com/154862
> > Commit-Queue: Mike Klein <mtklein@google.com>
> > Reviewed-by: Brian Osman <brianosman@google.com>
> 
> Change-Id: I6bc071e8a6025723d47f2ad5f6fb7f8fa5dccc2b
> Reviewed-on: https://skia-review.googlesource.com/155240
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

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

Change-Id: I1ce2ae01253e95da28f7d5b4bd82b59775e9fef8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/155403
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2018-09-18 21:22:42 +00:00
Kevin Lubick
c03a86affc [CanvasKit] Add docs
No-Try: true
Docs-Preview: https://skia.org/?cl=155400
Bug: skia:
Change-Id: I08b14ffa569b2bff81287f854c493a4cedabb5bb
Reviewed-on: https://skia-review.googlesource.com/155400
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2018-09-18 20:31:05 +00:00
Nigel Tao
81125c5643 Remove duplicate BUILD.gn configuration
There's another `if (skia_llvm_path != "")` about 40 lines down.

Bug: skia:
Change-Id: I490c0972367d0042e5f87868c0640cc106f6f6c2
Reviewed-on: https://skia-review.googlesource.com/154260
Reviewed-by: Leon Scroggins <scroggo@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2018-09-18 19:48:32 +00:00
Ben Wagner
d6931bb014 Work around FreeType issue with bitmap font and autohinter.
If a ttf font is bitmap only and autohinting is used and the no-bitmap
flag is used FreeType may return an empty outline glyph instead of
producing an error or a non-outline glyph. The way to work around this
at the moment is to first check if the face supports outlines. If it
does not then assume there is no outline.

Bug: skia:7878
Change-Id: I8f5c394f27fb2a55a359f2bdc55f957427f334bd
Reviewed-on: https://skia-review.googlesource.com/155362
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2018-09-18 19:16:02 +00:00
Cary Clark
6dcbb90025 fix conic fuzz
Avoid divide by zero in conic divide.
If the control point z value is zero, resulting
conic will have no weight, and control point value
will not affect conic; so any non-zero value will
work to avoid the zero divide.

R=kjlubick@google.com

Bug: oss-fuzz:10157
Change-Id: Ia0456ff6028559b4e1040725fea5f8bf4717e192
Reviewed-on: https://skia-review.googlesource.com/155320
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Auto-Submit: Cary Clark <caryclark@skia.org>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
2018-09-18 18:29:31 +00:00
skia-autoroll
5103aa3d74 Roll third_party/externals/angle2 95277a300f52..0fdb956d9c24 (1 commits)
95277a300f..0fdb956d9c


git log 95277a300f52..0fdb956d9c24 --date=short --no-merges --format='%ad %ae %s'
2018-09-18 jmadill@chromium.org Re-land "Inline and micro-optimize more for perf tests.""


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

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Perf-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE
TBR=reed@google.com

Change-Id: I4d53c9e1063f6827f772c9c29ceb8195c620f8db
Reviewed-on: https://skia-review.googlesource.com/155260
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-18 18:27:02 +00:00
Mike Klein
4a9631c186 Reland "implement SkPixmap::erase() with draws"
This is a reland of 42f29f1181

The original had to be reverted because of a buggy Chromium unit test,
now fixed.  I also took the opportunity to implement this with SkDraw
rather than SkCanvas.

Original change's description:
> implement SkPixmap::erase() with draws
>
> I don't want to have to maintain yet another switch on SkColorType.
>
> This should also make color management a bit clearer?
>
> Change-Id: I1508e0c30670b1987972f7eeba2dd6d23591c531
> Reviewed-on: https://skia-review.googlesource.com/154862
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

Change-Id: I6bc071e8a6025723d47f2ad5f6fb7f8fa5dccc2b
Reviewed-on: https://skia-review.googlesource.com/155240
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-09-18 17:39:00 +00:00
Robert Phillips
0790f8a471 Fix DDL reattachment of uniquely keyed proxies
This fix has three parts:
   No longer clear all proxy unique keys in DDL mode
   Handle unique keys appropriately in lazy proxy instantiation
   Handle attaching to cached surfaces for non-lazy proxies

Change-Id: I86b0422a784acaf8c5f9b67cb981b440e08352de
Reviewed-on: https://skia-review.googlesource.com/154502
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
2018-09-18 17:33:30 +00:00
Robert Phillips
869fe56c30 Revert "Suppress addition of changeListeners during DDL recording"
This should no longer be required with the addition of https://skia-review.googlesource.com/c/skia/+/154861/ (Make atomic lists list for bitmaps and paths)

Bug: skia:8324
Change-Id: I2177fe16ea8b049f36c5d3d5a17ea2c69ce42eca
Reviewed-on: https://skia-review.googlesource.com/154980
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2018-09-18 17:08:58 +00:00
Mike Klein
0191ed8e87 Make listener lists threadsafe with a mutex.
PS1 reverts commit 6c8d242b14.
PS2 uses an SkMutex for thread safety.

Change-Id: I9318f92cc028844b3dc5a99a00282c2762057895
Reviewed-on: https://skia-review.googlesource.com/155060
Reviewed-by: Mike Klein <mtklein@google.com>
2018-09-18 15:46:26 +00:00
Brian Salomon
279f873faa Fix image_from_yuv_textures with --preAbandonContext
Change-Id: Ibb2dfdf6eccb48fbd2c4a503e473170389e2ec2a
Reviewed-on: https://skia-review.googlesource.com/155169
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2018-09-18 15:42:50 +00:00
Mike Klein
1d6281d4bb Reland "implement SkPixmap::getPixel() with this->readPixels()."
This is a reland of 0944ae8afb

Original change's description:
> implement SkPixmap::getPixel() with this->readPixels().
> 
> Yet another big old switch statement I don't want to maintain.
> 
> Once again, I think this at least makes it explicit that we're
> returning an SkColor in the colorspace of the pixmap.
> 
> Change-Id: I34aa7312c0a1670910586fc5a4b1951275e73e2e
> Reviewed-on: https://skia-review.googlesource.com/154864
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

Change-Id: I07b0b11922a393072961edc7771d7a972ca1fd13
Reviewed-on: https://skia-review.googlesource.com/155166
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-09-18 15:15:37 +00:00
Florin Malita
beb8300d19 [skottie] Fix NaN |t| in CompTimeMapper::onTick
Catch infinite time scale values at construction time.

Bug: skia:8381
Change-Id: I538c5bd0a75b080856ec39b3e94e2a303bb9a289
Reviewed-on: https://skia-review.googlesource.com/155167
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Auto-Submit: Florin Malita <fmalita@chromium.org>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2018-09-18 14:59:31 +00:00
Florin Malita
217d4a556b [skottie] UBSAN divide-by-zero workaround
Use sk_ieee_float_divide to silence UBSAN.

(note: the result is already checked to be finite)

Bug: skia:10041
Change-Id: I97d1d6f84926b7162ed636be7afd052ca42d8e81
Reviewed-on: https://skia-review.googlesource.com/155165
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2018-09-18 14:28:53 +00:00
Mike Klein
afa35022d9 centralize RP loads and stores
This gets all the main places we set up loads and stores in
SkRasterPipeline.  Some tests and benches still use the old
generic append() method, and I think that's fine, and same
with some of the image codec code.

Change-Id: Ia27f106887f1a8d95d76e2366c17ab30eec504c1
Reviewed-on: https://skia-review.googlesource.com/154868
Auto-Submit: Mike Klein <mtklein@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2018-09-18 13:06:29 +00:00
Mike Klein
9ec77b5574 Revert "implement SkPixmap::erase() with draws"
This reverts commit 42f29f1181.

Reason for revert: Chrome roll?

Original change's description:
> implement SkPixmap::erase() with draws
> 
> I don't want to have to maintain yet another switch on SkColorType.
> 
> This should also make color management a bit clearer?
> 
> Change-Id: I1508e0c30670b1987972f7eeba2dd6d23591c531
> Reviewed-on: https://skia-review.googlesource.com/154862
> Commit-Queue: Mike Klein <mtklein@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

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

Change-Id: Ic05f49db7c3dd2c73a53622411e7f8d0f90773a9
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/155161
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-09-18 12:20:04 +00:00
Cary Clark
cdc371af3e fix bookmaker
add docs for new SkImage methods

Also, the tool slightly adjusted the spacing
for the include comments, and fixed a few references.

TBR=bsalomon@google.com

Docs-Preview: https://skia.org/?cl=155160
Bug: skia:
Change-Id: I7977ca3048bd7d0c23f84db19f62f7accdcd77bb
Reviewed-on: https://skia-review.googlesource.com/155160
Commit-Queue: Cary Clark <caryclark@skia.org>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Cary Clark <caryclark@skia.org>
2018-09-18 11:58:35 +00:00
skia-autoroll
f533d8a23a Roll third_party/externals/angle2 a49f60fee74d..95277a300f52 (3 commits)
a49f60fee7..95277a300f


git log a49f60fee74d..95277a300f52 --date=short --no-merges --format='%ad %ae %s'
2018-09-18 jie.a.chen@intel.com ES31: Add DispatchComputeIndirect support for D3D11
2018-09-17 courtneygo@google.com Fix AndroidManifest package name
2018-09-17 ynovikov@chromium.org Revert "Inline and micro-optimize more for perf tests."


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

The AutoRoll server is located here: https://autoroll.skia.org/r/angle-skia-autoroll

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

If the roll is causing failures, please contact the current sheriff, who should
be CC'd on the roll, and stop the roller if necessary.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia.primary:Perf-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Perf-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE;skia.primary:Test-Win10-Clang-ShuttleC-GPU-GTX960-x86_64-Debug-All-ANGLE
TBR=reed@google.com

Change-Id: I51bbc3edb3c4871628caf6268bb147dba439880c
Reviewed-on: https://skia-review.googlesource.com/155120
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2018-09-18 04:19:17 +00:00
Brian Salomon
d2fcfb5813 WEBGL_video_texture : sharing texture prototype in skia
Bug: 776222

Change-Id: I84c81bdaa6dc0b5548f116a28c6319e601effb32
Reviewed-on: https://skia-review.googlesource.com/146695
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Kenneth Russell <kbr@google.com>
2018-09-18 02:22:00 +00:00
Mike Klein
29a49bd220 Revert "implement SkPixmap::getPixel() with this->readPixels()."
This reverts commit 0944ae8afb.

Reason for revert: Chrome roll?

Original change's description:
> implement SkPixmap::getPixel() with this->readPixels().
> 
> Yet another big old switch statement I don't want to maintain.
> 
> Once again, I think this at least makes it explicit that we're
> returning an SkColor in the colorspace of the pixmap.
> 
> Change-Id: I34aa7312c0a1670910586fc5a4b1951275e73e2e
> Reviewed-on: https://skia-review.googlesource.com/154864
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

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

Change-Id: I827491cc047645876d5b7d5ac0067d266252f7ef
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/155040
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2018-09-17 23:28:56 +00:00
Mike Klein
f19e3f48b5 simplify src->dst matrix init
src->toXYZD50() and dst->fromXYZD5() always work now.

And if they've somehow got a non-3x3 matrix, fine...  we'll just handle
it wrong.  It's better to initialize the src->dst 3x3 with what we've
got and ignore the outer row and column than to leave it uninitialized
or zero or identity.

Bug: oss-fuzz:10305

Change-Id: I1904a4e297758412a1cc442e88a45b5ec2be9fb5
Reviewed-on: https://skia-review.googlesource.com/154867
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-09-17 22:59:39 +00:00
Herb Derby
6c8d242b14 Make atomic lists list for bitmaps and paths
Make the listner list for bitmas and paths use a simple atomic
stack. This stack implementation does not have the ABA problem
because you can only pop the entire stack at once
with exchange(nullptr).

BUG=skia:8324

Change-Id: I7b0438a42c473b36cd4b0cbf236bf1692c5afab3
Reviewed-on: https://skia-review.googlesource.com/154861
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2018-09-17 20:54:06 +00:00
Brian Osman
90d2d9381e Revert "Add Short4 vertex attributes, and benchmark them as 4.12 colors"
This reverts commit d2ca0473f6.

Reason for revert: Various bots failing.

Original change's description:
> Add Short4 vertex attributes, and benchmark them as 4.12 colors
> 
> This is likely our best widely portable option for encoding wide gamut
> colors that doesnt sacrifice too much performance. The benchmark uses
> them as we're likely to do: 4.12 fixed point, in the destination color
> space. We're using SINT vertex attributes for simplicity, so the encode
> and decode are simple multiply/divide by 4096.
> 
> Bug: skia:
> Change-Id: I9b544f3e187b775d81f83dc9dd44611570ad33c2
> Reviewed-on: https://skia-review.googlesource.com/155001
> Reviewed-by: Mike Klein <mtklein@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>

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

Change-Id: I921e29cf9a121c5752ec7d99a03470b5193afd4a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/154883
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2018-09-17 20:41:30 +00:00