aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/TileGridTest.cpp
Commit message (Collapse)AuthorAge
* Cut down SkBBH API more.Gravatar mtklein2014-10-27
| | | | | | | | | | | | | | - The expected case is now a single bulk-load insert() call instead of N; - reserve() and flushDeferredInserts() can fold into insert() now; - SkBBH subclasses may take ownership of the bounds This appears to be a performance no-op on both my Mac and N5. I guess even the simplest indirect branch predictor ("same as last time") can predict the repeated virtual calls to SkBBH::insert() perfectly. BUG=skia: Review URL: https://codereview.chromium.org/670213002
* BBHs: void* data -> unsigned dataGravatar mtklein2014-10-02
| | | | | | | | | | | | | | Now that the old backend's not using BBHs, we can specialize them for SkRecord's needs. The only thing we really want to store is op index, which should always be small enough to fit into an unsigned (unsigned also helps keep it straight from other ints floating around). This means we'll need half (32-bit) or a quarter (64-bit) the bytes in SkTileGrid, because we don't have to store an extra int for ordering. BUG=skia:2834 Review URL: https://codereview.chromium.org/617393004
* Change SkPicture::draw to playbackGravatar robertphillips2014-09-04
| | | | | | | | R=reed@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/540963002
* Convert BBH APIs to use SkRect.Gravatar mtklein2014-08-27
| | | | | | | | | | | | | Still TODO: convert internals of SkTileGrid.cpp and SkRTree.cpp to work in floats too. NOTREECHECKS=true BUG=skia:1021 R=robertphillips@google.com, reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/511613002
* De-parameterize SkNextDatumFunction.Gravatar mtklein2014-08-11
| | | | | | | | | | | | Just a simple refactor to make it clear we're only using this one method and this one type. BUG=skia: R=robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/465523002
* remove unnecessary bitmapdevice referencesGravatar reed2014-06-27
| | | | | | | | TBR= Author: reed@google.com Review URL: https://codereview.chromium.org/354143004
* Staging for cleanup of SkPicture-related headersGravatar robertphillips@google.com2014-04-18
| | | | | | | | https://codereview.chromium.org/243173002 git-svn-id: http://skia.googlecode.com/svn/trunk@14258 2bbb7eff-a529-9590-31e7-b0007b416f81
* Staged removal of SkPicture-derived classesGravatar commit-bot@chromium.org2014-04-17
| | | | | | | | | | | | | | This CL removes the SkPicture-derived classes (with a flag to keeps clients working). In the process it also lightens the recording factory function so it is no longer ref counted). The only interesting bits are in SkPicture* and Sk*Picture.* R=reed@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/238273012 git-svn-id: http://skia.googlecode.com/svn/trunk@14251 2bbb7eff-a529-9590-31e7-b0007b416f81
* Retract SkPicture::kOptimizeForClippedPlayback_RecordingFlag from public APIGravatar commit-bot@chromium.org2014-04-16
| | | | | | | | | | | | | | | | | | This CL sets the stage for retracting the SkPicture::kOptimizeForClippedPlayback_RecordingFlag flag from the public API (more work needs to be done in Blink & Chrome). In the new world the only way to set this flag (and thus instantiate an SkPicture-derived class) is by passing a factory to the SkPictureRecorder class. This is to get all clients always using factories so that we can then change the factory call used (i.e., so the factory just creates a BBH) and do away with the SkPicture-derived classes. BUG=skia:2315 R=reed@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/239703006 git-svn-id: http://skia.googlecode.com/svn/trunk@14221 2bbb7eff-a529-9590-31e7-b0007b416f81
* split SkPictureRecorder out of SkPictureGravatar robertphillips@google.com2014-04-13
| | | | | | | | https://codereview.chromium.org/214953003/ git-svn-id: http://skia.googlecode.com/svn/trunk@14171 2bbb7eff-a529-9590-31e7-b0007b416f81
* Roll back tests/TileGridTest.cpp back to where ASAN was happy.Gravatar commit-bot@chromium.org2014-03-28
| | | | | | | | | | | | | | | | | Revert "Change tilegrid test to test it directly, rather than through SkPicture" This reverts commit 7ae3bc7ffb3068b0585ad313d5c43ff1aab99737. Revert "Fix result order reliance" This reverts commit be4825c873856d8a6a91ea19cf1499da4b0a1fc1. BUG=skia:2345 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/216793006 git-svn-id: http://skia.googlecode.com/svn/trunk@13981 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix result order relianceGravatar commit-bot@chromium.org2014-03-17
| | | | | | | | | | | | | | The old tests presumed result order in a way was safe because SkPicture was sorting the paint calls. This fixes the tests to not check result ordering, just presence BUG=skia: R=robertphillips@google.com Author: iancottrell@google.com Review URL: https://codereview.chromium.org/197813011 git-svn-id: http://skia.googlecode.com/svn/trunk@13828 2bbb7eff-a529-9590-31e7-b0007b416f81
* Change tilegrid test to test it directly, rather than through SkPictureGravatar commit-bot@chromium.org2014-03-17
| | | | | | | | | | | | | This is necessary because it makes assumptions that picture will draw all the rects that match the grids, which may not hold if picture decides to improve the accuracy of the results. BUG=skia:2125 R=tomhudson@google.com, mtklein@google.com, reed@google.com Author: iancottrell@google.com Review URL: https://codereview.chromium.org/199083004 git-svn-id: http://skia.googlecode.com/svn/trunk@13827 2bbb7eff-a529-9590-31e7-b0007b416f81
* replace setConfig+allocPixels with single callGravatar mike@reedtribe.org2014-02-13
| | | | | | | | BUG=skia: Review URL: https://codereview.chromium.org/162643002 git-svn-id: http://skia.googlecode.com/svn/trunk@13426 2bbb7eff-a529-9590-31e7-b0007b416f81
* Cleanup: Sanitize the order of includes under tests/Gravatar tfarina@chromium.org2014-01-24
| | | | | | | | | | | | | | | | Initially this was to make sure Test.h appeared after the Sk*.h includes. Patch generated by the following command line: $ ~/chromium/src/tools/sort-headers.py tests/*.cpp BUG=None TEST=tests R=robertphillips@google.com Review URL: https://codereview.chromium.org/145313004 git-svn-id: http://skia.googlecode.com/svn/trunk@13177 2bbb7eff-a529-9590-31e7-b0007b416f81
* Move macros from TestClassDef.h to Test.hGravatar commit-bot@chromium.org2014-01-14
| | | | | | | | | | | | | | Motivation: those macros don't make any sense without the definitions in Test.h. BUG= R=mtklein@google.com Author: halcanary@google.com Review URL: https://codereview.chromium.org/138563004 git-svn-id: http://skia.googlecode.com/svn/trunk@13074 2bbb7eff-a529-9590-31e7-b0007b416f81
* Get rid of DEFINE_TESTCLASS() macro.Gravatar tfarina@chromium.org2013-12-18
| | | | | | | | | | | | | Remaining tests were rewrite to use DEF_TEST() macro instead. This fixes the FIXME in TestClassDef.h BUG=None TEST=tests R=mtklein@google.com Review URL: https://codereview.chromium.org/114563003 git-svn-id: http://skia.googlecode.com/svn/trunk@12760 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove SkFloatToScalar macroGravatar commit-bot@chromium.org2013-11-25
| | | | | | | | | | | BUG= R=reed@google.com, djsollen@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/85463005 git-svn-id: http://skia.googlecode.com/svn/trunk@12385 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "If the path is a rect, call drawRect to raster the geometry in ↵Gravatar bsalomon@google.com2013-10-22
| | | | | | | | | | SkCanvas::drawPath to get better performance." This reverts commit r11904 Review URL: https://codereview.chromium.org/35543002 git-svn-id: http://skia.googlecode.com/svn/trunk@11909 2bbb7eff-a529-9590-31e7-b0007b416f81
* If the path is a rect, call drawRect to raster the geometry in ↵Gravatar bsalomon@google.com2013-10-22
| | | | | | | | | | | | SkCanvas::drawPath to get better performance. Committed: http://code.google.com/p/skia/source/detail?r=11842 R=bsalomon@google.com Review URL: https://codereview.chromium.org/23484007 git-svn-id: http://skia.googlecode.com/svn/trunk@11904 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert r11842 (call drawRect to try GrAARectRenderer if the path is a rect - ↵Gravatar robertphillips@google.com2013-10-17
| | | | | | | | | | | | https://codereview.chromium.org/23484007) due to changes to the following GM images: inverse_paths pathopsinverse git-svn-id: http://skia.googlecode.com/svn/trunk@11845 2bbb7eff-a529-9590-31e7-b0007b416f81
* If the path is a rect, call drawRect to raster the geometry in ↵Gravatar commit-bot@chromium.org2013-10-17
| | | | | | | | | | | | SkCanvas::drawPath to get better performance. R=bsalomon@google.com, robertphillips@google.com, reed@google.com Author: yunchao.he@intel.com Review URL: https://codereview.chromium.org/23484007 git-svn-id: http://skia.googlecode.com/svn/trunk@11842 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove unnamed namespace usage from tests.Gravatar commit-bot@chromium.org2013-10-12
| | | | | | | | | | | | | | Skia code prefers static over unnamed namespace. BUG=None TEST=None R=bsalomon@google.com, robertphillips@google.com Author: tfarina@chromium.org Review URL: https://codereview.chromium.org/26962002 git-svn-id: http://skia.googlecode.com/svn/trunk@11747 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split SkDevice into SkBaseDevice and SkBitmapDeviceGravatar robertphillips@google.com2013-08-29
| | | | | | | | https://codereview.chromium.org/22978012/ git-svn-id: http://skia.googlecode.com/svn/trunk@10995 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert r10830 (Split SkDevice out of SkRasterDevice) until we can get ↵Gravatar robertphillips@google.com2013-08-20
| | | | | | Chromium ready. git-svn-id: http://skia.googlecode.com/svn/trunk@10835 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split SkDevice out of SkBitmapDeviceGravatar robertphillips@google.com2013-08-20
| | | | | | | | https://codereview.chromium.org/22978012/ git-svn-id: http://skia.googlecode.com/svn/trunk@10830 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-04-25
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@8851 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixing numerical rounding edge case in SkTileGridGravatar junov@chromium.org2013-04-24
| | | | | | | | | BUG=https://code.google.com/p/chromium/issues/detail?id=234688 TEST=TileGrid skia unit test Review URL: https://codereview.chromium.org/13860011 git-svn-id: http://skia.googlecode.com/svn/trunk@8839 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fixing SkTileGrid to clamp rather than clip content and querries that are ↵Gravatar junov@chromium.org2013-04-09
| | | | | | | | | | | | outside the bounds of the grid This fix prevents border padding and offsets on the tile grid structure from resulting in bad clipping. The job of clipping contents is left to the playback canvas. BUG=https://code.google.com/p/skia/issues/detail?id=1209 TEST=TileGrid unit test, Review URL: https://codereview.chromium.org/13493016 git-svn-id: http://skia.googlecode.com/svn/trunk@8576 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-03-01
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@7910 2bbb7eff-a529-9590-31e7-b0007b416f81
* Tests : Unused parameters cleanupGravatar sugoi@google.com2013-02-27
| | | | | | | I removed unused parameters in the tests wherever it was trivial to do so. I'm trying to get the easy ones out of the way before we get into more involved discussions around this. Review URL: https://codereview.appspot.com/7394055 git-svn-id: http://skia.googlecode.com/svn/trunk@7891 2bbb7eff-a529-9590-31e7-b0007b416f81
* Change SkTileGride geometry calculations to match the Chromium compositor.Gravatar junov@chromium.org2013-02-27
| | | | | | | | | | | | | | This patch changes the semantics of tileWidth/Height to include the border region, and uses an offset to take into account the fact that there is no outer border for outer tiles. This patch also fixes a previous bug where the right column and bottom row were considered to be included in bounds that are expressed as an SkIRect. Companion Chromium CL required for roll: https://codereview.chromium.org/12221077/ TEST=TileGrid unit test Review URL: https://codereview.appspot.com/7350050 git-svn-id: http://skia.googlecode.com/svn/trunk@7885 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2013-02-09
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@7688 2bbb7eff-a529-9590-31e7-b0007b416f81
* Adding option to SkTileGrid for specifying border pixels.Gravatar junov@chromium.org2013-02-08
| | | | | | | | The purpose of this patch is to make it possible for the chromium compositor to generate a TileGrid structure that is better suited for scaled playback. Review URL: https://codereview.appspot.com/7300072 git-svn-id: http://skia.googlecode.com/svn/trunk@7680 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Skia_Periodic_House_KeepingGravatar skia.committer@gmail.com2012-12-14
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@6809 2bbb7eff-a529-9590-31e7-b0007b416f81
* Modifying SkTileGrid to support arbitrary query rectangles.Gravatar junov@chromium.org2012-12-13
| | | | | | | | | | | Exposing SkTileGrid functionality in the public API through SkTileGridPicture. This patch also makes TileGrid and Rtree testable in gm, which revealed errors. TEST=gm with '--tileGrid' BUG=http://code.google.com/p/chromium/issues/detail?id=164636 Review URL: https://codereview.appspot.com/6933044 git-svn-id: http://skia.googlecode.com/svn/trunk@6783 2bbb7eff-a529-9590-31e7-b0007b416f81
* Unit testing for SkTileGridGravatar junov@chromium.org2012-11-07
Review URL: https://codereview.appspot.com/6827053 git-svn-id: http://skia.googlecode.com/svn/trunk@6331 2bbb7eff-a529-9590-31e7-b0007b416f81