aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkRegion_path.cpp
Commit message (Collapse)AuthorAge
* Revert "Revert "SkTypes: extract SkTo""Gravatar Hal Canary2018-06-14
| | | | | | | | | | | | | | | | This reverts commit fdcfb8b7c23fbf18f872d2c31d27978235033876. > Original change's description: > > SkTypes: extract SkTo > > > > Change-Id: I8de790d5013db2105ad885fa2683303d7c250b09 > > Reviewed-on: https://skia-review.googlesource.com/133620 > > Reviewed-by: Mike Klein <mtklein@google.com> Change-Id: Ida74fbc5c21248a724a5edbf9fae18a33bcb23aa Reviewed-on: https://skia-review.googlesource.com/134506 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* Revert "SkTypes: extract SkTo"Gravatar Hal Canary2018-06-13
| | | | | | | | | | | | | | | | | | | | | | | This reverts commit 2a2f67592602b18527bc3fd449132d420cd5b62e. Reason for revert: this appears to be what is holding up the Chrome roll. Original change's description: > SkTypes: extract SkTo > > Change-Id: I8de790d5013db2105ad885fa2683303d7c250b09 > Reviewed-on: https://skia-review.googlesource.com/133620 > Reviewed-by: Mike Klein <mtklein@google.com> TBR=mtklein@google.com,halcanary@google.com No-Presubmit: true No-Tree-Checks: true No-Try: true Change-Id: Iafd738aedfb679a23c061a51afe4b98a8d4cdfae Reviewed-on: https://skia-review.googlesource.com/134504 Reviewed-by: Hal Canary <halcanary@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* SkTypes: extract SkToGravatar Hal Canary2018-06-12
| | | | | | Change-Id: I8de790d5013db2105ad885fa2683303d7c250b09 Reviewed-on: https://skia-review.googlesource.com/133620 Reviewed-by: Mike Klein <mtklein@google.com>
* fix overflow in rgnbuilderGravatar Mike Reed2018-03-16
| | | | | | | | Bug: oss-fuzz:6956 Change-Id: I244e49d458eb78e0c6200fc3c147f0f67823f97f Reviewed-on: https://skia-review.googlesource.com/114780 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Ensure Y->X ordering when building a region from a pathGravatar Mike Reed2018-03-09
| | | | | | | | | | | | | | | | | | | | | | Our region-builder-blitter insists on being called in a Y->X sorted order, which means (for example) if it is given a rect, then next blit call must be below that rect. However, we have helpers that blit rects "through" a region, and they iterate through the region using Cliperator, which returns the minimum (mostly) number of rects inside the region -- but these are not in strict Y->X order. Hence the problem. This CL avoids this by fixing it at the source. When we are asked to build a region by drawing a path clipped to another region, we check if that clip is complex. If it is, we first regionize the path against the clip's bounds (easy), and then call a region-op to intersect that with the complex clip. Bug: skia:7491 Change-Id: Ibf0a99e5bb38e369c4b263b0b07bfc04a572de63 Reviewed-on: https://skia-review.googlesource.com/113424 Reviewed-by: Cary Clark <caryclark@google.com> Commit-Queue: Mike Reed <reed@google.com>
* handle paths with degenerate verbsGravatar Mike Reed2018-01-30
| | | | | | | | Bug: skia:7507 Change-Id: I13cedcf8a13f4ce4417ae5c19f7f74d2652724d2 Reviewed-on: https://skia-review.googlesource.com/101760 Reviewed-by: Cary Clark <caryclark@google.com> Commit-Queue: Mike Reed <reed@google.com>
* begin cleanup of malloc porting layerGravatar Mike Reed2018-01-05
| | | | | | | | | | | | | | 1. Merge some of the allocators into sk_malloc_flags by redefining a flag to mean zero-init 2. Add more private helpers to simplify our call-sites (and handle some overflow mul checks) 3. The 2-param helpers rely on the saturating SkSafeMath::Mul to pass max_size_t as the request, which should always fail. Bug:508641 Change-Id: I322f1e6ed91113467e0fdb12c91c3dad33d890c8 Reviewed-on: https://skia-review.googlesource.com/90940 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com> Reviewed-by: Stephan Altmueller <stephana@google.com>
* Mark overridden destructors with 'override' and remove 'virtual'Gravatar Brian Salomon2017-03-22
| | | | | | | | | This silences a new warning in clang 5.0 Change-Id: Ieb5b75a6ffed60107c3fd16075d2ecfd515b55e8 Reviewed-on: https://skia-review.googlesource.com/10006 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Make SkBlitter hierarchy explicit about what needs to be implemented.Gravatar herb2016-06-10
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2053823002 Review-Url: https://codereview.chromium.org/2053823002
* Style Change: NULL->nullptrGravatar halcanary2015-08-27
| | | | | | DOCS_PREVIEW= https://skia.org/?cl=1316233002 Review URL: https://codereview.chromium.org/1316233002
* Remove include of stdlib.h from SkTypes.h.Gravatar bungeman2015-08-26
| | | | | | | | | | | | | | | Unfortunately, immintrin.h (which is also included by SkTypes) includes xmmintrin.h which includes mm_malloc.h which includes stdlib.h for malloc even though, from the implementation, it is difficult to see why. Fortunately, arm_neon.h does not seem to be involved in such shenanigans, so building for Android will keep things sane. TBR=reed@google.com Doesn't change Skia API, just moves an include. Review URL: https://codereview.chromium.org/1313203003
* C++11 override should now be supported by all of {bots,Chrome,Android,Mozilla}Gravatar mtklein2015-03-25
| | | | | | | | | NOPRESUBMIT=true BUG=skia: DOCS_PREVIEW= https://skia.org/?cl=1037793002 Review URL: https://codereview.chromium.org/1037793002
* Handle paths that do not report empty, but have no edges.Gravatar reed2015-03-13
| | | | | | | | patch from issue 999963005 at patchset 1 (http://crrev.com/999963005#ps1) BUG=skia:3527 Review URL: https://codereview.chromium.org/1008883002
* Fix up all the easy virtual ... SK_OVERRIDE cases.Gravatar mtklein2015-01-09
| | | | | | | | | | | | This fixes every case where virtual and SK_OVERRIDE were on the same line, which should be the bulk of cases. We'll have to manually clean up the rest over time unless I level up in regexes. for f in (find . -type f); perl -p -i -e 's/virtual (.*)SK_OVERRIDE/\1SK_OVERRIDE/g' $f; end BUG=skia: Review URL: https://codereview.chromium.org/806653007
* Add SK_OVERRIDE to a few places that are missing it.Gravatar mtklein2014-12-15
| | | | | | | | | | This was done automatically by running clang-modernize -add-override -override-macros. It's not clear to me whether include/ is already clean or I just can't get the tool to work for headers. BUG=skia: Review URL: https://codereview.chromium.org/808463002
* speed up rgn building by inlining memcmp for 32bit valuesGravatar reed2014-06-20
| | | | | | | | | | | | | | on mac/clang, using circularclips gm/bench - before: 400ms - after: 250ms BUG=skia: R=tomhudson@chromium.org, mtklein@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/348143002
* Possibly uninitialized SkRgnBuilder fStorage.Gravatar commit-bot@chromium.org2013-12-30
| | | | | | | | | | | | | | fStorage needs to be initialized regardless of SkRgnBuilder::init()'s outcome - otherwise the destructor can end up freeing garbage. BUG=330293 R=reed@google.com, fmalita@google.com Author: fmalita@chromium.org Review URL: https://codereview.chromium.org/122313002 git-svn-id: http://skia.googlecode.com/svn/trunk@12846 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Revert of https://codereview.chromium.org/113823003/"Gravatar reed@google.com2013-12-30
| | | | | | | | | | This reverts commit 68b4b32066ea0ba9dbb5d326a836f8a54297b7aa. BUG= Review URL: https://codereview.chromium.org/122293002 git-svn-id: http://skia.googlecode.com/svn/trunk@12842 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of https://codereview.chromium.org/113823003/Gravatar commit-bot@chromium.org2013-12-30
| | | | | | | | | | | | | | | | Reason for revert: need to update callsites in linux codecs R=robertphillips@google.com TBR=robertphillips@google.com NOTREECHECKS=true NOTRY=true BUG= Author: reed@google.com Review URL: https://codereview.chromium.org/122283002 git-svn-id: http://skia.googlecode.com/svn/trunk@12841 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove Sk64 from public API, and start to remove usage internallyGravatar reed@google.com2013-12-30
| | | | | | | | | BUG= R=robertphillips@google.com Review URL: https://codereview.chromium.org/113823003 git-svn-id: http://skia.googlecode.com/svn/trunk@12840 2bbb7eff-a529-9590-31e7-b0007b416f81
* deprecate SkScalarRound (and its ilk), use SkScalarRound[ToInt,ToScalar]. ↵Gravatar reed@google.com2013-12-17
| | | | | | | | | | | #define SK_SUPPORT_DEPRECATED_SCALARROUND for legacy clients BUG= R=robertphillips@google.com Review URL: https://codereview.chromium.org/111353003 git-svn-id: http://skia.googlecode.com/svn/trunk@12719 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2013-10-16
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@11800 2bbb7eff-a529-9590-31e7-b0007b416f81
* account for inverse-paths when we prealloc storage in the rgn-builderGravatar reed@google.com2013-10-15
| | | | | | | | | | | test inversepath->rgn BUG= R=caryclark@google.com Review URL: https://codereview.chromium.org/27222005 git-svn-id: http://skia.googlecode.com/svn/trunk@11776 2bbb7eff-a529-9590-31e7-b0007b416f81
* bump picture version since SkPath has changed (conics)Gravatar reed@google.com2013-05-31
| | | | | | enable conics in SkPath git-svn-id: http://skia.googlecode.com/svn/trunk@9370 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "add asserts to point<-->verb helpers"Gravatar reed@google.com2013-05-30
| | | | | | This reverts commit b4775ac7b55802e87231768f002e4b42f233b0aa. git-svn-id: http://skia.googlecode.com/svn/trunk@9347 2bbb7eff-a529-9590-31e7-b0007b416f81
* add asserts to point<-->verb helpersGravatar reed@google.com2013-05-30
| | | | | | | | | | patch from issue 16153005 BUG= Review URL: https://codereview.chromium.org/16195004 git-svn-id: http://skia.googlecode.com/svn/trunk@9344 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-01-26
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@7406 2bbb7eff-a529-9590-31e7-b0007b416f81
* Result of running tools/sanitize_source_files.py (which was added in ↵Gravatar rmistry@google.com2012-08-23
| | | | | | | | | https://codereview.appspot.com/6465078/) This CL is part I of IV (I broke down the 1280 files into 4 CLs). Review URL: https://codereview.appspot.com/6485054 git-svn-id: http://skia.googlecode.com/svn/trunk@5262 2bbb7eff-a529-9590-31e7-b0007b416f81
* Iter::next takes a bool (defaults to true for now) if we want to consume ↵Gravatar reed@google.com2012-05-16
| | | | | | | | | | degenerates. path-filling and stroking pass false, as they already are written to handle small segments (and it makes next() run 2x faster if you pass false). Review URL: https://codereview.appspot.com/6214049 git-svn-id: http://skia.googlecode.com/svn/trunk@3974 2bbb7eff-a529-9590-31e7-b0007b416f81
* Just use std qsortGravatar reed@google.com2012-05-07
| | | | | | Review URL: https://codereview.appspot.com/6195052 git-svn-id: http://skia.googlecode.com/svn/trunk@3846 2bbb7eff-a529-9590-31e7-b0007b416f81
* store x-interval-count per scanline, so we can skip lines in O(1)Gravatar reed@google.com2012-05-02
| | | | | | Review URL: https://codereview.appspot.com/6147043 git-svn-id: http://skia.googlecode.com/svn/trunk@3825 2bbb7eff-a529-9590-31e7-b0007b416f81
* record yspancount and intervalcount in regionsGravatar reed@google.com2012-05-01
| | | | | | Review URL: https://codereview.appspot.com/6132055 git-svn-id: http://skia.googlecode.com/svn/trunk@3808 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update header comments to more accurately describe behavior ofGravatar tomhudson@google.com2012-01-03
| | | | | | | | | | SkRegion::getBoundaryPath(). Add SkASSERT of SkPath argument for safety. codereview.appspot.com/5504095/ git-svn-id: http://skia.googlecode.com/svn/trunk@2942 2bbb7eff-a529-9590-31e7-b0007b416f81
* Automatic update of all copyright notices to reflect new license terms.Gravatar epoger@google.com2011-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I have manually examined all of these diffs and restored a few files that seem to require manual adjustment. The following files still need to be modified manually, in a separate CL: android_sample/SampleApp/AndroidManifest.xml android_sample/SampleApp/res/layout/layout.xml android_sample/SampleApp/res/menu/sample.xml android_sample/SampleApp/res/values/strings.xml android_sample/SampleApp/src/com/skia/sampleapp/SampleApp.java android_sample/SampleApp/src/com/skia/sampleapp/SampleView.java experimental/CiCarbonSampleMain.c experimental/CocoaDebugger/main.m experimental/FileReaderApp/main.m experimental/SimpleCocoaApp/main.m experimental/iOSSampleApp/Shared/SkAlertPrompt.h experimental/iOSSampleApp/Shared/SkAlertPrompt.m experimental/iOSSampleApp/SkiOSSampleApp-Base.xcconfig experimental/iOSSampleApp/SkiOSSampleApp-Debug.xcconfig experimental/iOSSampleApp/SkiOSSampleApp-Release.xcconfig gpu/src/android/GrGLDefaultInterface_android.cpp gyp/common.gypi gyp_skia include/ports/SkHarfBuzzFont.h include/views/SkOSWindow_wxwidgets.h make.bat make.py src/opts/memset.arm.S src/opts/memset16_neon.S src/opts/memset32_neon.S src/opts/opts_check_arm.cpp src/ports/SkDebug_brew.cpp src/ports/SkMemory_brew.cpp src/ports/SkOSFile_brew.cpp src/ports/SkXMLParser_empty.cpp src/utils/ios/SkImageDecoder_iOS.mm src/utils/ios/SkOSFile_iOS.mm src/utils/ios/SkStream_NSData.mm tests/FillPathTest.cpp Review URL: http://codereview.appspot.com/4816058 git-svn-id: http://skia.googlecode.com/svn/trunk@1982 2bbb7eff-a529-9590-31e7-b0007b416f81
* grab from latest androidGravatar reed@android.com2008-12-17
git-svn-id: http://skia.googlecode.com/svn/trunk@27 2bbb7eff-a529-9590-31e7-b0007b416f81