aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core
Commit message (Collapse)AuthorAge
* Speculative revert to diagnose crash in chrome. Revert "Add SkCachedData and ↵Gravatar reed2014-10-03
| | | | | | | | | | | use it for SkMipMap" This reverts commit 92561a0b99ad6c08ab7a11dd1872f028199392e9. crasher in question: https://code.google.com/p/chromium/issues/detail?id=420178 Review URL: https://codereview.chromium.org/617613003
* remove unused TextBufferDirection enumGravatar reed2014-10-03
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/621403002
* Don't turn on dither for saveLayers which have no paintGravatar robertphillips2014-10-03
| | | | | | | | Only the gpu, 565 and msaa configs of GMs in ignored-tests.txt need rebaselining. NOTRY=true Review URL: https://codereview.chromium.org/619363002
* Add isSingleComponent bool to getConstantColorComponentGravatar egdaniel2014-10-03
| | | | | | | | | | Initial step to allowing effects to use/output 1 or 4 color/coverage components. This cl doesn't change any current logic and all effects still assume they are working with 4 components. BUG=skia: Committed: https://skia.googlesource.com/skia/+/3b8af078281a5a20f951b9fd84f38d92b8f6217b Review URL: https://codereview.chromium.org/608253002
* make SkMatrix::dump always availableGravatar reed2014-10-02
| | | | | | | BUG=skia: TBR= Review URL: https://codereview.chromium.org/624783002
* Add SkCachedData and use it for SkMipMapGravatar reed2014-10-02
| | | | Review URL: https://codereview.chromium.org/592843003
* Use +- 2B for unbounded draw ops.Gravatar mtklein2014-10-02
| | | | | | | | This lets us skip a check inside SkTileGrid::insert(). BUG=skia: Review URL: https://codereview.chromium.org/620093006
* specialize setConcat for scale+translateGravatar reed2014-10-02
| | | | | | | | This reverts commit 2a382f519999109b2e3445e73ddb4f0eae926b51. BUG=skia: Review URL: https://codereview.chromium.org/626583002
* Revert of Add isSingleComponent bool to getConstantColorComponent (patchset ↵Gravatar robertphillips2014-10-02
| | | | | | | | | | | | | | | | | | | | | | | #6 id:100001 of https://codereview.chromium.org/608253002/) Reason for revert: Changing some GMs Original issue's description: > Add isSingleComponent bool to getConstantColorComponent > > Initial step to allowing effects to use/output 1 or 4 color/coverage components. This cl doesn't change any current logic and all effects still assume they are working with 4 components. > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/3b8af078281a5a20f951b9fd84f38d92b8f6217b TBR=joshualitt@chromium.org,bsalomon@google.com,reed@google.com,egdaniel@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/617853003
* Caching the result of readPixelsSupportedGravatar piotaixr2014-10-02
| | | | | | | | | | | | | | | | | The call was calling GR_GL_GetIntegerv 2 times for each readPixels and thus was causing a loss of performance (resubmit of issue 344793008) Benchmark url: http://packages.gkny.fr/tst/index.html BUG=skia:2681 Committed: https://skia.googlesource.com/skia/+/753a2964afe5661ce9b2a8ca77ca9d0aabd3173c Committed: https://skia.googlesource.com/skia/+/8339371f1ec3c57a0741932fd96bff32c53d4e54 Review URL: https://codereview.chromium.org/364193004
* Add isSingleComponent bool to getConstantColorComponentGravatar egdaniel2014-10-02
| | | | | | | | Initial step to allowing effects to use/output 1 or 4 color/coverage components. This cl doesn't change any current logic and all effects still assume they are working with 4 components. BUG=skia: Review URL: https://codereview.chromium.org/608253002
* Demote getCount, getDepth, and clear to RTree-only methods.Gravatar mtklein2014-10-02
| | | | | | | | We use them only to test RTree. BUG=skia: Review URL: https://codereview.chromium.org/622773003
* Archive more dead code.Gravatar mtklein2014-10-02
| | | | | | | | These classes were used by QuadTree, which has been archived (with prejudice). BUG=skia: Review URL: https://codereview.chromium.org/616963006
* TileGrid: earliest need not be a pointer anymoreGravatar mtklein2014-10-02
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/625573003
* 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
* Revert of specialize setConcat for scale+translate (patchset #1 id:1 of ↵Gravatar robertphillips2014-10-02
| | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/620433002/) Reason for revert: Experimental to see if this revert "fixes" nanobench on the main console. Original issue's description: > specialize setConcat for scale+translate, helps drawText perf > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/e8db3ef2a2161084fa8eb1fd1d54c35bfff52d6c TBR=jvanverth@google.com,reed@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/620973003
* fix prev change to tooBigForLCD, and add testGravatar reed2014-10-01
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/617353003
* Don't adjust the bounds after a restore with the restore's paired ↵Gravatar mtklein2014-10-01
| | | | | | | | | | | | saveLayer's paint. It makes no sense for the paint from a saveLayer to effect anything outside its saveLayer/restore block. But as currently written, we'll adjust the clip bounds just after a restore by that paint. Turns out the test I wrote for the last CL (which caused this bug) actually had the bug baked into its expectations. I've updated them and added some notes to explain. BUG=418417 Review URL: https://codereview.chromium.org/623563002
* avoid extra math work in MackRecGravatar reed2014-10-01
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/615053005
* Remove DEPRECATED_beginRecording().Gravatar mtklein2014-10-01
| | | | | | | | | | | | | | | This removes: 1) ability to record old pictures with SkPictureRecorder; 2) a couple tests specific to the old backend. The functionality of DEPRECATED_beginRecording() now lives in (private) SkPicture::Backport(), which is the only place we need it now. BUG=skia: TBR=reed@google.com Review URL: https://codereview.chromium.org/618303002
* optimize setRectFan and join -- from profiling drawTextGravatar reed2014-10-01
| | | | | | | | BUG=skia: NOTREECHECKS=True NOTRY=True Review URL: https://codereview.chromium.org/615993003
* Archive more dead code.Gravatar mtklein2014-09-30
| | | | | | | | | BUG=skia: R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/617003004
* Strip old backend recording down to essentialsGravatar mtklein2014-09-30
| | | | | | | | | | | | | | | | | | | | | | | | | Feature-wise, this removes: 1) BBH support; 2) peephole optimizations; 3) record-time text op specializations; 4) the guarantee that SkPaints are flattened. This deletes the optimizations GM, which only exists to test the peepholes of the old backend. SkRecord optimizations are unit tested, and if that ever fails we can think about adding another GM like this, but they're different enough we'd want to start from scratch anyway. We need to keep the code that plays back the specialized text ops around for a while for compatibility with existing .SKPs that have those ops recorded. BUG=skia: CQ_EXTRA_TRYBOTS=tryserver.skia:Canary-Chrome-Ubuntu13.10-Ninja-x86_64-ToT-Trybot R=robertphillips@google.com, reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/617953002
* Clean up SK_PICTURE_USE_SK_RECORD and SK_PICTURE_OPTIMIZE_SK_RECORD.Gravatar mtklein2014-09-30
| | | | | | | | | | | | | | | | | This folds the code through as if they were defined, which is the explicit state in both our build and Chrome's. This leaves the EXPERIMENTAL_ and DEPRECATED_ hooks in to be cleaned up or privatized later. CQ_EXTRA_TRYBOTS=tryserver.skia:Canary-Chrome-Ubuntu13.10-Ninja-x86_64-ToT-Trybot BUG=skia: R=reed@google.com, robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/616033002
* Remove support for SkPicture::clone().Gravatar mtklein2014-09-30
| | | | | | | | | | | | | | | | This folds SK_SUPPORT_LEGACY_PICTURE_CLONE through as undefined. Chrome's not used clone() for a month or two, and we don't use it ourselves. Don't think Android ever did. CQ_EXTRA_TRYBOTS=tryserver.skia:Canary-Chrome-Ubuntu13.10-Ninja-x86_64-ToT-Trybot BUG=skia: R=reed@google.com, mtklein@google.com, robertphillips@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/620533002
* remove obsolete code for SK_SUPPORT_LEGACY_IMAGEGENERATORAPIGravatar reed2014-09-30
| | | | | | | | | BUG=skia: R=reed@google.com Author: reed@chromium.org Review URL: https://codereview.chromium.org/613933002
* Archive SkFloatGravatar mtklein2014-09-30
| | | | | | | | | | | | https://crrev.com/610153002/ reminded me that it existed, but it's entirely unused and made moot by hardware FP. Might as well trim a few K off libskia. BUG=skia: R=reed@google.com, mtklein@google.com, tfarina@chromium.org Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/619563003
* specialize setConcat for scale+translate, helps drawText perfGravatar reed2014-09-30
| | | | | | | | | BUG=skia: R=jvanverth@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/620433002
* Revert of GrResourceCache2 manages scratch texture. (patchset #14 id:260001 ↵Gravatar robertphillips2014-09-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | of https://codereview.chromium.org/608883003/) Reason for revert: Turning bots red: Nanobench seems to be uniformly failing on Android (http://108.170.220.21:10117/builders/Perf-Android-Venue8-PowerVR-x86-Release/builds/99/steps/RunNanobench/logs/stdio) Ubuntu GTX660 32bit is failing in both Debug and Release on GM generation (it appears to be out of memory) (http://108.170.220.120:10117/builders/Test-Ubuntu12-ShuttleA-GTX660-x86-Debug/builds/2457/steps/GenerateGMs/logs/stdio) Original issue's description: > GrResourceCache2 manages scratch texture. > > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/3d398c876440deaab39bbf2a9b881c337e6dc8d4 R=bsalomon@google.com TBR=bsalomon@google.com NOTREECHECKS=true NOTRY=true BUG=skia: Author: robertphillips@google.com Review URL: https://codereview.chromium.org/611383003
* GrResourceCache2 manages scratch texture.Gravatar bsalomon2014-09-30
| | | | | | | | | BUG=skia: R=robertphillips@google.com Author: bsalomon@google.com Review URL: https://codereview.chromium.org/608883003
* remove alphatype from colortableGravatar reed2014-09-29
| | | | | | | | | | | the owning bitmap is (already) responsible for knowing the alphatype BUG=skia: R=djsollen@google.com Author: reed@google.com Review URL: https://codereview.chromium.org/611093002
* Temp fix for crash when generating 16-bit cache for colorTables.Gravatar djsollen2014-09-29
| | | | | | | | | BUG=skia:2795 R=reed@google.com Author: djsollen@google.com Review URL: https://codereview.chromium.org/617443002
* Revert of Revert of Fix SkTextBlob offset semantics. (patchset #1 id:1 of ↵Gravatar fmalita2014-09-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/609223003/) Reason for revert: Re-landing: Chromium-side fix to be landed with the roll (https://codereview.chromium.org/607853003/) Original issue's description: > Revert of Fix SkTextBlob offset semantics. (patchset #2 id:20001 of https://codereview.chromium.org/605533002/) > > Reason for revert: > Breaking the Chrome builds with the error: > > [14:54:14.317833] ../../skia/ext/pixel_ref_utils.cc:221:16: error: 'drawPosText' marked 'override' but does not override any member functions > [14:54:14.318022] virtual void drawPosText(const SkDraw& draw, > [14:54:14.318082] ^ > > Original issue's description: > > Fix SkTextBlob offset semantics. > > > > Implement proper x/y drawTextBlob() handling by plumbing a > > drawPosText() offset parameter (to act as an additional glyph pos > > translation) throughout the device layer. > > > > The new offset superceeds the existing constY, with a minor semantic > > tweak: whereas previous implementations were ignoring constY in 2D > > positioning mode (scalarsPerGlyph == 2), now the offset is always > > observed, in all positioning modes. We can do this because existing > > drawPosText() clients always pass constY == 0 for full positioning mode. > > > > R=reed@google.com, jvanverth@google.com, robertphillips@google.com > > > > Committed: https://skia.googlesource.com/skia/+/c13bc571d3e61a43b87eb97f0719abd304cafaf2 > > TBR=jvanverth@google.com,reed@google.com,bsalomon@google.com,fmalita@chromium.org > NOTREECHECKS=true > NOTRY=true > > Committed: https://skia.googlesource.com/skia/+/d46b8d2bab7cfba8458432248e1568ac377429e9 R=jvanverth@google.com, reed@google.com, bsalomon@google.com, robertphillips@google.com TBR=bsalomon@google.com, jvanverth@google.com, reed@google.com, robertphillips@google.com NOTREECHECKS=true NOTRY=true Author: fmalita@chromium.org Review URL: https://codereview.chromium.org/607413003
* Always force the bounds of the empty pathref.Gravatar mtklein2014-09-29
| | | | | | | | | | | | | | | | | Chrome's TSAN bots are seeing various races on the bounds of the empty path ref, and it's a simple fix to just force them on creation. In fact, we used to do this for this very reason, but for some reason it looks like I decided it wasn't necessary. Maybe not, but it certainly doesn't hurt, and it's nice to keep TSAN happy. Reminder to self: merge this into M39 branch too. BUG=418299 R=fmalita@chromium.org, robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/603503003
* Revert of Fix SkTextBlob offset semantics. (patchset #2 id:20001 of ↵Gravatar robertphillips2014-09-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/605533002/) Reason for revert: Breaking the Chrome builds with the error: [14:54:14.317833] ../../skia/ext/pixel_ref_utils.cc:221:16: error: 'drawPosText' marked 'override' but does not override any member functions [14:54:14.318022] virtual void drawPosText(const SkDraw& draw, [14:54:14.318082] ^ Original issue's description: > Fix SkTextBlob offset semantics. > > Implement proper x/y drawTextBlob() handling by plumbing a > drawPosText() offset parameter (to act as an additional glyph pos > translation) throughout the device layer. > > The new offset superceeds the existing constY, with a minor semantic > tweak: whereas previous implementations were ignoring constY in 2D > positioning mode (scalarsPerGlyph == 2), now the offset is always > observed, in all positioning modes. We can do this because existing > drawPosText() clients always pass constY == 0 for full positioning mode. > > R=reed@google.com, jvanverth@google.com, robertphillips@google.com > > Committed: https://skia.googlesource.com/skia/+/c13bc571d3e61a43b87eb97f0719abd304cafaf2 R=jvanverth@google.com, reed@google.com, bsalomon@google.com, fmalita@chromium.org TBR=bsalomon@google.com, fmalita@chromium.org, jvanverth@google.com, reed@google.com NOTREECHECKS=true NOTRY=true Author: robertphillips@google.com Review URL: https://codereview.chromium.org/609223003
* Rename SkImage::draw(_, SkRect, SkRect) in SkImage::drawRect()Gravatar piotaixr2014-09-26
| | | | | | | | | BUG=skia:2947 R=reed@google.com, junov@chromium.org Author: piotaixr@chromium.org Review URL: https://codereview.chromium.org/605843002
* Fix SkTextBlob offset semantics.Gravatar Florin Malita2014-09-26
| | | | | | | | | | | | | | | | Implement proper x/y drawTextBlob() handling by plumbing a drawPosText() offset parameter (to act as an additional glyph pos translation) throughout the device layer. The new offset superceeds the existing constY, with a minor semantic tweak: whereas previous implementations were ignoring constY in 2D positioning mode (scalarsPerGlyph == 2), now the offset is always observed, in all positioning modes. We can do this because existing drawPosText() clients always pass constY == 0 for full positioning mode. R=reed@google.com, jvanverth@google.com, robertphillips@google.com Review URL: https://codereview.chromium.org/605533002
* Seems that some of our compliers can't infer this type, though most can.Gravatar Mike Klein2014-09-25
| | | | | | BUG=skia: Review URL: https://codereview.chromium.org/603263002
* Remove SkPaint dirty bits.Gravatar mtklein2014-09-25
| | | | | | | | | | | | | | | | | | | | | | | fDirtyBits is only used by SkPaint::FlatteningTraits, which in turn was only used as a smaller, faster format to flatten paints in-memory to dedup them in the old picture backend. SkRecord obsoleted all this. Neither flatten()/unflatten() (disk format) nor FlatteningTraits is used anywhere performance or size matters. Here I revert the deduping code back to using the disk format for flattened paints. We stil do have to flatten and unflatten paints while coverting from SkRecord backend to the old backend, so we can't just delete this all yet, but any faithful round trip flatten()/unflatten() pair will be fine, however slow. NOTRY=true BUG=skia: R=reed@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/604813003
* 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
* Fix SkXfermode deserialization.Gravatar senorblanco2014-09-24
| | | | | | | | | | | Validation was failing due to an inverted test condition. BUG=417266 R=reed@google.com Author: senorblanco@chromium.org Review URL: https://codereview.chromium.org/596333002
* 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
* Swap iteration order in TileGrid::insert().Gravatar mtklein2014-09-24
| | | | | | | | | | | | | Was looking at performance here (it's the record hotspot) and noticed we iterate through the grid out of order. This is a tiny little thing, but it's probably orthogonal to any other performance improvements we'll make in here. BUG=skia: R=robertphillips@google.com, mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/598933004
* 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
* We need to adjust the bounds of clip ops with SaveLayer paints too.Gravatar Mike Klein2014-09-23
| | | | | | | | | | | | | Before this CL, SkRecord only adjusted the bounds of draw ops for SaveLayers' paints. That worked fine, but as a final step we intersect the bounds of draw ops with the bounds of the current clip, essentially undoing all that work. I think the right fix here is to also adjust the bounds of the clip ops. BUG=skia:2957, 415468 R=robertphillips@google.com Review URL: https://codereview.chromium.org/595953002
* Patch to create a distinct geometry processor. The vast majority of this patchGravatar joshualitt2014-09-23
| | | | | | | | | | | | | is just a rename. The meat is in GrGeometryProcessor, GrProcessor, GrGL*Processor, GrProcessorStage, Gr*BackendProcessorFactory, GrProcessUnitTestFactory, and the builders BUG=skia: R=bsalomon@google.com Author: joshualitt@chromium.org Review URL: https://codereview.chromium.org/582963002
* Make a flipped fDirtyBit always mean "this field is not the default".Gravatar mtklein2014-09-22
| | | | | | | | | | | Haven't been able to measure any perf effect, so I figure I'll let the bots have at it. BUG=skia: R=mtklein@google.com Author: mtklein@chromium.org Review URL: https://codereview.chromium.org/595583003
* Introduce Props to surface (patchset #27 id:520001 of ↵Gravatar reed2014-09-22
| | | | | | | | | | | | https://codereview.chromium.org/551463004/)" This reverts commit 29c857d0f3a1cb837f73406eeb6ba9771879b5e7. TBR= Author: reed@google.com Review URL: https://codereview.chromium.org/588143004
* Revert of introduce Props to surface (patchset #27 id:520001 of ↵Gravatar reed2014-09-21
| | | | | | | | | | | | | | | | | | | | | | | | https://codereview.chromium.org/551463004/) Reason for revert: Broke call site in WebKit Original issue's description: > introduce Props to surface (work in progress) > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/3716fd067a5621bb94a6cb08d72afec8bf3aceda R=robertphillips@google.com, bsalomon@google.com, jvanverth@google.com, bungeman@google.com, fmalita@google.com, vangelis@chromium.org, reed@google.com TBR=bsalomon@google.com, bungeman@google.com, fmalita@google.com, jvanverth@google.com, reed@google.com, robertphillips@google.com, vangelis@chromium.org NOTREECHECKS=true NOTRY=true BUG=skia: Author: reed@chromium.org Review URL: https://codereview.chromium.org/583773004
* introduce Props to surface (work in progress)Gravatar reed2014-09-21
| | | | | | | | | BUG=skia: R=robertphillips@google.com, bsalomon@google.com, jvanverth@google.com, bungeman@google.com, fmalita@google.com, vangelis@chromium.org, reed@chromium.org Author: reed@google.com Review URL: https://codereview.chromium.org/551463004