external/skia/src.git
8 weeks agoremove SK_SUPPORT_LEGACY_BLURMASKFILTER_STYLE master
commit-bot@chromium.org [Sat, 31 May 2014 21:47:03 +0000 (21:47 +0000)]
remove SK_SUPPORT_LEGACY_BLURMASKFILTER_STYLE

R=scroggo@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15016 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoRevert of Port most uses of SkOnce to SkLazyPtr. (https://codereview.chromium.org...
commit-bot@chromium.org [Sat, 31 May 2014 00:15:22 +0000 (00:15 +0000)]
Revert of Port most uses of SkOnce to SkLazyPtr. (https://codereview.chromium.org/304383005/)

Reason for revert:
linux x86-64 release segfault in src/ports/SkFontHost_fontconfig.cpp:107

http://108.170.220.120:10117/builders/Test-Ubuntu12-ShuttleA-GTX660-x86_64-Release/builds/905/steps/RunTests/logs/stdio

Original issue's description:
> Port most uses of SkOnce to SkLazyPtr.
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=15006
>
> Committed: http://code.google.com/p/skia/source/detail?r=15014

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

Author: mtklein@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15015 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoPort most uses of SkOnce to SkLazyPtr.
commit-bot@chromium.org [Fri, 30 May 2014 23:59:12 +0000 (23:59 +0000)]
Port most uses of SkOnce to SkLazyPtr.

BUG=skia:

Committed: http://code.google.com/p/skia/source/detail?r=15006

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15014 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoAdd a way for the gpu veto to report back the reason why it said no
commit-bot@chromium.org [Fri, 30 May 2014 21:52:52 +0000 (21:52 +0000)]
Add a way for the gpu veto to report back the reason why it said no

BUG=2334
R=bsalomon@google.com

Author: humper@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15012 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoRevert of Port most uses of SkOnce to SkLazyPtr. (https://codereview.chromium.org...
commit-bot@chromium.org [Fri, 30 May 2014 21:00:52 +0000 (21:00 +0000)]
Revert of Port most uses of SkOnce to SkLazyPtr. (https://codereview.chromium.org/304383005/)

Reason for revert:
Leaking refs on SkTypeface on Macs.

Original issue's description:
> Port most uses of SkOnce to SkLazyPtr.
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=15006

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

Author: mtklein@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15009 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoAllow SkPictureImageFilter to be serialized when not run cross-process.
senorblanco@chromium.org [Fri, 30 May 2014 20:50:56 +0000 (20:50 +0000)]
Allow SkPictureImageFilter to be serialized when not run cross-process.

Picture serialization is not yet hardened, but it turns out we do need
serialization of SkPictureImageFilter for deferred SVG-on-SVG filters,
since the SkPaints (and thus the SkImageFilters) are serialized by
SkPictureRecord. However, deferred filters are always drawn in the
same process, so we can safely serialize them in this case. We do this
by turning the compile-time check for
SK_ALLOW_PICTUREIMAGEFILTER_SERIALIZATION to a runtime check for
isCrossProcess().

The image filter fuzzer sample was also modified to enable fuzzing
of basic picture image filters (the code had rotted a bit, being behind
an #ifdef that no one sets).

BUG=375162
R=sugoi@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15008 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoPort most uses of SkOnce to SkLazyPtr.
commit-bot@chromium.org [Fri, 30 May 2014 20:42:00 +0000 (20:42 +0000)]
Port most uses of SkOnce to SkLazyPtr.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15006 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoAdd an OR operator overload for SaveFlags to avoid extra static casts.
commit-bot@chromium.org [Fri, 30 May 2014 20:41:20 +0000 (20:41 +0000)]
Add an OR operator overload for SaveFlags to avoid extra static casts.

R=reed@google.com

Author: djsollen@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15005 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoRevert of Initial work to get ETC1 data up to the GPU (https://codereview.chromium...
commit-bot@chromium.org [Fri, 30 May 2014 20:36:21 +0000 (20:36 +0000)]
Revert of Initial work to get ETC1 data up to the GPU (https://codereview.chromium.org/302783002/)

Reason for revert:
ETC1 linking problems with chrome.

Original issue's description:
> Initial work to get ETC1 data up to the GPU
>
> Committed: http://code.google.com/p/skia/source/detail?r=15001

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15004 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoImplement SkPictureImageFilter bounds computation.
senorblanco@chromium.org [Fri, 30 May 2014 20:36:15 +0000 (20:36 +0000)]
Implement SkPictureImageFilter bounds computation.

SkPictureImageFilter::onFilterBounds() was unimplemented, causing
incorrect results for SVG filters and impl-side painting (see Chrome
bug https://code.google.com/p/chromium/issues/detail?id=375162).

BUG=skia:
R=reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15003 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoUse GrGLShaderBuilder::GenProgramOutput in GrGLProgram.
commit-bot@chromium.org [Fri, 30 May 2014 18:55:03 +0000 (18:55 +0000)]
Use GrGLShaderBuilder::GenProgramOutput in GrGLProgram.

R=robertphillips@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15002 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoInitial work to get ETC1 data up to the GPU
commit-bot@chromium.org [Fri, 30 May 2014 18:41:39 +0000 (18:41 +0000)]
Initial work to get ETC1 data up to the GPU

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15001 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoFixing clusterfuzz issue
commit-bot@chromium.org [Fri, 30 May 2014 17:32:50 +0000 (17:32 +0000)]
Fixing clusterfuzz issue

When reading an SkSSE2ProcCoeffXfermode object, fProcSIMD should never be NULL. The reason for this is that it's not possible to create such an object through SkPlatformXfermodeFactory_impl_SSE2(), which is the only function used to create these objects, so if we're reading one, it's clearly invalid.

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

Author: sugoi@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@15000 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agomove all code generation under genProgram() in GrGLShaderBuilder.
commit-bot@chromium.org [Fri, 30 May 2014 15:14:56 +0000 (15:14 +0000)]
move all code generation under genProgram() in GrGLShaderBuilder.

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

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14996 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoMove the LATC and ETC1 enum values to GrPixelConfig. I also tried to put in checks...
commit-bot@chromium.org [Fri, 30 May 2014 13:55:58 +0000 (13:55 +0000)]
Move the LATC and ETC1 enum values to GrPixelConfig. I also tried to put in checks in a few places to make sure that we weren't using these pixel configurations in places that we shouldn't be.

LATC is a DXT-esque alpha compression format that goes by a few other names (RGTC, 3DC). It might be useful to investigate using it to compress the alpha masks that we get from software rasterization. This patch set adds enums for that and recognition whether or not the device can support it.

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14991 2bbb7eff-a529-9590-31e7-b0007b416f81

8 weeks agoRevert "Revert of setConfig -> setInfo (https://codereview.chromium.org/308683005/)"
commit-bot@chromium.org [Fri, 30 May 2014 13:26:10 +0000 (13:26 +0000)]
Revert "Revert of setConfig -> setInfo (https://codereview.chromium.org/308683005/)"

This reverts commit eecaea4148805834f223681f70b6488ceba12d09.

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

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14989 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFix the rendering error of SkDraw::drawVertices in gpu path for solid color.
commit-bot@chromium.org [Fri, 30 May 2014 10:08:22 +0000 (10:08 +0000)]
Fix the rendering error of SkDraw::drawVertices in gpu path for solid color.

If both textures and vertex-colors are NULL, drawVertices should stroke hairlines with the paint's color.
This behavior is a useful debugging mode to visualize the mesh.

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

Author: yunchao.he@intel.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14985 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSanitizing source files in Housekeeper-Nightly
skia.committer@gmail.com [Fri, 30 May 2014 03:06:10 +0000 (03:06 +0000)]
Sanitizing source files in Housekeeper-Nightly

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14984 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFixing a clusterfuzz found issue
commit-bot@chromium.org [Fri, 30 May 2014 01:06:44 +0000 (01:06 +0000)]
Fixing a clusterfuzz found issue

BUG=378175
R=reed@google.com, sugoi@google.com

Author: sugoi@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14983 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoMake GrGLShaderBuilder store a GenProgramOutput
commit-bot@chromium.org [Thu, 29 May 2014 22:20:03 +0000 (22:20 +0000)]
Make GrGLShaderBuilder store a GenProgramOutput

R=robertphillips@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14982 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoIncremental refactoring of GrGLProgram and GrGLShaderBuilder
commit-bot@chromium.org [Thu, 29 May 2014 21:29:51 +0000 (21:29 +0000)]
Incremental refactoring of GrGLProgram and GrGLShaderBuilder

R=robertphillips@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14980 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of setConfig -> setInfo (https://codereview.chromium.org/308683005/)
commit-bot@chromium.org [Thu, 29 May 2014 21:10:32 +0000 (21:10 +0000)]
Revert of setConfig -> setInfo (https://codereview.chromium.org/308683005/)

Reason for revert:
broke all Windows bots

Original issue's description:
> setConfig -> setInfo
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14978

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

Author: epoger@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14979 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agosetConfig -> setInfo
commit-bot@chromium.org [Thu, 29 May 2014 20:47:53 +0000 (20:47 +0000)]
setConfig -> setInfo

BUG=skia:
R=robertphillips@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14978 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSkLazyPtr, mk. 2
commit-bot@chromium.org [Thu, 29 May 2014 20:13:22 +0000 (20:13 +0000)]
SkLazyPtr, mk. 2

SK_DECLARE_STATIC_LAZY_PTR and
SK_DECLARE_STATIC_LAZY_PTR_ARRAY let you declare a single or
array of static pointers that are lazily initialized.

You can think of this as a restricted, lighter-weight
version of SkOnce.  There's no guarantee that Create will be
called exactly once, but we do guarantee all threads will
agree on the resulting pointer.

We'll clean up any other extra pointers we Create()ed by
calling Destroy(), which defaults to SkDELETE.  In debug
mode, we also clean up the winning pointer at process exit,
so we can make sure we didn't leak it or free it early.

I've ported SkData (singleton) and SkXfermode (array) as
examples.  Once this lands I'll port most other users of
SkOnce.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14976 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoConstify the arguments to createTexture
commit-bot@chromium.org [Thu, 29 May 2014 19:26:48 +0000 (19:26 +0000)]
Constify the arguments to createTexture

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14975 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoMove all code generation from GrGLProgram to GrGLShaderBuilder
commit-bot@chromium.org [Thu, 29 May 2014 19:09:52 +0000 (19:09 +0000)]
Move all code generation from GrGLProgram to GrGLShaderBuilder

R=robertphillips@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14974 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agomove SkImageGenerator.cpp from src/images to src/core
reed@google.com [Thu, 29 May 2014 18:47:06 +0000 (18:47 +0000)]
move SkImageGenerator.cpp from src/images to src/core

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14973 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd testing for Rectanizer-derived classes
commit-bot@chromium.org [Thu, 29 May 2014 18:46:38 +0000 (18:46 +0000)]
Add testing for Rectanizer-derived classes

This in preparation for expanding the Rectanizer API for removing rects and adding a new derived class

R=jvanverth@google.com

Author: robertphillips@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14972 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoTinker with SkLazyFnPtr a bit.
commit-bot@chromium.org [Thu, 29 May 2014 18:29:48 +0000 (18:29 +0000)]
Tinker with SkLazyFnPtr a bit.

I moved the choice function from a get() arg to a template parameter.

I think this removes some of the overemphasis on "choose" from the call
site, making it a bit more clear it's normally very cheap.

It's also now more in line with what I'm thinking now for the general
SkLazyPtr<T>, which needs a "create" parameter just like SkLazyFnPtr's
"choose", but also a "destroy" that it might use both in .get() but also
at process exit.  That "destroy" needs to be made part of the type to be
called at exit, so might as well make "create" and "choose" template
parameters too so it's all consistent.

Also, add (C).

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14971 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd SkBarriers to ports.
commit-bot@chromium.org [Thu, 29 May 2014 18:24:54 +0000 (18:24 +0000)]
Add SkBarriers to ports.

This completes a TODO we've had to move our memory-barrier code out of
SkOnce.  I also want to start using sk_acquire_load elsewhere.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14970 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agofix bug in legacy code for SK_SUPPORT_LEGACY_IMAGEGENERATORAPI
reed@google.com [Thu, 29 May 2014 17:10:54 +0000 (17:10 +0000)]
fix bug in legacy code for SK_SUPPORT_LEGACY_IMAGEGENERATORAPI

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14967 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove SkRecorder's kWriteOnly mode.
commit-bot@chromium.org [Thu, 29 May 2014 16:52:40 +0000 (16:52 +0000)]
Remove SkRecorder's kWriteOnly mode.

I'm soon going to have SkRecorder start calling getTotalMatrix(), which
would be broken in write-only mode.  That change is big and nebulous,
but it's clear kWriteOnly needs to go, so we might as well kill it now.

My notes in bench_playback about kWriteOnly mode being important were
probably overly cautious.  I now think this is a fair enough comparison
even re-recording into a read-write canvas.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14963 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoreplace config() with colorType()
commit-bot@chromium.org [Thu, 29 May 2014 15:57:47 +0000 (15:57 +0000)]
replace config() with colorType()

BUG=skia:
R=robertphillips@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14959 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert "Revert of add colortable support to imagegenerator (https://codereview.chromi...
commit-bot@chromium.org [Thu, 29 May 2014 15:57:20 +0000 (15:57 +0000)]
Revert "Revert of add colortable support to imagegenerator (https://codereview.chromium.org/304443003/)"

Fix is to add colortable param to installPixels()

This reverts commit 924205aaf2e0c3c65dda13e0eaccde3e7b2a5c40.

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

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14958 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoMake SkPictureRecorder::partialReplay const
commit-bot@chromium.org [Thu, 29 May 2014 15:57:11 +0000 (15:57 +0000)]
Make SkPictureRecorder::partialReplay const

This will make it easier to integrate this into Android's use case.

R=reed@google.com

Author: robertphillips@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14957 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoPut DirectWrite bitmap fix behind the SK_IGNORE_DWRITE_BITMAP_FIX flag.
bungeman@google.com [Thu, 29 May 2014 15:54:27 +0000 (15:54 +0000)]
Put DirectWrite bitmap fix behind the SK_IGNORE_DWRITE_BITMAP_FIX flag.

R=reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14956 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoseparate view matrix from rt adjustment
commit-bot@chromium.org [Thu, 29 May 2014 01:12:10 +0000 (01:12 +0000)]
separate view matrix from rt adjustment

R=robertphillips@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14944 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSpin off just SkLazyFnPtr from 305513002.
commit-bot@chromium.org [Wed, 28 May 2014 21:43:59 +0000 (21:43 +0000)]
Spin off just SkLazyFnPtr from 305513002.

The memory barrier in SkOnce is a perf regression for sk_mem{set,cpy} in
SkUtils on ARM.  We can do a lot better for function pointers.

BUG=skia:

Committed: http://code.google.com/p/skia/source/detail?r=14929

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14938 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert "Remove SkThread.h from public API."
commit-bot@chromium.org [Wed, 28 May 2014 20:02:17 +0000 (20:02 +0000)]
Revert "Remove SkThread.h from public API."

Too much depends on SkThread being in include/core in Chrome build.

This reverts commit b1aec17df6078115c797839c9646081ccba2bd09.

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

BUG=skia:

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14934 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Spin off just SkLazyFnPtr from 305513002. (https://codereview.chromium...
commit-bot@chromium.org [Wed, 28 May 2014 19:58:14 +0000 (19:58 +0000)]
Revert of Spin off just SkLazyFnPtr from 305513002. (https://codereview.chromium.org/305753002/)

Reason for revert:
depends on bad cl

Original issue's description:
> Spin off just SkLazyFnPtr from 305513002.
>
> The memory barrier in SkOnce is a perf regression for sk_mem{set,cpy} in
> SkUtils on ARM.  We can do a lot better for function pointers.
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14929

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

Author: mtklein@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14933 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Fix SkAtomics_win.h typos. (https://codereview.chromium.org/293363017/)
commit-bot@chromium.org [Wed, 28 May 2014 19:57:18 +0000 (19:57 +0000)]
Revert of Fix SkAtomics_win.h typos. (https://codereview.chromium.org/293363017/)

Reason for revert:
depends on bad cl

Original issue's description:
> Fix SkAtomics_win.h typos.
>
> NOTRY=true
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14930

R=mtklein@chromium.org
TBR=mtklein@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: mtklein@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14932 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFix SkAtomics_win.h typos.
commit-bot@chromium.org [Wed, 28 May 2014 19:50:29 +0000 (19:50 +0000)]
Fix SkAtomics_win.h typos.

NOTRY=true

BUG=skia:
R=mtklein@google.com

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14930 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSpin off just SkLazyFnPtr from 305513002.
commit-bot@chromium.org [Wed, 28 May 2014 19:40:21 +0000 (19:40 +0000)]
Spin off just SkLazyFnPtr from 305513002.

The memory barrier in SkOnce is a perf regression for sk_mem{set,cpy} in
SkUtils on ARM.  We can do a lot better for function pointers.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14929 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFix filter bounds computation for SkOffsetImageFilter.
senorblanco@chromium.org [Wed, 28 May 2014 19:29:25 +0000 (19:29 +0000)]
Fix filter bounds computation for SkOffsetImageFilter.

SkOffsetImageFilter::onFilterBounds() was not recursing into its input
filter when computing bounds.

BUG=374556
R=junov@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14928 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove SkThread.h from public API.
commit-bot@chromium.org [Wed, 28 May 2014 19:24:54 +0000 (19:24 +0000)]
Remove SkThread.h from public API.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14926 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd SkPurgeGlobalDiscardableMemoryPool, needed to replace SkImageRef
commit-bot@chromium.org [Wed, 28 May 2014 18:51:03 +0000 (18:51 +0000)]
Add  SkPurgeGlobalDiscardableMemoryPool, needed to replace SkImageRef

BUG=skia:2389
R=reed@google.com, scroggo@google.com

Author: halcanary@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14925 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoMake image scaling have floating point scales. Third attempt to land this
commit-bot@chromium.org [Wed, 28 May 2014 17:30:02 +0000 (17:30 +0000)]
Make image scaling have floating point scales.  Third attempt to land this
due to some struggles with the CQ.  Original CL here:

https://codereview.chromium.org/298243003/

BUG=
R=bsalomon@google.com, epoger@google.com
TBR=bsalomon, epoger

Author: humper@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14920 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of add colortable support to imagegenerator (https://codereview.chromium.org...
commit-bot@chromium.org [Wed, 28 May 2014 16:16:08 +0000 (16:16 +0000)]
Revert of add colortable support to imagegenerator (https://codereview.chromium.org/304443003/)

Reason for revert:
failing tests

Original issue's description:
> add colortable support to imagegenerator
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14916

R=halcanary@google.com, scroggo@google.com
TBR=halcanary@google.com, scroggo@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14917 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoadd colortable support to imagegenerator
commit-bot@chromium.org [Wed, 28 May 2014 16:01:55 +0000 (16:01 +0000)]
add colortable support to imagegenerator

BUG=skia:
R=halcanary@google.com, scroggo@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14916 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoBetter handling of bitmaps in DirectWrite.
bungeman@google.com [Wed, 28 May 2014 15:40:26 +0000 (15:40 +0000)]
Better handling of bitmaps in DirectWrite.

R=reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14915 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoInclude SkTypes to fix Android frameworks build
commit-bot@chromium.org [Wed, 28 May 2014 15:02:37 +0000 (15:02 +0000)]
Include SkTypes to fix Android frameworks build

Since Android's defines are included in SkUserConfig (rather than
being defined in the build file), we need to include something that
includes SkUserConfig (transitively; meaning just about anything)
before we can use any build macros. Include SkTypes, "the correct
way to get access to the config system" so that
SK_BUILD_FOR_ANDROID is defined before querying it.

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

Author: scroggo@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14914 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSanitizing source files in Housekeeper-Nightly
skia.committer@gmail.com [Wed, 28 May 2014 03:06:06 +0000 (03:06 +0000)]
Sanitizing source files in Housekeeper-Nightly

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14912 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoadd replay entry point to SkPictureRecorder for Android
commit-bot@chromium.org [Tue, 27 May 2014 23:41:45 +0000 (23:41 +0000)]
add replay entry point to SkPictureRecorder for Android

This CL adds an Android-only entry point to address the Java Picture(Picture) and serialize use cases. Note that (in its current form) it doesn't preserve the old API's handling of unbalanced saves/saveLayers (this CL always balances them).

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

Author: robertphillips@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14911 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoremove SkBitmap::asImageInfo
commit-bot@chromium.org [Tue, 27 May 2014 21:30:37 +0000 (21:30 +0000)]
remove SkBitmap::asImageInfo

BUG=skia:
R=scroggo@google.com, halcanary@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14909 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoManual SVN revert of https://code.google.com/p/skia/source/detail?r=14905
epoger@google.com [Tue, 27 May 2014 21:12:42 +0000 (21:12 +0000)]
Manual SVN revert of https://code.google.com/p/skia/source/detail?r=14905

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14907 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agofloating point scale factors for images
commit-bot@chromium.org [Tue, 27 May 2014 20:54:04 +0000 (20:54 +0000)]
floating point scale factors for images

New version of https://codereview.chromium.org/298243003/ made to deal with binary file being lost.

BUG=
TBR=bsalomon
NOTRY=true

Author: humper@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14905 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Revert of Add compressed texture capabilities for GPU devices
commit-bot@chromium.org [Tue, 27 May 2014 19:26:59 +0000 (19:26 +0000)]
Revert of Revert of Add compressed texture capabilities for GPU devices
(https://codereview.chromium.org/307543002/)

Reason for revert:
Re-landing the original CL, because the revert didn't fix things.  See http://skbug.com/2608 ('RunDecodingTests failing on multiple platforms')

Original issue's description:
> Revert of Add compressed texture capabilities for GPU devices (https://codereview.chromium.org/292323003/)
>
> Reason for revert:
> RunDecodingTests failing on multiple platforms.  Please use trybots to validate and re-land.
>
> Original issue's description:
> > Add compressed texture capabilities for GPU devices
> >
> > BUG=skia:
> >
> > Committed: http://code.google.com/p/skia/source/detail?r=14880
> >
> > Committed: http://code.google.com/p/skia/source/detail?r=14901
>
> TBR=bsalomon@google.com,robertphillips@google.com,krajcevski@google.com
> NOTREECHECKS=true
> NOTRY=true
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14902

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

Author: epoger@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14903 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Add compressed texture capabilities for GPU devices (https://codereview...
commit-bot@chromium.org [Tue, 27 May 2014 19:07:10 +0000 (19:07 +0000)]
Revert of Add compressed texture capabilities for GPU devices (https://codereview.chromium.org/292323003/)

Reason for revert:
RunDecodingTests failing on multiple platforms.  Please use trybots to validate and re-land.

Original issue's description:
> Add compressed texture capabilities for GPU devices
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14880
>
> Committed: http://code.google.com/p/skia/source/detail?r=14901

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

Author: epoger@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14902 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd compressed texture capabilities for GPU devices
commit-bot@chromium.org [Tue, 27 May 2014 18:52:24 +0000 (18:52 +0000)]
Add compressed texture capabilities for GPU devices

BUG=skia:

Committed: http://code.google.com/p/skia/source/detail?r=14880

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14901 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove some unnecessary uses of SkOnce.
commit-bot@chromium.org [Tue, 27 May 2014 16:28:43 +0000 (16:28 +0000)]
Remove some unnecessary uses of SkOnce.

  - gm/imagefiltersgraph.cpp can just use a global registrar
  - SkScaledImageCache always accesses its global under a lock

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14897 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoUse SkAtomics_sync on Android
commit-bot@chromium.org [Tue, 27 May 2014 15:55:35 +0000 (15:55 +0000)]
Use SkAtomics_sync on Android

Every doc I've found about using Android's atomics says, "stop".

"* A handful of basic atomic operations.  The appropriate pthread
 * functions should be used instead of these whenever possible."

"... we recommend stopping from using these functions entirely. Very fortunately, GCC provides handy intrinsics functions that work with very reasonable performance and always provide a full barrier."

As far as I can tell, there's no code generation change here: both the __sync atomics and the android_ atomics use full memory barriers.  (And now with this all unified, it'll be easier to get the real wins by switching everything to __atomic atomics, which are like __sync atomics but allow control over memory barriers.)

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14896 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoDrop support for non-atomic non-mutex platforms.
commit-bot@chromium.org [Tue, 27 May 2014 15:16:37 +0000 (15:16 +0000)]
Drop support for non-atomic non-mutex platforms.

(Clients can still provide these themselves if they really want.)

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14894 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoImplement sk_atomic_conditional_inc with sk_atomic_cas.
commit-bot@chromium.org [Tue, 27 May 2014 15:00:32 +0000 (15:00 +0000)]
Implement sk_atomic_conditional_inc with sk_atomic_cas.

Now that we have sk_atomic_cas, we can replace all the platform-specific CAS loops with one.

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

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14892 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoMove SkDecodingImageGenerator.h to include/
commit-bot@chromium.org [Tue, 27 May 2014 14:59:47 +0000 (14:59 +0000)]
Move SkDecodingImageGenerator.h to include/

This will allow Android to access it and remove SkImageRef.

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

BUG=skia:2389
R=reed@google.com, djsollen@google.com, halcanary@google.com

Author: scroggo@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14891 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd OpenGL Compressed Texture enum values
commit-bot@chromium.org [Tue, 27 May 2014 14:35:25 +0000 (14:35 +0000)]
Add OpenGL Compressed Texture enum values

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14890 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agohide discardable factory from public imagegenerator api
commit-bot@chromium.org [Tue, 27 May 2014 14:14:22 +0000 (14:14 +0000)]
hide discardable factory from public imagegenerator api

BUG=skia:
R=halcanary@google.com, scroggo@google.com, djsollen@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14889 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoremove SK_SUPPORT_LEGACY_BITMAPFLATTEN code
commit-bot@chromium.org [Tue, 27 May 2014 14:03:51 +0000 (14:03 +0000)]
remove SK_SUPPORT_LEGACY_BITMAPFLATTEN code

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

Author: reed@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14888 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agosk_memcpy32 should fall back on libc memcpy.
commit-bot@chromium.org [Tue, 27 May 2014 12:45:42 +0000 (12:45 +0000)]
sk_memcpy32 should fall back on libc memcpy.

Writing it out ourselves was a ~2x slowdown on ARM.

BUG=skia:
R=henrik.smiding@intel.com, mtklein@google.com

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14886 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSanitizing source files in Housekeeper-Nightly
skia.committer@gmail.com [Sat, 24 May 2014 03:05:26 +0000 (03:05 +0000)]
Sanitizing source files in Housekeeper-Nightly

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14884 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Add compressed texture capabilities for GPU devices (https://codereview...
commit-bot@chromium.org [Fri, 23 May 2014 20:40:26 +0000 (20:40 +0000)]
Revert of Add compressed texture capabilities for GPU devices (https://codereview.chromium.org/292323003/)

Reason for revert:
Signeness comparison breaks build. After working some more, I think the API design will be cleaner without the Uncompressed enum, so I'm removing it and retesting everything.

Original issue's description:
> Add compressed texture capabilities for GPU devices
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14880

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14883 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agomove ashmem switching logic to SkDiscardableMemory::Create
commit-bot@chromium.org [Fri, 23 May 2014 20:25:15 +0000 (20:25 +0000)]
move ashmem switching logic to SkDiscardableMemory::Create

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

Author: halcanary@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14882 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoChange the PKM decoder to adhere to sampler size
commit-bot@chromium.org [Fri, 23 May 2014 20:00:59 +0000 (20:00 +0000)]
Change the PKM decoder to adhere to sampler size

This fixes a bug where the red and blue channels seemed to be swapped on some platforms after decoding, and brings it more in line with the logic already in libbmp.

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14881 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd compressed texture capabilities for GPU devices
commit-bot@chromium.org [Fri, 23 May 2014 20:00:54 +0000 (20:00 +0000)]
Add compressed texture capabilities for GPU devices

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

Author: krajcevski@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14880 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Modify sample buffer size for larger displays. (https://codereview.chromium...
commit-bot@chromium.org [Fri, 23 May 2014 19:13:56 +0000 (19:13 +0000)]
Revert of Modify sample buffer size for larger displays. (https://codereview.chromium.org/240433002/)

Reason for revert:
This also changes verylargebitmap, and the difference appears to be meaningful. Henrik, I have emailed you the images that differ.

Original issue's description:
> Modify sample buffer size for larger displays.
>
> Increases the intermediate buffer size for sample pixel indexes,
> used in the sample proc function calls. If the operation is bigger
> than the buffer it's split into multiple calls, creating overhead.
> This would especially impact the performance of SIMD optimizations.
> Also, aligns the start address of the buffer to 16 bytes, to enable
> more efficient SIMD optimizations.
>
> Author: henrik.smiding@intel.com
>
> Signed-off-by: Henrik Smiding <henrik.smiding@intel.com>
>
> Committed: http://code.google.com/p/skia/source/detail?r=14825
>
> Committed: http://code.google.com/p/skia/source/detail?r=14872

R=reed@google.com, mtklein@google.com, tomhudson@google.com, djsollen@google.com, joakim.landberg@intel.com, bsalomon@chromium.org, bsalomon@google.com, henrik.smiding@intel.com
TBR=reed@google.com
NOTREECHECKS=true
NOTRY=true

Author: scroggo@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14878 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoModify sample buffer size for larger displays.
commit-bot@chromium.org [Fri, 23 May 2014 16:05:43 +0000 (16:05 +0000)]
Modify sample buffer size for larger displays.

Increases the intermediate buffer size for sample pixel indexes,
used in the sample proc function calls. If the operation is bigger
than the buffer it's split into multiple calls, creating overhead.
This would especially impact the performance of SIMD optimizations.
Also, aligns the start address of the buffer to 16 bytes, to enable
more efficient SIMD optimizations.

Author: henrik.smiding@intel.com

Signed-off-by: Henrik Smiding <henrik.smiding@intel.com>
Committed: http://code.google.com/p/skia/source/detail?r=14825

R=reed@google.com, mtklein@google.com, tomhudson@google.com, djsollen@google.com, joakim.landberg@intel.com, scroggo@google.com, bsalomon@chromium.org, bsalomon@google.com

Author: henrik.smiding@intel.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14872 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agostop calling SkBitmap::flatten
commit-bot@chromium.org [Fri, 23 May 2014 13:21:55 +0000 (13:21 +0000)]
stop calling SkBitmap::flatten

BUG=skia:
R=scroggo@google.com, halcanary@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14867 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agofix stroking large drawPosText
commit-bot@chromium.org [Fri, 23 May 2014 12:32:23 +0000 (12:32 +0000)]
fix stroking large drawPosText

BUG=skia:
R=bungeman@google.com, yunchao.he@intel.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14865 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agofix the visual diff of raster vs gpu -- vertices_80. The sw-raster is correct, all...
commit-bot@chromium.org [Fri, 23 May 2014 08:09:26 +0000 (08:09 +0000)]
fix the visual diff of raster vs gpu -- vertices_80. The sw-raster is correct, all images are blurry.
While some images generated by gpu doesn't respect SkPaint's alpha value.

In gpu path, when pass SkPaint's alpha and color to GrPaint by SkPaint2GrPaintNoShader,
either alpha or colors can't not be passed. We can't pass both of them by the API.
Premultiply paint's alpha to colors's alpha in drawVertices, and pass colors to GrPaint.
The rendering result will respect colors in drawVertices, and the alpha value set in SkPaint as well.

BUG=skia:2592
R=bsalomon@google.com

Author: yunchao.he@intel.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14863 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSanitizing source files in Housekeeper-Nightly
skia.committer@gmail.com [Fri, 23 May 2014 03:03:34 +0000 (03:03 +0000)]
Sanitizing source files in Housekeeper-Nightly

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14862 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoturn assert into not_implemented_yet for patheffects on text
reed@google.com [Thu, 22 May 2014 18:53:10 +0000 (18:53 +0000)]
turn assert into not_implemented_yet for patheffects on text

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14854 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSimple PKM image decoder.
robertphillips@google.com [Thu, 22 May 2014 18:40:29 +0000 (18:40 +0000)]
Simple PKM image decoder.

https://codereview.chromium.org/292663011/

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14852 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove SK_IGNORE_UNDERLINE_POSITION_FIX now that it is no longer used.
bungeman@google.com [Thu, 22 May 2014 17:59:21 +0000 (17:59 +0000)]
Remove SK_IGNORE_UNDERLINE_POSITION_FIX now that it is no longer used.

R=reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14849 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoIn convexity checker don't advance last vector when x-product isn't significant.
commit-bot@chromium.org [Thu, 22 May 2014 14:58:53 +0000 (14:58 +0000)]
In convexity checker don't advance last vector when x-product isn't significant.

BUG=skia:2235
R=caryclark@google.com

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14845 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert "Temporarily disable NEON on Android framework builds."
commit-bot@chromium.org [Thu, 22 May 2014 13:42:34 +0000 (13:42 +0000)]
Revert "Temporarily disable NEON on Android framework builds."

R=scroggo@google.com

Author: djsollen@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14844 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove unused (by clients) SkUnitMapper
commit-bot@chromium.org [Thu, 22 May 2014 12:27:41 +0000 (12:27 +0000)]
Remove unused (by clients) SkUnitMapper

This reverts commit 874423a81b5bc2541c7397e6ab00d5e7c9fdaf98.

TBR=scroggo

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14842 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Fix compilation error when building with clang on Linux. (https://coderevie...
commit-bot@chromium.org [Thu, 22 May 2014 03:20:47 +0000 (03:20 +0000)]
Revert of Fix compilation error when building with clang on Linux. (https://codereview.chromium.org/287193006/)

Reason for revert:
need to revert this along with reverting the big unitmapper cl

Original issue's description:
> Fix compilation error when building with clang on Linux.
>
> ../../src/effects/gradients/SkGradientShader.cpp:487:22: error: unused
> function 'bitsTo16' [-Werror,-Wunused-function]
> static inline U16CPU bitsTo16(unsigned x, const unsigned bits) {
>
> R=bsalomon@google.com
> TEST=make tests
>
> Committed: http://code.google.com/p/skia/source/detail?r=14835

R=bsalomon@google.com, reed@google.com, tfarina@chromium.org
TBR=bsalomon@google.com, reed@google.com, tfarina@chromium.org
NOTREECHECKS=true
NOTRY=true

Author: reed@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14839 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Remove unused (by clients) SkUnitMapper (https://codereview.chromium.org...
commit-bot@chromium.org [Thu, 22 May 2014 02:55:59 +0000 (02:55 +0000)]
Revert of Remove unused (by clients) SkUnitMapper (https://codereview.chromium.org/283273002/) (https://codereview.chromium.org/288343009/)

Reason for revert:
required blink change failed to land

Original issue's description:
> Remove unused (by clients) SkUnitMapper (https://codereview.chromium.org/283273002/)
>
> This reverts commit dd50c83b5b34dab3a077741861b50ed1f2bc6b8f.
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14830

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

Author: reed@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14838 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFix compilation error when building with clang on Linux.
commit-bot@chromium.org [Wed, 21 May 2014 22:31:00 +0000 (22:31 +0000)]
Fix compilation error when building with clang on Linux.

../../src/effects/gradients/SkGradientShader.cpp:487:22: error: unused
function 'bitsTo16' [-Werror,-Wunused-function]
static inline U16CPU bitsTo16(unsigned x, const unsigned bits) {

R=bsalomon@google.com, reed@google.com
TEST=make tests

Author: tfarina@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14835 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove SkDebugf that is gumming up the bot logs
commit-bot@chromium.org [Wed, 21 May 2014 20:42:57 +0000 (20:42 +0000)]
Remove SkDebugf that is gumming up the bot logs

This SkDebugf is making the bot logs a bit harder to read:

http://108.170.220.120:10117/builders/Perf-Win7-ShuttleA-HD2000-x86-Release-ANGLE/builds/1959/steps/BenchPictures/logs/stdio

R=bsalomon@google.com

Author: robertphillips@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14832 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove unused (by clients) SkUnitMapper (https://codereview.chromium.org/283273002/)
commit-bot@chromium.org [Wed, 21 May 2014 19:56:46 +0000 (19:56 +0000)]
Remove unused (by clients) SkUnitMapper (https://codereview.chromium.org/283273002/)

This reverts commit dd50c83b5b34dab3a077741861b50ed1f2bc6b8f.

BUG=skia:
R=scroggo@google.com

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14830 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoFix undefined behavior in DirectWrite GDI compatible metrics.
bungeman@google.com [Wed, 21 May 2014 19:44:39 +0000 (19:44 +0000)]
Fix undefined behavior in DirectWrite GDI compatible metrics.

GetGdiCompatibleGlyphMetrics checks the matrix passed to it.
If the matrix has any NaNs or INFs or otherwise looks bad, it returns
E_INVALIDARG and so the advances will be zero.

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

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14829 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRemove 1/2 pixel offsets for distance field layout.
commit-bot@chromium.org [Wed, 21 May 2014 19:44:24 +0000 (19:44 +0000)]
Remove 1/2 pixel offsets for distance field layout.

The 1/2 pixel offsets are for rounding when snapping the glyphs to integer boundaries. Since we're using subpixel layout and sampled textures, we shouldn't snap to integer boundaries.

BUG=skia:2173
R=bungeman@google.com, reed@google.com

Author: jvanverth@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14828 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert "Modify sample buffer size for larger displays."
reed@google.com [Wed, 21 May 2014 16:38:43 +0000 (16:38 +0000)]
Revert "Modify sample buffer size for larger displays."

This reverts commit dd72f3bd0d500b9b3f900bcb8e904161ee51eae5.

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14827 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoRevert of Revert ""Revert of eliminate config param -- it was always self's config...
commit-bot@chromium.org [Wed, 21 May 2014 15:58:00 +0000 (15:58 +0000)]
Revert of Revert ""Revert of eliminate config param -- it was always self's config (https://codereview.chromi‚Ķ (https://codereview.chromium.org/291163005/)

Reason for revert:
broke 6 webgl/canvas tests in blink (don't know why yet)

https://storage.googleapis.com/chromium-layout-test-archives/WebKit_Mac10_7/27348/layout-test-results/results.html

Original issue's description:
> Revert ""Revert of eliminate config param -- it was always self's config (https://codereview.chromium.org/246513002/)"""
>
> This reverts commit 3dbceb4f8283b2fb1728d0daf010d036099a2eae.
>
> BUG=skia:
>
> Committed: http://code.google.com/p/skia/source/detail?r=14806

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

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14826 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoModify sample buffer size for larger displays.
commit-bot@chromium.org [Wed, 21 May 2014 15:16:15 +0000 (15:16 +0000)]
Modify sample buffer size for larger displays.

Increases the intermediate buffer size for sample pixel indexes,
used in the sample proc function calls. If the operation is bigger
than the buffer it's split into multiple calls, creating overhead.
This would especially impact the performance of SIMD optimizations.
Also, aligns the start address of the buffer to 16 bytes, to enable
more efficient SIMD optimizations.

Author: henrik.smiding@intel.com

Signed-off-by: Henrik Smiding <henrik.smiding@intel.com>
R=reed@google.com, mtklein@google.com, tomhudson@google.com, djsollen@google.com, joakim.landberg@intel.com, scroggo@google.com, bsalomon@chromium.org, bsalomon@google.com

Author: henrik.smiding@intel.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14825 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoAdd EXT suffix to EXT_map_buffer_range references
djsollen@google.com [Wed, 21 May 2014 13:52:13 +0000 (13:52 +0000)]
Add EXT suffix to EXT_map_buffer_range references

This rearranges the code to use the non-suffixed entry point for ES
3.x contexts, and the suffixed entry point on ES 2.0 contexts that
have the extension.

R=robertphillips@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14823 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoSSE2 implementation of memcpy32
commit-bot@chromium.org [Wed, 21 May 2014 12:43:07 +0000 (12:43 +0000)]
SSE2 implementation of memcpy32

With SSE2 version memcpy32, S32_Opaque_BlitRow32() in SkBlitRow_D32.cpp
has about 30% performance improvement. Here are the data on desktop
i7-3770.
before:
       bitmap_scale_filter_90_90   8888:  cmsecs =      2.01
      bitmaprect_FF_filter_trans   8888:  cmsecs =      3.61
    bitmaprect_FF_nofilter_trans   8888:  cmsecs =      3.57
   bitmaprect_FF_filter_identity   8888:  cmsecs =      3.53
 bitmaprect_FF_nofilter_identity   8888:  cmsecs =      3.53
              bitmap_4444_update   8888:  cmsecs =      4.84
     bitmap_4444_update_volatile   8888:  cmsecs =      4.81
                     bitmap_4444   8888:  cmsecs =      4.81
after:
       bitmap_scale_filter_90_90   8888:  cmsecs =      1.83
      bitmaprect_FF_filter_trans   8888:  cmsecs =      2.36
    bitmaprect_FF_nofilter_trans   8888:  cmsecs =      2.36
   bitmaprect_FF_filter_identity   8888:  cmsecs =      2.60
 bitmaprect_FF_nofilter_identity   8888:  cmsecs =      2.63
              bitmap_4444_update   8888:  cmsecs =      3.30
     bitmap_4444_update_volatile   8888:  cmsecs =      3.30
                     bitmap_4444   8888:  cmsecs =      3.29

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

Author: qiankun.miao@intel.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14822 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoUndo troublesome SSE 4.1 change for now to unblock Skia -> Chrome roll.
commit-bot@chromium.org [Tue, 20 May 2014 23:07:26 +0000 (23:07 +0000)]
Undo troublesome SSE 4.1 change for now to unblock Skia -> Chrome roll.

BUG=chromium:374796

NOTREECHECKS=true
R=fmalita@chromium.org, mtklein@google.com

Author: mtklein@chromium.org

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14816 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoCentralize decision about whether to do bicubic filtering, and fallbacks to mip,...
commit-bot@chromium.org [Tue, 20 May 2014 17:51:13 +0000 (17:51 +0000)]
Centralize decision about whether to do bicubic filtering, and fallbacks to mip, bilerp, or nearest

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

Author: bsalomon@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14809 2bbb7eff-a529-9590-31e7-b0007b416f81

2 months agoformalize named picture versions
commit-bot@chromium.org [Tue, 20 May 2014 17:31:08 +0000 (17:31 +0000)]
formalize named picture versions

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

Author: reed@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk/src@14807 2bbb7eff-a529-9590-31e7-b0007b416f81