This also updates create_test_font so that it can be built, compiles,
and uses SkFontStyle instead of SkTypeface::Style.
BUG=b/63669723
Change-Id: I6eb0f851853f4721cf8e5052255b5b6750c3257f
Reviewed-on: https://skia-review.googlesource.com/24740
Reviewed-by: Cary Clark <caryclark@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Ben Wagner <bungeman@google.com>
All these std::function instantiations fill the object files up with
almost 1MB of boilerplate generated code. I think we can do better by
implementing GrGLFunction as its own std::function-like type with much
less overhead, bringing the total object file size down to about 200K.
This reduces DM from 28780344 to 27726144 on my Mac, a touch above 1MB.
Change-Id: I219a86737d1dfb8b68e4eb47b51a8a98b18ff282
Reviewed-on: https://skia-review.googlesource.com/20551
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Bug: skia:
Change-Id: I4d0bdb9d954e49b79ace0552d7b74b36a512c00d
Reviewed-on: https://skia-review.googlesource.com/25642
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
For now, not adding writePixels to surface, since it appears we may not
be able to remove writePixels from canvas :(
Bug: skia:3216
Change-Id: I64ccebb31effacffe615ae4537fb46a161a6768d
Reviewed-on: https://skia-review.googlesource.com/25562
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Mike Reed <reed@google.com>
This reverts commit 467022b186.
Reason for revert: GrAHardwareBufferImageGenerator.cpp
Original change's description:
> Reduce dependence on GrSurface's origin field
>
> Unfortunately, GrGPU and its ilk are still using the GrSurface's origin a lot. I will clean that up in a second CL.
>
> Change-Id: Iba729440ce8ea8d24bb7f4e5de55ed576a0f176d
> Reviewed-on: https://skia-review.googlesource.com/24700
> Commit-Queue: Robert Phillips <robertphillips@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
TBR=bsalomon@google.com,robertphillips@google.com
Change-Id: I1b3f5c3b82d250ac164beb1d5c83abb6c3c6ab3b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/25620
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Unfortunately, GrGPU and its ilk are still using the GrSurface's origin a lot. I will clean that up in a second CL.
Change-Id: Iba729440ce8ea8d24bb7f4e5de55ed576a0f176d
Reviewed-on: https://skia-review.googlesource.com/24700
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Also tried to clean up the comments to be clearer.
Re-land of: https://skia-review.googlesource.com/25364, with some
macros that are used by Flutter restored.
Change-Id: I648815c275dfea2ec83a382a633af8d9f7780512
Reviewed-on: https://skia-review.googlesource.com/25561
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
We no longer do piecemeal analysis. This simplifies the change to make FPs have unique ownership.
Change-Id: I4e6b2c23b4277b612dedfc466cee74630a30e997
Reviewed-on: https://skia-review.googlesource.com/25362
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
This reverts commit 5a5207ae67.
Reason for revert: suspect this is the reason for Google3 roll failure.
First color mismatch. Expected ff0006f9, got ff0004fb
Expected output mismatch apps/cereal/skia_expected/radialGradient.png (3392 pixels)
Original change's description:
> Always use raster pipeline for radial gradients
>
> Change-Id: Id4c9ed45c28becf0e25ed9ff1b3380c7ca65aa4b
> Reviewed-on: https://skia-review.googlesource.com/25363
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> Commit-Queue: Florin Malita <fmalita@chromium.org>
TBR=mtklein@chromium.org,mtklein@google.com,fmalita@chromium.org,reed@google.com
Change-Id: I382a22f354d3c0a1465bd9c1555f226b0f1abb58
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/25441
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Testing notes:
$ out/dm --src colorImage --colorImages skimage/colorspace --config srgb 8888 f16
All images identical on Trashcan.
Had to revert before because of crashes on iOS, and image diffs
(32-bit ARM?).
Change-Id: Ic182c0f98b1a846a351499aa53293186bb55f2ad
Original: https://skia-review.googlesource.com/c/19744/
Reviewed-on: https://skia-review.googlesource.com/20680
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This reverts commit fd52317bf6.
Reason for revert:
../../flutter/shell/common/skia_event_tracer_impl.cc:34:12: error: use of undeclared identifier 'TRACE_EVENT_PHASE_BEGIN'
case TRACE_EVENT_PHASE_BEGIN:
:(
Original change's description:
> Delete more event tracing macros
>
> Also tried to clean up the comments to be clearer.
>
> Bug: skia:
> Change-Id: I9762564a7f59bbfbd6a43afe902596d25ff1d523
> Reviewed-on: https://skia-review.googlesource.com/25364
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> Commit-Queue: Brian Osman <brianosman@google.com>
TBR=mtklein@chromium.org,brianosman@google.com
Change-Id: I3869991b8aa3d0d67d12fbe76a207a1167801a63
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/25440
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Also tried to clean up the comments to be clearer.
Bug: skia:
Change-Id: I9762564a7f59bbfbd6a43afe902596d25ff1d523
Reviewed-on: https://skia-review.googlesource.com/25364
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
Now that we can natively do 2D blits, it's time to invert the blitH() /
blitRect() who-implements-whom relationship. blitRect() is our more
fundamental blit.
Change-Id: Ia0ae4a3cd75c7bbfc7bd5b08ff429193ce09a73b
Reviewed-on: https://skia-review.googlesource.com/25361
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Also removes a reference to GrBackendTextureDesc in a comment and updates markdown docs.
Docs-Preview: https://skia.org/?cl=24861
Bug: skia:
Change-Id: Ic6490d5ef46953450e6dee69271397bb2b94d0d6
Reviewed-on: https://skia-review.googlesource.com/24861
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Change-Id: Ia50661a8391da526d509adbe2d7203866c140b1c
Reviewed-on: https://skia-review.googlesource.com/25321
Reviewed-by: Mike Klein <mtklein@chromium.org>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
Not yet thread safe (so it forces threading off).
Builds JSON on the fly, so overhead is certainly bad.
Plan to fix all of that, but this at least "works".
There is now one tracing flag: 'trace'.
- 'debugf' installs the SkDebugf tracer.
- 'atrace' installs the Android ATrace tracer.
- Any other value is interpreted as a filename, and
produces a JSON file for chrome://tracing.
All three modes work in DM, nanobench, and Viewer.
Bug: skia:
Change-Id: I3fbc22382b99418a508c670be2770195c0a1c364
Reviewed-on: https://skia-review.googlesource.com/24781
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
[√] convert all stages to use SkJumper_MemoryCtx / be 2d-compatible
[√] convert compile to 2d also, remove 1d run/compile
[√] convert all call sites
[√] no diffs
Change-Id: I3b806eb8fe0c3ec043359616409f7cd1211a1e43
Reviewed-on: https://skia-review.googlesource.com/24263
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
(reland of https://skia-review.googlesource.com/c/24283/)
The legacy clamp specialization is still faster, but for repeat and
mirror RP wins (at low color stop counts).
Change-Id: I97a77188e912239f31e94600021b469ce7c40797
Reviewed-on: https://skia-review.googlesource.com/24742
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Florin Malita <fmalita@chromium.org>
Bug: skia:6870
Change-Id: Idd9a27518c1123c0a729b4d07461047f5530aae3
Reviewed-on: https://skia-review.googlesource.com/24960
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
This should avoid use of x18.
BUG=skia:6873
Change-Id: Iffafe0a48784b03942325517a999ad9bb44c1f99
Reviewed-on: https://skia-review.googlesource.com/25180
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Bug: skia:
Change-Id: Ief012869b740bbfb947a77c91c4478a851f2517e
Reviewed-on: https://skia-review.googlesource.com/25062
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
This is mostly dead code.
In order to make it truly dead, we need to opt drawing unpremul images
into SkRasterPipelineBlitter. They had been handled by
SkLinearBitmapPipeline, but can't be draw by SkBitmapProcLegacyShader.
Drawing unpremul images is tested by the GM all_variants_8888, which
gave us trouble last time around (serialize-8888 drew right, 8888 wrong)
but now draws fine. I think this was probably also the root of the
revert, drawing some unpremul image in Chrome's tests somewhere.
Change-Id: I453f9df44ade807316935921cbae82961e2f08aa
Reviewed-on: https://skia-review.googlesource.com/24862
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Bug: skia:6856
Change-Id: Iaaad2c22988cf8058304b7396c7d24eacd2f3edb
Reviewed-on: https://skia-review.googlesource.com/24745
Reviewed-by: Mike Klein <mtklein@chromium.org>
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Derek Sollenberger <djsollen@google.com>
- Handle alpha-only images with maskfilters
- No longer apply color-filter to alpha-only images (it should apply
to the paint color/shader composed with the alpha image instead).
- Alpha-only images without maskfilters do sub-pixel clipping.
- Non-alpha-only drawImages with maskfilters do sub-pixel clipping.
* Fixes `alpha_image` GM (output now matches GPU backend).
* Improves GMs `imagemasksubset` and `shadows`.
BUG=skia:6735
Change-Id: I62a82b4133ae0eb42d6315785bc3d2cb834bd352
Reviewed-on: https://skia-review.googlesource.com/24820
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Hal Canary <halcanary@google.com>
d17f6584df dropped flags and sampleCount,
and GrBackendTextureFlags itself. Drop these here to fix the Android
build.
Change-Id: I44e65b8eba79d8d2a9db9f64b2323f2ba006a8eb
Reviewed-on: https://skia-review.googlesource.com/24866
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>