aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/multipicturedraw.cpp
Commit message (Collapse)AuthorAge
* use tool_utils to encapsulate checking for recording canvas and makeSurfaceGravatar Mike Reed2018-01-02
| | | | | | | | Bug: skia: Change-Id: Ia93ee09dd213b8d6ad5c18e887add5ff3448c824 Reviewed-on: https://skia-review.googlesource.com/90243 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* move files out of private, and fix up callers to IWYUGravatar Mike Reed2017-05-16
| | | | | | | | | | Realized that a pending CL needed to add (yet another) private type to SkRecords.h, but w/o this CL I'd be forced to move that header also into private. This change frees us up to not have transitive exposure for types that need to be recorded. Bug: skia: Change-Id: Id79f1c2e44ba85e063c1360cf96c92de6397ca2b Reviewed-on: https://skia-review.googlesource.com/17031 Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Mike Klein <mtklein@chromium.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>
* 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>
* remove xfermode from public apiGravatar Mike Reed2016-10-28
| | | | | | | | | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4020 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Change-Id: I19cd056f2af778f10e8c6c2b7b2735593b43dbac Reviewed-on: https://skia-review.googlesource.com/4020 Reviewed-by: Florin Malita <fmalita@chromium.org> Reviewed-by: Mike Klein <mtklein@chromium.org> Commit-Queue: Mike Reed <reed@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
* Remove GrLayerHoisterGravatar robertphillips2016-07-13
| | | | | | | | This relies on https://codereview.chromium.org/1944013002/ (Add legacy flag to allow Skia to remove Ganesh layer hoister) landing first so as to not break the DEPS roll. GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1950523002 Review-Url: https://codereview.chromium.org/1950523002
* 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
* switch surface to sk_spGravatar reed2016-03-23
| | | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1817383002 CQ_EXTRA_TRYBOTS=client.skia.compile:Build-Ubuntu-GCC-x86_64-Release-CMake-Trybot,Build-Mac-Clang-x86_64-Release-CMake-Trybot Review URL: https://codereview.chromium.org/1817383002
* Reland of [2] of "switch colorfilters to sk_sp (patchset #11 id:200001 of ↵Gravatar reed2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.o… (patchset #1 id:1 of https://codereview.chromium.org/1821103004/ ) Reason for revert: guard has now landed in chrome Original issue's description: > Revert of Revert[2] of "switch colorfilters to sk_sp (patchset #11 id:200001 of https://codereview.chromium.o… (patchset #3 id:40001 of https://codereview.chromium.org/1825073002/ ) > > Reason for revert: > CreateModeFilter not compiling > > Original issue's description: > > Revert[2] of "switch colorfilters to sk_sp (patchset #11 id:200001 of https://codereview.chromium.org/1822623002/ )" > > > > Fixed legacy withColorFilter to call new(er) make method > > > > This reverts commit 1eb81db650d31f50be67b12d60c4f9e7dd08432f. > > > > BUG=skia: > > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1825073002 > > > > TBR= > > > > Committed: https://skia.googlesource.com/skia/+/4c9776b046dd5e9e46e2d1ce35154855c8fcb381 > > TBR= > # Skipping CQ checks because original CL landed less than 1 days ago. > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/d6889293dd0942f27f9593f679722c956831f2c4 TBR= # Not skipping CQ checks because original CL landed more than 1 days ago. BUG=skia: Review URL: https://codereview.chromium.org/1827433002
* Revert of Revert[2] of "switch colorfilters to sk_sp (patchset #11 id:200001 ↵Gravatar reed2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.o… (patchset #3 id:40001 of https://codereview.chromium.org/1825073002/ ) Reason for revert: CreateModeFilter not compiling Original issue's description: > Revert[2] of "switch colorfilters to sk_sp (patchset #11 id:200001 of https://codereview.chromium.org/1822623002/ )" > > Fixed legacy withColorFilter to call new(er) make method > > This reverts commit 1eb81db650d31f50be67b12d60c4f9e7dd08432f. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1825073002 > > TBR= > > Committed: https://skia.googlesource.com/skia/+/4c9776b046dd5e9e46e2d1ce35154855c8fcb381 TBR= # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1821103004
* Revert[2] of "switch colorfilters to sk_sp (patchset #11 id:200001 of ↵Gravatar reed2016-03-22
| | | | | | | | | | | | | | | https://codereview.chromium.org/1822623002/ )" Fixed legacy withColorFilter to call new(er) make method This reverts commit 1eb81db650d31f50be67b12d60c4f9e7dd08432f. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1825073002 TBR= Review URL: https://codereview.chromium.org/1825073002
* Revert of switch colorfilters to sk_sp (patchset #11 id:200001 of ↵Gravatar reed2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1822623002/ ) Reason for revert: need to fix unguarded makeWithFilter Original issue's description: > switch colorfilters to sk_sp > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1822623002 > > Committed: https://skia.googlesource.com/skia/+/f809d7687a4fb7b88b651b046da2bc0035d6aa09 TBR=fmalita@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1820303002
* switch colorfilters to sk_spGravatar reed2016-03-22
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1822623002 Review URL: https://codereview.chromium.org/1822623002
* return pictures as sk_spGravatar reed2016-03-18
| | | | | | | BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1811703002 Review URL: https://codereview.chromium.org/1811703002
* update callsites for Make image factoriesGravatar reed2016-03-17
| | | | | | | | | | | not forced yet, as we still have the build-guard. waiting on chrome CL BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1810813003 TBR= Review URL: https://codereview.chromium.org/1810813003
* 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
* make pixelsnap textblob* etc gm portableGravatar caryclark2015-07-28
| | | | | | TBR=reed@google.com Review URL: https://codereview.chromium.org/1263553002
* Cleanup: Remove unnecessary double-semicolons.Gravatar tfarina2015-04-27
| | | | | | | | | | | | | | | The entries were found by the following command line: $ find . -regex ".*\.[cChH]\(pp\)?" | xargs git grep -e ';;' --and --not -e 'for *(.*;;' Which is a combination of http://stackoverflow.com/a/3858879 and http://gitster.livejournal.com/27674.html BUG=None R=mtklein@google.com Review URL: https://codereview.chromium.org/1088763005
* Add matrix constructing helpers to SkMatrixGravatar robertphillips2015-03-26
| | | | Review URL: https://codereview.chromium.org/1034273002
* 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
* remove unused GM flagsGravatar mtklein2015-01-23
| | | | | | | | | | Depends on https://codereview.chromium.org/873753002/ Thumbs up to CLion for refactoring this for me. BUG=skia: Review URL: https://codereview.chromium.org/867963004
* Spin off GM::runAsBench() from flags.Gravatar mtklein2015-01-23
| | | | | | | | This will let us kill flags. BUG=skia: Review URL: https://codereview.chromium.org/873753002
* 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
* Change where layer hoisting data is gatheredGravatar robertphillips2014-11-11
| | | | | | | | | | | | This CL: 1) removes the EXPERIMENTAL_optimize on SkCanvas & SkDevice 2) moves the saveLayer gathering step to endRecording 3) Replaces GPUOptimize with SkRecordComputeLayers 4) Update bench_pictures & render_pictures to provide the new flag #2 also necessitated moving the BBH computation (and record optimization) out of SkPicture's ctor (and into endRecording) Review URL: https://codereview.chromium.org/718443002
* Fix multipicturedraw_biglayer GMGravatar robertphillips2014-10-06
| | | | | | Having a layer is a prerequisite for having it be hoisted. Review URL: https://codereview.chromium.org/632743002
* Reduce overdraw in MultiPictureDraw Sierpinski GMGravatar robertphillips2014-10-03
| | | | | | | | | | | | | As written, all the layers in the MPD Sierpinski GM are full screen. This CL bounds each layer to reduce overdraw. This CL will cause differences in: multipicturedraw_sierpinski_simple multipicturedraw_sierpinski_tiled but they are/will be suppressed in: (Don't turn on dither for saveLayers which have no paint - https://codereview.chromium.org/619363002/) Review URL: https://codereview.chromium.org/582633003
* Add a MultiPictureDraw GM to exercise layer clippingGravatar robertphillips2014-10-02
| | | | | | | | This adds a "biglayer" variant that creates a picture with a single big layer. The tiling composition will test whether the layer hoisting code correctly caches the layers with their clipping information. BUG=skia:2315 Review URL: https://codereview.chromium.org/617723004
* Make pictures in multipicturedraw GM fit in 0,0..W,H rangeGravatar robertphillips2014-09-29
| | | | | | | | | | | | Having the picture contents not actually reside in the 0,0..W,H range wrecks havoc with the layer hoisting. The hoisting works correctly but since the picture don't fulfill their contract the results look incorrect. This CL just translates the picture's contents to the right so they are within the picture bound. R=egdaniel@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/594363003
* SkCanvas::drawImage is the new way for drawing a SkImage to a CanvasGravatar piotaixr2014-09-24
| | | | | | | | | | | | BUG=skia:2947 Committed: https://skia.googlesource.com/skia/+/432789972c1e1f8a66165c75a250dba1853efa08 R=junov@chromium.org, reed@google.com, bsalomon@google.com Author: piotaixr@chromium.org Review URL: https://codereview.chromium.org/583453002
* Revert of SkCanvas::drawImage is the new way for drawing an SkImage to a ↵Gravatar borenet2014-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | Canvas (patchset #9 id:160001 of https://codereview.chromium.org/583453002/) Reason for revert: Broke ChromiumOS Ozone builder: http://build.chromium.org/p/chromium.chromiumos/builders/Linux%20ChromiumOS%20Ozone%20Builder/builds/4087/steps/compile/logs/stdio Reverting to unblock DEPS roll. Original issue's description: > SkCanvas::drawImage is the new way for drawing a SkImage to a Canvas > > BUG=skia:2947 > > Committed: https://skia.googlesource.com/skia/+/432789972c1e1f8a66165c75a250dba1853efa08 R=junov@chromium.org, reed@google.com, bsalomon@google.com, piotaixr@chromium.org TBR=bsalomon@google.com, junov@chromium.org, piotaixr@chromium.org, reed@google.com NOTREECHECKS=true NOTRY=true BUG=skia:2947 Author: borenet@google.com Review URL: https://codereview.chromium.org/598133002
* SkCanvas::drawImage is the new way for drawing a SkImage to a CanvasGravatar piotaixr2014-09-23
| | | | | | | | | BUG=skia:2947 R=junov@chromium.org, reed@google.com, bsalomon@google.com Author: piotaixr@chromium.org Review URL: https://codereview.chromium.org/583453002
* Fix memory leak in MultiPictureDraw GMGravatar robertphillips2014-09-19
| | | | | | | | R=fmalita@google.com, fmalita@chromium.org Author: robertphillips@google.com Review URL: https://codereview.chromium.org/585033002
* Extend MultiPictureDraw GMGravatar robertphillips2014-09-19
| | | | | | | | | | This new GM case is intended to exercise the matrix oriented aspects of layer caching. R=jvanverth@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/582113004
* Try out scalar picture sizesGravatar robertphillips2014-08-29
| | | | | | | | | | This paves the way for removing the 'fTile' parameter from SkPictureShader (although that should be a different CL). If we like this we could also move to providing an entire cull SkRect. R=reed@google.com, mtklein@google.com, fmalita@google.com, fmalita@chromium.org Author: robertphillips@google.com Review URL: https://codereview.chromium.org/513983002
* Fix leak in multipicturedraw GMs.Gravatar bsalomon2014-08-22
| | | | | | | | R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/502493002
* Fix surface leak in multidraw GMs.Gravatar bsalomon2014-08-21
| | | | | | | | TBR=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/496793003
* SkMultiPictureDraw APIGravatar robertphillips2014-08-21
This CL adds a new API to optimize across multiple SkPicture draw calls. Note that multiple pictures rendered at once (i.e., picture piles) should be flattened into a single new picture that includes the required clipping on the different layers. R=bsalomon@google.com, reed@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/491313003