aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/convex_all_line_paths.cpp
Commit message (Collapse)AuthorAge
* Add ear-clipping code to triangulate simple polygons.Gravatar Jim Van Verth2018-06-29
| | | | | | | | | | Use this to fill concave shadows. Bug: skia:7971 Change-Id: I63dc1ed845f9fa3fcd86f1ad13b03da23cae0313 Reviewed-on: https://skia-review.googlesource.com/135200 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Add SkOffsetSimplePolygon.Gravatar Jim Van Verth2018-04-03
| | | | | | | | | | | Performs inset and outset operations on simple polygons and returns a simple polygon, if possible. Bug: skia: Change-Id: I6d468174ad70b5279b736c532e19cbb84ff9f955 Reviewed-on: https://skia-review.googlesource.com/116483 Commit-Queue: Jim Van Verth <jvanverth@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Rename SkInsetConvexPolygon to SkOffsetPolygon.Gravatar Jim Van Verth2018-03-28
| | | | | | | | | Prep for adding new offset routines. Change-Id: I261c22d9998e5ae4567b697c5f20a31f20777ac1 Reviewed-on: https://skia-review.googlesource.com/116800 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Jim Van Verth <jvanverth@google.com>
* Revert "Revert "Create new inset algorithm for spot shadows""Gravatar Brian Salomon2017-03-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit e7c85c45c4c0a97adc6711bb12ecacc36af4ba11. Reason for revert: <INSERT REASONING HERE> Original change's description: > Revert "Create new inset algorithm for spot shadows" > > This reverts commit e5f5bf5175e426ebb6aa234f4387831c898f20ad. > > Reason for revert: Breaking a bunch of bots. e.g: > > https://luci-milo.appspot.com/swarming/task/3519cae0a03c7b10/steps/dm/0/stdout > > Original change's description: > > Create new inset algorithm for spot shadows > > > > BUG=skia: > > > > Change-Id: If7c67c2a5b9beea28f86d13362a5156b46394d0e > > Reviewed-on: https://skia-review.googlesource.com/9875 > > Commit-Queue: Ravi Mistry <rmistry@google.com> > > Reviewed-by: Brian Salomon <bsalomon@google.com> > > Reviewed-by: Robert Phillips <robertphillips@google.com> > > > > TBR=jvanverth@google.com,bsalomon@google.com,rmistry@google.com,robertphillips@google.com,msarett@google.com,reviews@skia.org > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Change-Id: I3d119ff631dbb1a41f873b9c8753d542ec91254e > Reviewed-on: https://skia-review.googlesource.com/10112 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Brian Salomon <bsalomon@google.com> > TBR=jvanverth@google.com,bsalomon@google.com,rmistry@google.com,msarett@google.com,robertphillips@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Change-Id: Ib3998300606d3a2e2fb3a14b2088cfad48363501 Reviewed-on: https://skia-review.googlesource.com/10113 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Revert "Create new inset algorithm for spot shadows"Gravatar Brian Salomon2017-03-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit e5f5bf5175e426ebb6aa234f4387831c898f20ad. Reason for revert: Breaking a bunch of bots. e.g: https://luci-milo.appspot.com/swarming/task/3519cae0a03c7b10/steps/dm/0/stdout Original change's description: > Create new inset algorithm for spot shadows > > BUG=skia: > > Change-Id: If7c67c2a5b9beea28f86d13362a5156b46394d0e > Reviewed-on: https://skia-review.googlesource.com/9875 > Commit-Queue: Ravi Mistry <rmistry@google.com> > Reviewed-by: Brian Salomon <bsalomon@google.com> > Reviewed-by: Robert Phillips <robertphillips@google.com> > TBR=jvanverth@google.com,bsalomon@google.com,rmistry@google.com,robertphillips@google.com,msarett@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Change-Id: I3d119ff631dbb1a41f873b9c8753d542ec91254e Reviewed-on: https://skia-review.googlesource.com/10112 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* Create new inset algorithm for spot shadowsGravatar Jim Van Verth2017-03-24
| | | | | | | | | | BUG=skia: Change-Id: If7c67c2a5b9beea28f86d13362a5156b46394d0e Reviewed-on: https://skia-review.googlesource.com/9875 Commit-Queue: Ravi Mistry <rmistry@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Reviewed-by: Robert Phillips <robertphillips@google.com>
* Remove SkAutoTDeleteArrayGravatar Ben Wagner2016-11-02
| | | | | | | | | | | | This class is already just an alias for std::unique_ptr<T[]>, so replace all uses with that and delete the class. CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-ASAN-Trybot,Test-Ubuntu-Clang-Golo-GPU-GT610-x86_64-Debug-ASAN-Trybot Change-Id: I40668d398356a22da071ee791666c7f728b59266 Reviewed-on: https://skia-review.googlesource.com/4362 Reviewed-by: Mike Reed <reed@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Replace a lot of 'static const' with 'constexpr' or 'const'.Gravatar mtklein2016-09-01
| | | | | | | | | | | | | | | | | | | | | | | 'static const' means, there must be at most one of these, and initialize it at compile time if possible or runtime if necessary. This leads to unexpected code execution, and TSAN* will complain about races on the guard variables. Generally 'constexpr' or 'const' are better choices. Neither can cause races: they're either intialized at compile time (constexpr) or intialized each time independently (const). This CL prefers constexpr where possible, and uses const where not. It even prefers constexpr over const where they don't make a difference... I want to have lots of examples of constexpr for people to see and mimic. The scoped-to-class static has nothing to do with any of this, and is not changed. * Not yet on the bots, which use an older TSAN. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2300623005 Review-Url: https://codereview.chromium.org/2300623005
* Ignore fill when stroke & filling convex line-only pathsGravatar robertphillips2016-08-26
| | | | | | | | | | | | | | | | | | This seems to work well for miter and bevel joins with the resulting stroke and fill path remaining convex. There seems to be an issue with round joins where the outer generated shell is usually not convex. Without this CL the resulting stroke & filled paths are always concave. Perf-wise (on Windows): convex-lineonly-paths-stroke-and-fill bench (in ms) w/o w/CL %decrease 8888 2.88 2.01 30.2 gpu 4.4 1.38 68.6 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2275243003 Review-Url: https://codereview.chromium.org/2275243003
* Style bikeshed - remove extraneous whitespaceGravatar halcanary2016-03-29
| | | | | | GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1842753002 Review URL: https://codereview.chromium.org/1842753002
* Style Change: NULL->nullptrGravatar halcanary2015-08-27
| | | | | | DOCS_PREVIEW= https://skia.org/?cl=1316233002 Review URL: https://codereview.chromium.org/1316233002
* Style Change: SkNEW->new; SkDELETE->deleteGravatar halcanary2015-08-26
| | | | | | DOCS_PREVIEW= https://skia.org/?cl=1316123003 Review URL: https://codereview.chromium.org/1316123003
* Use static_assert instead of SK_COMPILE_ASSERT.Gravatar bungeman2015-08-20
| | | | | | | Now that static_assert is allowed, there is no need to use a non- standard compile time assertion Review URL: https://codereview.chromium.org/1306443004
* SkPath::Direction serves two masters:Gravatar reed2015-06-10
| | | | | | | | | | | | | - input param to addFoo (e.g. addRect), where only CW or CCW are valid) - output param from computing functions, that sometimes return kUnknown This CL's intent is to split these into distinct enums/features: - Direction (public) loses kUnknown, and is only used for input - FirstDirection (private) is used for computing the first direction we see when analyzing a contour BUG=skia: Review URL: https://codereview.chromium.org/1176953002
* Fix convex-lineonly-paths GM so it plays nice with SampleAppGravatar robertphillips2015-05-08
| | | | Review URL: https://codereview.chromium.org/1131273002
* Fix memory deletion error in "convex-lineonly-paths" GMGravatar robertphillips2015-04-28
| | | | | | TBR=humper@google.com Review URL: https://codereview.chromium.org/1110153002
* Add new GM/bench for line-only convex pathsGravatar robertphillips2015-04-28
BUG=472723 Review URL: https://codereview.chromium.org/1112603002