Commit Graph

1948 Commits

Author SHA1 Message Date
Mike Reed
75ae421c24 IWYU -- SkShader.h
Bug: skia:
Change-Id: I57bffc14c4888627a22158e35f3ac3b762138f02
Reviewed-on: https://skia-review.googlesource.com/98520
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-01-23 18:08:30 +00:00
Robert Phillips
f35fd8d2f2 Move more internal methods from GrContext to GrContextPriv (take 3)
Change-Id: Ied630e61cf95780bf85032867e6ce663e1ef9c2f
Reviewed-on: https://skia-review.googlesource.com/98000
Reviewed-by: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2018-01-22 16:53:17 +00:00
Leon Scroggins
2914555e00 Revert "Move more internal methods from GrContext to GrContextPriv (take 2)"
This reverts commit c22e50bd31.

Reason for revert: Speculative fix for Android roll

Original change's description:
> Move more internal methods from GrContext to GrContextPriv (take 2)
> 
> Change-Id: I47108910517d61edeb52f82793d384fdb5605d45
> Reviewed-on: https://skia-review.googlesource.com/97241
> Commit-Queue: Robert Phillips <robertphillips@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

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

Change-Id: I3a77ac33c5f48529357cf9c683d5f4cacaa2379f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/97582
Reviewed-by: Leon Scroggins <scroggo@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2018-01-20 17:09:10 +00:00
Robert Phillips
c22e50bd31 Move more internal methods from GrContext to GrContextPriv (take 2)
Change-Id: I47108910517d61edeb52f82793d384fdb5605d45
Reviewed-on: https://skia-review.googlesource.com/97241
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2018-01-19 19:26:46 +00:00
Hal Canary
07320e46c0 Revert "Move more internal methods from GrContext to GrContextPriv"
This reverts commit f440cecbfd.

Reason for revert: breaking android builds. 

Original change's description:
> Move more internal methods from GrContext to GrContextPriv
> 
> TBR=bsalomon@google.com
> Change-Id: Ia8cf0e0d30451c69bc7a08215aafa6abe6e0ddbe
> Reviewed-on: https://skia-review.googlesource.com/97080
> Commit-Queue: Robert Phillips <robertphillips@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>

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

Change-Id: If263f8161f0fbe3fc6ee8f34bb09e237705c3694
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/97200
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2018-01-19 18:18:24 +00:00
Robert Phillips
f440cecbfd Move more internal methods from GrContext to GrContextPriv
TBR=bsalomon@google.com
Change-Id: Ia8cf0e0d30451c69bc7a08215aafa6abe6e0ddbe
Reviewed-on: https://skia-review.googlesource.com/97080
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2018-01-19 18:03:03 +00:00
Jim Van Verth
b1b80f7de4 Remove tonal color from DrawShadow internals
Bug: b/71719631
Change-Id: I676c34dfe5ea9b5e184ea53dd49a8b835d4e8cb6
Reviewed-on: https://skia-review.googlesource.com/95741
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2018-01-19 16:32:13 +00:00
Robert Phillips
6be756b673 Move resourceProvider accessor to GrContextPriv (take 2)
TBR=bsalomon@google.com
Change-Id: I3fd46ebfad0d04b8a2bfa6190f81308f3a6be620
Reviewed-on: https://skia-review.googlesource.com/95121
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2018-01-16 20:53:28 +00:00
Hal Canary
be46e24d57 Revert "Move resourceProvider accessor to GrContextPriv"
This reverts commit 1f9ed8501b.

Reason for revert: 
 1. breaking android roll 
 2. breaking Build-Debian9-Clang-arm-Release-Android_API26



Original change's description:
> Move resourceProvider accessor to GrContextPriv
> 
> Change-Id: I5cddd620a7ec4b006b7359864ede58e9d4dd684e
> Reviewed-on: https://skia-review.googlesource.com/94340
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Reviewed-by: Greg Daniel <egdaniel@google.com>
> Commit-Queue: Robert Phillips <robertphillips@google.com>

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

Change-Id: I20b2d267c0925f20453b635663654967199a1197
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/94964
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2018-01-16 18:33:14 +00:00
Robert Phillips
1f9ed8501b Move resourceProvider accessor to GrContextPriv
Change-Id: I5cddd620a7ec4b006b7359864ede58e9d4dd684e
Reviewed-on: https://skia-review.googlesource.com/94340
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2018-01-16 17:02:45 +00:00
Brian Salomon
b5ef1f9b13 Make GrTextureOp capable of edge antialiasing.
Bug: skia:
Change-Id: I0088bdbb6a76811611fa4628656bf9513c5bf04a
Reviewed-on: https://skia-review.googlesource.com/91105
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2018-01-11 19:37:51 +00:00
Hal Canary
c5980d0aa3 SkDocument: remove unused fDoneProc
Change-Id: I9a0739992e90a0a6d44a75b0b570097553343f1d
Reviewed-on: https://skia-review.googlesource.com/92141
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2018-01-08 20:53:41 +00:00
Mike Reed
bd3a0cce99 Revert "Revert "remove unused SkCurveMeasure""
This reverts commit 4d1d8bcf6d.

Reason for revert: will try a manual roll to update static_initializers.gni

Original change's description:
> Revert "remove unused SkCurveMeasure"
> 
> This reverts commit 065c2e827e.
> 
> Reason for revert: change static initializer count?
> 
> Original change's description:
> > remove unused SkCurveMeasure
> > 
> > Bug: skia:
> > Change-Id: I36eb00883bc17e8eef4d1d226972f0125f0e2630
> > Reviewed-on: https://skia-review.googlesource.com/91702
> > Reviewed-by: Mike Reed <reed@google.com>
> > Commit-Queue: Mike Reed <reed@google.com>
> 
> TBR=reed@google.com
> 
> Change-Id: I0d8ad2aa8b38a389048ba8bf5cafafea5788c3e1
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: skia:
> Reviewed-on: https://skia-review.googlesource.com/91343
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Mike Reed <reed@google.com>

TBR=reed@google.com

Change-Id: I7e6dfc5841b089dff047cd1d78dcebb722cdf8a4
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/91361
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-01-06 18:24:57 +00:00
Mike Reed
4d1d8bcf6d Revert "remove unused SkCurveMeasure"
This reverts commit 065c2e827e.

Reason for revert: change static initializer count?

Original change's description:
> remove unused SkCurveMeasure
> 
> Bug: skia:
> Change-Id: I36eb00883bc17e8eef4d1d226972f0125f0e2630
> Reviewed-on: https://skia-review.googlesource.com/91702
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Mike Reed <reed@google.com>

TBR=reed@google.com

Change-Id: I0d8ad2aa8b38a389048ba8bf5cafafea5788c3e1
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/91343
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-01-06 13:19:26 +00:00
Mike Reed
065c2e827e remove unused SkCurveMeasure
Bug: skia:
Change-Id: I36eb00883bc17e8eef4d1d226972f0125f0e2630
Reviewed-on: https://skia-review.googlesource.com/91702
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2018-01-05 22:32:14 +00:00
Kevin Lubick
4284613cfe Enable conditional-uninitialized flag
Bug: skia:7462
Cq-Include-Trybots: skia.primary:Test-Debian9-Clang-GCE-CPU-AVX2-x86_64-Release-All-SKNX_NO_SIMD
Change-Id: I1c0a09984bf28a5c620a89af56040f018bae6310
Reviewed-on: https://skia-review.googlesource.com/90941
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
2018-01-05 18:03:25 +00:00
Hal Canary
3c36ef6be9 SkFloatToDecimal moved to src/utils
This change stages SkFloatToDecimal() for possible re-use by pdfium.

Change-Id: Iedc0c78c8a633f0b0973365d2d8b540b5443590d
Reviewed-on: https://skia-review.googlesource.com/90400
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
2018-01-03 19:59:31 +00:00
Mike Reed
7557bbbe19 Revert "remove approxbytes api from SkPicture"
This reverts commit bfc11853a8.

Bug: skia:
Change-Id: Ied4baad0496a06a52bec6965f9c97e13ebe2ab0a
Reviewed-on: https://skia-review.googlesource.com/89442
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-25 02:51:32 +00:00
Mike Reed
0a9d728851 Revert "re-add dummy printf to fix bots"
This reverts commit 1395994aa0.

Reason for revert: broke flutter

Original change's description:
> re-add dummy printf to fix bots
> 
> Bug: skia:
> Change-Id: I3184736f37481c5ac20eae1a15c17aed4f3c3e52
> Reviewed-on: https://skia-review.googlesource.com/89441
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Mike Reed <reed@google.com>

TBR=borenet@google.com,rmistry@google.com,jcgregorio@google.com,reed@google.com

Change-Id: I36b9efffe8a0c9df1970a31ffee5cb59171d967f
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/89381
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-25 00:31:01 +00:00
Florin Malita
cda4e94b0d Add a bench for comparing complex clip strategies
Clip consisting of a union of |n| circles.

Comparing mask (2x saveLayer + srcIn) vs. clipPath approaches.

MBP numbers:

! -> high variance, ? -> moderate variance
    micros   	bench
    233.05 !	clip_strategy_mask_100	gl
    207.61 !	clip_strategy_mask_10	gl
    210.41 ?	clip_strategy_mask_5	gl
    219.10 ?	clip_strategy_mask_1	gl
    115.56 ?	clip_strategy_path_100	gl
    113.29 !	clip_strategy_path_10	gl
    102.36 ?	clip_strategy_path_5	gl
      6.37 ?	clip_strategy_path_1	gl

    361.06 !	clip_strategy_mask_100	8888
    328.97 !	clip_strategy_mask_10	8888
    316.72 !	clip_strategy_mask_5	8888
    325.84 !	clip_strategy_mask_1	8888
    368.54 !	clip_strategy_path_100	8888
    306.99 !	clip_strategy_path_10	8888
    298.71 !	clip_strategy_path_5	8888
    191.00 !	clip_strategy_path_1	8888

TBR=

Change-Id: I945c12e2e35b9847af06342473e56272e2041e21
Reviewed-on: https://skia-review.googlesource.com/72521
Commit-Queue: Florin Malita <fmalita@chromium.org>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2017-12-24 17:12:42 +00:00
Mike Reed
1395994aa0 re-add dummy printf to fix bots
Bug: skia:
Change-Id: I3184736f37481c5ac20eae1a15c17aed4f3c3e52
Reviewed-on: https://skia-review.googlesource.com/89441
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-24 14:21:31 +00:00
Mike Reed
bfc11853a8 remove approxbytes api from SkPicture
Bug: skia:
Change-Id: I292bc9ab52fe8df3ce97a2ad4b06085b0332b19d
Reviewed-on: https://skia-review.googlesource.com/89440
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-24 13:40:41 +00:00
Mike Reed
47fdf6c85e add serialprocs to MultiDocument, hide redundant methods
Bug: skia:
Change-Id: I6521e93af79439bd8c1d2f5130a68492044a2ee9
Reviewed-on: https://skia-review.googlesource.com/87788
Reviewed-by: Wei Li <weili@chromium.org>
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-21 12:36:30 +00:00
Chris Dalton
040238bded Add a tools flag to suppress geometry shaders
Bug: skia:
Change-Id: I38736c5d49e3b281c2d23af3908575274ff97b5c
Reviewed-on: https://skia-review.googlesource.com/86282
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-12-19 17:26:56 +00:00
Mike Klein
f1f1162273 remove append_from_srgb()
It's now no different than append(from_srgb).

Bug: skia:7419

Change-Id: I97c59b6987f033ec2f1859db40ca3056b87b370a
Reviewed-on: https://skia-review.googlesource.com/86741
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-12-18 19:48:43 +00:00
Brian Osman
7035a8e797 Fix benches that aren't really timing what we want
Remove full clears from benches
Fix unbounded canvas modification in GM benches

Bug: skia:
Change-Id: Ie3d67282714a7b4e980aec399056c0e9df330993
Reviewed-on: https://skia-review.googlesource.com/86040
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-12-18 15:56:02 +00:00
Mike Reed
2e3f2e9b48 Revert "Revert "remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code""
This reverts commit 800f5541bb.

Reason for revert: google3 updated

Original change's description:
> Revert "remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code"
> 
> This reverts commit 7f846f273c.
> 
> Reason for revert: missed callsite in google3
> 
> Original change's description:
> > remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code
> > 
> > Bug: skia:
> > Change-Id: Ia88f3e2fdf6d5c6e5128eaefda0d68c7042ae7a2
> > Reviewed-on: https://skia-review.googlesource.com/85500
> > Commit-Queue: Mike Reed <reed@google.com>
> > Reviewed-by: Hal Canary <halcanary@google.com>
> 
> TBR=halcanary@google.com,reed@google.com
> 
> Change-Id: I232dc24831bd8d52e9cbbc7ee58177af0617574a
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: skia:
> Reviewed-on: https://skia-review.googlesource.com/85600
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Mike Reed <reed@google.com>

TBR=halcanary@google.com,reed@google.com

Change-Id: I6ccd032caf87020cba8d515ffb25d07b87267363
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/86101
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-15 20:43:10 +00:00
Mike Reed
800f5541bb Revert "remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code"
This reverts commit 7f846f273c.

Reason for revert: missed callsite in google3

Original change's description:
> remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code
> 
> Bug: skia:
> Change-Id: Ia88f3e2fdf6d5c6e5128eaefda0d68c7042ae7a2
> Reviewed-on: https://skia-review.googlesource.com/85500
> Commit-Queue: Mike Reed <reed@google.com>
> Reviewed-by: Hal Canary <halcanary@google.com>

TBR=halcanary@google.com,reed@google.com

Change-Id: I232dc24831bd8d52e9cbbc7ee58177af0617574a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/85600
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-15 05:24:09 +00:00
Mike Reed
7f846f273c remove SK_SUPPORT_LEGACY_PDF_PIXELSERIALIZER dead code
Bug: skia:
Change-Id: Ia88f3e2fdf6d5c6e5128eaefda0d68c7042ae7a2
Reviewed-on: https://skia-review.googlesource.com/85500
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Hal Canary <halcanary@google.com>
2017-12-15 04:28:07 +00:00
Mike Reed
a4daf19319 Moving extra options/parameters into PDFMetadata
Bug: skia:
Change-Id: I29aa69e5765a7f8ba05b0361912d1f5276d77de3
Reviewed-on: https://skia-review.googlesource.com/84501
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-14 21:20:27 +00:00
Brian Osman
36703d9d36 Push much of the SkColorSpace_Base interface up to SkColorSpace
Some pieces still remain, but the next step looks less mechanical,
so I wanted to land this piece independently.

Bug: skia:
Change-Id: Ie63afcfa08af2f6e4996911fa2225c43441dbfb2
Reviewed-on: https://skia-review.googlesource.com/84120
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-12-12 19:34:29 +00:00
Stan Iliev
ca8c0953e8 Implement a fast path for solid color lattice rectangle
Add a flag that hints, which lattice rectangles are solid colors.
Draw solid rectangles and 1x1 rectangles with drawRect.

Test: Measured performance of a ninepatch drawn by HWUI
Bug: b/69796044
Change-Id: Ib3b00ca608da42fa9f2d2038cc126a978421ec7c
Reviewed-on: https://skia-review.googlesource.com/79821
Commit-Queue: Stan Iliev <stani@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
2017-12-11 18:26:18 +00:00
Mike Reed
0933bc9b67 Revert "Revert "resources: remove most uses of GetResourcePath()""
This reverts commit cca2300559.

Reason for revert: think I guessed wrong about g32 -- unreverting

Original change's description:
> Revert "resources: remove most uses of GetResourcePath()"
> 
> This reverts commit 5093a539de.
> 
> Reason for revert: google3 seems broken
> 
> Original change's description:
> > resources: remove most uses of GetResourcePath()
> > 
> > Going forward, we will standardize on GetResourceAsData(), which will
> > make it easier to run tests in environments without access to the
> > filesystem.
> > 
> > Also: GetResourceAsData() complains when a resource is missing.
> > This is usually an error.
> > 
> > Change-Id: Iaf70b71b0ca5ed8cd1a5538a60ef185ae8736188
> > Reviewed-on: https://skia-review.googlesource.com/82642
> > Reviewed-by: Hal Canary <halcanary@google.com>
> > Commit-Queue: Hal Canary <halcanary@google.com>
> 
> TBR=halcanary@google.com,scroggo@google.com
> 
> Change-Id: Ic5a7c0167c995a672e6b06dc92abe00564432214
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/83001
> Reviewed-by: Mike Reed <reed@google.com>
> Commit-Queue: Mike Reed <reed@google.com>

TBR=halcanary@google.com,scroggo@google.com,reed@google.com

Change-Id: I5a46e4de61186a8a5eb9cacd3275e24e311d5a07
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/82942
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-09 01:27:50 +00:00
Mike Reed
cca2300559 Revert "resources: remove most uses of GetResourcePath()"
This reverts commit 5093a539de.

Reason for revert: google3 seems broken

Original change's description:
> resources: remove most uses of GetResourcePath()
> 
> Going forward, we will standardize on GetResourceAsData(), which will
> make it easier to run tests in environments without access to the
> filesystem.
> 
> Also: GetResourceAsData() complains when a resource is missing.
> This is usually an error.
> 
> Change-Id: Iaf70b71b0ca5ed8cd1a5538a60ef185ae8736188
> Reviewed-on: https://skia-review.googlesource.com/82642
> Reviewed-by: Hal Canary <halcanary@google.com>
> Commit-Queue: Hal Canary <halcanary@google.com>

TBR=halcanary@google.com,scroggo@google.com

Change-Id: Ic5a7c0167c995a672e6b06dc92abe00564432214
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/83001
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-12-08 21:09:19 +00:00
Hal Canary
53e5e7d4ce resources: resource identifiers don't begin with leading slash
Change-Id: I52522ffffbf0f5176ac9156cd563b41d6fdde59f
Reviewed-on: https://skia-review.googlesource.com/82940
Reviewed-by: Leon Scroggins <scroggo@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2017-12-08 20:03:18 +00:00
Hal Canary
5093a539de resources: remove most uses of GetResourcePath()
Going forward, we will standardize on GetResourceAsData(), which will
make it easier to run tests in environments without access to the
filesystem.

Also: GetResourceAsData() complains when a resource is missing.
This is usually an error.

Change-Id: Iaf70b71b0ca5ed8cd1a5538a60ef185ae8736188
Reviewed-on: https://skia-review.googlesource.com/82642
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
2017-12-08 19:30:48 +00:00
Hal Canary
c465d13e6f resources: orgainize directory.
Should make it easier to ask just for images.

Change-Id: If821743dc924c4bfbc6b2b2d29b14affde7b3afd
Reviewed-on: https://skia-review.googlesource.com/82684
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
2017-12-08 17:16:00 +00:00
Brian Salomon
20b1572912 Delete GLBench and subclasses
Bug: skia:6305
Change-Id: I3b2f2a8898f25d3dd0ec47668895dd4d00668575
Reviewed-on: https://skia-review.googlesource.com/82040
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2017-12-07 18:09:29 +00:00
Mike Klein
bbfe515474 remove ThermalManager
It throttles 1000x more than intended, and I suspect that some of the
trip points it uses to decide when to throttle make no sense.  We've
already turned it off on the Nexus 5x.

Change-Id: Idf556a83fe61ccc5f63c7bede3eecbe80087e28b
Reviewed-on: https://skia-review.googlesource.com/81303
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-12-06 21:25:29 +00:00
Yuqian Li
24e963d429 Test performance of 565 bitmap scaling
This would catch b/70172912

On Linux desktops, see the difference between 8888 and 565 using:

nanobench --config 8888 -m ^bitmap_RGB_565_scale$ ^bitmap_BGRA_8888_scale$ ^bitmap_RGB_565_scale_bilerp$ ^bitmap_BGRA_8888_scale_bilerp$

On Android, use:

nanobench --config 8888 -m ^bitmap_RGB_565_scale$ ^bitmap_RGBA_8888_scale$ ^bitmap_RGB_565_scale_bilerp$ ^bitmap_RGBA_8888_scale_bilerp$

The results are similar if nanobench is run with --config 565. So
it seems that the destination color type isn't very critical.

Bug: skia:
Change-Id: I71defda4d9e089a9a973cdb0c161773bc16e4a24
Reviewed-on: https://skia-review.googlesource.com/81141
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Yuqian Li <liyuqian@google.com>
2017-12-06 18:32:29 +00:00
Mike Reed
e45ff46a65 add benchType deserial to time deserializing pictures
Piece of the larger effort to merge readbuffer and validatingreadbuffer

Bug: skia:
Change-Id: I79305e27c4712c3b91d213d09d6c2ef24b86e671
Reviewed-on: https://skia-review.googlesource.com/81120
Commit-Queue: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
2017-12-06 16:12:09 +00:00
Brian Osman
f5beefd34d Fix shader linker errors on several GL benchmarks
These were using an obsolete shader caps bit to manaully declare their
own FP output variable. That led to two outputs (after SkSL added
sk_FragColor), which led to errors about multiple outputs being declared
(without specifying location). SkSL handles all of this, so just use
sk_FragColor directly.

Bug: skia:
Change-Id: Id38657b6bf8c63c8f80d6ae3354a1507734a209f
Reviewed-on: https://skia-review.googlesource.com/73344
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-11-17 20:52:26 +00:00
Herb Derby
35c556f33e Revert "Revert "Direct evaluation of gaussian""
This reverts commit a53d999007.

Reason for revert: Bug in SkNx_sse fixed.

Original change's description:
> Revert "Direct evaluation of gaussian"
>
> This reverts commit 5e18cdea0a.
>
> Reason for revert: ASAN
> Original change's description:
> > Direct evaluation of gaussian
> >
> > The SVG(CSS) standard allows the 3 pass algorithm for sigma >= 2. But
> > sigma < 2, the code must evaluate to the convolution. The old code used
> > an interpolation scheme between windowed filters. This code directly
> > evaluates the gaussian kernel for sigma < 2.
> >
> > This code produces cleaner results, is 25% faster, and does not use a
> > temporary memory buffer.
> >
> > Change-Id: Ibd0caa73cadd06b637f55ba7bd4fefcfe7ac73db
> > Reviewed-on: https://skia-review.googlesource.com/62540
> > Commit-Queue: Herb Derby <herb@google.com>
> > Reviewed-by: Mike Klein <mtklein@google.com>
>
> TBR=mtklein@google.com,herb@google.com
>
> Change-Id: I936077dfa659d71bc361339d98340c55545a1eb8
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/72481
> Reviewed-by: Brian Osman <brianosman@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>

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

Change-Id: I4c30e3481308a8148d40223519e286885ec6f880
Reviewed-on: https://skia-review.googlesource.com/72900
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Herb Derby <herb@google.com>
2017-11-16 22:46:09 +00:00
Brian Osman
a53d999007 Revert "Direct evaluation of gaussian"
This reverts commit 5e18cdea0a.

Reason for revert: ASAN
Original change's description:
> Direct evaluation of gaussian
> 
> The SVG(CSS) standard allows the 3 pass algorithm for sigma >= 2. But
> sigma < 2, the code must evaluate to the convolution. The old code used
> an interpolation scheme between windowed filters. This code directly
> evaluates the gaussian kernel for sigma < 2.
> 
> This code produces cleaner results, is 25% faster, and does not use a
> temporary memory buffer.
> 
> Change-Id: Ibd0caa73cadd06b637f55ba7bd4fefcfe7ac73db
> Reviewed-on: https://skia-review.googlesource.com/62540
> Commit-Queue: Herb Derby <herb@google.com>
> Reviewed-by: Mike Klein <mtklein@google.com>

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

Change-Id: I936077dfa659d71bc361339d98340c55545a1eb8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/72481
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-11-16 19:10:04 +00:00
Herbert Derby
5e18cdea0a Direct evaluation of gaussian
The SVG(CSS) standard allows the 3 pass algorithm for sigma >= 2. But
sigma < 2, the code must evaluate to the convolution. The old code used
an interpolation scheme between windowed filters. This code directly
evaluates the gaussian kernel for sigma < 2.

This code produces cleaner results, is 25% faster, and does not use a
temporary memory buffer.

Change-Id: Ibd0caa73cadd06b637f55ba7bd4fefcfe7ac73db
Reviewed-on: https://skia-review.googlesource.com/62540
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2017-11-16 18:06:22 +00:00
Chris Dalton
7c02cc7934 Add clipping options to path text bench and samples
Bug: skia:
Change-Id: I632a2fa5627ef1438d9ab451318a42d12c61b802
Reviewed-on: https://skia-review.googlesource.com/67683
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-11-07 01:51:31 +00:00
Mike Klein
03141d25cf remove SkThread, using std::thread instead
Change-Id: I871dd5eea4496e87c206b46d9eae81cb521b11ce
Reviewed-on: https://skia-review.googlesource.com/65103
Reviewed-by: Hal Canary <halcanary@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-10-30 16:45:29 +00:00
Mike Reed
7306bcd758 - add bench for pixmap orient
- reduce code size by using a draw instead of custom blits

Bug: skia:
Change-Id: I90f9fb2abf40496e771f1f725556c178d730b590
Reviewed-on: https://skia-review.googlesource.com/62860
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Reed <reed@google.com>
2017-10-25 16:56:08 +00:00
Jim Van Verth
33397f2793 Fix shader compilation error in GrInstancedArraysBench
Change-Id: Ifd87e752fe1712ab4adef6c5f5de8798ab6c4991
Reviewed-on: https://skia-review.googlesource.com/50680
Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
2017-10-23 17:46:29 +00:00
Chris Dalton
a2ac30da36 Enable CCPR for volatile paths
Enables for volatile paths and when path mask caching is disabled.

Bug: skia:
Change-Id: I644b17f2a4f77a4ddf85265f520599499c0800cf
Reviewed-on: https://skia-review.googlesource.com/60481
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-10-17 18:48:42 +00:00