aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/pathops
Commit message (Collapse)AuthorAge
* abort op early if path isn't parseableGravatar caryclark2014-10-03
| | | | | | | TBR= BUG=419649 Review URL: https://codereview.chromium.org/623943002
* fail on extremely large coincident curvesGravatar caryclark2014-09-29
| | | | | | | | | TBR= BUG=418381 Author: caryclark@google.com Review URL: https://codereview.chromium.org/607913007
* fail early if coincidence can't be resolvedGravatar caryclark2014-09-19
| | | | | | | | | | | | Bail out if a very large value causes coincidence resolution to fail. TBR= BUG=415866 Author: caryclark@google.com Review URL: https://codereview.chromium.org/585913002
* fix battlefield website by disallowing very small coordinatesGravatar caryclark2014-09-18
| | | | | | | | | | | also add and remove comments to document other attempts to fix this that had drawbacks R=fmalita@chromium.org BUG=414409 Author: caryclark@google.com Review URL: https://codereview.chromium.org/575553003
* fail when coincidence is too far apartGravatar caryclark2014-09-08
| | | | | | | | | TBR= BUG=410552 Author: caryclark@google.com Review URL: https://codereview.chromium.org/556433002
* add const to arrays of member functionsGravatar caryclark2014-08-25
| | | | | | | | | | | | | running 'size ./out/Release/libskia_core.a' revealed a couple of places where path ops chose poorly and declared arrays of member functions to be unnecessarily writable. R=reed@android.com TBR=reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/461363003
* copy points in array that may stretchGravatar caryclark2014-08-20
| | | | | | | | | | | | | | | | | | Description: Potential SkOpSegment::addT() use-after-free The 'pt' arg can be a reference to a point stored in the local fTs TDArray => appending may cause a realloc and leave the reference pointing to deallocated mem. Copy the points from the stretchy array before adding them. R=fmalita@google.com, fmalita@chromium.org, fmalita BUG=405417 Author: caryclark@google.com Review URL: https://codereview.chromium.org/489853002
* fix pathops skp-derived bugs; add more failing testsGravatar caryclark2014-08-12
| | | | | | | | TBR= Author: caryclark@google.com Review URL: https://codereview.chromium.org/463883002
* relax quadratic binary search testGravatar caryclark2014-08-12
| | | | | | | | | | | | | | | | Extreme implicit quartic equations solve to roots that are different enough that they appear to have failed. In this case, fall back on binary searching to find an intersection. Relax the condition when this happens; don't give up just because the computed implicit root points aren't remotely the same. TBR=reed BUG=skia:2808 Author: caryclark@google.com Review URL: https://codereview.chromium.org/456383003
* update pathops core and testsGravatar caryclark2014-07-18
| | | | | | | | | | split out skpclip (the test of 1M pictures) into its own project TBR=reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/400033002
* add pathops tight bounds; conform path ops' gyp to unit testsGravatar caryclark2014-06-24
| | | | | | | | | | | | | | | | | | Implement path tight bounds using path ops machinery. This is not as efficient as it could be; for instance, internally, it creates a path ops structure more suited to intersection. If this shows up as a performance bottleneck, it could be improved. Fix path ops gyp files, which have fallen out of sync with other tests. R=mtklein@google.com, bsalomon@google.com TBR=mtklein BUG=skia:1712 Author: caryclark@google.com Review URL: https://codereview.chromium.org/348343002
* Add some missing header include guardsGravatar george2014-06-20
| | | | | | | | | BUG=skia: R=reed@google.com, bsalomon@google.com, tfarina@chromium.org Author: george@mozilla.com Review URL: https://codereview.chromium.org/325843002
* Fix last pathops skp bugGravatar caryclark2014-06-18
| | | | | | | | | | | | | | | | | | | | | | This fixes the last bug discovered by iterating through the 800K skp corpus representing the top 1M websites. For every clip on the stack, the paths are replaced with the pathop intersection. The resulting draw is compared with the original draw for pixel errors. At least two prominent bugs remain. In one, the winding value is confused by a cubic with an inflection. In the other, a quad/cubic pair, nearly coincident, fails to find an intersection. These minor changes include ignoring very tiny self-intersections of cubics, and processing degenerate edges that don't connect to anything else. R=reed@android.com TBR=reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/340103002
* fix chromeGravatar caryclark2014-06-17
| | | | | | | | | | | | | had #if SK_DEBUG instead of #ifdef SK_DEBUG R=reed@android.com TBR=reed NOTRY=true NOTREECHECKS=true Author: caryclark@google.com Review URL: https://codereview.chromium.org/338333002
* Enabling the canvas bit to turn the clip stack into a flat replace exposed ↵Gravatar caryclark2014-06-17
| | | | | | | | | | | | | | | | | | around 100 failures when testing the 800K skp set generated from the top 1M web sites. This fixes all but one of those failures. Major changes include: - Replace angle indices with angle pointers. This was motivated by the need to add angles later but not renumber existing angles. - Aggressive segment chase. When the winding is known on a segment, more aggressively passing that winding to adjacent segments allows fragmented data sets to succeed. - Line segments with ends nearly the same are treated as coincident first. - Transfer partial coincidence by observing that if segment A is partially coincident to B and C then B and C may be partially coincident. TBR=reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/272153002
* When solving the cubic line intersection directly fails, use binary search ↵Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | as a fallback. The cubic line intersection math empirically works 99.99% of the time (fails 3100 out of 1B random tests) but when it fails, an intersection may be missed altogether. The binary search is may not find a solution if the cubic line failed to find any solutions at all, but so far that case hasn't arisen. BUG=skia:2504 TBR=reed@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/266063003 git-svn-id: http://skia.googlecode.com/svn/trunk@14614 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-05-01
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14492 2bbb7eff-a529-9590-31e7-b0007b416f81
* Rename SK_DEBUGBREAK to SK_ALWAYSBREAKGravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | | Committed: http://code.google.com/p/skia/source/detail?r=14473 R=caryclark@google.com, reed@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/263553012 git-svn-id: http://skia.googlecode.com/svn/trunk@14481 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of Rename SK_DEBUGBREAK to SK_ALWAYSBREAK ↵Gravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/263553012/) Reason for revert: Broke windows bot Original issue's description: > Rename SK_DEBUGBREAK to SK_ALWAYSBREAK > > Committed: http://code.google.com/p/skia/source/detail?r=14473 R=caryclark@google.com, reed@google.com TBR=caryclark@google.com, reed@google.com NOTREECHECKS=true NOTRY=true Author: bsalomon@google.com Review URL: https://codereview.chromium.org/260763003 git-svn-id: http://skia.googlecode.com/svn/trunk@14476 2bbb7eff-a529-9590-31e7-b0007b416f81
* Rename SK_DEBUGBREAK to SK_ALWAYSBREAKGravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | R=caryclark@google.com, reed@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/263553012 git-svn-id: http://skia.googlecode.com/svn/trunk@14473 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix cubic/line intersection; add skp testsGravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | BUG=skia:2488 TBR=reed Author: caryclark@google.com Review URL: https://codereview.chromium.org/252243003 git-svn-id: http://skia.googlecode.com/svn/trunk@14458 2bbb7eff-a529-9590-31e7-b0007b416f81
* one more tsan fixGravatar commit-bot@chromium.org2014-04-25
| | | | | | | | | | | | BUG=skia:2460 R=mtklein@google.com TBR=mtklein Author: caryclark@google.com Review URL: https://codereview.chromium.org/255893002 git-svn-id: http://skia.googlecode.com/svn/trunk@14382 2bbb7eff-a529-9590-31e7-b0007b416f81
* pathops debug globals use atomic incrementGravatar commit-bot@chromium.org2014-04-25
| | | | | | | | | | | | R=mtklein@google.com TBR=mtklein BUG=skia:2460 Author: caryclark@google.com Review URL: https://codereview.chromium.org/257773007 git-svn-id: http://skia.googlecode.com/svn/trunk@14379 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix minor skp-found bugsGravatar commit-bot@chromium.org2014-04-25
| | | | | | | | | | | | | remove globals from pathops_unittest BUG=skia:2460 TBR=mtklein Author: caryclark@google.com Review URL: https://codereview.chromium.org/239563004 git-svn-id: http://skia.googlecode.com/svn/trunk@14378 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-04-15
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14196 2bbb7eff-a529-9590-31e7-b0007b416f81
* change #if SK_DEBUG to #ifdef SK_DEBUGGravatar commit-bot@chromium.org2014-04-14
| | | | | | | | | | | | | | | | fix broken build change #if DEBUG to #ifdef DEBUG (fixes canary) NOTRY=true R=reed@google.com TBR=reed@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/237573002 git-svn-id: http://skia.googlecode.com/svn/trunk@14189 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix broken buildGravatar commit-bot@chromium.org2014-04-14
| | | | | | | | | | | | | | | change 'char' to 'int8_t' BUG=skia: NOTRY=true TBR=reed@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/237263004 git-svn-id: http://skia.googlecode.com/svn/trunk@14186 2bbb7eff-a529-9590-31e7-b0007b416f81
* Mike R: please sanity check SkPostConfig.hGravatar commit-bot@chromium.org2014-04-14
| | | | | | | | | | | | | | | | | | | | | | | | Mike K: please sanity check Test.cpp and skia_test.cpp Feel free to look at the rest, but I don't expect any in depth review of path ops innards. Path Ops first iteration used QuickSort to order segments radiating from an intersection to compute the winding rule. This revision uses a circular sort instead. Breaking out the circular sort into its own long-lived structure (SkOpAngle) allows doing less work and provides a home for caching additional sorting data. The circle sort is more stable than the former sort, has a robust ordering and fewer exceptions. It finds unsortable ordering less often. It is less reliant on the initial curve tangent, using convex hulls instead whenever it can. Additional debug validation makes sure that the computed structures are self-consistent. A new visualization tool helps verify that the angle ordering is correct. The 70+M tests pass with this change on Windows, Mac, Linux 32 and Linux 64 in debug and release. R=mtklein@google.com, reed@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/131103009 git-svn-id: http://skia.googlecode.com/svn/trunk@14183 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-02-22
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@13551 2bbb7eff-a529-9590-31e7-b0007b416f81
* Potential fix for array bounds warning.Gravatar commit-bot@chromium.org2014-02-21
| | | | | | | | | | | BUG=skia:2123 R=caryclark@google.com Author: jvanverth@google.com Review URL: https://codereview.chromium.org/164753003 git-svn-id: http://skia.googlecode.com/svn/trunk@13531 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove file added accidentallyGravatar commit-bot@chromium.org2014-01-14
| | | | | | | | | | | | TBR=reed@google.com NOTREECHECKS=true NOTRY=true Author: caryclark@google.com Review URL: https://codereview.chromium.org/131053006 git-svn-id: http://skia.googlecode.com/svn/trunk@13062 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove unused reduce order codeGravatar caryclark@google.com2013-11-25
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/85763002 git-svn-id: http://skia.googlecode.com/svn/trunk@12377 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix pathops quad line intersectionGravatar caryclark@google.com2013-11-25
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@12374 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-11-22
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@12358 2bbb7eff-a529-9590-31e7-b0007b416f81
* optimize pathops coverageGravatar commit-bot@chromium.org2013-11-21
| | | | | | | | | | | | | | | Remove unused code from SkOpSegment.cpp and friends. Add new tests exposed by coverage. Fix a bug exposed by coverage -- removing the need to detect points that are nearby when intersecting. Add gyp rule for building coverage flavor on Mac. R=mtklein@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/75453003 git-svn-id: http://skia.googlecode.com/svn/trunk@12344 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix line intersectionGravatar caryclark@google.com2013-11-08
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@12197 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix for Chromium-side compilation complaint:Gravatar robertphillips@google.com2013-11-03
| | | | | | | | src/pathops/SkIntersectionHelper.h:10:13: error: #if with no expression git-svn-id: http://skia.googlecode.com/svn/trunk@12108 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-11-02
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@12101 2bbb7eff-a529-9590-31e7-b0007b416f81
* pathops work in progressGravatar caryclark@google.com2013-11-01
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/52653002 git-svn-id: http://skia.googlecode.com/svn/trunk@12089 2bbb7eff-a529-9590-31e7-b0007b416f81
* Clean up SkTypes.h.Gravatar bungeman@google.com2013-10-11
| | | | | | | | | | | | | | | | | | | This change removes sk_stdint.h since it is only needed for vs2008 and earlier. This change removes SK_MMAP_SUPPORT define since it is no longer used. This change removes the stdio.h include from SkTypes.h since on many systems this is a very large header, few Skia files actually use it, it is available everywhere standard, and SkDebugf should be used instead. After this change there is no need for external users to put Skia's include/config into their own list of includes, saving the headache of having two header files of the same name and sometimes getting the wrong one depending on include order. R=bsalomon@google.com, djsollen@google.com Review URL: https://codereview.chromium.org/27044002 git-svn-id: http://skia.googlecode.com/svn/trunk@11738 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-10-03
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@11585 2bbb7eff-a529-9590-31e7-b0007b416f81
* path ops work in progressGravatar caryclark@google.com2013-10-02
| | | | | | | | | | | | make more skps work remove edit files BUG= Review URL: https://codereview.chromium.org/23542056 git-svn-id: http://skia.googlecode.com/svn/trunk@11570 2bbb7eff-a529-9590-31e7-b0007b416f81
* path ops work in progressGravatar caryclark@google.com2013-09-16
| | | | | | | | | | path ops work in progress BUG= Review URL: https://codereview.chromium.org/21359002 git-svn-id: http://skia.googlecode.com/svn/trunk@11291 2bbb7eff-a529-9590-31e7-b0007b416f81
* My clang now doesn't complain about !"foo".Gravatar mtklein@google.com2013-08-22
| | | | | | | | | BUG= R=robertphillips@google.com Review URL: https://codereview.chromium.org/22875037 git-svn-id: http://skia.googlecode.com/svn/trunk@10874 2bbb7eff-a529-9590-31e7-b0007b416f81
* turn off debugging printfsGravatar caryclark@google.com2013-07-23
| | | | | | | | | | | | | fix pathops issues 1417, 1418 be more rigorous about pulling intersections of lines to end points rewrite cubic/line and quad/line intersections to share style BUG= Review URL: https://codereview.chromium.org/19543005 git-svn-id: http://skia.googlecode.com/svn/trunk@10270 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix linux point compareGravatar caryclark@google.com2013-07-15
| | | | | | | | | | fix linux pt compare BUG= Review URL: https://codereview.chromium.org/19203002 git-svn-id: http://skia.googlecode.com/svn/trunk@10076 2bbb7eff-a529-9590-31e7-b0007b416f81
* path ops near exactGravatar caryclark@google.com2013-07-15
| | | | | | | | | | | | | | | | | Modify line intersections to first - match exact ends - compute intersections - match near ends where the exact ends are preferred, then near matches, then computed matches. This pulls matches towards existing end points when possible, and keeps intersection distances consistent with different line/line line/quad and line/cubic computations. BUG= Review URL: https://codereview.chromium.org/19183003 git-svn-id: http://skia.googlecode.com/svn/trunk@10073 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-07-09
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@9919 2bbb7eff-a529-9590-31e7-b0007b416f81
* path ops work in progressGravatar caryclark@google.com2013-07-08
| | | | | | | | BUG= Review URL: https://codereview.chromium.org/18058007 git-svn-id: http://skia.googlecode.com/svn/trunk@9908 2bbb7eff-a529-9590-31e7-b0007b416f81
* use else instead of else-if -- fixes 'possibly unused' warningGravatar reed@google.com2013-07-02
| | | | | | | | | BUG= R=bsalomon@google.com Review URL: https://codereview.chromium.org/18527003 git-svn-id: http://skia.googlecode.com/svn/trunk@9863 2bbb7eff-a529-9590-31e7-b0007b416f81