Go to file
Michael Ludwig 8098e63c9e Increase precision in barycentric_coord calculations
For quads with very large coordinates, the barycentric coordinate
calculations could be very inaccurate in 32 bit. This lead to
erroneously thinking the render target was contained within the
quad's triangles, instead of just intersecting it.

By scaling the coordinates to a more reasonable magnitude before
multiplying and subtracting the coordinate values, reasonable
accuracy is preserved w/o needing to do everything in 64 bit.

Because it produces coordinates relative to the triangle vertices,
the computed values remain the same as if the unscaled coordinates
were used with higher precision math.

This seems to prevent GM_crbug_10141204 from being misclassified as
a fullscreen clear when its large rect geometry just intersects
the device.

Bug: skia:9779, chromium:10141204
Change-Id: Ia97c2c4e288907ddbb7058d3e7ed97112143b7dc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/265977
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2020-01-23 16:04:07 +00:00
animations first cut at a checkbox 2009-10-21 19:41:10 +00:00
bench Reland "Specialize SkRectanzier to SkRectanizerSkyline" 2020-01-23 15:28:26 +00:00
bin [infra] Fix bin/try 2020-01-14 12:05:56 +00:00
build/fuchsia Add logger service. 2020-01-04 02:27:14 +00:00
build_overrides Update Dawn backend to ToT. This is about 3 months of changes. 2019-10-15 22:26:38 +00:00
dm DCI-P3 -> Display P3 in Skia 2020-01-16 21:24:16 +00:00
docker Make OUTPUT_DIRECTORY in ProdDoxyfile configurable 2019-12-18 16:46:25 +00:00
docs/examples [minor] docs/examples: cleanup 2020-01-16 17:47:15 +00:00
example Revert "Revert "switch to new filltype for SkPath"" 2019-11-26 17:43:14 +00:00
experimental Fix compilation settings for wasm debugger 2020-01-17 20:44:13 +00:00
fuzz Make it safe to include SkRuntimeEffect.h from client code 2019-12-30 21:06:56 +00:00
gm Add GM for crbug:10141204 2020-01-23 15:06:16 +00:00
gn Reland "Specialize SkRectanzier to SkRectanizerSkyline" 2020-01-23 15:28:26 +00:00
include Remove fConfig from GrSurfaceDesc. 2020-01-23 15:53:36 +00:00
infra Disable Programs test on MacBook10.1-Metal 2020-01-23 15:12:06 +00:00
modules Another attempt to aling ellipsis behavior with TxtLib 2020-01-22 22:50:53 +00:00
platform_tools Reland "GrGLMakeNativeInterface_{iOS,mac,win}: clean up" 2020-01-08 16:55:43 +00:00
resources [skottie] Add custom props rendering GM 2020-01-17 13:53:02 +00:00
samplecode Reland "Specialize SkRectanzier to SkRectanizerSkyline" 2020-01-23 15:28:26 +00:00
site Update remote access documentation for Win2019 2020-01-07 18:55:57 +00:00
specs [img-decode] Start on proposed new spec 2019-05-06 17:39:19 +00:00
src Increase precision in barycentric_coord calculations 2020-01-23 16:04:07 +00:00
tests Remove fConfig from GrSurfaceDesc. 2020-01-23 15:53:36 +00:00
third_party [canvaskit] Remove support for T1 fonts and reduce code size 2020-01-06 18:49:41 +00:00
tools Remove fConfig from GrSurfaceDesc. 2020-01-23 15:53:36 +00:00
.clang-format restore .clang-format 2019-03-21 15:52:32 +00:00
.clang-tidy add google-build-namespaces to clang-tidy checks 2018-12-12 16:33:59 +00:00
.gitignore clean up some .gitignores 2019-05-15 19:55:45 +00:00
.gn Basic standalone GN configs. 2016-07-21 12:25:45 -07:00
AUTHORS Optimize SkSL xor where one argument is constant 2019-12-20 14:50:46 +00:00
BUILD.gn extend -O1 hack to avx2 code as well 2020-01-22 22:02:59 +00:00
codereview.settings Make uploading to Gerrit the default for Skia 2016-11-09 19:07:56 +00:00
CONTRIBUTING Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
CQ_COMMITTERS Moved committer list to chrome-infra-auth and deleted it from the repo 2015-09-02 13:37:54 -07:00
DEPS Roll ../src f2517d68dfde..7afe38da7578 (473 commits) 2020-01-23 05:39:24 +00:00
go.mod Update go.skia.org/infra in go.mod/go.sum 2020-01-09 15:03:46 +00:00
go.sum Update go.skia.org/infra in go.mod/go.sum 2020-01-09 15:03:46 +00:00
LICENSE LICENSE file: clean up 2019-11-22 21:59:03 +00:00
OWNERS add OWNERS file 2017-12-01 19:50:19 +00:00
PRESUBMIT.py remove obsolete presubmit checks 2020-01-14 15:47:13 +00:00
public.bzl [skottie] Cleanup: convert shape layer adapters to new pattern 2020-01-22 20:16:36 +00:00
README Fix references to https://sites.google.com/site/skiadocs/. 2015-02-03 13:12:54 -02:00
README.chromium Update README.chromium. 2015-06-11 13:19:24 -07:00
RELEASE_NOTES.txt Make SkImageInfo::validRowBytes consider alignment 2020-01-22 16:40:34 +00:00
whitespace.txt Whitespace test 2019-05-18 13:05:29 +00:00

Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.

See full details, and build instructions, at https://skia.org.