platform/upstream/libSkiaSharp.git
10 years agoSkTextBlob GPipe serialization.
fmalita [Thu, 28 Aug 2014 20:59:42 +0000 (13:59 -0700)]
SkTextBlob GPipe serialization.

Instead of relying on unrolling blobs in SkCanvas, serialize when
passing through a GPipe.

This is a prerequisite for pushing the blob draw op to the device.

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

Author: fmalita@chromium.org

Review URL: https://codereview.chromium.org/511783005

10 years agoadd SK_API to SkImageInfo
reed [Thu, 28 Aug 2014 20:37:52 +0000 (13:37 -0700)]
add SK_API to SkImageInfo

BUG=skia:
TBR=bungeman
NOTRY=True

Author: reed@google.com

Review URL: https://codereview.chromium.org/513333003

10 years agorename ScaledImageCache to ResourceCache
reed [Thu, 28 Aug 2014 20:35:23 +0000 (13:35 -0700)]
rename ScaledImageCache to ResourceCache

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

Author: reed@google.com

Review URL: https://codereview.chromium.org/511283002

10 years agoFix memory leak in SkPDFType1Font
djsollen [Thu, 28 Aug 2014 19:34:41 +0000 (12:34 -0700)]
Fix memory leak in SkPDFType1Font

BUG=skia:2880
R=bungeman@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/514313003

10 years agoRebaseline N10 GPU hairmodes.
jvanverth [Thu, 28 Aug 2014 19:18:41 +0000 (12:18 -0700)]
Rebaseline N10 GPU hairmodes.

This bug appears to be gone.

BUG=skia:1655
TBR=bsalomon@google.com

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/515303004

10 years agoEnsure that we don't reference decoders that we don't build
djsollen [Thu, 28 Aug 2014 19:04:41 +0000 (12:04 -0700)]
Ensure that we don't reference decoders that we don't build

R=scroggo@google.com, robertphillips@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/517663002

10 years agoRevert of Revert of add gamma/sRGB to SkImageInfo (patchset #1 of https://codereview...
reed [Thu, 28 Aug 2014 18:57:33 +0000 (11:57 -0700)]
Revert of Revert of add gamma/sRGB to SkImageInfo (patchset #1 of https://codereview.chromium.org/512243002/)

Reason for revert:
this revert was premature -- the chrome canary I looked at is old, and newer ones were green. So trying again...

Original issue's description:
> Revert of add gamma/sRGB to SkImageInfo (patchset #4 of https://codereview.chromium.org/514753002/)
>
> Reason for revert:
> breaks linker on chrome -- may need SK_API, but not sure.
>
> Original issue's description:
> > add gamma/sRGB to SkImageInfo
> >
> > BUG=skia:
> >
> > Committed: https://skia.googlesource.com/skia/+/615c369777258231054840a88cdb74c68c382485
>
> TBR=bungeman@google.com,bsalomon@google.com
> NOTREECHECKS=true
> NOTRY=true
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/dc53701216c0e9f98eacf6c0cda769ebbd200b59

R=bungeman@google.com, bsalomon@google.com
TBR=bsalomon@google.com, bungeman@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: reed@google.com

Review URL: https://codereview.chromium.org/511363002

10 years agoUpdate FontMgr expectations now the Win7 ANGLE bot is back online.
Derek Sollenberger [Thu, 28 Aug 2014 18:53:43 +0000 (14:53 -0400)]
Update FontMgr expectations now the Win7 ANGLE bot is back online.

BUG=skia:2829

Review URL: https://codereview.chromium.org/510383004

10 years agoFix error handling in DirectWrite with tiny text.
bungeman [Thu, 28 Aug 2014 18:42:29 +0000 (11:42 -0700)]
Fix error handling in DirectWrite with tiny text.

If there is an error while trying to determine the metrics,
we need to bail instead of potentially using uninitialized data.

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

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/511783003

10 years agoRestore text vertex buffer alloc and other optimizations.
jvanverth [Thu, 28 Aug 2014 17:39:40 +0000 (10:39 -0700)]
Restore text vertex buffer alloc and other optimizations.

Modifies the fontcache GM to ensure that the font cache is forced to flush.

Committed: https://skia.googlesource.com/skia/+/9c3d24b9d1ba3d955094ff0cb1ba2d11e1c1adca

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

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/466363009

10 years agomanual revert of bitmap scale change while I investigate failures
humper [Thu, 28 Aug 2014 16:54:41 +0000 (09:54 -0700)]
manual revert of bitmap scale change while I investigate failures
on chromeos

TBR=reed
NOTREECHECKS=True

Author: humper@google.com

Review URL: https://codereview.chromium.org/516923003

10 years agoMake textures register with GrResourceCache2 as scratch.
bsalomon [Thu, 28 Aug 2014 16:54:34 +0000 (09:54 -0700)]
Make textures register with GrResourceCache2 as scratch.

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/510053003

10 years agoUpdate baselines for the fontMgr GMs.
bungeman [Thu, 28 Aug 2014 16:34:28 +0000 (12:34 -0400)]
Update baselines for the fontMgr GMs.
BUG=skia:2829

10 years agoRevert of add gamma/sRGB to SkImageInfo (patchset #4 of https://codereview.chromium...
reed [Thu, 28 Aug 2014 13:53:19 +0000 (06:53 -0700)]
Revert of add gamma/sRGB to SkImageInfo (patchset #4 of https://codereview.chromium.org/514753002/)

Reason for revert:
breaks linker on chrome -- may need SK_API, but not sure.

Original issue's description:
> add gamma/sRGB to SkImageInfo
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/615c369777258231054840a88cdb74c68c382485

R=bungeman@google.com, bsalomon@google.com
TBR=bsalomon@google.com, bungeman@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: reed@google.com

Review URL: https://codereview.chromium.org/512243002

10 years agoAdd Android copy_directory_contents_[to|from]_device scripts
Eric Boren [Thu, 28 Aug 2014 13:31:15 +0000 (09:31 -0400)]
Add Android copy_directory_contents_[to|from]_device scripts

BUG=skia:
NOTRY=true
R=djsollen@google.com

Review URL: https://codereview.chromium.org/510653004

10 years agoadd gamma/sRGB to SkImageInfo
reed [Thu, 28 Aug 2014 12:56:37 +0000 (05:56 -0700)]
add gamma/sRGB to SkImageInfo

BUG=skia:
R=bungeman@google.com, bsalomon@google.com

Author: reed@google.com

Review URL: https://codereview.chromium.org/514753002

10 years agoUpdate SKP version to 86
borenet [Thu, 28 Aug 2014 12:46:26 +0000 (05:46 -0700)]
Update SKP version to 86

Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/515053002

10 years agoDisable bitmap decoders for GPU specific formats on Android framework
djsollen [Thu, 28 Aug 2014 12:41:21 +0000 (05:41 -0700)]
Disable bitmap decoders for GPU specific formats on Android framework

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

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/510913003

10 years agoMake setVertexAttribs in GrDrawState take a stride parameter.
egdaniel [Thu, 28 Aug 2014 12:41:14 +0000 (05:41 -0700)]
Make setVertexAttribs in GrDrawState take a stride parameter.

BUG=skia:

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

R=bsalomon@google.com

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/511593004

10 years agoIncrease test tolerance.
mtklein [Thu, 28 Aug 2014 12:14:31 +0000 (05:14 -0700)]
Increase test tolerance.

NOTREECHECKS=true

CQ_EXTRA_TRYBOTS=tryserver.skia:Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Release-Trybot

BUG=skia:
R=mtklein@google.com

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/516503003

10 years agoMore test debugging. Too close for decimal. I'm switching to hex.
Mike Klein [Thu, 28 Aug 2014 11:15:32 +0000 (07:15 -0400)]
More test debugging.  Too close for decimal.  I'm switching to hex.

BUG=skia:

Review URL: https://codereview.chromium.org/515753005

10 years agoDirectWrite to use aliased if ClearType is empty.
Ben Wagner [Wed, 27 Aug 2014 23:17:41 +0000 (19:17 -0400)]
DirectWrite to use aliased if ClearType is empty.

Some CJK fonts with some versions of DirectWrite return valid
data for bitmaps, but not for cleartype data.

For reference, two screenshots. M37 Stable and then with this patch:

http://imgur.com/9pf3rB9,EiTb6Li

See https://code.google.com/p/chromium/issues/detail?id=396624#c10 for
content of test html file.

R=eae@chromium.org, reed@google.com, shrikant@chromium.org, bungeman@chromium.org, cpu@chromium.org
BUG=chromium:407945

Review URL: https://codereview.chromium.org/504343007

10 years agoAdd some debugging to figure out what's up with failing Mac 10.8 Release bot.
Mike Klein [Wed, 27 Aug 2014 23:08:52 +0000 (19:08 -0400)]
Add some debugging to figure out what's up with failing Mac 10.8 Release bot.

BUG=skia:

Review URL: https://codereview.chromium.org/511013002

10 years agoUpdate expectations for FontMgr that were missed in previous runs
Derek Sollenberger [Wed, 27 Aug 2014 21:02:18 +0000 (17:02 -0400)]
Update expectations for FontMgr that were missed in previous runs

BUG=skia:2829

Review URL: https://codereview.chromium.org/516533003

10 years agoRevert of Restore text alloc optimizations. (patchset #4 of https://codereview.chromi...
djsollen [Wed, 27 Aug 2014 20:12:25 +0000 (13:12 -0700)]
Revert of Restore text alloc optimizations. (patchset #4 of https://codereview.chromium.org/466363009/)

Reason for revert:
GM failures on http://108.170.220.120:10115/builders/Test-Ubuntu12-ShuttleA-GTX660-x86-Release/builds/1867/

Original issue's description:
> Restore text vertex buffer alloc and other optimizations.
>
> Modifies the fontcache GM to ensure that the font cache is forced to flush.
>
> Committed: https://skia.googlesource.com/skia/+/9c3d24b9d1ba3d955094ff0cb1ba2d11e1c1adca

R=bsalomon@google.com, robertphillips@google.com, jvanverth@google.com
TBR=bsalomon@google.com, jvanverth@google.com, robertphillips@google.com
NOTREECHECKS=true
NOTRY=true

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/510103003

10 years agoRevert of Make setVertexAttribs in GrDrawState take a stride parameter. (patchset...
djsollen [Wed, 27 Aug 2014 20:07:34 +0000 (13:07 -0700)]
Revert of Make setVertexAttribs in GrDrawState take a stride parameter. (patchset #5 of https://codereview.chromium.org/511593004/)

Reason for revert:
GM failures on http://108.170.220.120:10115/builders/Test-Ubuntu12-ShuttleA-GTX660-x86-Release/builds/1867/

Original issue's description:
> Make setVertexAttribs in GrDrawState take a stride parameter.
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/af013bf8afc4c77ab8ff230f536e2ade973427fa

R=bsalomon@google.com, egdaniel@google.com
TBR=bsalomon@google.com, egdaniel@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/502533004

10 years agoRevert of Possible fix to Restore text vertex buffer alloc and other optimizations...
djsollen [Wed, 27 Aug 2014 20:06:01 +0000 (13:06 -0700)]
Revert of Possible fix to Restore text vertex buffer alloc and other optimizations. (patchset #1 of https://codereview.chromium.org/513863004/)

Reason for revert:
GM failures on http://108.170.220.120:10115/builders/Test-Ubuntu12-ShuttleA-GTX660-x86-Release/builds/1867/

Original issue's description:
> Possible fix to Restore text vertex buffer alloc and other optimizations.
> NOTRY=True
> NOTREECHECKS=True
> TBR=jvanverth@google.com
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/85f94844fc31eddee9cb507377cb3f74c1ed34f2

R=jvanverth@google.com, egdaniel@google.com
TBR=egdaniel@google.com, jvanverth@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/516613002

10 years agoCan't hurt to make this SkNoncopyable.
mtklein [Wed, 27 Aug 2014 20:02:24 +0000 (13:02 -0700)]
Can't hurt to make this SkNoncopyable.

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/510953002

10 years agoJPEG(JFIF only) directly embedded into PDF
halcanary [Wed, 27 Aug 2014 20:00:54 +0000 (13:00 -0700)]
JPEG(JFIF only) directly embedded into PDF

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

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/515493003

10 years agoUpdate fontMgr expectations for Mac/Linux/Windows
Derek Sollenberger [Wed, 27 Aug 2014 19:50:03 +0000 (15:50 -0400)]
Update fontMgr expectations for Mac/Linux/Windows

BUG=skia:2829

Review URL: https://codereview.chromium.org/514913002

10 years agoPossible fix to Restore text vertex buffer alloc and other optimizations.
egdaniel [Wed, 27 Aug 2014 19:23:23 +0000 (12:23 -0700)]
Possible fix to Restore text vertex buffer alloc and other optimizations.
NOTRY=True
NOTREECHECKS=True
R=jvanverth@google.com
TBR=jvanverth@google.com

BUG=skia:

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/513863004

10 years agoMake setVertexAttribs in GrDrawState take a stride parameter.
egdaniel [Wed, 27 Aug 2014 19:17:24 +0000 (12:17 -0700)]
Make setVertexAttribs in GrDrawState take a stride parameter.

BUG=skia:
R=bsalomon@google.com

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/511593004

10 years agoAdd test that confirms Pictures don't leak pixel refs.
mtklein [Wed, 27 Aug 2014 19:12:23 +0000 (12:12 -0700)]
Add test that confirms Pictures don't leak pixel refs.

Have been investigating memory leak failures that show SkRecords'
ImmutableBitmap copy leaking.  I think this test proves its not
an obvious problem with ImmutableBitmap or SkRecord.

http://build.chromium.org/p/chromium.memory/builders/Linux%20Chromium%20OS%20ASan%20LSan%20Tests%20%282%29/builds/2509/steps/interactive_ui_tests/logs/stdio

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/516593002

10 years agoSwitch GPU Optimization code to SkRecord
robertphillips [Wed, 27 Aug 2014 18:53:28 +0000 (11:53 -0700)]
Switch GPU Optimization code to SkRecord

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

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/504393002

10 years agoRestore text vertex buffer alloc and other optimizations.
jvanverth [Wed, 27 Aug 2014 18:53:17 +0000 (11:53 -0700)]
Restore text vertex buffer alloc and other optimizations.

Modifies the fontcache GM to ensure that the font cache is forced to flush.

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

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/466363009

10 years agoUpdate GPU baselines for the fontMgr GMs.
Derek Sollenberger [Wed, 27 Aug 2014 18:48:09 +0000 (14:48 -0400)]
Update GPU baselines for the fontMgr GMs.

BUG=skia:2829

Review URL: https://codereview.chromium.org/511973002

10 years agoUpdate non-GPU baselines for the fontMgr GMs.
Derek Sollenberger [Wed, 27 Aug 2014 18:38:45 +0000 (14:38 -0400)]
Update non-GPU baselines for the fontMgr GMs.

BUG=skia:2829

Review URL: https://codereview.chromium.org/515473003

10 years agoAdd resources/mandrill_512_q075.jpg
Hal Canary [Wed, 27 Aug 2014 17:44:34 +0000 (13:44 -0400)]
Add resources/mandrill_512_q075.jpg

convert resources/mandrill_512.png ppm:- | cjpeg -quality 75 > resources/mandrill_512_q075.jpg

Motivation:  We need JPEG images for testing PDF.  (e.g. http://crrev.com/515493003 )

R=djsollen@google.com

Review URL: https://codereview.chromium.org/508173002

10 years agoConvert BBH APIs to use SkRect.
mtklein [Wed, 27 Aug 2014 17:39:42 +0000 (10:39 -0700)]
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

10 years agoAdd missing text blob SkDrawCommand string.
fmalita [Wed, 27 Aug 2014 15:41:25 +0000 (08:41 -0700)]
Add missing text blob SkDrawCommand string.

R=robertphillips@google.com

Author: fmalita@chromium.org

Review URL: https://codereview.chromium.org/510853002

10 years agoadd n5
mtklein [Wed, 27 Aug 2014 15:38:12 +0000 (08:38 -0700)]
add n5

NOTRY=true

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/506403004

10 years agoFail gracefully for KTX files with width or height of zero.
djsollen [Wed, 27 Aug 2014 15:00:09 +0000 (08:00 -0700)]
Fail gracefully for KTX files with width or height of zero.

R=robertphillips@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/514603003

10 years agoalways scale to an integer; compensate for fractional image sizes by leaving the...
humper [Wed, 27 Aug 2014 14:56:49 +0000 (07:56 -0700)]
always scale to an integer; compensate for fractional image sizes by leaving the fractional scale in the matrix

BUG=skia:
R=reed@google.com

Author: humper@google.com

Review URL: https://codereview.chromium.org/470233002

10 years agoIgnore font_mgr gms until we can rebase them
Derek Sollenberger [Wed, 27 Aug 2014 14:45:37 +0000 (10:45 -0400)]
Ignore font_mgr gms until we can rebase them

BUG=skia:2829
R=mtklein@google.com

Review URL: https://codereview.chromium.org/513813002

10 years agoLookup glyphs based on character code and language tag.
djsollen [Wed, 27 Aug 2014 14:03:13 +0000 (07:03 -0700)]
Lookup glyphs based on character code and language tag.

This is particularly important on Android where we expect the
FontManager to return different glyphs for the same character code
depending on language.

BUG=skia:2829
R=bungeman@google.com, tomhudson@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/492763003

10 years agoRemove skip draw check in GrContext
egdaniel [Wed, 27 Aug 2014 13:58:54 +0000 (06:58 -0700)]
Remove skip draw check in GrContext

BUG=skia:
R=bsalomon@google.com

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/488563003

10 years agoClean up some benches that answer questions we're no longer asking.
mtklein [Wed, 27 Aug 2014 13:34:16 +0000 (06:34 -0700)]
Clean up some benches that answer questions we're no longer asking.

NOTREECHECKS=true

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/512503002

10 years agoUpdate SKP version to 85
borenet [Wed, 27 Aug 2014 04:18:32 +0000 (21:18 -0700)]
Update SKP version to 85

Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/513563003

10 years agoImprove performance of highQualityFilter
qiankun.miao [Wed, 27 Aug 2014 02:06:41 +0000 (19:06 -0700)]
Improve performance of highQualityFilter

Move loop invariant caculation out of loop. This gives about 15% speedup
for bitmap_BGRA_8888_A_scale_rotate_bicubic on my desktop i7-3770.

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

Author: qiankun.miao@intel.com

Review URL: https://codereview.chromium.org/502953004

10 years agoRemove SkQuadTree.
mtklein [Tue, 26 Aug 2014 21:07:04 +0000 (14:07 -0700)]
Remove SkQuadTree.

We're not testing it to the same degree we do RTree and TileGrid.  Any changes
we'll make to BBH APIs become 33% easier without it.  If find we want it again,
we can always resurrect it.

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/500373005

10 years agoRemove SkImageFilter::Set/GetExternalCache.
senorblanco [Tue, 26 Aug 2014 21:06:00 +0000 (14:06 -0700)]
Remove SkImageFilter::Set/GetExternalCache.

These were removed from the .cpp in
be129b26f13d575fd6b396c6ae759838ecc9bd1a, but I forgot to remove them
from the header.

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

Author: senorblanco@chromium.org

Review URL: https://codereview.chromium.org/492693003

10 years agoMake GrGpuResources register with GrResourceCache2 after fully constructed.
bsalomon [Tue, 26 Aug 2014 21:01:07 +0000 (14:01 -0700)]
Make GrGpuResources register with GrResourceCache2 after fully constructed.

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

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/504313002

10 years agoPRESUBMIT should only check owners for the top level include directory
rmistry [Tue, 26 Aug 2014 21:00:54 +0000 (14:00 -0700)]
PRESUBMIT should only check owners for the top level include directory

BUG=skia:1846
R=borenet@google.com

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/511503002

10 years agoUpdate valgrind suppression file for new FontConfig code.
bungeman [Tue, 26 Aug 2014 20:48:00 +0000 (13:48 -0700)]
Update valgrind suppression file for new FontConfig code.

BUG=skia:2879
R=djsollen@google.com, mtklein@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/488343003

10 years agoEnsure SkFontMgr_fontconfig debug thread locking is initialized.
bungeman [Tue, 26 Aug 2014 20:47:20 +0000 (13:47 -0700)]
Ensure SkFontMgr_fontconfig debug thread locking is initialized.

R=mtklein@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/512433002

10 years agoRevert of Make GrGpuResources register with GrResourceCache2 after fully constructed...
bsalomon [Tue, 26 Aug 2014 20:11:11 +0000 (13:11 -0700)]
Revert of Make GrGpuResources register with GrResourceCache2 after fully constructed. (patchset #3 of https://codereview.chromium.org/504313002/)

Reason for revert:
Breaking the bots

Original issue's description:
> Make GrGpuResources register with GrResourceCache2 after fully constructed.
>
> Committed: https://skia.googlesource.com/skia/+/d68b3e491bb765beb7ca5e4ac8e0c80dedf5a83b

R=robertphillips@google.com
TBR=robertphillips@google.com
NOTREECHECKS=true
NOTRY=true

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/488463004

10 years agoMake GrGpuResources register with GrResourceCache2 after fully constructed.
bsalomon [Tue, 26 Aug 2014 19:51:20 +0000 (12:51 -0700)]
Make GrGpuResources register with GrResourceCache2 after fully constructed.

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/504313002

10 years agoReimplement deserialization of SkImageFilter's uniqueID.
senorblanco [Tue, 26 Aug 2014 19:27:12 +0000 (12:27 -0700)]
Reimplement deserialization of SkImageFilter's uniqueID.

9fa60d ("Simplify flattening to just write enough ... ") simplified just
a tad too much. In particular, it disabled deserialization of
SkImageFilter's uniqueID, which in turn caused the failure of
SkImageFilter's cache, which caused a large regression in Chrome's SVG
filter performance.

The medium-term fix is to switch to the new SkRecordDraw SkPicture
backend, which will make the unique IDs unnecessary.

This change is an "in case of emergecy" CL, in the event that there are
problems switching on the new backend in Chrome. For that reason, it's
minimalist: only the filters used by Chrome are modified, and whitespace
changes are kept to a minimum. In this way, it should be easy to revert
once the new backend goes in.

R=reed@google.com

Author: senorblanco@chromium.org

Review URL: https://codereview.chromium.org/503833002

10 years agoCreate Read-only Base class for GrDrawState that holds data members and getters
egdaniel [Tue, 26 Aug 2014 19:24:06 +0000 (12:24 -0700)]
Create Read-only Base class for GrDrawState that holds data members and getters

Base class will but used also in follow up cl that will create an OptDrawState class which will
share much of the same data/functions as DrawState. Thus the base class
BUG=skia:
R=bsalomon@google.com

Author: egdaniel@google.com

Review URL: https://codereview.chromium.org/506803003

10 years agoCopy SkImage expectations for ChromeOS recipes bot
borenet [Tue, 26 Aug 2014 19:20:53 +0000 (12:20 -0700)]
Copy SkImage expectations for ChromeOS recipes bot

BUG=skia:761
R=rmistry@google.com
TBR=rmistry
NOTRY=true

Author: borenet@google.com

Review URL: https://codereview.chromium.org/485563005

10 years agogit-sync-deps: handle recursion and deps_os at the same time
halcanary [Tue, 26 Aug 2014 19:06:47 +0000 (12:06 -0700)]
git-sync-deps: handle recursion and deps_os at the same time

NOTRY=true
R=mtklein@google.com, borenet@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/494713005

10 years agoFallback to moveTo when unable to find the first tangent in cubicTo
piotaixr [Tue, 26 Aug 2014 18:59:04 +0000 (11:59 -0700)]
Fallback to moveTo when unable to find the first tangent in cubicTo

When calling cubicTo(a, b, c) and if the distance between fPrevPt and a
is too small, b is used instead of a to calculate the first tangent,
even if the distance between fPrevPt and b is too small.

In debug mode, this is causing an assertion to fail in
SkPathStroker::preJoinTo() and, in Release, the use of an
unitialized value.

The first patch set is adding a failing test.
The second one add the fix to SkPathStroker::cubicTo()

BUG=skia:2820
R=bsalomon@chromium.org, junov@chromium.org, reed@google.com, caryclark@google.com, bsalomon@google.com

Author: piotaixr@chromium.org

Review URL: https://codereview.chromium.org/460813002

10 years agoRemove reliance on linked in GL functions for assembling GLES interfaces.
bsalomon [Tue, 26 Aug 2014 18:35:23 +0000 (11:35 -0700)]
Remove reliance on linked in GL functions for assembling GLES interfaces.

Make Android pull in gl2.h directly to workaround broken eglGetProcAddress for unextended GLES2 functions.

Use interface assembler for angle and iOS.

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/500153002

10 years agoPrevent malformed ICO files from recursively decoding
djsollen [Tue, 26 Aug 2014 18:35:14 +0000 (11:35 -0700)]
Prevent malformed ICO files from recursively decoding

R=reed@google.com, scroggo@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/511453002

10 years agoAlways use cpu-features library on android.
djsollen [Tue, 26 Aug 2014 18:30:15 +0000 (11:30 -0700)]
Always use cpu-features library on android.

This CL also removes the debug capability of runtime switching
in/out of NEON mode as it uses deprecated APIs.

BUG=skia:1061
R=tomhudson@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/506033003

10 years agoremove (unused) scale parameter from measureText
reed [Tue, 26 Aug 2014 18:30:01 +0000 (11:30 -0700)]
remove (unused) scale parameter from measureText

BUG=skia:
R=bungeman@google.com, djsollen@google.com

Author: reed@google.com

Review URL: https://codereview.chromium.org/510433002

10 years agoSkAutoTDelete::operator T*()
halcanary [Tue, 26 Aug 2014 18:06:25 +0000 (11:06 -0700)]
SkAutoTDelete::operator T*()

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

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/506963002

10 years agoremove commented-out code
reed [Tue, 26 Aug 2014 18:04:16 +0000 (11:04 -0700)]
remove commented-out code

TBR=senorblanco@google.com
NOTRY=True

Author: reed@google.com

Review URL: https://codereview.chromium.org/505253002

10 years agoRevert of Testing TBR'ing public API owners (patchset #1 of https://codereview.chromi...
rmistry [Tue, 26 Aug 2014 17:43:14 +0000 (10:43 -0700)]
Revert of Testing TBR'ing public API owners (patchset #1 of https://codereview.chromium.org/486203009/)

Reason for revert:
Reverting whitespace change

Original issue's description:
> Testing TBR'ing public API owners
>
> BUG=skia:2870
> TBR=xyz,reed
> NOTRY=true
>
> (SkipBuildbotRuns)
>
> Committed: https://skia.googlesource.com/skia/+/96b77dee4e985513abd4042db088bd286fd84383

TBR=
NOTREECHECKS=true
NOTRY=true
BUG=skia:2870

(SkipBuildbotRuns)

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/504193003

10 years agoTesting TBR'ing public API owners
rmistry [Tue, 26 Aug 2014 17:41:21 +0000 (10:41 -0700)]
Testing TBR'ing public API owners

BUG=skia:2870
TBR=xyz,reed
NOTRY=true

(SkipBuildbotRuns)

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/486203009

10 years agoSkData to SkStreamAsset to avoid unneeded copying
halcanary [Tue, 26 Aug 2014 17:38:07 +0000 (10:38 -0700)]
SkData to SkStreamAsset to avoid unneeded copying

R=mtklein@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/502193002

10 years agoPublic API changes are allowed if an owner is TBR'ed.
rmistry [Tue, 26 Aug 2014 17:30:29 +0000 (10:30 -0700)]
Public API changes are allowed if an owner is TBR'ed.

The following TBR formats are supported:
* TBR=reed
* TBR=reed@google.com
* TBR=xyz,reed
* TBR=xyz,reed@google.com

BUG=skia:2870
R=borenet@google.com

Author: rmistry@google.com

Review URL: https://codereview.chromium.org/504843003

10 years agoretool image cache to be generic cache, allowing the client to subclass "Rec", so...
reed [Tue, 26 Aug 2014 16:08:04 +0000 (09:08 -0700)]
retool image cache to be generic cache, allowing the client to subclass "Rec", so they can provide a custom Key and arbitrary Value.

Follow-on CLs

- rename ScaledimageCache to something like GeneralCache
- explore if we can use call-backs or some mechanism to completely hide "lock/unlock", by forcing all clients to support "copying" their value out of the cache as the result of a Find.

R=mtklein@google.com, senorblanco@google.com, bsalomon@google.com, qiankun.miao@intel.com, senorblanco@chromium.org

Author: reed@google.com

Review URL: https://codereview.chromium.org/507483002

10 years agoFix overflow when comparing two ints by promoting the sum to 64-bits.
djsollen [Tue, 26 Aug 2014 15:31:24 +0000 (08:31 -0700)]
Fix overflow when comparing two ints by promoting the sum to 64-bits.

R=reed@google.com, scroggo@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/505153003

10 years agoAdd text blob gm baselines.
Florin Malita [Tue, 26 Aug 2014 15:17:02 +0000 (11:17 -0400)]
Add text blob gm baselines.

Review URL: https://codereview.chromium.org/504203002

10 years agoSkTextBlob plumbing
fmalita [Tue, 26 Aug 2014 14:56:44 +0000 (07:56 -0700)]
SkTextBlob plumbing

Add SkTextBlob serialization + drawTextBlob() overrides.

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

Author: fmalita@chromium.org

Review URL: https://codereview.chromium.org/499413002

10 years agoRemove unused header file in SkScaledImageCache.cpp
qiankun.miao [Tue, 26 Aug 2014 14:33:07 +0000 (07:33 -0700)]
Remove unused header file in SkScaledImageCache.cpp

BUG=skia:
R=reed@google.com

Author: qiankun.miao@intel.com

Review URL: https://codereview.chromium.org/506783003

10 years agoUpdate SKP version to 84
borenet [Tue, 26 Aug 2014 12:07:35 +0000 (05:07 -0700)]
Update SKP version to 84

Automatic commit by the RecreateSKPs bot.

TBR=
BUG=skia:

Author: borenet@google.com

Review URL: https://codereview.chromium.org/506783006

10 years agoImplement NV_path_rendering on OpenGL ES
kkinnunen [Tue, 26 Aug 2014 05:21:16 +0000 (22:21 -0700)]
Implement NV_path_rendering on OpenGL ES

Implement support for NV_path_rendering on OpenGL ES. Use
glProgramPathFragmentInputGenNV function call instead of glPathTexGenNV to
communicate transforms to fragment shader.

The intention is that the NVPR paths will be drawn with the same shader program
as non-NVPR geometry. For NVPR calls, the GPU will skip the vertex shader and
just run the fragment shader.

After program is linked, query the locations of the fragment shader inputs with
glGetResourceLocation. The location will be used to set the transforms with
glProgramPathFragmentInputGenNV.

The functions and their workings are documented in:

glProgramPathFragmentInputGenNV
https://www.opengl.org/registry/specs/NV/path_rendering.txt
(note: addition as of API version 1.3)

glGetResourceLocation
https://www.opengl.org/registry/specs/ARB/program_interface_query.txt
http://www.opengl.org/registry/doc/glspec44.core.pdf
(function is in core Open GL 4.4)

Note: glProgramPathFragmentInputGenNV could be used also for OpenGL. However,
using seems to trigger a bug in the driver. Disable this feature on OpenGL at
least until the driver is fixed and released. The bug manifests in shadertext
test, where the lower-left text pair is missing. Valgrind catches a bad read
for the test and causes the context to OOM reproducibly.

R=bsalomon@google.com, cdalton@nvidia.com, joshualitt@google.com, joshualitt@chromium.org

Author: kkinnunen@nvidia.com

Review URL: https://codereview.chromium.org/367643004

10 years agoRebaselines for a6785ccb540 (Add a working SkFontMgr_fontconfig.)
bungeman [Mon, 25 Aug 2014 21:18:04 +0000 (17:18 -0400)]
Rebaselines for a6785ccb540 (Add a working SkFontMgr_fontconfig.)

10 years agoBound everything except drawText().
mtklein [Mon, 25 Aug 2014 21:16:15 +0000 (14:16 -0700)]
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

10 years agoUnfurl catch-all bounds(). This makes it a little easier to track progress.
mtklein [Mon, 25 Aug 2014 20:49:29 +0000 (13:49 -0700)]
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

10 years agoRebaselines for a6785ccb540 (Add a working SkFontMgr_fontconfig.)
bungeman [Mon, 25 Aug 2014 19:47:15 +0000 (15:47 -0400)]
Rebaselines for a6785ccb540 (Add a working SkFontMgr_fontconfig.)

10 years agoFix recursive computation of filter bounds for drop shadow,
senorblanco [Mon, 25 Aug 2014 19:46:58 +0000 (12:46 -0700)]
Fix recursive computation of filter bounds for drop shadow,
morphology, blur.

[Reland with fixed tests.]

Because we're computing "backwards" from a clip rect of destination
pixels to be filled to the required source pixels, we should use tail
recursion rather than head recursion in onFilterBounds().

This actually only makes a difference for drop-shadow, where
the computation is non-commutative. Blur and morphology commute, but I
moved them to tail recursion anyway for clarity (so all onFilterBounds
use tail recursion).

BUG=skia:
R=bsalomon@google.com

Author: senorblanco@chromium.org

Review URL: https://codereview.chromium.org/481273005

10 years agoRevert of Benchmark designed to exercise fractional image scale/translation (patchset...
djsollen [Mon, 25 Aug 2014 19:03:11 +0000 (12:03 -0700)]
Revert of Benchmark designed to exercise fractional image scale/translation (patchset #2 of https://codereview.chromium.org/491793003/)

Reason for revert:
fires asserts on Linux Debug builds

http://108.170.220.120:10115/builders/Test-Ubuntu12-ShuttleA-GTX660-x86_64-Debug/builds/1910

Original issue's description:
> Benchmark designed to exercise fractional image scale/translation
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/5fc226641a0926dddbf70ba784f344881f4c05b9

R=reed@google.com, humper@google.com
TBR=humper@google.com, reed@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/470063007

10 years agoAdd a working SkFontMgr_fontconfig.
bungeman [Mon, 25 Aug 2014 19:00:49 +0000 (12:00 -0700)]
Add a working SkFontMgr_fontconfig.

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

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/396143004

10 years agoBenchmark designed to exercise fractional image scale/translation
humper [Mon, 25 Aug 2014 18:17:48 +0000 (11:17 -0700)]
Benchmark designed to exercise fractional image scale/translation

BUG=skia:
R=reed@google.com

Author: humper@google.com

Review URL: https://codereview.chromium.org/491793003

10 years agogradtext also needed rebaselining from the gamma change
Mike Klein [Mon, 25 Aug 2014 17:50:29 +0000 (13:50 -0400)]
gradtext also needed rebaselining from the gamma change

BUG=skia:

Review URL: https://codereview.chromium.org/501113002

10 years agoRequire length in sk_wchar_to_string.
bungeman [Mon, 25 Aug 2014 17:16:01 +0000 (10:16 -0700)]
Require length in sk_wchar_to_string.

This information is already available at all call sites and allows
the call to WideCharToMultiByte to not overwrite the '\0' in the
writable_str() which isn't really writable.

BUG=skia:1989
R=reed@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/500113002

10 years agoRebaseline 565 precision changes and matrixconvolution.
Mike Klein [Mon, 25 Aug 2014 17:14:16 +0000 (13:14 -0400)]
Rebaseline 565 precision changes and matrixconvolution.

BUG=skia:2797

Review URL: https://codereview.chromium.org/504873002

10 years agoDocument return value of SkPaint::operator==.
mtklein [Mon, 25 Aug 2014 17:10:47 +0000 (10:10 -0700)]
Document return value of SkPaint::operator==.

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

Author: mtklein@chromium.org

Review URL: https://codereview.chromium.org/467063003

10 years agoRevert of Fix recursive computation of filter bounds for drop shadow, (patchset ...
djsollen [Mon, 25 Aug 2014 16:06:19 +0000 (09:06 -0700)]
Revert of Fix recursive computation of filter bounds for drop shadow, (patchset #1 of https://codereview.chromium.org/481273005/)

Reason for revert:
This CL is currently breaking the Win7 and Win8 bots on some of the new tests (in DM).

Original issue's description:
> Fix recursive computation of filter bounds for drop shadow,
> morphology, blur.
>
> Because we're computing "backwards" from a clip rect of destination
> pixels to be filled to the required source pixels, we should use tail
> recursion rather than head recursion in onFilterBounds().
>
> This actually only makes a difference for drop-shadow, where
> the computation is non-commutative. Blur and morphology commute, but I
> moved them to tail recursion anyway for clarity (so all onFilterBounds
> use tail recursion).
>
> BUG=skia:
>
> Committed: https://skia.googlesource.com/skia/+/28648fe4a69b0cee8df42b5966e4e645c3aabefb

R=bsalomon@google.com, senorblanco@chromium.org
TBR=bsalomon@google.com, senorblanco@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/504773003

10 years agoFix recursive computation of filter bounds for drop shadow,
senorblanco [Mon, 25 Aug 2014 15:06:57 +0000 (08:06 -0700)]
Fix recursive computation of filter bounds for drop shadow,
morphology, blur.

Because we're computing "backwards" from a clip rect of destination
pixels to be filled to the required source pixels, we should use tail
recursion rather than head recursion in onFilterBounds().

This actually only makes a difference for drop-shadow, where
the computation is non-commutative. Blur and morphology commute, but I
moved them to tail recursion anyway for clarity (so all onFilterBounds
use tail recursion).

BUG=skia:
R=bsalomon@google.com

Author: senorblanco@chromium.org

Review URL: https://codereview.chromium.org/481273005

10 years agoXPS to use PathOps for inverse winding paths.
bungeman [Mon, 25 Aug 2014 14:31:53 +0000 (07:31 -0700)]
XPS to use PathOps for inverse winding paths.

R=caryclark@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/484343003

10 years agoReverse swap order in DirectWrite typeface.
bungeman [Mon, 25 Aug 2014 14:14:02 +0000 (07:14 -0700)]
Reverse swap order in DirectWrite typeface.

C++ forbids temporaries to bind to non-const references.
VC++ allows you to do so anyway, but it makes clang on Windows sad.

R=reed@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/487533004

10 years agoadd const to arrays of member functions
caryclark [Mon, 25 Aug 2014 13:53:04 +0000 (06:53 -0700)]
add const to arrays of member functions

running 'size ./out/Release/libskia_core.a' revealed a couple of
places where path ops chose poorly and declared arrays of member
functions to be unnecessarily writable.

R=reed@android.com
TBR=reed

Author: caryclark@google.com

Review URL: https://codereview.chromium.org/461363003

10 years agoAdd SK_API to SkTextBlob and SkTextBlobBuilder.
jbroman [Mon, 25 Aug 2014 13:22:12 +0000 (06:22 -0700)]
Add SK_API to SkTextBlob and SkTextBlobBuilder.

BUG=skia:2868
R=fmalita@chromium.org, reed@google.com

Author: jbroman@chromium.org

Review URL: https://codereview.chromium.org/497993002

10 years agoremove SkPurgeGlobalDiscardableMemoryPool
halcanary [Mon, 25 Aug 2014 13:20:13 +0000 (06:20 -0700)]
remove SkPurgeGlobalDiscardableMemoryPool

BUG=skia:2721
R=reed@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/495453004

10 years agoClean up useless comments in SkScaledImageCache.h
qiankun.miao [Mon, 25 Aug 2014 13:08:25 +0000 (06:08 -0700)]
Clean up useless comments in SkScaledImageCache.h

BUG=skia:
R=reed@google.com

Author: qiankun.miao@intel.com

Review URL: https://codereview.chromium.org/499203002

10 years agoUpdate SKP version to 82
borenet [Sun, 24 Aug 2014 03:48:08 +0000 (20:48 -0700)]
Update SKP version to 82

Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/499893002