If skia_use_fonthost_mac is set, use SkFontMgr_mac_ct_factory.cpp on
both macOS and iOS. Previously, this was only used on macOS, causing iOS
Flutter builds to default to SkFontMgr_empty_factory.cpp on that
platform.
Patch that introduced the Flutter iOS issue:
https://skia-review.googlesource.com/c/skia/+/295437
Change-Id: If2f1e7db47a55245de6c2658ad564e79134d3e7d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297194
Commit-Queue: Chris Bracken <cbracken@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
This reverts commit dff4d584ed.
Reason for revert: breaking the google3 roll
Change-Id: I0e26c77e9bad0f48bc726d3b63a97d5aa7fa51ac
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297190
Reviewed-by: Derek Sollenberger <djsollen@google.com>
This reverts commit 907f34bfc1.
Reason for revert: speculating that this is breaking the chromium roll
Change-Id: I7283f9e9d52066be4c13aff72a948f9332977e59
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297186
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: Derek Sollenberger <djsollen@google.com>
Bug: skia:10139
Change-Id: If539b6ad3a55c157fa5761abeaf13b318047839e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296731
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
With commit 75626e4 "Regularize selection of fontmgr." the skottiekit
and convaskit compile.sh files were updated, but the wasm-skp-debugger
one was overlooked. This will lead to selection of the empty fontmgr
which cannot load fonts.
Change-Id: I8c3090866f27d42a0f1fcf74e3209298d7cb0af5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296722
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
We no longer need to maintain a vector of analytic FPs and run them in
series. (CCPR and fShader do not support chaining in this CL, so we do
need to assemble a vector of FPs at the last instant.)
Change-Id: I1f7a64cf617d577e05e1fe41c740361f702a76b0
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296861
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Change-Id: If5abcd2347871c62e03c8708705ec1041572465a
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296838
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
proposed and upcoming APIs and how they may be able to be used with
CanvasKit.
Change-Id: I085e65e7e3c58ef2cbe2ce60ddd813b2c531c890
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296752
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Convert many formatted strings to plain old strings.
Favor readability of generator over generated code since
we typically pretty print the generated code if we need
to read it.
Change-Id: I0185cd1133f09d07e8ebd8c959e0397818727611
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297057
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Because GrOvalEffect is used in GrRRectEffect, this will be useful in
followup CLs that port over GrRRectEffect to MakeResult.
Change-Id: Id1d9344af7666d79c62766adfeb920e4ac124a4e
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296596
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
GrQuadEffect and GrConicEffect were the only FPs that supported the
HairlineAA clip-edge type. These FPs have been updated to implicitly
always use HairlineAA, and other FPs no longer need to consider the
HairlineAA case.
This CL also updates the bezier-effects GM images to remove the non-
hairline test columns.
Change-Id: Ice942106344cf48480e972da4aab1c6055f9911e
Bug: skia:10393
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297019
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
When the fuzzer is used, some of the positions are so far out in the
float space, that all values become the same making empty rects.
Using joinNonEmptyArg really had no advantages.
Bug: chromium:1095625
Change-Id: I46a61e422ff7053aca2f34494a2f5f0ec7e8fc74
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297026
Commit-Queue: Herb Derby <herb@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: Herb Derby <herb@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
For instanced data this value controls how many instances to draw before
going to the next set of instance data in the buffer. For all of Skia's
uses this is 1.
Change-Id: I280ef3fbe431f5d9233657a5e5783c03b3b1cf6c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297025
Commit-Queue: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
This should fix the flaky GM results that appeared when caching was
fixed/enabled recently.
Bug: skia:10395
Change-Id: Idd35f6a57e94504d56186be3601b52728ada97e7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297018
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Change-Id: I36c748f7e91c0b9695623e60bd87b98605800159
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/297017
Commit-Queue: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Renamed all codepoints into utf16Index
Change-Id: Ie915395a56ac825637f6dbb25824cd1635a5b0a6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296438
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Plus some minor cleanup and asserts.
Bug: oss-fuzz:23395
Change-Id: I667bee2d7f21864defe2fd97df9eb4e99d69d9ca
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296451
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Tyler Denniston <tdenniston@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
This reverts commit 6fb3687413.
Reason for revert: breaking a bunch of linux builds
Change-Id: I71dd154785fb00dd20bc157d5d5daf1ee2101fc2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296996
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Change-Id: I5c1e6d8fd52ecfe628a78569b4665a64e1499fa5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296938
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Bug: skia:10139
Change-Id: I07b95233c7a7892be8b70e7b640c71ce438545f1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296803
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
This tests the case where the stroke has butt caps and its width
significantly larger than the path itself. There seems to be some
uncertainty over what should actually be drawn in some of these cases,
as evidenced by the variable results from different path renderers
here.
Change-Id: I5b62ec446bfbba73d09ddb4eac710e338bedfc6e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296114
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Change-Id: I1c9cd865c3fd37b5d4c911790713d9ca2283aeee
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296724
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Previously, all backends allowed the SkSL to be edited, and GL allowed
GLSL to be edited. Now any backend's source can be seen, and they can
all be edited (other than SPIR-V). Tested with HLSL and SPIRV. I don't
have a Mac available, but MSL should work, too.
Change-Id: Ia2a11bb5922dd49a5f25840e48384e0246a28b69
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296856
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
We were always tagging the stored shaders as SkSL, so they (naturally)
didn't compile when we loaded them.
Change-Id: I96062808751b6233c9e90b29150f66270d0dd198
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296836
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
A follow up CL will use the availability of this information - the full
list of targets of a GrRenderTask – to enable faster storage of the
lastRenderTask association for a given surface proxy in a given drawing
manager.
Bug: skia:10320
Change-Id: I3eb3276b483a7f09481774896a024172b73a4c84
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296729
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Adlai Holler <adlai@google.com>
Change-Id: Id6df54efa6d71d35b682e6910d08371fc8065c88
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296799
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Some clients already have SkTypeface objects, and forcing them to pass
these as SkData is awkward - especially since Skottie immediately turns
them into SkTypeface again.
Replace the existing loadFont() callback with loadTypeface().
(for compatibility, we try both for now, but the plan is to phase-out
loadFont)
Change-Id: Ib4c2446a96cb6a5f95581c405d0a1b4ecff7ddb2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296718
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
In order to emulate OOP-R's behavior, GM needs to pass GPU-backed resources to a DDL recorder.
This change allows GMs to create GPU resources first (in onGpuSetup w/ a direct context) and then use them in onDraw (with only a GrRecordingContext).
Change-Id: Ifa3002af73eb9926f653fb4c4bf4542c0749d658
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294336
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Currently supports SkSL & HLSL. We should see if we can safely serialize
the shader blobs returned by D3DCompile.
We can't (yet) view the HLSL in Viewer - the shader viewer/editor needs
an overhaul to support backend-specific source formats (MSL, HLSL,
disassembled SPIRV). Going to look into that in a separate CL.
Change-Id: Ife1fd1d3d724674b24793df2d86c52a9b8f7de23
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296734
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Change-Id: I42db2a887316e9e6487513c56afc730f98111a6d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296735
Commit-Queue: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Auto-Submit: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Don't sort thresholds and allow full 0..1 range
Change-Id: I228be036bb259bea53ac9885e758c9e46ced1d62
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296717
Commit-Queue: Brian Salomon <bsalomon@google.com>
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Change-Id: I8e6309b5ae794b0291ecc45267f67328a0f52829
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296716
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
This arrangement allows the backend texture to outlive the YCbCr SkImage.
Change-Id: I34939d05bf1091c8efcacb687dc1900729d4cbe5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/296478
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>