platform/upstream/libSkiaSharp.git
8 years agoGN: _turbo -> -turbo to match Fuchsia
mtklein [Mon, 22 Aug 2016 13:32:39 +0000 (06:32 -0700)]
GN: _turbo -> -turbo to match Fuchsia

We might as well match the folks who are using our GN files now.

We've got plenty of strategies in our pocket for when we try to move Chrome
onto our GN files (and who knows, there may be even a new better way by then):
  * Same sort of rename in Chrome's third_party
  * Aliased targets via //build/secondary in Chrome.
  * Indirection via build_overrides

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2265503002

Review-Url: https://codereview.chromium.org/2265503002

8 years agoSimplify the gradient color stop optimizer
fmalita [Mon, 22 Aug 2016 13:28:57 +0000 (06:28 -0700)]
Simplify the gradient color stop optimizer

We're just discarding the leftmost/rightmost stops -- this can be
achieved by simply adjusting the start offset and count.

R=reed@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2265803002

Review-Url: https://codereview.chromium.org/2265803002

8 years agoAdd a gradient edge optimization test
fmalita [Mon, 22 Aug 2016 13:22:28 +0000 (06:22 -0700)]
Add a gradient edge optimization test

R=reed@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2267593002

Review-Url: https://codereview.chromium.org/2267593002

8 years agomake zoomer text clearer
reed [Mon, 22 Aug 2016 02:30:13 +0000 (19:30 -0700)]
make zoomer text clearer

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2267623002

TBR=

Review-Url: https://codereview.chromium.org/2267623002

8 years agoadd translate to exercise non-identity ctm performance
reed [Sun, 21 Aug 2016 22:03:47 +0000 (15:03 -0700)]
add translate to exercise non-identity ctm performance

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2261063002

TBR=

Review-Url: https://codereview.chromium.org/2261063002

8 years agoUpdate SKP version
update-skps [Sun, 21 Aug 2016 08:51:30 +0000 (01:51 -0700)]
Update SKP version

Automatic commit by the RecreateSKPs bot.

TBR=
NO_MERGE_BUILDS
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2261983002

Review-Url: https://codereview.chromium.org/2261983002

8 years agoremove unused field from SkDrawIter
reed [Sat, 20 Aug 2016 18:32:48 +0000 (11:32 -0700)]
remove unused field from SkDrawIter

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2267553002

TBR=

Review-Url: https://codereview.chromium.org/2267553002

8 years agostore info in basedevice, change getter to non-virtual const&
reed [Sat, 20 Aug 2016 14:59:19 +0000 (07:59 -0700)]
store info in basedevice, change getter to non-virtual const&

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2261003003

Review-Url: https://codereview.chromium.org/2261003003

8 years agosrc/utils/SkBitSet: simplify
halcanary [Fri, 19 Aug 2016 23:23:23 +0000 (16:23 -0700)]
src/utils/SkBitSet: simplify

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2265623002

Review-Url: https://codereview.chromium.org/2265623002

8 years agoRename circular_arcs_circular_arcs_fill to circular_arcs_fill.
bsalomon [Fri, 19 Aug 2016 20:41:28 +0000 (13:41 -0700)]
Rename circular_arcs_circular_arcs_fill to circular_arcs_fill.

Also fix issue with second paint's alpha getting overwritten.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2265643002

Review-Url: https://codereview.chromium.org/2265643002

8 years agoMove GrFixedClip into src directory
csmartdalton [Fri, 19 Aug 2016 20:29:27 +0000 (13:29 -0700)]
Move GrFixedClip into src directory

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254343003

Review-Url: https://codereview.chromium.org/2254343003

8 years agoAdded a small widget framework to the interactive bevel SampleApp
dvonbeck [Fri, 19 Aug 2016 19:41:48 +0000 (12:41 -0700)]
Added a small widget framework to the interactive bevel SampleApp

I made a small framework to add slider and radial controls more easily.
The Sample now has controls for light direction and color.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259183003

Review-Url: https://codereview.chromium.org/2259183003

8 years agoPlumb drawArc to SkDevice.
bsalomon [Fri, 19 Aug 2016 18:25:19 +0000 (11:25 -0700)]
Plumb drawArc to SkDevice.

Plumbs the drawArc canvas method down to SkDevice without converting to a path. Plumbs through the various recording canvas classes.

BUG=skia:5227
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257023003

Review-Url: https://codereview.chromium.org/2257023003

8 years agoAdded SkColor4f::FromColor3f(SkColor3f, float a)
dvonbeck [Fri, 19 Aug 2016 18:23:15 +0000 (11:23 -0700)]
Added SkColor4f::FromColor3f(SkColor3f, float a)

Planning to use this for the ColorDisplay widget in https://codereview.chromium.org/2259183003/

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2264643002

Review-Url: https://codereview.chromium.org/2264643002

8 years agoAdd GMs for testing drawArc.
bsalomon [Fri, 19 Aug 2016 17:53:13 +0000 (10:53 -0700)]
Add GMs for testing drawArc.

This is in preparation for virtualizing this on SkCanvas/SkDevice.

Tests the following variations:

aa and non-aa
stroke/hairline/fill
cap types
using center point and not

BUG=skia:5227
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2264593002

Review-Url: https://codereview.chromium.org/2264593002

8 years agoFast path translate() in SkCanvas and SkLiteDL.
mtklein [Fri, 19 Aug 2016 16:05:27 +0000 (09:05 -0700)]
Fast path translate() in SkCanvas and SkLiteDL.

This adds didTranslate() so that SkLiteDL (and other canvas recorders)
can record the translate rather than the full concat.

It also adds a case to SkMatrix::preTranslate() to fast path
translate x translate -> translate (i.e. +=).

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255283002

Committed: https://skia.googlesource.com/skia/+/5fa47f4fd13b3158de4599414c86d17649c2dd1c

Misc bots failing in pictureimagefilter replay modes.
https://luci-milo.appspot.com/swarming/task/30b8e53f3a1f4f10/steps/dm/0/stdout

Problem is FMA vs. not.

CQ_INCLUDE_TRYBOTS=master.client.skia:
Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-Fast-Trybot

Review-Url: https://codereview.chromium.org/2255283002

8 years agoImplement gradient simplification for 0,0,1 and 0,1,1 gradients
fmenozzi [Fri, 19 Aug 2016 15:56:56 +0000 (08:56 -0700)]
Implement gradient simplification for 0,0,1 and 0,1,1 gradients

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

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2256843004

Review-Url: https://codereview.chromium.org/2256843004

8 years agoSimplify embeddability test.
bungeman [Fri, 19 Aug 2016 15:45:37 +0000 (08:45 -0700)]
Simplify embeddability test.

There is no reason to read the whole OS/2 table, and no need to spell
out the full names of all the types over and over.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2256783002

Review-Url: https://codereview.chromium.org/2256783002

8 years agoFix bug, always keep fIsScaleTranslate in correct state
msarett [Fri, 19 Aug 2016 15:38:36 +0000 (08:38 -0700)]
Fix bug, always keep fIsScaleTranslate in correct state

BUG:639179
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2263513003

Review-Url: https://codereview.chromium.org/2263513003

8 years agoStep 1 of opts_crc32 rollout.
mtklein [Fri, 19 Aug 2016 15:07:51 +0000 (08:07 -0700)]
Step 1 of opts_crc32 rollout.

  - This adds an crc32_sources variable to opts.gypi and hooks it into
    our GYP build with a dummy source file.

Step 2 will hook crc32_sources into Chrome's GN build.
Step 3 will actually land some code using CRC32 instructions.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259233002

Review-Url: https://codereview.chromium.org/2259233002

8 years agoSome assert fixes for running the Fuzzer sample in GPU mode.
senorblanco [Fri, 19 Aug 2016 15:07:22 +0000 (08:07 -0700)]
Some assert fixes for running the Fuzzer sample in GPU mode.

quadraticPointCount, cubicPointCount: passing NaN to GrNextPow2 causes
it to assert, so detect that and return the max points per curve
instead.

Passing a zero scale to GrStyle::applyToPath() makes it assert, so
draw nothing (likely what drawing with a zero scale is going to do
anyway).

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257423002

Review-Url: https://codereview.chromium.org/2257423002

8 years agoReturn color shader instead of 2-color gradient when color count is 1
fmenozzi [Fri, 19 Aug 2016 14:50:57 +0000 (07:50 -0700)]
Return color shader instead of 2-color gradient when color count is 1

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259823005

Committed: https://skia.googlesource.com/skia/+/da082a5767d7edfd3abe74fc683392422565a606
Review-Url: https://codereview.chromium.org/2259823005

8 years agofix fuzzes
caryclark [Fri, 19 Aug 2016 14:01:33 +0000 (07:01 -0700)]
fix fuzzes

TBR=reed@google.com
BUG=639157, 638783
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255243003

Review-Url: https://codereview.chromium.org/2255243003

8 years agoSkFontMgr_android clean up.
bungeman [Fri, 19 Aug 2016 12:03:26 +0000 (05:03 -0700)]
SkFontMgr_android clean up.

This removes the never used defaultTypeface, uses 'StyleSet' in field
names consistently, fixes potential leaks of names, and moves fields to
sk_sp.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2256253003

Review-Url: https://codereview.chromium.org/2256253003

8 years agoinclude extra_cflags* in the step description
mtklein [Fri, 19 Aug 2016 11:27:34 +0000 (04:27 -0700)]
include extra_cflags* in the step description

This keeps them visible on the bots.
E.g. https://luci-milo.appspot.com/swarming/task/30b9147a09f2ac10/steps/ninja/0/stdout

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254733008

Review-Url: https://codereview.chromium.org/2254733008

8 years agomust call rand in reliable order for bots
reed [Fri, 19 Aug 2016 02:35:52 +0000 (19:35 -0700)]
must call rand in reliable order for bots

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254403002

TBR=

Review-Url: https://codereview.chromium.org/2254403002

8 years agoExpand Issue Tracking docs to include triage, Chrome instructions
hcm [Fri, 19 Aug 2016 01:32:17 +0000 (18:32 -0700)]
Expand Issue Tracking docs to include triage, Chrome instructions

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255133003
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=2255133003

Review-Url: https://codereview.chromium.org/2255133003

8 years agoRevert of Fast path translate() in SkCanvas and SkLiteDL. (patchset #5 id:80001 of...
mtklein [Fri, 19 Aug 2016 00:43:59 +0000 (17:43 -0700)]
Revert of Fast path translate() in SkCanvas and SkLiteDL. (patchset #5 id:80001 of https://codereview.chromium.org/2255283002/ )

Reason for revert:
speculative

Original issue's description:
> Fast path translate() in SkCanvas and SkLiteDL.
>
> This adds didTranslate() so that SkLiteDL (and other canvas recorders)
> can record the translate rather than the full concat.
>
> It also adds a case to SkMatrix::preTranslate() to fast path
> translate x translate -> translate (i.e. +=).
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255283002
>
> Committed: https://skia.googlesource.com/skia/+/5fa47f4fd13b3158de4599414c86d17649c2dd1c

TBR=herb@google.com,reed@google.com,mtklein@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2264433002

8 years agoquick check to not use AutoDrawLooper
reed [Fri, 19 Aug 2016 00:15:25 +0000 (17:15 -0700)]
quick check to not use AutoDrawLooper

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248373004

Review-Url: https://codereview.chromium.org/2248373004

8 years agoRevert of Return color shader instead of 2-color gradient when color count is 1 ...
reed [Thu, 18 Aug 2016 23:13:50 +0000 (16:13 -0700)]
Revert of Return color shader instead of 2-color gradient when color count is 1 (patchset #3 id:40001 of https://codereview.chromium.org/2259823005/ )

Reason for revert:
breaks 2-pt-conical, which can sometimes not draw anything

Original issue's description:
> Return color shader instead of 2-color gradient when color count is 1
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259823005
>
> Committed: https://skia.googlesource.com/skia/+/da082a5767d7edfd3abe74fc683392422565a606

TBR=fmenozzi@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2257993002

8 years agoDetect CRC32 instructions on ARMv8.
mtklein [Thu, 18 Aug 2016 22:59:08 +0000 (15:59 -0700)]
Detect CRC32 instructions on ARMv8.

I have successfully detected CRC32 instruction support on my Nexus 5x.

Use of these instructions to follow... I am not yet sure which compilers if any will give me instrinsics or let me write them in asm.

defined(__ARM_FEATURE_CRC32) should cover users like Android Framework who build with the best settings possible.  cpu-features.h covers use cases like Clank and our bots.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259133002

Review-Url: https://codereview.chromium.org/2259133002

8 years agoBatched implementation of drawLattice() for GPU
msarett [Thu, 18 Aug 2016 22:46:03 +0000 (15:46 -0700)]
Batched implementation of drawLattice() for GPU

Bechmarks (Nexus 6P):

Src=100x100, Dst=250x250, NumRects=9
Android              77.7us
Skia (without patch) 57.2us
Skia (with patch)    30.9us

Src=100x100, Dst=500x500, NumRects=9
Android              77.0us
Skia (without patch) 56.9us
Skia (with patch)    31.8us

Src=100x100, Dst=1000x1000, NumRects=9
Android              180us
Skia (without patch) 96.8us
Skia (with patch)    70.5us

Src=100x100, Dst=250x250, NumRects=15
Android              208us
Skia (without patch) 155us
Skia (with patch)    38.2us

Src=100x100, Dst=500x500, NumRects=15
Android              207us
Skia (without patch) 152us
Skia (with patch)    38.4us

Src=100x100, Dst=1000x1000, NumRects=15
Android              233us
Skia (without patch) 156us
Skia (with patch)    99.9us

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255963002

Committed: https://skia.googlesource.com/skia/+/93242c4ae50dfcc0d922cdb3ba80bbc7b4bbe93d
Review-Url: https://codereview.chromium.org/2255963002

8 years agoFast path translate() in SkCanvas and SkLiteDL.
mtklein [Thu, 18 Aug 2016 22:42:32 +0000 (15:42 -0700)]
Fast path translate() in SkCanvas and SkLiteDL.

This adds didTranslate() so that SkLiteDL (and other canvas recorders)
can record the translate rather than the full concat.

It also adds a case to SkMatrix::preTranslate() to fast path
translate x translate -> translate (i.e. +=).

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255283002

Review-Url: https://codereview.chromium.org/2255283002

8 years agoRelax check for gpu use of static src-over XP
egdaniel [Thu, 18 Aug 2016 22:21:55 +0000 (15:21 -0700)]
Relax check for gpu use of static src-over XP

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259113002

Review-Url: https://codereview.chromium.org/2259113002

8 years agoadd simplerect gm
reed [Thu, 18 Aug 2016 22:01:10 +0000 (15:01 -0700)]
add simplerect gm

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257263002

TBR=bsalomon
NOTRY=True

Review-Url: https://codereview.chromium.org/2257263002

8 years agoReturn color shader instead of 2-color gradient when color count is 1
fmenozzi [Thu, 18 Aug 2016 21:50:56 +0000 (14:50 -0700)]
Return color shader instead of 2-color gradient when color count is 1

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259823005

Review-Url: https://codereview.chromium.org/2259823005

8 years agoUse CSS3 style matching on Android.
bungeman [Thu, 18 Aug 2016 21:36:02 +0000 (14:36 -0700)]
Use CSS3 style matching on Android.

Android framework doesn't really use this, the largest user is Chromium.
At the moment this doesn't resolve oblique requests in a nice way, but
the existing code is somewhat close to CSS3 rules already. Instead of
adding oblique handling manually, just use the existing CSS3 style
matching.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2256843003

Review-Url: https://codereview.chromium.org/2256843003

8 years agoRevert of Batched implementation of drawLattice() for GPU (patchset #7 id:180001...
msarett [Thu, 18 Aug 2016 21:29:22 +0000 (14:29 -0700)]
Revert of Batched implementation of drawLattice() for GPU (patchset #7 id:180001 of https://codereview.chromium.org/2255963002/ )

Reason for revert:
Things drawing weird.

Original issue's description:
> Batched implementation of drawLattice() for GPU
>
> Bechmarks (Nexus 6P):
>
> Src=100x100, Dst=250x250, NumRects=9
> Android              77.7us
> Skia (without patch) 57.2us
> Skia (with patch)    34.7us
>
> Src=100x100, Dst=500x500, NumRects=9
> Android              77.0us
> Skia (without patch) 56.9us
> Skia (with patch)    44.5us
>
> Src=100x100, Dst=1000x1000, NumRects=9
> Android              180us
> Skia (without patch) 96.8us
> Skia (with patch)    70.5us
>
> Src=100x100, Dst=250x250, NumRects=15
> Android              208us
> Skia (without patch) 155us
> Skia (with patch)    55.9us
>
> Src=100x100, Dst=500x500, NumRects=15
> Android              207us
> Skia (without patch) 152us
> Skia (with patch)    63.0us
>
> Src=100x100, Dst=1000x1000, NumRects=15
> Android              233us
> Skia (without patch) 156us
> Skia (with patch)    99.9us
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255963002
>
> Committed: https://skia.googlesource.com/skia/+/93242c4ae50dfcc0d922cdb3ba80bbc7b4bbe93d

TBR=bsalomon@google.com,reed@google.com,djsollen@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2255683004

8 years agoSkPDF: in-place font subsetting
halcanary [Thu, 18 Aug 2016 21:22:52 +0000 (14:22 -0700)]
SkPDF: in-place font subsetting

Motivation: gross code simplification, also no bitset lookups at draw time.

SkPDFFont owns its glyph useage bitset.

SkPDFSubstituteMap goes away.

SkPDFObject interface is simplified.

SkPDFDocument tracks font usage (as hash set), not glyph usage.

SkPDFFont gets a simpler constructor.

SkPDFFont has first and last glyph set in constructor, not adjusted later.

SkPDFFont implementations are simplified.

SkPDFGlyphSet is replaced with simple SkBitSet.

SkPDFFont sizes its SkBitSets based on glyph count.

SkPDFGlyphSetMap goes away.

SkBitSet is now non-copyable.

SkBitSet now how utility methods to match old SkPDFGlyphSet.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253283004

CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Win-MSVC-GCE-CPU-AVX2-x86_64-Release-GDI-Trybot,Test-Win-MSVC-GCE-CPU-AVX2-x86_64-Debug-GDI-Trybot

Review-Url: https://codereview.chromium.org/2253283004

8 years agoFix initialization bug for fConservativeIsScaleTranslate
msarett [Thu, 18 Aug 2016 21:03:30 +0000 (14:03 -0700)]
Fix initialization bug for fConservativeIsScaleTranslate

Also don't mark it as conservative, we expect it to be correct all
the time.

TBR=reed@google.com
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2261573002

Review-Url: https://codereview.chromium.org/2261573002

8 years agoDelay creation of cpu-side buffer memory until actually needed
robertphillips [Thu, 18 Aug 2016 21:01:14 +0000 (14:01 -0700)]
Delay creation of cpu-side buffer memory until actually needed

IIUC what is going on, this won't really do anything bad but will defer allocation of the cpu-side buffer until it is actually needed.

BUG=635015
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248283007

Review-Url: https://codereview.chromium.org/2248283007

8 years agoBatched implementation of drawLattice() for GPU
msarett [Thu, 18 Aug 2016 20:11:48 +0000 (13:11 -0700)]
Batched implementation of drawLattice() for GPU

Bechmarks (Nexus 6P):

Src=100x100, Dst=250x250, NumRects=9
Android              77.7us
Skia (without patch) 57.2us
Skia (with patch)    34.7us

Src=100x100, Dst=500x500, NumRects=9
Android              77.0us
Skia (without patch) 56.9us
Skia (with patch)    44.5us

Src=100x100, Dst=1000x1000, NumRects=9
Android              180us
Skia (without patch) 96.8us
Skia (with patch)    70.5us

Src=100x100, Dst=250x250, NumRects=15
Android              208us
Skia (without patch) 155us
Skia (with patch)    55.9us

Src=100x100, Dst=500x500, NumRects=15
Android              207us
Skia (without patch) 152us
Skia (with patch)    63.0us

Src=100x100, Dst=1000x1000, NumRects=15
Android              233us
Skia (without patch) 156us
Skia (with patch)    99.9us

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255963002

Review-Url: https://codereview.chromium.org/2255963002

8 years agomake LayerIter private, and remove skipClip option
reed [Thu, 18 Aug 2016 19:45:34 +0000 (12:45 -0700)]
make LayerIter private, and remove skipClip option

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257203002

Review-Url: https://codereview.chromium.org/2257203002

8 years agoGN: make libjpeg_turbo target Chrome-compatible
mtklein [Thu, 18 Aug 2016 19:04:13 +0000 (12:04 -0700)]
GN: make libjpeg_turbo target Chrome-compatible

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257903002

Review-Url: https://codereview.chromium.org/2257903002

8 years agoTessellator: better fix for reused-edges issue.
senorblanco [Thu, 18 Aug 2016 17:20:47 +0000 (10:20 -0700)]
Tessellator: better fix for reused-edges issue.

The GrTessellator fix for doubly-added edges in
https://codereview.chromium.org/2259493002/ could leave
a MonotonePoly with zero edges. This is a problem for
Poly::addEdge(), which assumes that MonotonePolys always have
at least one edge. The fix is to move the check and early-out up to
Poly::addEdge(). This should also tighten up the vertex count.

(Unfortunately, the only repro I have for this issue is very
convoluted, and requires non-landed code.)

BUG=skia:5636
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2251643008

Review-Url: https://codereview.chromium.org/2251643008

8 years agoSkPDF: cache metrics once.
halcanary [Thu, 18 Aug 2016 16:52:48 +0000 (09:52 -0700)]
SkPDF:  cache metrics once.

Motivation: drawText can look up unicode mapping at draw time to see
if ActualText should be used after crrev.com/2084533004 lands.

For each SkTypeface, only call getAdvancedTypefaceMetrics() once per
document.  Cache the result in the SkPDFCanon, indexed by SkFontID.
Also cache PDF FontDescriptors in the canon, also indexed by SkFontID
(Type1 fonts only).

Simplify PDF font lookup, map SkFontID+SkGlyphID into a uint64_t.  Map
that uint64_t to SkPDFFonts.  Remove SkPDFCanon::findFont(),
SkPDFCanon::addFont(), SkPDFFont::IsMatch(), and enum SkPDFFont::Match.

SkPDFFont no longer holds on to ref of SkAdvancedTypefaceMetrics.
Instead, SkPDFFont::GetFontResource() and SkPDFFont::getFontSubset()
get metrics from canon.

SkPDFFont multybite bool is now a function of type.

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253993002

CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Win-MSVC-GCE-CPU-AVX2-x86_64-Release-GDI-Trybot,Test-Win-MSVC-GCE-CPU-AVX2-x86_64-Debug-GDI-Trybot

Review-Url: https://codereview.chromium.org/2253993002

8 years agoremove disable aa/dither flags from Props -- never used
reed [Thu, 18 Aug 2016 16:30:44 +0000 (09:30 -0700)]
remove disable aa/dither flags from Props -- never used

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2257643003

TBR=bsalomon

Review-Url: https://codereview.chromium.org/2257643003

8 years agoInteractive Bevel Sample App
dvonbeck [Thu, 18 Aug 2016 15:55:48 +0000 (08:55 -0700)]
Interactive Bevel Sample App

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2246243002

Review-Url: https://codereview.chromium.org/2246243002

8 years agoDon't emit dead code in circle shader when not using distance vectors.
bsalomon [Thu, 18 Aug 2016 15:32:27 +0000 (08:32 -0700)]
Don't emit dead code in circle shader when not using distance vectors.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254103004

Review-Url: https://codereview.chromium.org/2254103004

8 years agoRename WorseCaseSize to WorstCasSize
robertphillips [Thu, 18 Aug 2016 14:11:13 +0000 (07:11 -0700)]
Rename WorseCaseSize to WorstCasSize
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259863002

Review-Url: https://codereview.chromium.org/2259863002

8 years agoAdd alpha type to texture producer
brianosman [Thu, 18 Aug 2016 13:43:03 +0000 (06:43 -0700)]
Add alpha type to texture producer

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250403003

Review-Url: https://codereview.chromium.org/2250403003

8 years agoAdd executable bit and shebang to python files
anmittal [Thu, 18 Aug 2016 11:36:25 +0000 (04:36 -0700)]
Add executable bit and shebang to python files

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253373002

Review-Url: https://codereview.chromium.org/2253373002

8 years agoRevert of Reduce window rectangles cap to 8 (patchset #1 id:1 of https://codereview...
robertphillips [Wed, 17 Aug 2016 23:29:39 +0000 (16:29 -0700)]
Revert of Reduce window rectangles cap to 8 (patchset #1 id:1 of https://codereview.chromium.org/2254013002/ )

Reason for revert:
Breaking Ubuntu

Original issue's description:
> Reduce window rectangles cap to 8
>
> Lowers the cap to 8 and adds a warning message if this value is ever
> exceeded. The largest (only) implementation currently supports 8, so
> there isn't yet reason to go higher.
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254013002
>
> Committed: https://skia.googlesource.com/skia/+/52d721580ee22525c285e2d13cf3975a7a1b2843

TBR=mjk@nvidia.com,bsalomon@google.com,csmartdalton@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review-Url: https://codereview.chromium.org/2253293003

8 years agoRevert of SkPDF: cache metrics once. (patchset #4 id:60001 of https://codereview...
robertphillips [Wed, 17 Aug 2016 23:28:28 +0000 (16:28 -0700)]
Revert of SkPDF:  cache metrics once. (patchset #4 id:60001 of https://codereview.chromium.org/2253993002/ )

Reason for revert:
because

Original issue's description:
> SkPDF:  cache metrics once.
>
> Motivation: drawText can look up unicode mapping at draw time to see
> if ActualText should be used after crrev.com/2084533004 lands.
>
> For each SkTypeface, only call getAdvancedTypefaceMetrics() once per
> document.  Cache the result in the SkPDFCanon, indexed by SkFontID.
> Also cache PDF FontDescriptors in the canon, also indexed by SkFontID
> (Type1 fonts only).
>
> Simplify PDF font lookup, map SkFontID+SkGlyphID into a uint64_t.  Map
> that uint64_t to SkPDFFonts.  Remove SkPDFCanon::findFont(),
> SkPDFCanon::addFont(), SkPDFFont::IsMatch(), and enum SkPDFFont::Match.
>
> SkPDFFont no longer holds on to ref of SkAdvancedTypefaceMetrics.
> Instead, SkPDFFont::GetFontResource() and SkPDFFont::getFontSubset()
> get metrics from canon.
>
> SkPDFFont multybite bool is now a function of type.
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253993002
>
> Committed: https://skia.googlesource.com/skia/+/0a61270f4ba85d10659fb63a86817b435ec04c94

TBR=bungeman@google.com,halcanary@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review-Url: https://codereview.chromium.org/2251813006

8 years ago[SVGDom] Fix <ellipse> positioning
fmalita [Wed, 17 Aug 2016 22:08:48 +0000 (15:08 -0700)]
[SVGDom] Fix <ellipse> positioning

R=robertphillips@google.com,stephana@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253283002

Review-Url: https://codereview.chromium.org/2253283002

8 years agoFix assert caused by floating point error in tessellating path renderer.
senorblanco [Wed, 17 Aug 2016 21:56:22 +0000 (14:56 -0700)]
Fix assert caused by floating point error in tessellating path renderer.

In rare cases, floating point error causes the tesselator to add the
same Vertex to more than one Poly on the same side. This was not a big
problem when we were allocating new vertices when constructing Polys,
but after https://codereview.chromium.org/2029243002 it causes more serious
issues, since each Edge can only belong to two Polys, and violating this
condition messes up the linked list of Edges used for left & right Polys
and the associated estimated vertex count.

The fix is to simply let the first Poly win, and skip that vertex for
subsequent Polys. Since this only occurs in cases where vertices are very
close to each other, it should have little visual effect.

This is also exercised by Nebraska-StateSeal.svg.

BUG=skia:5636
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259493002

Review-Url: https://codereview.chromium.org/2259493002

8 years ago[SVGDom] Add support for assorted absolute units
fmalita [Wed, 17 Aug 2016 21:51:03 +0000 (14:51 -0700)]
[SVGDom] Add support for assorted absolute units

R=robertphillips@google.com,stephana@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2259473002

Review-Url: https://codereview.chromium.org/2259473002

8 years agoSkPDF: cache metrics once.
halcanary [Wed, 17 Aug 2016 21:21:42 +0000 (14:21 -0700)]
SkPDF:  cache metrics once.

Motivation: drawText can look up unicode mapping at draw time to see
if ActualText should be used after crrev.com/2084533004 lands.

For each SkTypeface, only call getAdvancedTypefaceMetrics() once per
document.  Cache the result in the SkPDFCanon, indexed by SkFontID.
Also cache PDF FontDescriptors in the canon, also indexed by SkFontID
(Type1 fonts only).

Simplify PDF font lookup, map SkFontID+SkGlyphID into a uint64_t.  Map
that uint64_t to SkPDFFonts.  Remove SkPDFCanon::findFont(),
SkPDFCanon::addFont(), SkPDFFont::IsMatch(), and enum SkPDFFont::Match.

SkPDFFont no longer holds on to ref of SkAdvancedTypefaceMetrics.
Instead, SkPDFFont::GetFontResource() and SkPDFFont::getFontSubset()
get metrics from canon.

SkPDFFont multybite bool is now a function of type.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253993002

Review-Url: https://codereview.chromium.org/2253993002

8 years agoAdd alphaType() to SkImage
brianosman [Wed, 17 Aug 2016 21:01:05 +0000 (14:01 -0700)]
Add alphaType() to SkImage

Keep isOpaque as a convenience method -- many places really only need to
know that for optimization purposes (SrcOver -> Src, etc...).

In all the places where we pull data back out or convert to another
object and need to supply an SkImageInfo, we can avoid losing information
about premulness.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250663002

Review-Url: https://codereview.chromium.org/2250663002

8 years agoFix BUILD.gn for arch other then x86 and x64
anmittal [Wed, 17 Aug 2016 20:57:26 +0000 (13:57 -0700)]
Fix BUILD.gn for arch other then x86 and x64

opts_gypi should only be defined for x86 and x64 else we get unused
variable error

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248323002

Review-Url: https://codereview.chromium.org/2248323002

8 years agoFix computation of clipped src rect when tiling bitmaps in SkGpuDevice
bsalomon [Wed, 17 Aug 2016 20:56:57 +0000 (13:56 -0700)]
Fix computation of clipped src rect when tiling bitmaps in SkGpuDevice
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2252913004

Review-Url: https://codereview.chromium.org/2252913004

8 years agoReduce window rectangles cap to 8
csmartdalton [Wed, 17 Aug 2016 20:52:15 +0000 (13:52 -0700)]
Reduce window rectangles cap to 8

Lowers the cap to 8 and adds a warning message if this value is ever
exceeded. The largest (only) implementation currently supports 8, so
there isn't yet reason to go higher.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254013002

Review-Url: https://codereview.chromium.org/2254013002

8 years agoEagerly update the unichar to glyphID mapping.
herb [Wed, 17 Aug 2016 20:51:54 +0000 (13:51 -0700)]
Eagerly update the unichar to glyphID mapping.

In addition, some small cleanups.

BUG=chromium:635005
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2249063005

Review-Url: https://codereview.chromium.org/2249063005

8 years agofix no-gpu build
reed [Wed, 17 Aug 2016 20:24:05 +0000 (13:24 -0700)]
fix no-gpu build

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253073003

TBR=robertphilips
NOTREECHECKS=true

Review-Url: https://codereview.chromium.org/2253073003

8 years agoFix fb variable name in GLSL
egdaniel [Wed, 17 Aug 2016 19:55:30 +0000 (12:55 -0700)]
Fix fb variable name in GLSL

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2252143002

NOTREECHECKS=True

Review-Url: https://codereview.chromium.org/2252143002

8 years agoSkLiteDL: a little spring cleaning
mtklein [Wed, 17 Aug 2016 18:39:48 +0000 (11:39 -0700)]
SkLiteDL: a little spring cleaning

  - kill off optimizeFor() now that we know it's broken and have a better way;
  - simplify makeThreadsafe() a bit: we're not calling it anyway.

This sort of earns me back some crazy code currency,
which I am going to try to spend making reset() faster.

If anything, this appears to make makeThreadsafe() _faster_.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254913002

Review-Url: https://codereview.chromium.org/2254913002

8 years agoSimplify adding attributes to GrGeometryProcessor
bsalomon [Wed, 17 Aug 2016 18:33:39 +0000 (11:33 -0700)]
Simplify adding attributes to GrGeometryProcessor
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248323003

Review-Url: https://codereview.chromium.org/2248323003

8 years agoFix SampleAndroidShadows warnings
fmalita [Wed, 17 Aug 2016 18:33:29 +0000 (11:33 -0700)]
Fix SampleAndroidShadows warnings

R=jvanverth@google.com,robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2255863002
NOTRY=true

Review-Url: https://codereview.chromium.org/2255863002

8 years agopin as texture api
reed [Wed, 17 Aug 2016 18:12:33 +0000 (11:12 -0700)]
pin as texture api

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2241353002

Review-Url: https://codereview.chromium.org/2241353002

8 years agoMove FamilyClass and Panose enums to enum class.
bungeman [Wed, 17 Aug 2016 17:59:30 +0000 (10:59 -0700)]
Move FamilyClass and Panose enums to enum class.

The IBMFamilyClass and Panose structures are obvious candidates
for simplification now that it is no longer necessary to nest
enums inside structs to avoid name clashes.

Review-Url: https://codereview.chromium.org/2253543004

8 years agoFix various issues with framebuffer fetch
egdaniel [Wed, 17 Aug 2016 17:59:00 +0000 (10:59 -0700)]
Fix various issues with framebuffer fetch

This CL does two things. First it fixes a bug of ours where when using
a custom fbFetch variable (es 3.0 and higher), we sometimes overwrite
the out color and then attempt to use it as the dst color later. This is
fixed here by using an intermediate variable.

Secondly I've added a workaround to an andreno fbFetch where reading from
the outColor always returns the original dstColor even if we've overwritten
the value.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248403003

Review-Url: https://codereview.chromium.org/2248403003

8 years agoDetemplatize GrGLSLGeometryProcessor::setTransformDataHelper()
bsalomon [Wed, 17 Aug 2016 17:30:17 +0000 (10:30 -0700)]
Detemplatize GrGLSLGeometryProcessor::setTransformDataHelper()

Instead take a local matrix parameter.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250563004

Review-Url: https://codereview.chromium.org/2250563004

8 years agoSkLiteDL: inline empty()
mtklein [Wed, 17 Aug 2016 17:20:27 +0000 (10:20 -0700)]
SkLiteDL: inline empty()

1.85%     1.85%  RenderThread     6458  6475  /system/lib64/libskia.so  SkLiteDL::empty() const

:/

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2254823002

Review-Url: https://codereview.chromium.org/2254823002

8 years agoAdd alternative spot shadow to Android shadow sample
jvanverth [Wed, 17 Aug 2016 17:06:18 +0000 (10:06 -0700)]
Add alternative spot shadow to Android shadow sample

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2246273003

Review-Url: https://codereview.chromium.org/2256713002

8 years agoImplement difference clip rects with window rectangles
csmartdalton [Wed, 17 Aug 2016 17:00:21 +0000 (10:00 -0700)]
Implement difference clip rects with window rectangles

Plumbs the pipeline for window rectangles and uses them for a very
basic implementation of difference clip rects. This puts a common
Blink pattern on fast path, but we will still eventually need to make
more comprehensive use of window rectangles during clipping.

GTX 960 perf result:
                              gpu                     glinst4                 glinst16
desk_jsfiddlebigcar.skp       0.254 -> 0.177 [70%]    0.279 -> 0.197 [71%]    0.577 -> 0.196 [34%]
keymobi_sfgate_com_.skp       0.697 -> 0.513 [74%]    0.766 -> 0.451 [59%]    0.769 -> 0.597 [78%]
keymobi_blogger.skp           0.406 -> 0.314 [77%]    0.436 -> 0.292 [67%]    0.696 -> 0.319 [46%]
desk_pokemonwiki.skp          0.121 -> 0.098 [81%]     0.13 -> 0.105 [81%]    0.216 -> 0.097 [45%]
desk_wikipedia.skp            0.121 -> 0.098 [81%]     0.13 -> 0.104 [80%]    0.199 -> 0.104 [52%]
keymobi_androidpolice_co...   0.443 -> 0.382 [86%]    0.447 -> 0.398 [89%]    0.444 -> 0.396 [89%]
keymobi_booking_com_sear...   1 .15 ->  1.03 [90%]     1.17 ->  1.06 [91%]     1.17 ->  1.05 [90%]
keymobi_theverge_com.skp      0.417 -> 0.396 [95%]    0.426 -> 0.405 [95%]    0.429 ->   0.4 [93%]

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2251573002

Review-Url: https://codereview.chromium.org/2251573002

8 years agoMake GrReducedClip's gen ID only apply to the element list
csmartdalton [Wed, 17 Aug 2016 16:39:38 +0000 (09:39 -0700)]
Make GrReducedClip's gen ID only apply to the element list

Renames fGenID to fElementsGenID and designates this value as
undefined when when the element list is empty.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2244223004

Review-Url: https://codereview.chromium.org/2244223004

8 years agoKick the can down the road a bit w.r.t. fuzzer complaint
robertphillips [Wed, 17 Aug 2016 16:28:59 +0000 (09:28 -0700)]
Kick the can down the road a bit w.r.t. fuzzer complaint

BUG=635787
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2247033006

Review-Url: https://codereview.chromium.org/2247033006

8 years agoFix tile bitmap code in SkGpuDevice to compute correct local coords.
bsalomon [Wed, 17 Aug 2016 16:02:09 +0000 (09:02 -0700)]
Fix tile bitmap code in SkGpuDevice to compute correct local coords.

This fixes a bug when using an alpha bitmap/image with a SkShader where the SkShader's GrFragmentProcessor would receive incorrect coordinates.

BUG=skia:5643

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2249163004

Review-Url: https://codereview.chromium.org/2249163004

8 years agoMinor cleanup of GP classes in GrOvalRenderer
bsalomon [Wed, 17 Aug 2016 16:00:24 +0000 (09:00 -0700)]
Minor cleanup of GP classes in GrOvalRenderer

Move GLSL nested classes to private and remove unnecessary public getters.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2253903002

Review-Url: https://codereview.chromium.org/2253903002

8 years agoModify SkPngCodec to recognize 565 images from the sBIT chunk
msarett [Wed, 17 Aug 2016 15:54:08 +0000 (08:54 -0700)]
Modify SkPngCodec to recognize 565 images from the sBIT chunk

Conveniently, SkPngImageEncoder already writes the sBIT chunk
appropriately.

BUG=skia:5616
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2212563003

Review-Url: https://codereview.chromium.org/2212563003

8 years ago[SVGDom] Add <line> support
fmalita [Wed, 17 Aug 2016 15:38:15 +0000 (08:38 -0700)]
[SVGDom] Add <line> support

R=robertphillips@google.com,stephana@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2244223005

Review-Url: https://codereview.chromium.org/2244223005

8 years agoCast for fuzzer complaint
robertphillips [Wed, 17 Aug 2016 15:02:51 +0000 (08:02 -0700)]
Cast for fuzzer complaint

Given the cast in the following else block, this isn't the first time we've encountered this.

BUG=637187
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2258463002

Review-Url: https://codereview.chromium.org/2258463002

8 years agoAdd alternative ambient shadow method to Android shadow sample
jvanverth [Wed, 17 Aug 2016 14:59:41 +0000 (07:59 -0700)]
Add alternative ambient shadow method to Android shadow sample

TBR=bsalomon@google.com
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2249973003

Review-Url: https://codereview.chromium.org/2249973003

8 years agoSkPDF: pull out SkPDFMakeCIDGlyphWidthsArray.cpp
halcanary [Wed, 17 Aug 2016 14:57:27 +0000 (07:57 -0700)]
SkPDF: pull out SkPDFMakeCIDGlyphWidthsArray.cpp

Extract from inside SkPDFFont.cpp
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2251803002

Review-Url: https://codereview.chromium.org/2251803002

8 years agoAdd gerrit config lines to cq.cfg
rmistry [Wed, 17 Aug 2016 14:51:57 +0000 (07:51 -0700)]
Add gerrit config lines to cq.cfg

Needed for the CQ to see Gerrit. Eg:
https://cs.chromium.org/chromium/tools/depot_tools/infra/config/cq.cfg?q=cq.cfg&sq=package:chromium&dr=C&l=9

BUG=skia:5627
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2251643005

Review-Url: https://codereview.chromium.org/2251643005

8 years agomove private test for sect_with_horizontal into unittests
reed [Wed, 17 Aug 2016 14:37:57 +0000 (07:37 -0700)]
move private test for sect_with_horizontal into unittests

BUG=638575
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250353004

Review-Url: https://codereview.chromium.org/2250353004

8 years agoAdd mssa configs for vulkan, and simple bug fix
egdaniel [Wed, 17 Aug 2016 13:26:16 +0000 (06:26 -0700)]
Add mssa configs for vulkan, and simple bug fix

BUG=skia:5127
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2251473002

Review-Url: https://codereview.chromium.org/2251473002

8 years agofix fuzz
caryclark [Wed, 17 Aug 2016 13:14:06 +0000 (06:14 -0700)]
fix fuzz

TBR=reed@google.com
BUG=638496
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250413002

Review-Url: https://codereview.chromium.org/2250413002

8 years agoGN: make current_cpu work
mtklein [Wed, 17 Aug 2016 01:28:43 +0000 (18:28 -0700)]
GN: make current_cpu work

Then we can use it to remind ourselves that SSE and AVX are x86-only.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2247413003

Review-Url: https://codereview.chromium.org/2247413003

8 years agoSkLiteDL: thread the original canvas matrix through for SetMatrix::Draw().
mtklein [Wed, 17 Aug 2016 00:18:27 +0000 (17:18 -0700)]
SkLiteDL: thread the original canvas matrix through for SetMatrix::Draw().

The SkLiteDL is recorded in some identity space (imagine, SkMatrix::I()),
but played back in a different one (here named SkMatrix original).  Any
calls to setMatrix() need to be made relative to this new space.

All other ops already operate in relative coordinates.

This should let us not fiddle with setMatrix().

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2247353003

Review-Url: https://codereview.chromium.org/2247353003

8 years agoRevert of Start using vertex attributes for nine-patch blurred rrect draws (patchset...
robertphillips [Tue, 16 Aug 2016 22:49:20 +0000 (15:49 -0700)]
Revert of Start using vertex attributes for nine-patch blurred rrect draws (patchset #8 id:140001 of https://codereview.chromium.org/2245653002/ )

Reason for revert:
??

Original issue's description:
> Start using vertex attributes for nine-patch blurred rrect draws
>
> Calved off:
> https://codereview.chromium.org/2243133002/ (Pull handling of blurred circles out of GrRRectBlurEffect::Make)
> https://codereview.chromium.org/2249463002/ (Update blurred rrect mask filter creation method to also handle caching)
> https://codereview.chromium.org/2248533002/ (Update ComputeBlurredRRectParams to compute all the parameters needed for occluded blurred rrect ninepatch draws)
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2245653002
>
> Committed: https://skia.googlesource.com/skia/+/087905a730241939da320092543c19dc06d5a7b4

TBR=bsalomon@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review-Url: https://codereview.chromium.org/2250543004

8 years ago[SVGDom] Add <circle>, <ellipse> support
fmalita [Tue, 16 Aug 2016 22:38:51 +0000 (15:38 -0700)]
[SVGDom] Add <circle>, <ellipse> support

R=robertphillips@google.com,stephana@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2249033003

Review-Url: https://codereview.chromium.org/2249033003

8 years agoAdd test for platform encoders, turn off platform encoders by default
msarett [Tue, 16 Aug 2016 22:11:24 +0000 (15:11 -0700)]
Add test for platform encoders, turn off platform encoders by default

Clients that like WIC and CG can still use them.  And we can be
confident about that, since we now test WIC and CG.

Let Skia always use our own encoders by default, so we can do cool,
custom things on all platforms.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250683003

Review-Url: https://codereview.chromium.org/2250683003

8 years agoFix bug in cubic derivative coefficient with missing parens
hstern [Tue, 16 Aug 2016 22:10:34 +0000 (15:10 -0700)]
Fix bug in cubic derivative coefficient with missing parens

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2242603002

Review-Url: https://codereview.chromium.org/2242603002

8 years agoStart using vertex attributes for nine-patch blurred rrect draws
robertphillips [Tue, 16 Aug 2016 21:50:18 +0000 (14:50 -0700)]
Start using vertex attributes for nine-patch blurred rrect draws

Calved off:
https://codereview.chromium.org/2243133002/ (Pull handling of blurred circles out of GrRRectBlurEffect::Make)
https://codereview.chromium.org/2249463002/ (Update blurred rrect mask filter creation method to also handle caching)
https://codereview.chromium.org/2248533002/ (Update ComputeBlurredRRectParams to compute all the parameters needed for occluded blurred rrect ninepatch draws)

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2245653002

Review-Url: https://codereview.chromium.org/2245653002

8 years agoOnly test SVG DM sources against direct raster/gpu sinks.
fmalita [Tue, 16 Aug 2016 21:23:29 +0000 (14:23 -0700)]
Only test SVG DM sources against direct raster/gpu sinks.

There isn't much value in testing against indirect or vector sinks.

R=mtklein@google.com,robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2252443002

Review-Url: https://codereview.chromium.org/2252443002

8 years agoRemove SkPreprocessorSeq.h and SkTypedEnum.h.
bungeman [Tue, 16 Aug 2016 19:27:49 +0000 (12:27 -0700)]
Remove SkPreprocessorSeq.h and SkTypedEnum.h.

These were added to allow the use of typed enums before typed enums were
available on all platforms. Now that typed enums are available, just use
them directly.

Review-Url: https://codereview.chromium.org/2254513002

8 years agoSkPDF: Font names need escaping
halcanary [Tue, 16 Aug 2016 18:54:57 +0000 (11:54 -0700)]
SkPDF: Font names need escaping

NOTRY=true

Review-Url: https://codereview.chromium.org/2250763002

8 years agoSkPDF: eliminate SkPDFCIDfont class
halcanary [Tue, 16 Aug 2016 17:29:38 +0000 (10:29 -0700)]
SkPDF: eliminate SkPDFCIDfont class

get_glyph_widths() and set_glyph_widths() combined.

set_glyph_widths() now takes a SkPDFGlyphSet*.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2244173005

Review-Url: https://codereview.chromium.org/2244173005

8 years agofix fuzz bug
caryclark [Tue, 16 Aug 2016 17:25:29 +0000 (10:25 -0700)]
fix fuzz bug

TBR=reed@google.com
BUG=637968, 638002
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2250573003

Review-Url: https://codereview.chromium.org/2250573003