History log of /external/skia/src/core/SkRecordDraw.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
23d8593f8127411d9d687b4565b34b4ecd6b11d3 07-Mar-2015 schenney <schenney@chromium.org> Update SkPicture cull rects with RTree information

When computed, the RTree for an SkPicture will have a root
bounds that reflects the best bounding information available,
rather than the best estimate at the time the picture recorder
is created. Given that creators frequently don't know ahead of
time what will be drawn, the RTree bound is often tighter.

Perf testing on Chrome indicates a small raster performance
advantage. For upcoming painting changes in Chrome the
performance advantage is much larger.

BUG=

Committed: https://skia.googlesource.com/skia/+/2dd3b6647dc726f36fd8774b3d0d2e83b493aeac

Review URL: https://codereview.chromium.org/971803002
/external/skia/src/core/SkRecordDraw.cpp
a0865b4620cc614586a5c02f258da2436ed3ab2b 05-Mar-2015 joshualitt <joshualitt@google.com> Revert of Update SkPicture cull rects with RTree information (patchset #6 id:140001 of https://codereview.chromium.org/971803002/)

Reason for revert:
Might be breaking deps roll

Original issue's description:
> Update SkPicture cull rects with RTree information
>
> When computed, the RTree for an SkPicture will have a root
> bounds that reflects the best bounding information available,
> rather than the best estimate at the time the picture recorder
> is created. Given that creators frequently don't know ahead of
> time what will be drawn, the RTree bound is often tighter.
>
> Perf testing on Chrome indicates a small raster performance
> advantage. For upcoming painting changes in Chrome the
> performance advantage is much larger.
>
> BUG=
>
> Committed: https://skia.googlesource.com/skia/+/2dd3b6647dc726f36fd8774b3d0d2e83b493aeac

TBR=mtklein@google.com,schenney@chromium.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/977413003
/external/skia/src/core/SkRecordDraw.cpp
2dd3b6647dc726f36fd8774b3d0d2e83b493aeac 05-Mar-2015 schenney <schenney@chromium.org> Update SkPicture cull rects with RTree information

When computed, the RTree for an SkPicture will have a root
bounds that reflects the best bounding information available,
rather than the best estimate at the time the picture recorder
is created. Given that creators frequently don't know ahead of
time what will be drawn, the RTree bound is often tighter.

Perf testing on Chrome indicates a small raster performance
advantage. For upcoming painting changes in Chrome the
performance advantage is much larger.

BUG=

Review URL: https://codereview.chromium.org/971803002
/external/skia/src/core/SkRecordDraw.cpp
bfd5bff75c0ce27a70f02e4b5578d66aa9d6e306 10-Feb-2015 mtklein <mtklein@chromium.org> Simplify SkBBH::insert API

No one's exploiting the ability to take ownership of the array anymore.

BUG=skia:

Review URL: https://codereview.chromium.org/913833002
/external/skia/src/core/SkRecordDraw.cpp
3cb3840c9af6f70896cf5565a38d4ee03c02d767 06-Feb-2015 reed <reed@google.com> Rename SkCanvasDrawable to SkDrawable, and make public

(patchset #2 id:20001 of https://codereview.chromium.org/903993002/)"

This reverts commit c4e87724920222a218f31b22612efc5b1ec0ed6c.

BUG=skia:
TBR=
NOTREECHECKS=True

Review URL: https://codereview.chromium.org/898343004
/external/skia/src/core/SkRecordDraw.cpp
c4e87724920222a218f31b22612efc5b1ec0ed6c 06-Feb-2015 reed <reed@google.com> Revert of rename SkCanvasDrawable to SkDrawable, and make public (patchset #2 id:20001 of https://codereview.chromium.org/903993002/)

Reason for revert:
bug in gyp

Original issue's description:
> rename SkCanvasDrawable to SkDrawable, and make public
>
> BUG=skia:
> NOTRY=True
> ... winbuilder flake
>
> Committed: https://skia.googlesource.com/skia/+/4ae9eb7463cf2160723407359608f221c0d5e2a6

TBR=robertphillips@google.com,djsollen@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/882853006
/external/skia/src/core/SkRecordDraw.cpp
4ae9eb7463cf2160723407359608f221c0d5e2a6 06-Feb-2015 reed <reed@google.com> rename SkCanvasDrawable to SkDrawable, and make public

BUG=skia:
NOTRY=True
... winbuilder flake

Review URL: https://codereview.chromium.org/903993002
/external/skia/src/core/SkRecordDraw.cpp
783fe16b8ed1cd1cff34eacc33296874a32f293b 07-Jan-2015 robertphillips <robertphillips@google.com> Rename SkDrawPictureCallback to SkPicture::AbortCallback

Committed: https://skia.googlesource.com/skia/+/7ef197255deb4e2fa64c03c7130d56ddf164e83c

Review URL: https://codereview.chromium.org/829983003
/external/skia/src/core/SkRecordDraw.cpp
8ea6dabbb15ef276645b7a6ebab44a4a532ac990 07-Jan-2015 reed <reed@chromium.org> Revert of Rename SkDrawPictureCallback to SkPicture::AbortCallback (patchset #2 id:20001 of https://codereview.chromium.org/829983003/)

Reason for revert:
speculative revert to unblock DEPS roll

Original issue's description:
> Rename SkDrawPictureCallback to SkPicture::AbortCallback
>
> Committed: https://skia.googlesource.com/skia/+/7ef197255deb4e2fa64c03c7130d56ddf164e83c

TBR=reed@google.com,robertphillips@google.com
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/824013004
/external/skia/src/core/SkRecordDraw.cpp
7ef197255deb4e2fa64c03c7130d56ddf164e83c 06-Jan-2015 robertphillips <robertphillips@google.com> Rename SkDrawPictureCallback to SkPicture::AbortCallback

Review URL: https://codereview.chromium.org/829983003
/external/skia/src/core/SkRecordDraw.cpp
49aabde6ef80e39f00a2d00487cf5a881987dd81 05-Jan-2015 mtklein <mtklein@chromium.org> Clean up dead clear() code in SkRecord.

This removes the SkRecords::Clear struct and everything that refers to it.
Notice there is nothing actually creating a Clear, which means this is all
dead code.

Now that all ops obey the clip, I don't think we need the weird
inflate-empty-to-epsilon hack for BBH queries.

BUG=skia:

Review URL: https://codereview.chromium.org/835813002
/external/skia/src/core/SkRecordDraw.cpp
c4fda92f45b9649f233a5b8636618a6431aa59cb 02-Jan-2015 reed <reed@chromium.org> remove unused drawData

BUG=skia:

Review URL: https://codereview.chromium.org/830083002
/external/skia/src/core/SkRecordDraw.cpp
c187a3c8849ba5e409f79ead21cd5bc82173d9f8 30-Dec-2014 robertphillips <robertphillips@google.com> Fix computation of bound in FillBounds::updateSaveBounds

intersect doesn't change the bounds when the two bounds do not intersect. This is definitely not the intended behavior.

With the SKPs captured on 12/23/14, Chrome began passing Skia drawPicture ops that did not intersect the current clip - which revealed this bug.

Review URL: https://codereview.chromium.org/817483004
/external/skia/src/core/SkRecordDraw.cpp
478dd723362fefc2023aee03e11216d913eeac03 16-Dec-2014 robertphillips <robertphillips@google.com> Fix layer hoisting image filter corner cases

This CL fixes 5 bugs related to hoisting image filters:

For image filters the src layer (the one prior to filtering) often needs to be
smaller then the final layer. This requires the saveLayer's optional bounds
to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in
compute_source_rect and carried around in GrCachedLayer.

The image filters can add an extra offset to the final draw operation.
This is now computed in GrLayerHoister::FilterLayer and carried around in
GrCachedLayer.

Filtered layers must use exact matches. This is now done in GrLayerCache::lock.

The filter cache requires a valid matrix so it can compute the correct offset.
This is now done in GrLayerHoister::FilterLayer.

Filtered layers need to be drawn with drawSprite while unfiltered (and therefore
hopefully atlased) layers can be drawn with drawBitmap. This is now done in
draw_replacement_bitmap.

Committed: https://skia.googlesource.com/skia/+/702eb9622102599d94ab6798e6227cf29f48c2d3

Review URL: https://codereview.chromium.org/803183003
/external/skia/src/core/SkRecordDraw.cpp
86f032832fc3527ab561bcbd9d2a546f7f676f73 16-Dec-2014 robertphillips <robertphillips@google.com> Revert of Fix layer hoisting image filter corner cases (patchset #3 id:40001 of https://codereview.chromium.org/803183003/)

Reason for revert:
Breaking DM

Original issue's description:
> Fix layer hoisting image filter corner cases
>
> This CL fixes 5 bugs related to hoisting image filters:
>
> For image filters the src layer (the one prior to filtering) often needs to be
> smaller then the final layer. This requires the saveLayer's optional bounds
> to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in
> compute_source_rect and carried around in GrCachedLayer.
>
> The image filters can add an extra offset to the final draw operation.
> This is now computed in GrLayerHoister::FilterLayer and carried around in
> GrCachedLayer.
>
> Filtered layers must use exact matches. This is now done in GrLayerCache::lock.
>
> The filter cache requires a valid matrix so it can compute the correct offset.
> This is now done in GrLayerHoister::FilterLayer.
>
> Filtered layers need to be drawn with drawSprite while unfiltered (and therefore
> hopefully atlased) layers can be drawn with drawBitmap. This is now done in
> draw_replacement_bitmap.
>
> Committed: https://skia.googlesource.com/skia/+/702eb9622102599d94ab6798e6227cf29f48c2d3

TBR=bsalomon@google.com
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/790643009
/external/skia/src/core/SkRecordDraw.cpp
702eb9622102599d94ab6798e6227cf29f48c2d3 16-Dec-2014 robertphillips <robertphillips@google.com> Fix layer hoisting image filter corner cases

This CL fixes 5 bugs related to hoisting image filters:

For image filters the src layer (the one prior to filtering) often needs to be
smaller then the final layer. This requires the saveLayer's optional bounds
to be stored (in SkLayerInfo.h and SkRecordDraw.cpp) and then used in
compute_source_rect and carried around in GrCachedLayer.

The image filters can add an extra offset to the final draw operation.
This is now computed in GrLayerHoister::FilterLayer and carried around in
GrCachedLayer.

Filtered layers must use exact matches. This is now done in GrLayerCache::lock.

The filter cache requires a valid matrix so it can compute the correct offset.
This is now done in GrLayerHoister::FilterLayer.

Filtered layers need to be drawn with drawSprite while unfiltered (and therefore
hopefully atlased) layers can be drawn with drawBitmap. This is now done in
draw_replacement_bitmap.

Review URL: https://codereview.chromium.org/803183003
/external/skia/src/core/SkRecordDraw.cpp
9a5380dd358a9c559a41beef7cb368cd7f0ca51f 16-Dec-2014 mtklein <mtklein@google.com> Revert of Use SkPaint::getFontBounds() for text bounding boxes in pictures. (patchset #1 id:1 of https://codereview.chromium.org/805983003/)

Reason for revert:
Test-Win7-ShuttleA-HD2000-x86-Debug-GDI

Original issue's description:
> Use SkPaint::getFontBounds() for text bounding boxes in pictures.
>
> Now that SkTextBlobs have landed, this is a perf no-op, but it at least lets us eliminate a bunch of questionable hacks.
>
> CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot,Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Debug-Trybot
>
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/02d2b9831579173e783569530ab7bae08de907e9

TBR=reed@google.com,mtklein@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/789793004
/external/skia/src/core/SkRecordDraw.cpp
02d2b9831579173e783569530ab7bae08de907e9 16-Dec-2014 mtklein <mtklein@chromium.org> Use SkPaint::getFontBounds() for text bounding boxes in pictures.

Now that SkTextBlobs have landed, this is a perf no-op, but it at least lets us eliminate a bunch of questionable hacks.

CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot,Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Debug-Trybot

BUG=skia:

Review URL: https://codereview.chromium.org/805983003
/external/skia/src/core/SkRecordDraw.cpp
f0f14113431ace669f278fdd97b50950f2cf4c80 12-Dec-2014 mtklein <mtklein@chromium.org> Cull pushCull and popCull from Skia.

These calls are unused and going away. Waiting on crrev.com/796083002.

BUG=skia:

Review URL: https://codereview.chromium.org/794263002
/external/skia/src/core/SkRecordDraw.cpp
f55c314bfa6db980941f8d0ab485beb2e08589ab 11-Dec-2014 mtklein <mtklein@chromium.org> Enforce thread-safety of bitmaps in pictures via the type.

No runtime difference here, but it makes it impossible to forget to make
a shallow copy; you can't get at the full bitmap without it.

NOTREECHECKS=true

BUG=skia:

Review URL: https://codereview.chromium.org/799603002
/external/skia/src/core/SkRecordDraw.cpp
c54d8db4d169ea5f2af2a9a2349df007bd428475 10-Dec-2014 Florin Malita <fmalita@google.com> Remove SkCanvas::drawBitmapMatrix()

R=mtklein@google.com, reed@google.com, robertphillips@google.com

Review URL: https://codereview.chromium.org/789033002
/external/skia/src/core/SkRecordDraw.cpp
8eddfb50c0c9e4bcba6384a2ce39852b5fb5becb 04-Dec-2014 reed <reed@google.com> Change clear() to respect the clip

This reverts commit af641a1c10f176cb9617026d3cc93c117a85d13d.

BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/783493002
/external/skia/src/core/SkRecordDraw.cpp
e99d499caa7dbc80b58e0faf5ce137e7d30cc5d0 03-Dec-2014 robertphillips <robertphillips@google.com> Fuse GrReplacements and GrLayerCache

The conversion step from GrCachedLayer to ReplacementInfo isn't necessary.

Review URL: https://codereview.chromium.org/769533004
/external/skia/src/core/SkRecordDraw.cpp
af641a1c10f176cb9617026d3cc93c117a85d13d 03-Dec-2014 reed <reed@chromium.org> Revert "Change clear() to respect the clip"

This reverts commit 3729469d6a12266037b697c2192768545e097ab0.

BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/778563002
/external/skia/src/core/SkRecordDraw.cpp
3729469d6a12266037b697c2192768545e097ab0 02-Dec-2014 reed <reed@google.com> Change clear() to respect the clip

patch from issue 769703002 at patchset 1 (http://crrev.com/769703002#ps1)

BUG=skia:

Review URL: https://codereview.chromium.org/772533004
/external/skia/src/core/SkRecordDraw.cpp
af57903f330a0afd0c10244d4a66f64fdbef5d1e 01-Dec-2014 mtklein <mtklein@chromium.org> Force SkMatrix type while recording too.

This switches to a new way of doing this, enforcing the caching with the type
recorded rather than having to do it in SkRecorder. Should be more foolproof.

Updated SkPath and SkBitmap's equivalents too. ImmutableBitmap was close,
but using inheritance now makes the rest of the code less weird.

BUG=437511

I'm not sure whether or not this will _fix_ the SkMatrix aspect of that bug.
There may be other SkMatrices that we're racing on. It does cover the obvious
ones, though, and removing the SkTRacy<> wrapper will allow TSAN to show
us any other races.

It turned out to be easier to turn missing optional matrices into I early rather
than late. I figure this should be harmless. Recording and playback perf both
look neutral.

Review URL: https://codereview.chromium.org/773433003
/external/skia/src/core/SkRecordDraw.cpp
01d6e5f462d1d52203ee1a6660415877e4cf2dde 01-Dec-2014 robertphillips <robertphillips@google.com> Use variable length key (rather than accumulated matrix) as save layer hoisting key

Adding the rendering canvas' CTM to the layer hoisting key (i.e., Add support for hoisting layers in pictures drawn with a matrix - https://codereview.chromium.org/748853002/) has increased the cache miss rate due to accumulated floating point error. This CL fixes part of the issue by using the chain of operation indices leading to each saveLayer as the key. The canvas' CTM must still form part of the key but should be less subject to accumulated error.

BUG=skia:2315

Review URL: https://codereview.chromium.org/753253002
/external/skia/src/core/SkRecordDraw.cpp
1bdfd3f4f09e47364f76d3f08177b1ce844ac786 24-Nov-2014 reed <reed@google.com> option to return drawable from recording

patch from issue 747033005 at patchset 80001 (http://crrev.com/747033005#ps80001)

BUG=skia:

Review URL: https://codereview.chromium.org/732653004
/external/skia/src/core/SkRecordDraw.cpp
42ddcd49060f64be57f00e651650154f9b4f3a08 21-Nov-2014 mtklein <mtklein@chromium.org> All the small packing tweaks mentioned in the bug.

BUG=skia:3144

Review URL: https://codereview.chromium.org/748063002
/external/skia/src/core/SkRecordDraw.cpp
cdeeb095a629b0db9f0ddff09516f2b78255c047 20-Nov-2014 mtklein <mtklein@chromium.org> SkRecord: Pack SkRegion::Op and AA bit together.

Saves 4 bytes per clip op.

BUG=skia:

Review URL: https://codereview.chromium.org/741093002
/external/skia/src/core/SkRecordDraw.cpp
7cc1a34fbf5506e3a9e6834f0dcd988aa7c94084 20-Nov-2014 mtklein <mtklein@chromium.org> Make sure pictures draw Clears even when the clip is empty.

We fix this by rewriting empty queries to very tiny queries, which will certainly
hit ops that span the entire picture (like Clear) and hopefully not much more.

(This doesn't quite work in the full cull rect world if [0,0,ε,ε] doesn't
overlap the picture. Let's cross that bridge when we get there.)

BUG=432991

Review URL: https://codereview.chromium.org/732723004
/external/skia/src/core/SkRecordDraw.cpp
72f92acd47a884b9a1cc961a822a2d4e586b54c1 19-Nov-2014 mtklein <mtklein@chromium.org> No need to short circuit the query rect here anymore.

Whatever assertion was triggering in SkRTree.cpp seems to be gone now.

BUG=432991

Review URL: https://codereview.chromium.org/725373003
/external/skia/src/core/SkRecordDraw.cpp
6be2aa9a251bf6022570a03140f956655b3ef1da 18-Nov-2014 reed <reed@google.com> wip for drawables

Idea:

1. in its mutable recording state, keep a table of drawables on the side, and store an index in the record list.

2. In "immediate-mode" draw, just call the clients drawable directly (need access to our private list to turn the stored index into a proc)

3. when we "snap", we replace the list of drawables with a list of (sub) pictures, and then during playback of the snapped picture, we invoke a private drawable which just calls "drawPicture" on the index'd subpicture.

Review URL: https://codereview.chromium.org/727363003
/external/skia/src/core/SkRecordDraw.cpp
8910879098694c61267e21789d933928c1b7995e 17-Nov-2014 robertphillips <robertphillips@google.com> Make BBH parameter to SkRecordComputeLayers and SkRecordFillBounds optional

Chromium creates a picture to contain their picture pile in order to use MultiPictureDraw. They currently do not create a bounding box for that picture but I still need layer information for it. This change allows Chromium to continue without a BBH but still have layer information.

In the future, the brute force BBH might be suitable for their use case.

Please see gpu_raster_worker_pool.cc in (Add flag to beginRecording to request saveLayer information - https://codereview.chromium.org/721883002/) for where this is happening in Chromium.

Review URL: https://codereview.chromium.org/733963004
/external/skia/src/core/SkRecordDraw.cpp
82365915476caedc130d0e36012a1ce0c007c4ae 12-Nov-2014 robertphillips <robertphillips@google.com> Rename GrAccelData to SkLayerInfo and move it to src/core

Review URL: https://codereview.chromium.org/719133002
/external/skia/src/core/SkRecordDraw.cpp
74576eba1440c092025d6557e08da50678599d4e 12-Nov-2014 robertphillips <robertphillips@google.com> Clean up CollectLayers code

Now that CollectLayers directly uses FillBounds we can:

skip the explicit intersection with the clipBounds after an adjustAndMap call

skip the storage and use of the clipBounds in SaveLayerInfo

Review URL: https://codereview.chromium.org/719793002
/external/skia/src/core/SkRecordDraw.cpp
4e8e3421aa919a82eb1dd287fecbd079f5a320b4 12-Nov-2014 robertphillips <robertphillips@chromium.org> Move SkRecordComputeLayers and CollectLayers into SkRecordDraw.cpp

Rather then exposing parts of FillBounds (as in Expose FillBounds to allow GrPictureUtils::CollectLayers to be layered on top of it - https://codereview.chromium.org/698643002/), this CL moves CollectLayers into SkRecordDraw.cpp to accomplish the layering.

Review URL: https://codereview.chromium.org/716913003
/external/skia/src/core/SkRecordDraw.cpp
d239d425148e5c1445b6a99d9bc33348c41197bc 03-Nov-2014 danakj <danakj@chromium.org> Add comments to SkRecordDraw to help people follow.

The calls to visit() to execute the SkRecord::Draw::operator() code path
is not clear to read, so adding some comments to help other new-comers
follow this through to the SkCanvas calls.

R=mtklein@chromium.org

Review URL: https://codereview.chromium.org/695403003
/external/skia/src/core/SkRecordDraw.cpp
4d52afef5cf90a2fed3bb69db71675c6450ab397 03-Nov-2014 robertphillips <robertphillips@google.com> Shrink saveLayer device bounds when it supplies an explicit bounds and has a complex paint

This CL shrinks the bound computed for saveLayers that possess both an explicit
bound and a complex paint (e.g., one that affects transparent black). In this
case the bound of the layer should be the clipped explicit bound rather then
the clip prior/after the saveLayer/restore block.

In the following the first bound is the currently computed bound
while the second is the new/desired one:

For a 100x100 picture

saveLayer (no bound, no paint) [ 0 0 100 100 ] [ 50 50 100 100 ]
setMatrix (translate 50, 50) [ 0 0 100 100 ] [ 50 50 100 100 ]
saveLayer (bound of 0, 0, 50, 50 - complex paint) [ 0 0 100 100 ] [ 50 50 100 100 ]
restore [ 0 0 100 100 ] [ 50 50 100 100 ]
restore [ 0 0 100 100 ] [ 50 50 100 100 ]

Review URL: https://codereview.chromium.org/696763002
/external/skia/src/core/SkRecordDraw.cpp
a41d3c33bc4e335dd4702bb9915fdf31d31d6c24 30-Oct-2014 junov <junov@chromium.org> Make RTree handle the case where the playback canvas has empty clip bounds

BUG=skia:3074

Review URL: https://codereview.chromium.org/678303004
/external/skia/src/core/SkRecordDraw.cpp
ed167acb7b494bf0aece05ac8a68b560782b027c 30-Oct-2014 mtklein <mtklein@google.com> Revert of Use SkTypeface::getBounds() in bounding-box calculations. (patchset #5 id:80001 of https://codereview.chromium.org/680363003/)

Reason for revert:
Mac mini asserting

Original issue's description:
> Use SkTypeface::getBounds() in bounding-box calculations.
>
> This should produce tighter conservative bounding boxes for text than the
> approximation code it replaces.
>
> Recording performance is neutral on my desktop. Playback performance
> improves by up to 15% on text heavy pages, e.g.
>
> desk_pokemonwiki.skp_1 3.24ms -> 2.83ms 0.87x
> desk_baidu.skp_1 1.91ms -> 1.58ms 0.83x
>
> Committed: https://skia.googlesource.com/skia/+/bf8dc343df4fbdcb8af546eb68b640e011a33489
>
> CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot
>
> Committed: https://skia.googlesource.com/skia/+/c51add674dfb89b988a7fbc05f41838c203f9dcd

TBR=reed@google.com,mtklein@chromium.org
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/690833002
/external/skia/src/core/SkRecordDraw.cpp
c51add674dfb89b988a7fbc05f41838c203f9dcd 29-Oct-2014 mtklein <mtklein@chromium.org> Use SkTypeface::getBounds() in bounding-box calculations.

This should produce tighter conservative bounding boxes for text than the
approximation code it replaces.

Recording performance is neutral on my desktop. Playback performance
improves by up to 15% on text heavy pages, e.g.

desk_pokemonwiki.skp_1 3.24ms -> 2.83ms 0.87x
desk_baidu.skp_1 1.91ms -> 1.58ms 0.83x

Committed: https://skia.googlesource.com/skia/+/bf8dc343df4fbdcb8af546eb68b640e011a33489

CQ_EXTRA_TRYBOTS=client.skia:Test-Win7-ShuttleA-HD2000-x86-Debug-Trybot

Review URL: https://codereview.chromium.org/680363003
/external/skia/src/core/SkRecordDraw.cpp
27f965a577262deb9182c6935f3af05bb52b817c 29-Oct-2014 mtklein <mtklein@google.com> Revert of Use SkTypeface::getBounds() in bounding-box calculations. (patchset #3 id:40001 of https://codereview.chromium.org/680363003/)

Reason for revert:
http://build.chromium.org/p/client.skia/builders/Test-Win7-ShuttleA-HD2000-x86-Debug/builds/97/steps/nanobench/logs/stdio

Original issue's description:
> Use SkTypeface::getBounds() in bounding-box calculations.
>
> This should produce tighter conservative bounding boxes for text than the
> approximation code it replaces.
>
> Recording performance is neutral on my desktop. Playback performance
> improves by up to 15% on text heavy pages, e.g.
>
> desk_pokemonwiki.skp_1 3.24ms -> 2.83ms 0.87x
> desk_baidu.skp_1 1.91ms -> 1.58ms 0.83x
>
> Committed: https://skia.googlesource.com/skia/+/bf8dc343df4fbdcb8af546eb68b640e011a33489

TBR=reed@google.com,mtklein@chromium.org
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/685173002
/external/skia/src/core/SkRecordDraw.cpp
bf8dc343df4fbdcb8af546eb68b640e011a33489 29-Oct-2014 mtklein <mtklein@chromium.org> Use SkTypeface::getBounds() in bounding-box calculations.

This should produce tighter conservative bounding boxes for text than the
approximation code it replaces.

Recording performance is neutral on my desktop. Playback performance
improves by up to 15% on text heavy pages, e.g.

desk_pokemonwiki.skp_1 3.24ms -> 2.83ms 0.87x
desk_baidu.skp_1 1.91ms -> 1.58ms 0.83x

Review URL: https://codereview.chromium.org/680363003
/external/skia/src/core/SkRecordDraw.cpp
4477c3c0e6eb064772aefe8737425cd1c2ce557f 27-Oct-2014 mtklein <mtklein@chromium.org> Cut down SkBBH API more.
- 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
/external/skia/src/core/SkRecordDraw.cpp
41966d49b0cc9dd2250dac4417ed3b365fb6d704 20-Oct-2014 mtklein <mtklein@chromium.org> Dilate approximated text bounds to squelch recent assertion failure.

This is once again an issue related to logo fonts, so I don't
see any easy way to add a regression test for this.

BUG=424824

Review URL: https://codereview.chromium.org/665103002
/external/skia/src/core/SkRecordDraw.cpp
65151754b9fdb6a968d7307764c20655d1b680a0 16-Oct-2014 piotaixr <piotaixr@chromium.org> Override SkCanvas::drawImage() in SkRecorder.

BUG=skia:2947

Review URL: https://codereview.chromium.org/610003002
/external/skia/src/core/SkRecordDraw.cpp
19653d1d004610b4ba07ce563a5701164e120e45 16-Oct-2014 fmalita <fmalita@chromium.org> Implicit SkTextBlob bounds

Compute blob bounds when the client doesn't pass explicit run rects to
the builder. This allows us to remove a couple of internal workarounds.

R=reed@google.com,mtklein@google.com,bungeman@google.com

Review URL: https://codereview.chromium.org/654873003
/external/skia/src/core/SkRecordDraw.cpp
208d1704c2cc1161ea337a05155f2b9a04edd351 09-Oct-2014 mtklein <mtklein@chromium.org> Add SkBBoxHierarchy::reserve() as an optional size hint.

I want to play around with how SkTileGrid stores its tiles. Having a
cap on the number of insert() calls can be pretty handy.

While I'm at it, I gave flush() a default empty impl. Like reserve(),
it's really an optional hook for subclasses.

BUG=skia:

Review URL: https://codereview.chromium.org/639933003
/external/skia/src/core/SkRecordDraw.cpp
0a528c187ab2221e9720d17d1bc76123b5fa8788 02-Oct-2014 mtklein <mtklein@chromium.org> Use +- 2B for unbounded draw ops.

This lets us skip a check inside SkTileGrid::insert().

BUG=skia:

Review URL: https://codereview.chromium.org/620093006
/external/skia/src/core/SkRecordDraw.cpp
6bd41969a0f2283a7a7320bb0025551353c241ec 02-Oct-2014 mtklein <mtklein@chromium.org> BBHs: void* data -> unsigned data

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
/external/skia/src/core/SkRecordDraw.cpp
8e393bf70ea2aab9ca31f52c15b518436c7b6055 01-Oct-2014 mtklein <mtklein@chromium.org> Don't adjust the bounds after a restore with the restore's paired 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
/external/skia/src/core/SkRecordDraw.cpp
271a030f5d0d3c59715fbeffb31c761279f3f8ca 23-Sep-2014 Mike Klein <mtklein@chromium.org> We need to adjust the bounds of clip ops with SaveLayer paints too.

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
/external/skia/src/core/SkRecordDraw.cpp
9b222a5ddd3b39ca191d8443bade6052cdcb713d 18-Sep-2014 mtklein <mtklein@chromium.org> Simplify a little in SkRecords.h:

- ACT_AS_PTR can just expose const methods to get at the pointers.
(If the thing stored must stay const, we pass a const T.)
- DrawPatch works fine with Record# macros, so use Record5.

BUG=skia:
R=fmalita@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/585523003
/external/skia/src/core/SkRecordDraw.cpp
4815fe5a0a497b676677fb4e4a0f05c511855490 16-Sep-2014 robertphillips <robertphillips@google.com> Fix bug in layer hoisting transition to SkRecord backend

Care must be taken when setting up the initial CTM matrix for partial SkRecord playbacks b.c. all the setMatrix calls will concatenate with the initial matrix (which may be different then the CTM that is required to draw correctly).

R=mtklein@google.com, bsalomon@google.com

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/549143003
/external/skia/src/core/SkRecordDraw.cpp
327f905d2cb0d37c302d651d8f2b17ea56368467 15-Sep-2014 dneto <dneto@chromium.org> Fix recording of saveLayout with unusual Xfermodes.

This is the root cause of a Chrome rendering bug when it tiles
layers with masks.

BUG=skia:1291,chromium:401593
R=reed@google.com, mtklein@google.com, junov@chromium.org

Author: dneto@chromium.org

Review URL: https://codereview.chromium.org/568073004
/external/skia/src/core/SkRecordDraw.cpp
49f085dddff10473b6ebf832a974288300224e60 05-Sep-2014 bsalomon <bsalomon@google.com> "NULL !=" = NULL

R=reed@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/544233002
/external/skia/src/core/SkRecordDraw.cpp
29dfaa80f5776904f42b72b387a99e75f8dc5f5f 04-Sep-2014 mtklein <mtklein@chromium.org> Implement all SkCanvas overrides that SkPictureRecord does.

Primarily this is for isDrawingToLayer(). drawData() and onNewSurface() are
for completeness.

BUG=409138
R=robertphillips@google.com, mtklein@google.com, reed@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/545613002
/external/skia/src/core/SkRecordDraw.cpp
937c9c7eb4e06d4d3bc495e129c7b8103a5d6c0f 03-Sep-2014 mtklein <mtklein@chromium.org> Fix drawPosText() bounds bug.

We didn't catch this in our local tests because we tend to use default
kUTF8_TextEncoding with single-byte characters, which means N == byteLength.

BUG=409110
R=reed@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/531933002
/external/skia/src/core/SkRecordDraw.cpp
00f30bdc9e34b013da54b4406f36556c5be8d041 02-Sep-2014 mtklein <mtklein@chromium.org> SkRecordPartialDraw with less code duplication

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/527423002
/external/skia/src/core/SkRecordDraw.cpp
a8d7f0b13cd4c6d773fcf055fe17db75d260fa05 29-Aug-2014 robertphillips <robertphillips@google.com> Try out scalar picture sizes

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
/external/skia/src/core/SkRecordDraw.cpp
533eb782edaa0b6fece6166d3001edf72ec39f11 27-Aug-2014 mtklein <mtklein@chromium.org> Convert BBH APIs to use SkRect.

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
/external/skia/src/core/SkRecordDraw.cpp
131a22b2a22e4656f2351d42785fc3dee7a98fe2 25-Aug-2014 mtklein <mtklein@chromium.org> Bound everything except drawText().

BUG=skia:
R=robertphillips@google.com, fmalita@chromium.org, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/470063008
/external/skia/src/core/SkRecordDraw.cpp
68199a2d5f0cd0b9577b9695b9e095e720e96950 25-Aug-2014 mtklein <mtklein@chromium.org> Unfurl catch-all bounds(). This makes it a little easier to track progress.

I think we've worked out the SaveLayer bounds as of crrev.com/496963003, so
remove that TODO.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/501153002
/external/skia/src/core/SkRecordDraw.cpp
5f0e82204ecca0805a7689cdba5f802458e103f4 22-Aug-2014 mtklein <mtklein@chromium.org> Support comment groups in SkRecord.

This should fix the failing paint-command-log-nodes.html layout test.

BUG=406425
R=tomhudson@chromium.org

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/501533003
/external/skia/src/core/SkRecordDraw.cpp
d910f544439fffa6c2bcc5181b79b2811a4c130a 22-Aug-2014 mtklein <mtklein@chromium.org> Fix saveLayer() with a pixel-moving filter vs SkBBoxHierarchyRecord / SkRecordDraw

In SkBBoxHierarchyRecord:
Since the bounds we pass to saveLayer are in the pre-filtering
coordinate space, they aren't correct for determining the actual
device pixels touched by the saveLayer in this case.

The easiest fix for now is to pass the clip bounds, since the final
draw done in restore() will never draw outside the clip.

In SkRecordDraw:
We do adjust the bounds passed to saveLayer, so we just need to make
sure that when we're using a paint that may affect transparent black,
we ignore the calculated bounds of draw ops and use the clip intersected
with those adjusted bounds.

See originally crrev.com/497773002

BUG=skia:
R=reed@google.com, senorblanco@chromium.org, junov@chromium.org, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/496963003
/external/skia/src/core/SkRecordDraw.cpp
c8460493adbaba5acef69b3127c452df99117b24 22-Aug-2014 mtklein <mtklein@chromium.org> 1.5x -> 2x text size for y pad.

This will expand the cheat to just big enough to pass an assertion coming
from our GDI bot. Currently failing:
-6.000000 -1.500000 6.000000 1.500000 vs. -1.000000 -2.000000 3.000000 1.000000
Will become (-8 -2 8 2) vs. (-1 -2 3 1).

BUG=skia:
R=mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/496153002
/external/skia/src/core/SkRecordDraw.cpp
d13291a5a3d2a79b5348ecc4a8e38ab1b6da85f0 21-Aug-2014 mtklein <mtklein@chromium.org> Ignore small text sizes in the text bounding assert.

Seems we sometimes give back unduely large metrics for 0 text size.

BUG=skia:2862
R=reed@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/498503003
/external/skia/src/core/SkRecordDraw.cpp
00d5c2c6523321d25b32905ff4822f083a4173ee 21-Aug-2014 fmalita <fmalita@chromium.org> SkTextBlob

Initial implementation.

R=bungeman@google.com, jbroman@chromium.org, mtklein@google.com, reed@google.com, robertphillips@google.com

Author: fmalita@chromium.org

Review URL: https://codereview.chromium.org/473633002
/external/skia/src/core/SkRecordDraw.cpp
9a657fa0b493ae43ed35ae04a686c5402d701420 20-Aug-2014 caryclark <caryclark@google.com> fix #if to #ifdef for SK_DEBUG

fix the chrome build

R=mtklein@google.com
TBR=mtklein
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: caryclark@google.com

Review URL: https://codereview.chromium.org/495453003
/external/skia/src/core/SkRecordDraw.cpp
a19afb418027800c245ad19d651d8cf2071c9d70 20-Aug-2014 mtklein <mtklein@chromium.org> Cheat to go fast, but be careful in debug mode.

Turns out recording actual text metrics is currently really slow.
If we want to compete with the (cheating) status quo, gotta cheat too.

BUG=skia:
R=reed@google.com, robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/494483002
/external/skia/src/core/SkRecordDraw.cpp
6332f1dd20d73a6d8b9564af7c27d09394eb6596 19-Aug-2014 mtklein <mtklein@chromium.org> Record concat as setMatrix.

Mainly this cuts out a type to have to think about in SkRecord world.
It also means all the CTMs are recorded directly in the SkRecord, so
we can track the current CTM by pointer rather than by copying.

BUG=skia:
R=reed@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/484673003
/external/skia/src/core/SkRecordDraw.cpp
3e8232b6ef6b04290f0c280f88b38f8cd2c3f3ec 18-Aug-2014 mtklein <mtklein@chromium.org> Counterproposal for skirting the BBH when the query fully contains the picture.

BUG=skia:
R=reed@google.com, robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/485703002
/external/skia/src/core/SkRecordDraw.cpp
62b67ae96e94fd22569b058a3bc4625b9f52ed56 18-Aug-2014 mtklein <mtklein@chromium.org> Start actually bounding some draw ops.

This covers most of the common draws.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/469213007
/external/skia/src/core/SkRecordDraw.cpp
479601b9a74b5b8e424ed3d68882e161617bdceb 18-Aug-2014 mtklein <mtklein@chromium.org> Small tweaks and a bug fix.

Bug fixed: I was calling paint->canComputeFastBounds() where I should have been calling fSaveStack[i].paint->canComputeFastBounds().

This suggested I factor out the paint adjusting code, now called AdjustForPaint(). This removes the getImageFilter() check for SaveLayers, which seems like an optimization we can add back later if it proves important.

We're going to want to intersect the bounds with the current clip bounds eventually, so might as well land that here too.

Plus, more const.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/481543002
/external/skia/src/core/SkRecordDraw.cpp
0ed4e863c0b8f8a9ca8182148bf9849e5b5bf2aa 18-Aug-2014 mtklein <mtklein@chromium.org> Stop sorting the results of SkBBH::search().

We only seem to need to sort with SkQuadTree, which is not actively used by
client code. So it's really just wasted work. SkQuadTree is interesting, but
I'd rather disable it than slow down the production code path.

BUG=skia:2834
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/471063004
/external/skia/src/core/SkRecordDraw.cpp
a723b576aed31a6eb2bdda6388e6bd779d04c6b0 15-Aug-2014 mtklein <mtklein@chromium.org> SkRecordDraw: incorporate clip into BBH

NOTREECHECKS=true

BUG=skia:
R=robertphillips@google.com, senorblanco@chromium.org, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/474983002
/external/skia/src/core/SkRecordDraw.cpp
6cfa73a29a26edf1d03bca224ad6860396308ffc 13-Aug-2014 mtklein <mtklein@chromium.org> Start tracking the CTM while filling the BBH in SkRecordDraw.

Depends on https://codereview.chromium.org/475473002/

BUG=skia:
R=robertphillips@google.com, reed@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/468193003
/external/skia/src/core/SkRecordDraw.cpp
828ce1f34b3471c108aee6ac2c39ddb90d0be11e 13-Aug-2014 mtklein <mtklein@chromium.org> Start filling BBH in SkRecordDraw.

This starts with a skeleton of how to calculate bounds for ops which don't have
their own bounds. For any given Save/Restore block, we'll find the union of the
bounds of all the draws inside it (including other Save/Restore blocks), then say
those are the bounds of all non-draws in the block, including the Save and Restore.

To implement this, we keep a stack of active Save blocks. Any time we hit a
non-drawing op ("control"), we'll add it to that Save block (implemented with a
separate stack of indices and a count of control ops in the entry on the Save
stack). Save and SaveLayer push onto the stack, and Restore pops the stack, at
which point we can fill in the bounds for all the control ops in the block.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/475473002
/external/skia/src/core/SkRecordDraw.cpp
b3c9d1c33caf325aada244204215eb790c228c12 12-Aug-2014 dandov <dandov@google.com> SkCanvas::drawPatch param SkPoint[12]

drawPatch now receives as parameter const SkPoint cubics[12]

Adjusted derived classes and serialization.

Ajusted GM's and benches that take into account combinations of optional
parameters, the scale of the patch and 4 different types of patches.

Planning on adding the extra functionality of SkPatch in another CL.

BUG=skia:
R=egdaniel@google.com, reed@google.com

Author: dandov@google.com

Review URL: https://codereview.chromium.org/463493002
/external/skia/src/core/SkRecordDraw.cpp
03bde3e6fa8deaf635bd19b45de69ebea71ec299 12-Aug-2014 mtklein <mtklein@chromium.org> SkTileGrid: store insertion order, return results sorted by that.

This removes the need to assume the void* are SkPictureStateTree::Data*.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/466503002
/external/skia/src/core/SkRecordDraw.cpp
5ad6ee1b2ce54f8e59b9f5a337c688a98a4b0f2a 11-Aug-2014 mtklein <mtklein@chromium.org> Plumbing for using a BBH in SkRecordDraw.

For now this only creates a degenerate bounding box hierarchy where all ops
just have maximal bounds. I will flesh out FillBounds in future CL(s).

Not quite sure why QuadTree and TileGrid aren't drawing right---haven't even
looked at the diffs yet---so I've disabled those test modes for now. RTree
seems fine, so that'll at least get us coverage for all this new plumbing.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com, reed@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/454123003
/external/skia/src/core/SkRecordDraw.cpp
d5fa1a455aad61f3e99081fe7a9b065cb3b115c6 09-Aug-2014 reed <reed@google.com> add drawPicture variant that takes a matrix and paint

will need some staging strategy, since chrome and blink have overrides of onDrawPicture

R=robertphillips@google.com, fmalita@google.com, bsalomon@google.com, mtklein@google.com

Author: reed@google.com

Review URL: https://codereview.chromium.org/448793004
/external/skia/src/core/SkRecordDraw.cpp
f4078ad1ec42f549369ac4f639aab18d00afae95 08-Aug-2014 mtklein <mtklein@chromium.org> SkRecord: Strip out cull-skipping and y-only drawPosTextH skipping.

These optimizations are outclassed by a general bounding-box hierarchy,
and are just going to make plugging that into SkRecordDraw more complicated.

BUG=skia:
R=robertphillips@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/452983002
/external/skia/src/core/SkRecordDraw.cpp
2347b624678fedf1d2f7ab1d79b9ad70087c3392 07-Aug-2014 reed <reed@google.com> change drawPicture in SkRecord to just ref the picture

also fix some int/unsigned/size_t warnings

BUG=skia:
R=mtklein@google.com

Author: reed@google.com

Review URL: https://codereview.chromium.org/449933002
/external/skia/src/core/SkRecordDraw.cpp
963137b75c0a1fe91f35e9826742f36309f5e65d 07-Aug-2014 dandov <dandov@google.com> Stopped skipping tests in dm of SkPatch by implementing the
corresponding drawPath calls on classes that derive from SkCanvas.

BUG=skia:
R=egdaniel@google.com, bsalomon@google.com, mtklein@google.com, robertphillips@google.com

Author: dandov@google.com

Review URL: https://codereview.chromium.org/429343004
/external/skia/src/core/SkRecordDraw.cpp
7cdc1ee11545a10708e857adf1d4a94a2f1e2a48 07-Jul-2014 mtklein <mtklein@chromium.org> Add always-threaded SkRecord quilt tests.

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
/external/skia/src/core/SkRecordDraw.cpp
5f6102d07982043542343ff0a6c67b1319ac9fc7 30-Jun-2014 Florin Malita <fmalita@chromium.org> SaveFlags be-gone

Remove the deprecated save(SaveFlags), willSave(SaveFlags) and all
traces of kMatrix_SaveFlags/kClip_SaveFlag.

BUG=skia:2297
R=mtklein@google.com, reed@google.com, robertphillips@google.com

Review URL: https://codereview.chromium.org/340403003
/external/skia/src/core/SkRecordDraw.cpp
c11530ea73b2a2fcb431df0f5c1887d08ac9113c 24-Jun-2014 Mike Klein <mtklein@google.com> Tick off some TODOs:

- support fRecord in copy constructor
- support SkDrawPictureCallback

Moved SkDrawPictureCallback to its own header so
SkRecordDraw can include it without pulling in all of
SkPicture.

Adding an SkAutoSaveRestore to SkRecordDraw was the easiest
way to match the balance guarantees of the callback, and
probably not a bad idea in general. Updated its tests.

BUG=skia:
R=robertphillips@google.com

Review URL: https://codereview.chromium.org/349973008
/external/skia/src/core/SkRecordDraw.cpp
887f3979f0c717e69a8b7d169169bc27eb46d3b5 17-Jun-2014 mtklein <mtklein@chromium.org> Add EXPERIMENTAL_beginRecording() for SkRecord-based recording.

The interesting stuff is in SkPictureRecorder.{h,cpp}. The rest is mostly moving SkRecord from its own directories into core to avoid circular dependencies in GYP.

After plumbing SkRecord all the way through in Picture, I'll delete its old entry point include/record/SkRecording.h. For now it and record.gypi need to stay where they are to keep Chrome building.

BUG=skia:
R=reed@google.com, mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/331573004
/external/skia/src/core/SkRecordDraw.cpp