290d6df49b
This brings back the 2px wide picture frame approach described in these slides: go/thin-line-aa. This has been in place when the per-edge-aa only needed to support rectangles but was scrapped when the code path was updated to support arbitrary quadrilaterals. I opted to have the GrQuadPerEdgeAA logic check for degeneracy and update what it requests for the outset. This scale factor out to a 2px wide shape makes sense in the context of anti-aliasing, but not so for the generalized inset/outset logic defined in GrQuadUtils. It would have been more efficient to implement it there, but would have locked it in to being just AA inset/outset. I also updated SkGpuDevice's drawStrokedLine to construct the quad of the line directly, and to always turn a line path into a rect, instead of restricting it based on matrix or stroked width. With this new change the quality of the fill rect is much higher under rotations and perspective compared to the hairline. See rect case: https://drive.google.com/file/d/1xwgG5heADcdXYShsDodgbuv2tbHfuBNt/view?usp=sharing Hairline case: https://drive.google.com/file/d/1duNLxiYLLJhsJ94Uc01rSxjB4ar6_Ud9/view?usp=sharing Bug: chromium:820987 Change-Id: Ibd58b89a467ad5a61c5479d11259024259f1bb47 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/329418 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Michael Ludwig <michaelludwig@google.com> |
||
---|---|---|
animations | ||
bazel | ||
bench | ||
bin | ||
build/fuchsia | ||
build_overrides | ||
client_utils/android | ||
demos.skia.org | ||
dm | ||
docker | ||
docs/examples | ||
example | ||
experimental | ||
fuzz | ||
gm | ||
gn | ||
include | ||
infra | ||
modules | ||
platform_tools | ||
resources | ||
samplecode | ||
site | ||
specs | ||
src | ||
tests | ||
third_party | ||
tools | ||
.bazelignore | ||
.clang-format | ||
.clang-tidy | ||
.gitignore | ||
.gn | ||
AUTHORS | ||
BUILD.bazel | ||
BUILD.gn | ||
codereview.settings | ||
CONTRIBUTING | ||
CQ_COMMITTERS | ||
DEPS | ||
go.mod | ||
go.sum | ||
LICENSE | ||
OWNERS | ||
PRESUBMIT.py | ||
public.bzl | ||
README | ||
README.chromium | ||
RELEASE_NOTES.txt | ||
whitespace.txt | ||
WORKSPACE.bazel |
Skia is a complete 2D graphic library for drawing Text, Geometries, and Images. See full details, and build instructions, at https://skia.org.