aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
Commit message (Collapse)AuthorAge
* Remove unused (by clients) SkUnitMapperGravatar commit-bot@chromium.org2014-05-22
| | | | | | | | | | | | This reverts commit 874423a81b5bc2541c7397e6ab00d5e7c9fdaf98. TBR=scroggo Author: reed@google.com Review URL: https://codereview.chromium.org/288313009 git-svn-id: http://skia.googlecode.com/svn/trunk@14842 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of Remove unused (by clients) SkUnitMapper ↵Gravatar commit-bot@chromium.org2014-05-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/283273002/) (https://codereview.chromium.org/288343009/) Reason for revert: required blink change failed to land Original issue's description: > Remove unused (by clients) SkUnitMapper (https://codereview.chromium.org/283273002/) > > This reverts commit dd50c83b5b34dab3a077741861b50ed1f2bc6b8f. > > BUG=skia: > > Committed: http://code.google.com/p/skia/source/detail?r=14830 R=scroggo@google.com, reed@google.com TBR=reed@google.com, scroggo@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: reed@chromium.org Review URL: https://codereview.chromium.org/296823008 git-svn-id: http://skia.googlecode.com/svn/trunk@14838 2bbb7eff-a529-9590-31e7-b0007b416f81
* Remove unused (by clients) SkUnitMapper ↵Gravatar commit-bot@chromium.org2014-05-21
| | | | | | | | | | | | | | | (https://codereview.chromium.org/283273002/) This reverts commit dd50c83b5b34dab3a077741861b50ed1f2bc6b8f. BUG=skia: R=scroggo@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/288343009 git-svn-id: http://skia.googlecode.com/svn/trunk@14830 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add function to get both min and max scale factors from matrixGravatar commit-bot@chromium.org2014-05-20
| | | | | | | | | | R=reed@google.com, jvanverth@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/298473002 git-svn-id: http://skia.googlecode.com/svn/trunk@14804 2bbb7eff-a529-9590-31e7-b0007b416f81
* Rename SkMatrix::get(Max|Min)Stretch to get(Min|Max)ScaleGravatar commit-bot@chromium.org2014-05-20
| | | | | | | | | | R=reed@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/295713002 git-svn-id: http://skia.googlecode.com/svn/trunk@14798 2bbb7eff-a529-9590-31e7-b0007b416f81
* Try out SkMatrix::Concat.Gravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | | | This should RVO to the same as doing it on the stack with setConcat. BUG=skia: R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/293693002 git-svn-id: http://skia.googlecode.com/svn/trunk@14782 2bbb7eff-a529-9590-31e7-b0007b416f81
* Don't clobber initial transform with SetMatrix.Gravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | BUG=skia:2378 R=reed@google.com, mtklein@google.com, robertphillips@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/290883004 git-svn-id: http://skia.googlecode.com/svn/trunk@14778 2bbb7eff-a529-9590-31e7-b0007b416f81
* Ensure playing back a picture always balances saves and restoresGravatar commit-bot@chromium.org2014-05-19
| | | | | | | | | | | | | | This "fixes" the legacy interface's possible creation of pictures with unbalanced save/restores. The Android dox will need to be updated once/if this lands. R=reed@google.com, scroggo@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/286033005 git-svn-id: http://skia.googlecode.com/svn/trunk@14772 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of remove unused (by clients) SkUnitMapper ↵Gravatar commit-bot@chromium.org2014-05-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/283273002/) Reason for revert: does not address all legacy callsites in chrome. e.g. [13:45:32.091872] ../../ui/native_theme/native_theme_base.cc:608:76: error: no matching function for call to ‘SkGradientShader::CreateLinear(SkPoint [3], SkColor [3], NULL, int, SkShader::TileMode, NULL)’ [13:45:32.091919] gradient_bounds, colors, NULL, 3, SkShader::kClamp_TileMode, NULL)); Original issue's description: > remove unused (by clients) SkUnitMapper > > BUG=skia: > > Committed: http://code.google.com/p/skia/source/detail?r=14761 R=robertphillips@google.com, scroggo@google.com, george@mozilla.com TBR=george@mozilla.com, robertphillips@google.com, scroggo@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: reed@google.com Review URL: https://codereview.chromium.org/287063009 git-svn-id: http://skia.googlecode.com/svn/trunk@14763 2bbb7eff-a529-9590-31e7-b0007b416f81
* remove unused (by clients) SkUnitMapperGravatar commit-bot@chromium.org2014-05-16
| | | | | | | | | | | BUG=skia: R=robertphillips@google.com, scroggo@google.com, george@mozilla.com Author: reed@google.com Review URL: https://codereview.chromium.org/283273002 git-svn-id: http://skia.googlecode.com/svn/trunk@14761 2bbb7eff-a529-9590-31e7-b0007b416f81
* comment out info4 test until Rob can fix itGravatar reed@google.com2014-05-14
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14741 2bbb7eff-a529-9590-31e7-b0007b416f81
* Reland bug fixes from "4x allocation in PipeController is probably overkill."Gravatar commit-bot@chromium.org2014-05-14
| | | | | | | | | | | BUG=372671 R=mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/283093002 git-svn-id: http://skia.googlecode.com/svn/trunk@14727 2bbb7eff-a529-9590-31e7-b0007b416f81
* Manually revert "4x allocation in PipeController is probably overkill."Gravatar commit-bot@chromium.org2014-05-14
| | | | | | | | | | | | | | | | This reverts commit 2d91efffdb57646a495de5bf859ff281ef86dd12. Conflicts: src/pipe/SkGPipeWrite.cpp BUG=372671 R=mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/277653004 git-svn-id: http://skia.googlecode.com/svn/trunk@14725 2bbb7eff-a529-9590-31e7-b0007b416f81
* Flatten resources directoryGravatar halcanary@google.com2014-05-09
| | | | | | | | | | | | | | On android trybots, the files in a subdirectory weren't being loaded onto the device. Consequently, the ImageDecoderOptions test was not testing anything. I had to relax that unit test to reflect the existing behavior of our libjpeg decoder on Android. R=djsollen@google.com Review URL: https://codereview.chromium.org/264583007 git-svn-id: http://skia.googlecode.com/svn/trunk@14682 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert "Flatten resources directory"Gravatar djsollen@google.com2014-05-09
| | | | | | Review URL: https://codereview.chromium.org/278033002 git-svn-id: http://skia.googlecode.com/svn/trunk@14679 2bbb7eff-a529-9590-31e7-b0007b416f81
* Flatten resources directoryGravatar commit-bot@chromium.org2014-05-09
| | | | | | | | | | | | | | | | On android trybots, the files in a subdirectory weren't being loaded onto the device. Consequently, the ImageDecoderOptions test was not testing anything. I had to relax that unit test to reflect the existing behavior of our libjpeg decoder on Android. R=djsollen@google.com Author: halcanary@google.com Review URL: https://codereview.chromium.org/264583007 git-svn-id: http://skia.googlecode.com/svn/trunk@14678 2bbb7eff-a529-9590-31e7-b0007b416f81
* cleanup GrContext resource cache apiGravatar commit-bot@chromium.org2014-05-09
| | | | | | | | | | R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/275563005 git-svn-id: http://skia.googlecode.com/svn/trunk@14669 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-05-09
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14661 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix rendering artifacts in pull-saveLayers-forward modeGravatar commit-bot@chromium.org2014-05-08
| | | | | | | | | | | | | | | | | | | | This CL fixes 2 bugs in the pre-rendering of saveLayers: 1) The drawBitmapRect call wasn't occurring in device space so could sometimes be double transformed 2) The BBH op skipping in SkPicturePlayback could sometimes mess up the SkPictureStateTree's state It also reduces the number of layers that are pre-rendered when a BBH is not in use. Committed: http://code.google.com/p/skia/source/detail?r=14650 R=bsalomon@google.com, reed@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/267293007 git-svn-id: http://skia.googlecode.com/svn/trunk@14659 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split Star into Star (stores nothing) and List (stores matches).Gravatar commit-bot@chromium.org2014-05-08
| | | | | | | | | | | | | | | | | | | Just noticed that the cull noop pattern (PushCull, Star<NoOp>, PopCull) would trigger the Star that stores matches. We certainly don't need those matches here, so instead of magically determining which Star you need, we'll make you tell us which one you want. No one but List's unit test needs List. I'll leave it for now, but we might find it's not useful. BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com, bungeman@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/275623002 git-svn-id: http://skia.googlecode.com/svn/trunk@14655 2bbb7eff-a529-9590-31e7-b0007b416f81
* Noop away PushCull/PopCull pairs with nothing between them.Gravatar commit-bot@chromium.org2014-05-08
| | | | | | | | | | | BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/277613002 git-svn-id: http://skia.googlecode.com/svn/trunk@14653 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-05-08
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14636 2bbb7eff-a529-9590-31e7-b0007b416f81
* Move paints to the front of draw structs.Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | The order of arguments in these structs is arbitrary, so we might as well arrange them to optimize something. Putting the paints at the front means the logic to find the paint is a lot more concise: it's usually just ptr+0, or *(ptr+0) when the SkPaint is optional. This considerably reduces the size of the jump table in IsDraw::operator(). BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/272673002 git-svn-id: http://skia.googlecode.com/svn/trunk@14634 2bbb7eff-a529-9590-31e7-b0007b416f81
* Convert all SkRecordPattern matchers into SkRecord mutators.Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | | | - Allow any return type from SkRecord mutators and visitors; - update existing calls to mutate and visit; - convert match to operator() in SkRecordPattern; - tidy up a few inelegant bits of old code in tests. The net result is that the generated code is much clearer. All the mutate() calls inline as you'd hope, and you can now actually follow along with the disassembly. BUG=skia:2378 R=fmalita@chromium.org, bungeman@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/273643007 git-svn-id: http://skia.googlecode.com/svn/trunk@14631 2bbb7eff-a529-9590-31e7-b0007b416f81
* Some small cleanups for image filter code.Gravatar senorblanco@chromium.org2014-05-07
| | | | | | | | | | | Use the 2-param flavour of mapVector instead of the 3-param, where possible. Add an SkMatrixImageFilter test case to the tiling unit test. R=junov@chromium.org Review URL: https://codereview.chromium.org/277543002 git-svn-id: http://skia.googlecode.com/svn/trunk@14630 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix for SkDisplacementMap::onFilterBounds().Gravatar senorblanco@chromium.org2014-05-07
| | | | | | | | | | | | | Two problems: we were not applying the CTM to the scale parameter when modifying clip bounds, and the recursion for onFilterBounds() must be done in the reverse order. BUG=370914 R=junov@chromium.org Review URL: https://codereview.chromium.org/272643003 git-svn-id: http://skia.googlecode.com/svn/trunk@14627 2bbb7eff-a529-9590-31e7-b0007b416f81
* save-draw*-restore -> noop-draw*-noopGravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | save-drawA-drawB-drawC-restore always means drawA-drawB-drawC, no matter what flags we use for save(). This one triggers all over the silk SKPs and in several of the bot SKPs, typically as save-drawBitmap-restore. BUG=skia:2378 R=robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/267793006 git-svn-id: http://skia.googlecode.com/svn/trunk@14618 2bbb7eff-a529-9590-31e7-b0007b416f81
* When solving the cubic line intersection directly fails, use binary search ↵Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | as a fallback. The cubic line intersection math empirically works 99.99% of the time (fails 3100 out of 1B random tests) but when it fails, an intersection may be missed altogether. The binary search is may not find a solution if the cubic line failed to find any solutions at all, but so far that case hasn't arisen. BUG=skia:2504 TBR=reed@google.com Author: caryclark@google.com Review URL: https://codereview.chromium.org/266063003 git-svn-id: http://skia.googlecode.com/svn/trunk@14614 2bbb7eff-a529-9590-31e7-b0007b416f81
* 4x allocation in PipeController is probably overkill.Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | | | | | | | | | | When verylargebitmap GM runs in cross-process pipe mode, we're requestBlock()ing ~200M to carry the bitmaps. The current implementation ends up allocating ~800M, which is a bit wasteful. SkGPipeWrite already rounds up to 16K, so just rely on that. This change exposed several bugs in pipe: - we don't reserve enough space in drawVertices - we don't reserve enough space for factory names in cross-process mode - we don't quite have the right check in needOpBytes to see if we needed to send off the current block and allocate a new one SETUP_NOTIFY and generally calling doNotify() more often than necessary made things hard to debug and understand. Now the pipe always waits to send off its current block until it needs more space than that block can provide, or it's the final block. We can put these back if we need the proactive flushing, but it seems not necessary? Removed an assert in DeferredCanvasTest, which is somtimes 2 (Debug), sometimes 3 (Release). It seemed like the other asserts were more essential, and this one was more of a white-box assertion. Still sound if we remove it? BUG=skia:2478 R=scroggo@google.com, mtklein@google.com, reed@google.com, junov@chromium.org Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/267863002 git-svn-id: http://skia.googlecode.com/svn/trunk@14613 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add SaveLayer-Draw-Restore optimization.Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | | | | This is like SkPictureRecord's remove_save_layer1 but works with all draw calls. Interesting patterns removed: SaveLayer-DrawRect-Restore: Silk SKPs, desk_weather SaveLayer-DrawPath-Restore: desk_carsvg, desk_wowwiki, tabl_androidpolice SaveLayer-DrawPosTextH-Restore: tabl_android_police There may be others, but I stopped looking. BUG=skia:2378 R=robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/269813010 git-svn-id: http://skia.googlecode.com/svn/trunk@14610 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split CPU and GPU DeferredCanvas testsGravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | Nothing important, just happened to notice this and figured it was good hygiene. DEF_TESTs run in parallel, while DEF_GPUTESTs run all run serially. BUG=skia: Committed: http://code.google.com/p/skia/source/detail?r=14603 R=junov@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/271483002 git-svn-id: http://skia.googlecode.com/svn/trunk@14608 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert of Split CPU and GPU DeferredCanvas tests ↵Gravatar commit-bot@chromium.org2014-05-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | (https://codereview.chromium.org/271483002/) Reason for revert: breaking the run tests steps on ChromeOS. See http://108.170.220.120:10117/builders/Test-ChromeOS-Alex-GMA3150-x86-Debug/builds/1669 Original issue's description: > Split CPU and GPU DeferredCanvas tests > > Nothing important, just happened to notice this and figured it was good hygiene. > DEF_TESTs run in parallel, while DEF_GPUTESTs run all run serially. > > BUG=skia: > > Committed: http://code.google.com/p/skia/source/detail?r=14603 R=junov@chromium.org, mtklein@google.com, mtklein@chromium.org TBR=junov@chromium.org, mtklein@chromium.org, mtklein@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: djsollen@google.com Review URL: https://codereview.chromium.org/270283003 git-svn-id: http://skia.googlecode.com/svn/trunk@14607 2bbb7eff-a529-9590-31e7-b0007b416f81
* Sanitizing source files in Housekeeper-NightlyGravatar skia.committer@gmail.com2014-05-07
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14605 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix for empty saveLayer() with a filter which affects transparent black.Gravatar senorblanco@chromium.org2014-05-06
| | | | | | | | | | | | | | | | | | | | | If an saveLayer()/restore() is recorded, tilegrid/rtree will cull them out and not draw anything. This is correct for most cases, but if the paint in the saveLayer() is one that affects transparent black (e.g., it contains a color filter or image filter which affects transparent black), this is incorrect: the filter should be applied. Fixed by adding a no-op between the saveLayer() and restore(), and adding a bbox node pointing at that node with the saveLayer()'s bounds. This exposed a bug in SkPictureRecord.cpp's match(), where it would assert if the NOOP was the last op seen. Fixed with an early-out before calling peek_op_and_size(). BUG=skia:2254 Review URL: https://codereview.chromium.org/262363007 git-svn-id: http://skia.googlecode.com/svn/trunk@14604 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split CPU and GPU DeferredCanvas testsGravatar commit-bot@chromium.org2014-05-06
| | | | | | | | | | | | | | Nothing important, just happened to notice this and figured it was good hygiene. DEF_TESTs run in parallel, while DEF_GPUTESTs run all run serially. BUG=skia: R=junov@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/271483002 git-svn-id: http://skia.googlecode.com/svn/trunk@14603 2bbb7eff-a529-9590-31e7-b0007b416f81
* SaveLayer is not a draw.Gravatar commit-bot@chromium.org2014-05-06
| | | | | | | | | | | | | | | | | Will keep thinking about the best way to handle this: - leave as-is - tag the records - some range check on T::kType - just list all Draw* in IsDraw BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/269543023 git-svn-id: http://skia.googlecode.com/svn/trunk@14602 2bbb7eff-a529-9590-31e7-b0007b416f81
* Infrastructure changes to support pull-saveLayers-forward taskGravatar commit-bot@chromium.org2014-05-06
| | | | | | | | | | | | | | | | | | | | | This is split out of (First pass at pre-rendering saveLayers for GPU - https://codereview.chromium.org/261663003/). It mainly: Moves NeedsDeepCopy to somewhere more accessible (so GrPictureUtils.cpp can use it) Moves ComputeAccelDataKey somewhere more accessible (so GPUPicture test can use it) Adds unit test for picture saveLayer analysis (done in EXPERIMENTAL_optimize) Adds new fields to SaveLayerInfo that are needed to pull forward layers Committed: http://code.google.com/p/skia/source/detail?r=14571 R=bsalomon@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/266203003 git-svn-id: http://skia.googlecode.com/svn/trunk@14586 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add pattern matchers for SkRecordGravatar commit-bot@chromium.org2014-05-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a mid-level library for finding patterns of commands in an SkRecord. At the API level, it's a bit regex inspired. Some examples: - Pattern1<Is<DrawRect>> matches a single DrawRect - Pattern1<Star<Is<DrawRect>>> matches 0 or more DrawRects - Pattern2<Is<ClipRect>, Is<DrawRect>> matches a single clip rect followed by a single draw rect - Pattern3<Is<Save>, Star<IsDraw>, Is<Restore>> matches a single Save, followed by any number of Draws, followed by Restore - Pattern1<Or<Is<DrawRect>, Is<ClipRect>>> matches a DrawRect or a ClipRect - Pattern1<Not<Is<ClipRect>>> matches a command that's notClipRect. Once you have a pattern, you can call .search() on it to step through ranges of matching commands. This means patterns can replace most of the custom iteration logic for optimization passes: the generic pattern searching steps through all the optimization candidates, which optimization-specific code further inspects and mutates. SkRecordTraits is now unused. Bye bye! Generated code and performance of SkRecordOpts is very similar to what it was before. (I had to use SK_ALWAYS_INLINE in a few places to make this so.) BUG=skia:2378 R=fmalita@chromium.org, bungeman@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/263063002 git-svn-id: http://skia.googlecode.com/svn/trunk@14582 2bbb7eff-a529-9590-31e7-b0007b416f81
* Revert r14571 (Infrastructure changes to support pull saveLayers forward ↵Gravatar robertphillips@google.com2014-05-05
| | | | | | task - https://codereview.chromium.org/266203003) due to breaking Android unit tests git-svn-id: http://skia.googlecode.com/svn/trunk@14578 2bbb7eff-a529-9590-31e7-b0007b416f81
* Adds a mechanism for GrCacheable objects to notify the resource cacheGravatar commit-bot@chromium.org2014-05-05
| | | | | | | | | | | | | | | | | when their size has changed. GrResourceCacheEntry now holds a reference to the cache, and a cached value of the resource's most recent size. Also utilizes this new functionality for mipmaps, and adds a test for changing resource sizes. R=bsalomon@google.com, robertphillips@google.com Author: cdalton@nvidia.com Review URL: https://codereview.chromium.org/257093002 git-svn-id: http://skia.googlecode.com/svn/trunk@14576 2bbb7eff-a529-9590-31e7-b0007b416f81
* Infrastructure changes to support pull-saveLayers-forward taskGravatar commit-bot@chromium.org2014-05-05
| | | | | | | | | | | | | | | | | | | This is split out of (First pass at pre-rendering saveLayers for GPU - https://codereview.chromium.org/261663003/). It mainly: Moves NeedsDeepCopy to somewhere more accessible (so GrPictureUtils.cpp can use it) Moves ComputeAccelDataKey somewhere more accessible (so GPUPicture test can use it) Adds unit test for picture saveLayer analysis (done in EXPERIMENTAL_optimize) Adds new fields to SaveLayerInfo that are needed to pull forward layers R=bsalomon@google.com Author: robertphillips@google.com Review URL: https://codereview.chromium.org/266203003 git-svn-id: http://skia.googlecode.com/svn/trunk@14571 2bbb7eff-a529-9590-31e7-b0007b416f81
* Update tests/RecordOptsTest.cppGravatar commit-bot@chromium.org2014-05-05
| | | | | | | | | | | | | | | - use REPORTER_ASSERT; - assert the type first, then the pointer != NULL. This helps explain why ptr == NULL; - add a simpler NoopSaveRestore test case, which can help debugging failures of the larger test case. BUG=skia:2378 R=fmalita@chromium.org, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/264043012 git-svn-id: http://skia.googlecode.com/svn/trunk@14570 2bbb7eff-a529-9590-31e7-b0007b416f81
* fix double->float warningGravatar reed@google.com2014-05-05
| | | | git-svn-id: http://skia.googlecode.com/svn/trunk@14568 2bbb7eff-a529-9590-31e7-b0007b416f81
* add rounding-using-doubles methods on SkScalar and SkRectGravatar commit-bot@chromium.org2014-05-05
| | | | | | | | | | | | | | | Inspired by the excellent repro case for https://crbug.com/364224 patch from issue 265933010 BUG=skia: R=bungeman@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/267003002 git-svn-id: http://skia.googlecode.com/svn/trunk@14566 2bbb7eff-a529-9590-31e7-b0007b416f81
* Split GrResource into GrCacheable/GrGpuObjectGravatar commit-bot@chromium.org2014-05-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this change, an object needed to inherit from GrResource (and thus be a GPU object) in order to live in the GrResourceCache. That was a problem for caching items that weren't GPU objects themselves, but owned GPU objects. This change splits GrResource into two classes: 1. GrCacheable: The base class for objects that can live in the GrResourceCache. 2. GrGpuObject, which inherits from GrCacheable: The base class for objects that get tracked by GrGpu. This change is purely a refactor; there is no change in functionality. Change-Id: I3e8daeb1f123041f414aa306c1366e959ae9e39e BUG=skia: R=bsalomon@google.com Author: cdalton@nvidia.com Review URL: https://codereview.chromium.org/251013002 git-svn-id: http://skia.googlecode.com/svn/trunk@14553 2bbb7eff-a529-9590-31e7-b0007b416f81
* Fix for SkMatrixConvolutionImageFilter with large borders.Gravatar senorblanco@chromium.org2014-05-02
| | | | | | | | | | | Intersect the requested processing rect with the destination bounds. R=junov@chromium.org Review URL: https://codereview.chromium.org/267863004 git-svn-id: http://skia.googlecode.com/svn/trunk@14543 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add a fix for a spurious assert in SkMatrixConvolutionImageFilter.Gravatar senorblanco@chromium.org2014-05-01
| | | | | | | | | | | | | | | When matrix convolution processes border pixels with zero width, it asserts in getAddr32() with an invalid x coordinate. The assert is harmless, since the returned pointer is never accessed (the next line is a loop from left to right, which does nothing, since left == right). However, the fix is simple: early out on an empty rect before entering the outer loop. R=sugoi@chromium.org Review URL: https://codereview.chromium.org/265693005 git-svn-id: http://skia.googlecode.com/svn/trunk@14497 2bbb7eff-a529-9590-31e7-b0007b416f81
* one valgrind.supp to rule them all.Gravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | R=mtklein@google.com, robertphillips@google.com, borenet@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/268473004 git-svn-id: http://skia.googlecode.com/svn/trunk@14487 2bbb7eff-a529-9590-31e7-b0007b416f81
* Add Valgrind suppressions for nvidia driver.Gravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | | | | Did we recently switch the machine Valgrind runs on from an ati card to an nvidia one? BUG=skia: R=bsalomon@google.com, borenet@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/266473010 git-svn-id: http://skia.googlecode.com/svn/trunk@14482 2bbb7eff-a529-9590-31e7-b0007b416f81
* Avoid undefined behavior and enable asserts in ClampTest.Gravatar commit-bot@chromium.org2014-04-30
| | | | | | | | | | | | | | | The old code here wasn't being careful to avoid int32_t overflow in slow_check. Fix that. R_ASSERT hasn't been doing anything for a while. As a result, there are a couple bugs in SkClampRange, marked as such and commented out. The asserts also weren't quite passing, so I fixed them up (allowing 0xFFFF to be considered either as part of the ramp or part of V1.) BUG=skia:2481 R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/260523004 git-svn-id: http://skia.googlecode.com/svn/trunk@14479 2bbb7eff-a529-9590-31e7-b0007b416f81