aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/resizeimagefilter.cpp
Commit message (Collapse)AuthorAge
* Fix clipping of SkMatrixImageFilter input (take 2)Gravatar Robert Phillips2018-05-10
| | | | | | | | | | This cannot land before the Chrome CL https://chromium-review.googlesource.com/c/chromium/src/+/1052850 (Add a flag to ignore an upcoming Skia bug fix that changes layout and unit tests) Bug: skia:7931 Change-Id: I2951a727bd3f61aeda0e1e322cd76e48f677f75f Reviewed-on: https://skia-review.googlesource.com/127125 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Revert "Fix clipping of SkMatrixImageFilter input"Gravatar Robert Phillips2018-05-09
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit cb8b5d1101d0a1bf7c78f3d1fec73afbe470994c. Reason for revert: Chrome layout tests Original change's description: > Fix clipping of SkMatrixImageFilter input > > Bug: skia:7931 > Change-Id: I3e424dcd5c0b04542976f4f59a5836e7c3079d06 > Reviewed-on: https://skia-review.googlesource.com/127020 > Reviewed-by: Greg Daniel <egdaniel@google.com> > Commit-Queue: Robert Phillips <robertphillips@google.com> TBR=egdaniel@google.com,robertphillips@google.com Change-Id: I6b871071e180c45016038dcf2b01d2c96e93911c No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia:7931 Reviewed-on: https://skia-review.googlesource.com/127160 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Fix clipping of SkMatrixImageFilter inputGravatar Robert Phillips2018-05-09
| | | | | | | | Bug: skia:7931 Change-Id: I3e424dcd5c0b04542976f4f59a5836e7c3079d06 Reviewed-on: https://skia-review.googlesource.com/127020 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Update SkMatrixImageFilter to sk_spGravatar robertphillips2016-04-05
| | | | | | | | TBR=reed@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1858353002 Review URL: https://codereview.chromium.org/1858353002
* Update SkImageSource to sk_spGravatar robertphillips2016-04-01
| | | | | | | | TBR=reed@google.com GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1842243002 Review URL: https://codereview.chromium.org/1842243002
* 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
* 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
* Convert unit tests, GMs from SkBitmapSource to SkImagesourceGravatar fmalita2015-09-15
| | | | | | | | | | | This removes SkBitmapSource clients within Skia. http://crrev.com/1334173004 does the same for Blink, so we should be able to remove SkBitmapSource in a follow-up. R=reed@google.com,robertphillips@google.com,mtklein@google.com Review URL: https://codereview.chromium.org/1343123002
* Style Change: NULL->nullptrGravatar halcanary2015-08-27
| | | | | | DOCS_PREVIEW= https://skia.org/?cl=1316233002 Review URL: https://codereview.chromium.org/1316233002
* Begin kLegacyFontHost_InitType cleanupGravatar robertphillips2015-06-22
| | | | | | | | | | | | | | | | | | This CL starts the process of pushing kLegacyFontHost_InitType-type SkSurfaceProps up the call stack and out of Skia. It: Gets rid of the default SkBaseDevice ctor. This means everyone has to always hand an explicit SkSurfaceProps to it. It makes public the SkBitmapDevice creation methods that require SkSurfaceProps. Removes (in Skia's code base) all SkBitmapDevice ctor calls w/o SkSurfaceProps. Makes the "recording" canvases (e.g., pdf, svg, xps) explicitly not use kLegacyFontHost_InitType. Replicates the creating canvas/device's flags on saveLayer devices BUG=skia:3934 Review URL: https://codereview.chromium.org/1204433002
* Revert of Revert of stop calling SkScalarDiv (patchset #1 id:1 of ↵Gravatar reed2015-05-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1138263002/) Reason for revert: android patched, blink has rolled Original issue's description: > Revert of stop calling SkScalarDiv (patchset #4 id:60001 of https://codereview.chromium.org/1135053002/) > > Reason for revert: > need to wait for Blink roll (and patch android) > > Original issue's description: > > stop calling SkScalarDiv > > > > BUG=skia: > > TBR= > > > > Committed: https://skia.googlesource.com/skia/+/67d71c898249a7af3523b16c6a69895a63bfae0a > > TBR= > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/2629697933b5cc975e45d2a45c48f803fc6cbcec TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1135693003
* Revert of stop calling SkScalarDiv (patchset #4 id:60001 of ↵Gravatar reed2015-05-12
| | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/1135053002/) Reason for revert: need to wait for Blink roll (and patch android) Original issue's description: > stop calling SkScalarDiv > > BUG=skia: > TBR= > > Committed: https://skia.googlesource.com/skia/+/67d71c898249a7af3523b16c6a69895a63bfae0a TBR= NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1138263002
* stop calling SkScalarDivGravatar reed2015-05-12
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/1135053002
* Change some more GMs to clear to opaque black, not transparent black.Gravatar senorblanco2015-04-09
| | | | | | | | N.B.: this will change results on the bots for all the tests modified. BUG=skia:3319 Review URL: https://codereview.chromium.org/1077763002
* Move SkMatrixImageFilter into core, and add a factory fn for it.Gravatar senorblanco2015-03-20
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/1011273003
* SkPaint::FilterLevel -> SkFilterQualityGravatar reed2015-03-16
| | | | | | | | | clone (+rebase) of https://codereview.chromium.org/1009183002/ BUG=skia: TBR=scroggo@google.com Review URL: https://codereview.chromium.org/1014533004
* 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
* 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
* Revert to enabling all of -O2 as it exposes a bug in the toolchain.Gravatar djsollen2014-09-03
| | | | | | | | | | | | Instead as a workaround we will temporarily disable tiling the few GMs that produce errors with the existing 64-bit ARM toolchain. BUG=skia:2908 R=mtklein@google.com Author: djsollen@google.com Review URL: https://codereview.chromium.org/537713002
* Fix for saveLayer() with filters vs. the BBox Hierarchy.Gravatar senorblanco2014-07-14
| | | | | | | | | | | | | | | | | | | | When building acceleration structures for SkPicture, we must transform the primitive's bounds not only by its own SkPaint, but by the paints of any saveLayer()s currently active above it. We do this by pushing the SkPaint onto a stack on saveLayer(), and popping them on restore(). We also push a NULL paint in save(), so that the pushes and pops are balanced. BUG=skia:2734 R=mtklein@google.com, reed@google.com, robertphillips@google.com Committed: https://skia.googlesource.com/skia/+/6ca0b6a46cbe9bef3e2b9b9db813ec864efd62de Author: senorblanco@chromium.org Review URL: https://codereview.chromium.org/380373003
* Revert "Fix for saveLayer() with filters vs. the BBox Hierarchy." andGravatar senorblanco2014-07-14
| | | | | | | | | | | | | | | | "resizeimagefiler is ok with a BBH now". This reverts commits 6ca0b6a46cbe9bef3e2b9b9db813ec864efd62de and 8fa73202eaffbd7591ee218ad452b9afde81f505. Apparently causing problems in SKP playback. R=mtklein@google.com, robertphillips@google.com TBR=mtklein, robertphillips BUG=skia: Author: senorblanco@chromium.org Review URL: https://codereview.chromium.org/381353005
* resizeimagefiler is ok with a BBH nowGravatar mtklein2014-07-11
| | | | | | | | | BUG=skia: R=senorblanco@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/387933002
* Merge Replay and Quilt tasks, adding in all BBH implementations.Gravatar mtklein2014-07-09
| | | | | | | | | | | | | | | | | | | | | | | | Replay isn't that helpful of a test any more now that we have the more stringent Quilt tests. Quilt was missing bounding box hierarchies, though, while Replay was sort of testing RTree (pointlessly, as it was drawing without any clip). Now Quilt does everything, testing RTree, QuadTree, and TileGrid. Quilt mode now falls back to drawing all at once (i.e. Replay) for GMs that don't tile perfectly. Still a TODO to make this check more flexible than exact pixel matches. Two GMs fail when using a BBH: - imageresizetiled - resizeimagefilter We think we're not adjusting the bounds of save layers by their paint. This is probably a bug, but one to be fixed separately from adding new tests. BUG=skia: R=robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/377373003
* Add always-threaded SkRecord quilt tests.Gravatar mtklein2014-07-07
| | | | | | | | | | | | | | | | | | | | | Now that we're drawing tiles threaded like implside painting, remove the checks that those lock counts are balanced. They're just not right for anyone anymore. SkBitmaps themselves are not threadsafe (even const ones), so shallow copy them on playback of an SkRecord. (The underlying SkPixelRefs are threadsafe.) Simplify quilt drawing by using SkBitmap::extractSubset. No need for locking. Bump up to 256x256 tiles. 16x16 tiles just murders performance (way too much contention). This has the nice side effect of letting us enable a bunch more GMs for quilt mode; they drew wrong with small tiles but exactly right with large. BUG=171776 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/371023005
* 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
* Turn on quilt mode in DM.Gravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | | | | | | | | - Rename TileGrid -> Quilt to avoid the name overload. - Tag all failing GMs with kSkipTiled_Flag. You may be wondering, do any GMs pass? Yes, some do! And that trends towards all of them as we increase --quiltTile. Two GMs only fail in --quilt mode in 565. Otherwise all GMs which fail are skipped, and those which don't fail aren't. (The 8888 variants of those two GMs are skipped even though they pass.) BUG=skia:2477 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/256373002 git-svn-id: http://skia.googlecode.com/svn/trunk@14457 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement a generic matrix transform image filter.Gravatar senorblanco@chromium.org2014-03-25
| | | | | | | | | | | | | This will be used in Blink to accommodate matrices that contain rotation or shearing. This is a generalization of SkResizeImageFilter, so I've replaced all uses of SkResizeImageFilter in Skia. (It might be easier to review by diffing it with SkResizeImageFilter, too.) R=reed@google.com Review URL: https://codereview.chromium.org/211103006 git-svn-id: http://skia.googlecode.com/svn/trunk@13941 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixed double offset in resize filterGravatar commit-bot@chromium.org2014-03-21
| | | | | | | | | | | | | | | The fix is trivial, simply remove the extra offset I added another case to the resizeimagefilter gm and made it so that it looks exactly like the one next to it, so that failure is easy to detect visually. BUG=skia: R=senorblanco@google.com, senorblanco@chromium.org Author: sugoi@chromium.org Review URL: https://codereview.chromium.org/208303002 git-svn-id: http://skia.googlecode.com/svn/trunk@13892 2bbb7eff-a529-9590-31e7-b0007b416f81
* Factory methods for heap-allocated SkImageFilter objects.Gravatar commit-bot@chromium.org2014-03-10
| | | | | | | | | | | | | | | | | | This is part of an effort to ensure that all SkPaint effects can only be allocated on the heap. This patch makes the constructors of SkImageFilter and its subclasses non-public and instead provides factory methods for creating these objects on the heap. We temporarily keep constructor of publicly visible classes public behind a flag. BUG=skia:2187 R=scroggo@google.com, mtklein@chromium.org, reed@google.com, senorblanco@google.com, senorblanco@chromium.org, bsalomon@google.com, sugoi@chromium.org, zork@chromium.org Author: dominikg@chromium.org Review URL: https://codereview.chromium.org/182983003 git-svn-id: http://skia.googlecode.com/svn/trunk@13718 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement a resize image filter. This is needed for the "filterRes" feature ↵Gravatar senorblanco@chromium.org2014-01-15
| | | | | | | | | | | | | | | | | in SVG filter effects, which specifies the required size for intermediate processing buffers. In order to make this work, we need to render the primitive at the given resolution (doable at the callsite in Blink), and then to resize the result to the actual on-screen size. The latter is where this filter comes in. It simply applies a scaling factor (and the current CTM) to its input, and draws its input bitmap at that size. R=reed@google.com Committed: https://code.google.com/p/skia/source/detail?r=13077 Reverted: https://code.google.com/p/skia/source/detail?r=13078 BUG= Review URL: https://codereview.chromium.org/136863006 git-svn-id: http://skia.googlecode.com/svn/trunk@13082 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Implement a resize image filter."Gravatar senorblanco@chromium.org2014-01-14
| | | | | | | | | | This reverts commit 3f996e31c7043929fc1553b9b5ecd6a82b5fe125 (r13077). TBR=reed Review URL: https://codereview.chromium.org/136793012 git-svn-id: http://skia.googlecode.com/svn/trunk@13078 2bbb7eff-a529-9590-31e7-b0007b416f81
* Implement a resize image filter. This is needed for the "filterRes" feature ↵Gravatar senorblanco@chromium.org2014-01-14
in SVG filter effects, which specifies the required size for intermediate processing buffers. In order to make this work, we need to render the primitive at the given resolution (doable at the callsite in Blink), and then to resize the result to the actual on-screen size. The latter is where this filter comes in. It simply applies a scaling factor (and the current CTM) to its input, and draws its input bitmap at that size. R=reed@google.com Review URL: https://codereview.chromium.org/136863006 git-svn-id: http://skia.googlecode.com/svn/trunk@13077 2bbb7eff-a529-9590-31e7-b0007b416f81