aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/emptypath.cpp
Commit message (Collapse)AuthorAge
* add drawString helper to canvasGravatar Cary Clark2017-04-28
| | | | | | | | | | | | | | | | | | Many tests and examples use drawText with a guess of how long the text is in bytes, or a call to strlen(). Add a helper to SkCanvas to simplify these examples. Add another helper for SkString. R=reed@google.com Change-Id: I0204a31e938f065606f08ee7cd9a6b36db791ee2 Reviewed-on: https://skia-review.googlesource.com/13642 Commit-Queue: Cary Clark <caryclark@google.com> Reviewed-by: Cary Clark <caryclark@google.com> Reviewed-by: Mike Reed <reed@google.com> Reviewed-by: Cary Clark <caryclark@skia.org>
* GM: some header cleanupGravatar Mike Klein2017-03-22
| | | | | | | | | | | | | | gm.h includes sk_tool_utils.h but does not use it. The bulk of this CL makes each gm that uses sk_tool_utils include it. sk_tool_utils.h also provided SkRandom and SkTDArray, so a couple GMs add those headers too. Change-Id: Ieb2a7c542f0ca89c3223f744fc11b0ff37af36c1 Reviewed-on: https://skia-review.googlesource.com/10014 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Herb Derby <herb@google.com>
* 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
* 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
* Bot fixGravatar msarett2015-09-04
| | | | | | | | | https://codereview.chromium.org/1311503008 https://uberchromegw.corp.google.com/i/client.skia/builders/Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Coverage/builds/1083/steps/build%20dm/logs/stdio BUG=skia: Review URL: https://codereview.chromium.org/1331463004
* draw 3 moveTos followed by various others [moves, lines, closes]Gravatar reed2015-09-04
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1311503008
* IWYU: 'core' target, files starting A-C.Gravatar bungeman2015-08-05
| | | | | | | | | TBR=reed@google.com Verbal lgtm, does not change API. Committed: https://skia.googlesource.com/skia/+/7403d87db8e43d4c2b5b25ac22a0ebc22bd09d69 Review URL: https://codereview.chromium.org/1265033002
* Revert of IWYU: 'core' target, files starting A-C. (patchset #5 id:80001 of ↵Gravatar reed2015-08-04
| | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1265033002/ ) Reason for revert: revert to unblock DEPS roll ../../chrome/browser/chromeos/display/overscan_calibrator.cc:43:10: error: variable has incomplete type 'SkPath' SkPath base_path; Original issue's description: > IWYU: 'core' target, files starting A-C. > > TBR=reed@google.com > Verbal lgtm, does not change API. > > Committed: https://skia.googlesource.com/skia/+/7403d87db8e43d4c2b5b25ac22a0ebc22bd09d69 TBR=reed@google.com,mtklein@google.com,bungeman@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1273613002
* IWYU: 'core' target, files starting A-C.Gravatar bungeman2015-08-04
| | | | | | | TBR=reed@google.com Verbal lgtm, does not change API. Review URL: https://codereview.chromium.org/1265033002
* rename portable_typeface_always to portable_typefaceGravatar caryclark2015-07-24
| | | | | | TBR=reed@google.com Review URL: https://codereview.chromium.org/1257773002
* Revert of Revert of make gm background colors 565 compatible (patchset #1 ↵Gravatar caryclark2015-06-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | id:1 of https://codereview.chromium.org/1184123002/) Reason for revert: underlying problem with portable refs deleted more than once fixed Original issue's description: > Revert of make gm background colors 565 compatible (patchset #2 id:20001 of https://codereview.chromium.org/1176243006/) > > Reason for revert: > breaks many bots with refcnt error > > Original issue's description: > > make gm background colors 565 compatible > > > > Change a batch of GM tests to convert their background color > > so that it is representable in 8888 and 565. > > > > Enable portable text in those same tests to minimize platform > > differences. > > > > In a couple of bitmap tests, use portable typefaces instead of > > choosing 'Times' which may or may not be available on the platform. > > > > R=borenet@google.com > > > > Committed: https://skia.googlesource.com/skia/+/be7f768a357aefb39c42d24b81b24d647bb6ab70 > > TBR=borenet@google.com > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > > Committed: https://skia.googlesource.com/skia/+/0bdb08b1ba8fbd18c4838f86a23f1ef4b3a3bfdf TBR=borenet@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1182403003
* Revert of make gm background colors 565 compatible (patchset #2 id:20001 of ↵Gravatar caryclark2015-06-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1176243006/) Reason for revert: breaks many bots with refcnt error Original issue's description: > make gm background colors 565 compatible > > Change a batch of GM tests to convert their background color > so that it is representable in 8888 and 565. > > Enable portable text in those same tests to minimize platform > differences. > > In a couple of bitmap tests, use portable typefaces instead of > choosing 'Times' which may or may not be available on the platform. > > R=borenet@google.com > > Committed: https://skia.googlesource.com/skia/+/be7f768a357aefb39c42d24b81b24d647bb6ab70 TBR=borenet@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1184123002
* make gm background colors 565 compatibleGravatar caryclark2015-06-15
| | | | | | | | | | | | | | | Change a batch of GM tests to convert their background color so that it is representable in 8888 and 565. Enable portable text in those same tests to minimize platform differences. In a couple of bitmap tests, use portable typefaces instead of choosing 'Times' which may or may not be available on the platform. R=borenet@google.com Review URL: https://codereview.chromium.org/1176243006
* remove lcdGravatar caryclark2015-06-12
| | | | | | TBR=djsollen@google.com Review URL: https://codereview.chromium.org/1183753002
* make emptypath portable; add 565 color utilityGravatar caryclark2015-06-12
| | | | | | R=djsollen@google.com Review URL: https://codereview.chromium.org/1182833004
* There can be only one (SkRandom)!Gravatar scroggo2014-12-15
| | | | | | | | | | | | | | | | | | | | | Remove SkLCGRandom. We already decided the new one was better, which is why we wrote the new SkRandom. Convert GMs that were using SkLCGRandom to use the improved SkRandom. Motivated by the fact that these GMs draw differently on some runs. We believe this to be a result of using the old SkLCGRandom. Add each of the tests that were using SkLCGRandom to ignore-tests.txt, since we expect they'll draw differently using SkRandom. Move a trimmed down version of SkLCGRandom into SkDiscretePathEffect. In order to preserve the old behavior, trim down SkLCGRandom to only the methods used by SkDiscretePathEffect, and hide it in SkDiscretePathEffect's cpp file. BUG=skia:3241 Review URL: https://codereview.chromium.org/805963002
* Add standard fonts to all GMs.Gravatar Cary Clark2014-07-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allow GM results to be compared across machines and platforms by standardizing the fonts used by all tests. This adds runtime flags to DM to use either the system font context (the default), the fonts in the resources directory ( --resourceFonts ) or a set of canonical paths generated from the fonts ( --portableFonts ). This CL should leave the current DM results unchanged by default. If the portable font data or resource font is missing when DM is run, it falls back to using the system font context. The create_test_font tool generates the paths and metrics read by DM with the --portableFonts flag set, and generates the font substitution tables read by DM with the --resourceFonts flag set. If DM is run in SkDebug mode with the --reportUsedChars flag set, it generates the corresponding data compiled into the create_test_font tool. All GM tests set their typeface information by calling either sk_tool_utils::set_portable_typeface or sk_tool_utils::portable_typeface . (The former takes the paint, the latter returns a SkTypeface.) These calls can be removed in the future when the Font Manager can be superceded. BUG=skia:2687 R=mtklein@google.com Review URL: https://codereview.chromium.org/407183003
* Cleanup: Get rid of make_isize() function from gm.h.Gravatar tfarina2014-06-09
| | | | | | | | | | | | | | | This helper function is not necessary. The same thing can be achieved by using SkISize::Make() provided by SkTSize API. BUG=skia:2645 TEST=make dm && out/Debug/dm R=robertphillips@google.com, reed@google.com Author: tfarina@chromium.org Review URL: https://codereview.chromium.org/326523002
* Change old PRG to be SkLCGRandom; change new one to SkRandomGravatar commit-bot@chromium.org2013-09-09
| | | | | | | | | | | | | | The goal here is to get people to start using the new random number generator, while leaving the old one in place so we don't have to rebaseline GMs. R=reed@google.com, bsalomon@google.com Author: jvanverth@google.com Review URL: https://chromiumcodereview.appspot.com/23576015 git-svn-id: http://skia.googlecode.com/svn/trunk@11169 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 III of IV (I broke down the 1280 files into 4 CLs). Review URL: https://codereview.appspot.com/6475053 git-svn-id: http://skia.googlecode.com/svn/trunk@5264 2bbb7eff-a529-9590-31e7-b0007b416f81
* Import all GMs as Samples.Gravatar bsalomon@google.com2011-10-31
| | | | | | | | Review URL: http://codereview.appspot.com/5332043/ git-svn-id: http://skia.googlecode.com/svn/trunk@2564 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixed signed/unsigned comparison warnings in empty path gm/sampleGravatar bsalomon@google.com2011-10-10
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@2439 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixup rendering of empty paths (including inverted fills)Gravatar bsalomon@google.com2011-10-05
Add GM and Sample that draw empty paths with various styles and fills Review URL: http://codereview.appspot.com/5185047/ git-svn-id: http://skia.googlecode.com/svn/trunk@2414 2bbb7eff-a529-9590-31e7-b0007b416f81