platform/upstream/libSkiaSharp.git
8 years agochange SkStreams to work with sk_sp<SkData> instead of SkData*
reed [Mon, 12 Sep 2016 19:01:44 +0000 (12:01 -0700)]
change SkStreams to work with sk_sp<SkData> instead of SkData*

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

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

8 years agoFix device cfg for GalaxyS7
borenet [Mon, 12 Sep 2016 18:56:37 +0000 (11:56 -0700)]
Fix device cfg for GalaxyS7

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

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

8 years agoDocumentation: MSKP
halcanary [Mon, 12 Sep 2016 18:56:28 +0000 (11:56 -0700)]
Documentation: MSKP

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

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

8 years agoAdd workaround for Adreno copyImageToBuffer calls on Vulkan
egdaniel [Mon, 12 Sep 2016 18:51:29 +0000 (11:51 -0700)]
Add workaround for Adreno copyImageToBuffer calls on Vulkan

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

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

8 years agoRun recipes.py with --timestamps
borenet [Mon, 12 Sep 2016 18:51:26 +0000 (11:51 -0700)]
Run recipes.py with --timestamps

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

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

8 years agoFix GaussianEdgeShader GLSL code
jvanverth [Mon, 12 Sep 2016 17:09:16 +0000 (10:09 -0700)]
Fix GaussianEdgeShader GLSL code

Implicit conversion of int constants to float is not always
guaranteed

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2328263004
TBR=herbderby@google.com
NOTRY=true
NOTREECHECKS=true

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

8 years agoRemove unneeded GrGLSLTransformedCoordsArray type
bsalomon [Mon, 12 Sep 2016 16:30:36 +0000 (09:30 -0700)]
Remove unneeded GrGLSLTransformedCoordsArray type

Rename GrGLSLFragmentBuilder::ensureFSCoords2D to ensureCoords2D and make it take an arbitrary GrShaderVar.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2324663004

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

8 years agoRevert of Turned on SkSL->GLSL compiler (patchset #12 id:220001 of https://codereview...
ethannicholas [Mon, 12 Sep 2016 16:15:53 +0000 (09:15 -0700)]
Revert of Turned on SkSL->GLSL compiler (patchset #12 id:220001 of https://codereview.chromium.org/2288033003/ )

Reason for revert:
Compilation errors on some bots.

Original issue's description:
> Turned on SkSL->GLSL compiler
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2288033003
>
> Committed: https://skia.googlesource.com/skia/+/9b0fe3d125f237d9884732a48414fa85fc71b4e3

TBR=benjaminwagner@google.com,bsalomon@google.com,egdaniel@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/2337553002

8 years agoRemove unneeded bounds outset in GrDrawContext::drawVertices.
bsalomon [Mon, 12 Sep 2016 16:05:48 +0000 (09:05 -0700)]
Remove unneeded bounds outset in GrDrawContext::drawVertices.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2329403004

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

8 years agoglTexStorage requires sized formats, ensure that we're following that rule
brianosman [Mon, 12 Sep 2016 16:05:14 +0000 (09:05 -0700)]
glTexStorage requires sized formats, ensure that we're following that rule

In some situations (at least ANGLE ES3), we were passing GL_BGRA, rather
than GL_BGRA8.

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

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

8 years agoRemove ability to skip coord transform comparison in pipeline comparison.
bsalomon [Mon, 12 Sep 2016 15:55:38 +0000 (08:55 -0700)]
Remove ability to skip coord transform comparison in pipeline comparison.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2316413003

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

8 years agoSkPDF: refactor & code cleanup ahead of https://crrev.com/2322403002
halcanary [Mon, 12 Sep 2016 15:55:29 +0000 (08:55 -0700)]
SkPDF: refactor & code cleanup ahead of https://crrev.com/2322403002

SkPDFDevice::GraphicStateEntry: remove unnecessary fFont and
fTextSize.

SkPDFDevice::updateFont(): replace with update_font() and inlined
code.  De-duplicate this block of code.

SkPDFResourceDict::GetResourceTypePrefix function made public: removes
need for temporary SkString returned by
SkPDFResourceDict::getResourceName()

GlyphPositioner: delay writing intial matrix until first glyph.
Assert that widechars is a constant.

SkPDFFont::FontType(): make public so that PDFDevice can know about
multibyte status.

SkPDFFont::countStretch() removed, and the stretch loop flattened.

*no changes in PDF output*

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

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

8 years agoTwo changes:
brianosman [Mon, 12 Sep 2016 15:50:19 +0000 (08:50 -0700)]
Two changes:

1. Remove special premul handling from gamut xform code

Alpha is a constant, so the gamut transformation results remain unchanged
(it distributes across the linear matrix multiply).

2. Use SkMatrix44 rather than array of floats

Preserves semantic intention, and makes upcoming code (where we transform
colors on the CPU by that matrix) simpler.

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

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

8 years agoTurned on SkSL->GLSL compiler
ethannicholas [Mon, 12 Sep 2016 15:50:13 +0000 (08:50 -0700)]
Turned on SkSL->GLSL compiler
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2288033003

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

8 years agoUpdate SampleAndroidShadows to use algorithm closer to Android OpenGL
jvanverth [Mon, 12 Sep 2016 14:51:04 +0000 (07:51 -0700)]
Update SampleAndroidShadows to use algorithm closer to Android OpenGL

Includes:
* Update light position to be at a similar distance to Android OS
* Scale spot shadows correctly
* Compute stroke shapes and radii correctly
* Allow for larger blur radius for shadows

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2319003003
TBR=reed@google.com
NOTRY=true
NOTREECHECKS=true

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

8 years agohelper to SkRect to create from SkISize
reed [Mon, 12 Sep 2016 13:32:07 +0000 (06:32 -0700)]
helper to SkRect to create from SkISize

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

TBR=
NOTREECHECKS=True
NOTRY=True

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

8 years agocheck for identity in translate
reed [Mon, 12 Sep 2016 13:31:48 +0000 (06:31 -0700)]
check for identity in translate

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

TBR=
NOTREECHECKS=True
NOTRY=True

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

8 years agofix code behind SK_SUPPORT_LEGACY_MINOR_EFFECT_PTR
reed [Mon, 12 Sep 2016 13:31:05 +0000 (06:31 -0700)]
fix code behind SK_SUPPORT_LEGACY_MINOR_EFFECT_PTR

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

TBR=
NOTREECHECKS=True
NOTRY=True

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

8 years agouse expected name for setDrawLooper/getDrawLooper
reed [Sun, 11 Sep 2016 12:40:31 +0000 (05:40 -0700)]
use expected name for setDrawLooper/getDrawLooper

Needed for future pipe cl.
Next cl should be to guard the looper entirely (since its deprecated)

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

TBR=

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

8 years agoUpdate SKP version
update-skps [Sun, 11 Sep 2016 09:21:46 +0000 (02:21 -0700)]
Update SKP version

Automatic commit by the RecreateSKPs bot.

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

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

8 years agoSkPDF: SkShaper_primitive uses new textblob API
halcanary [Sat, 10 Sep 2016 14:01:53 +0000 (07:01 -0700)]
SkPDF: SkShaper_primitive uses new textblob API

This will enable me to test the new API in unit tests without
depending on HarfBuzz (after https://crrev.com/2322403002 lands).

TBR=
BUG=skia:5434

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

8 years agoAdds missing and removes duplicate tracing macros.
carlosk [Fri, 9 Sep 2016 23:15:19 +0000 (16:15 -0700)]
Adds missing and removes duplicate tracing macros.

This fixes the missing tracing nested instant call without any arguments and
removes the duplicate of the one with 2 arguments.

This is a follow up on https://crrev.com/2326483004

BUG=645308
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2321283002
NOPRESUBMIT=true
CQ_EXCLUDE_TRYBOTS=client.skia.fyi:skia_presubmit-Trybot

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

8 years agomade point lights linear attenuation; also fixed point light depth bug
vjiaoblack [Fri, 9 Sep 2016 18:58:19 +0000 (11:58 -0700)]
made point lights linear attenuation; also fixed point light depth bug

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

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

8 years agoSkPDF/Tests: imporve test coverage.
halcanary [Fri, 9 Sep 2016 18:41:59 +0000 (11:41 -0700)]
SkPDF/Tests: imporve test coverage.

Also: make sure that all SkPDF unit tests are named SkPDF_* to
make testing changes to SkPDF easier.  Other cleanup.

Add test: SkPDF_pdfa_document to verify that flag in public API
works.

SkPDF_JpegIdentification test: test slightly malformed JPEGs to
verify that all code paths work.

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

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

8 years agoFix color gamut xform matrices in GPU code
brianosman [Fri, 9 Sep 2016 18:30:55 +0000 (11:30 -0700)]
Fix color gamut xform matrices in GPU code

Now that we're not storing them transposed, we can plumb them to the
shader column-major all the way, and then multiply colors on the right, as
it should be.

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

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

8 years agoGN: port a few missing Android bits from GYP.
mtklein [Fri, 9 Sep 2016 18:07:45 +0000 (11:07 -0700)]
GN: port a few missing Android bits from GYP.

The SK_GAMMA_ defines change text rendering on Android.
This is how they're set in GYP for Android... everyone else is default (sRGB).

Linking AndroidSkDebugToStdOut.o causes SkDebugf to go to both logcat and
stdout on Android.  Without it, it only goes to logcat.  The file has no effect
on non-Android platforms.

BUG=skia:

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

8 years agoFix storage of gamut transform matrices in SkColorSpace
brianosman [Fri, 9 Sep 2016 17:36:17 +0000 (10:36 -0700)]
Fix storage of gamut transform matrices in SkColorSpace

We were effectively storing the transpose, which made all of our
operations on individual colors, and our concatenation of matrices
awkward and backwards.

I'm planning to push this further into Ganesh, where I had incorrectly
adjusted to the previous layout, treating colors as row vectors in the
shaders.

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

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

8 years agoSkip adding coincident edges found
caryclark [Fri, 9 Sep 2016 16:37:57 +0000 (09:37 -0700)]
Skip adding coincident edges found
during curve intersection if their
ends are nearly the same.

Loosen conic/line intersection point
check.

Detect when coincident points are
unordered. This means that points
a/b/c on one curve may appear in
b/c/a order on the opposite curve.

Restructure addMissing to return
success and return if a coincidence
was added as a parameter.

With this, tiger part a works.
Tiger part b exposes bugs around
tight quads that are nearly coincident
with themselves, and are coincident
with something else.

The greedy coicident matcher
may cause the point order to be
out of sync.

Still working out what to do in
this case.

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

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

8 years agoAdded in Radial Shadows
vjiaoblack [Fri, 9 Sep 2016 16:22:39 +0000 (09:22 -0700)]
Added in Radial Shadows

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

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

8 years agoDelete some LUTs from SkColorSpaceXform
msarett [Fri, 9 Sep 2016 14:48:05 +0000 (07:48 -0700)]
Delete some LUTs from SkColorSpaceXform

No need to keep these around.  In the rare case that these are
needed, we can just go ahead and build them.

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

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

8 years agofix fuzzer
caryclark [Fri, 9 Sep 2016 14:41:36 +0000 (07:41 -0700)]
fix fuzzer

Earlier fix aborted coincident loop on wrong condition.
This aborts only when it reaches the end, and then
propagates the error out correctly.

TBR=reed@google.com
BUG=644680, 644684
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2327053002

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

8 years agoFix issues in assets scripts
borenet [Fri, 9 Sep 2016 12:37:29 +0000 (05:37 -0700)]
Fix issues in assets scripts

- Delete unconditionally uses 'gsutil'
- args.gsutil not plumbed properly

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

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

8 years agoSkPDF: implement drawTextBlob()
halcanary [Fri, 9 Sep 2016 12:34:55 +0000 (05:34 -0700)]
SkPDF: implement drawTextBlob()

Pass new fields from https://skia.googlesource.com/skia/+/4f0a23a into
SkPDFDevice::internalDrawText() (a later CL will use
them for /ActualText.

No change in PDF output.

BUG=skia:5434

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

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

8 years agoSkPDF: hand SfntlyWrapper::SubsetFont() ttcIndex, not fontName.
halcanary [Thu, 8 Sep 2016 22:04:38 +0000 (15:04 -0700)]
SkPDF: hand SfntlyWrapper::SubsetFont() ttcIndex, not fontName.

Also, minor code refactoring.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2258233002

Committed: https://skia.googlesource.com/skia/+/fce190647285423bf36c44bca09db78a6af30f9f
Review-Url: https://codereview.chromium.org/2258233002

8 years agoFix strange failures on Android N
kjlubick [Thu, 8 Sep 2016 20:04:30 +0000 (13:04 -0700)]
Fix strange failures on Android N

We were seeing problems where dm ended with exit code 0, but the step still failed.
It seems they changed what N returns when a thing completes.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2319843003
TBR=bugsbunny

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

8 years agoBenchmarks for testing changes to GrResourceCache replacement policy when over budget.
bsalomon [Thu, 8 Sep 2016 19:35:32 +0000 (12:35 -0700)]
Benchmarks for testing changes to GrResourceCache replacement policy when over budget.

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

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

8 years agoChecking for valid colorType, alphaType, colorSpace in SkCodec
msarett [Thu, 8 Sep 2016 18:55:16 +0000 (11:55 -0700)]
Checking for valid colorType, alphaType, colorSpace in SkCodec

* Refactor to share code between SkPngCodec and SkWebpCodec
* Didn't end up sharing with SkJpegCodec but did refactor
  that code a bit
* Disallow conversions to F16 with non-linear color spaces
* Fail to decode if we fail to create a SkColorSpaceXform
  (should be an assert soon).  We used to fallback on a
  legacy decode if we failed to create the transform.
* A bunch of name changes

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

Committed: https://skia.googlesource.com/skia/+/7a9900d6d34e437bb24beb5524a1f6488ae138c9
Review-Url: https://codereview.chromium.org/2319293003

8 years agoMove prepareForExternalIO implementation from GrContext to GrDrawingManager
bsalomon [Thu, 8 Sep 2016 18:28:59 +0000 (11:28 -0700)]
Move prepareForExternalIO implementation from GrContext to GrDrawingManager
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2324473002

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

8 years agoApple devices do not support CRC32 instructions. Don't believe Clang's lies.
mtklein [Thu, 8 Sep 2016 18:22:09 +0000 (11:22 -0700)]
Apple devices do not support CRC32 instructions.  Don't believe Clang's lies.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2322033002
CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot

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

8 years agoRevert of Checking for valid colorType, alphaType, colorSpace in SkCodec (patchset...
msarett [Thu, 8 Sep 2016 17:54:34 +0000 (10:54 -0700)]
Revert of Checking for valid colorType, alphaType, colorSpace in SkCodec (patchset #2 id:100001 of https://codereview.chromium.org/2319293003/ )

Reason for revert:
Broken perf bots

Original issue's description:
> Checking for valid colorType, alphaType, colorSpace in SkCodec
>
> * Refactor to share code between SkPngCodec and SkWebpCodec
> * Didn't end up sharing with SkJpegCodec but did refactor
>   that code a bit
> * Disallow conversions to F16 with non-linear color spaces
> * Fail to decode if we fail to create a SkColorSpaceXform
>   (should be an assert soon).  We used to fallback on a
>   legacy decode if we failed to create the transform.
> * A bunch of name changes
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2319293003
>
> Committed: https://skia.googlesource.com/skia/+/7a9900d6d34e437bb24beb5524a1f6488ae138c9

TBR=scroggo@google.com,brianosman@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/2328663002

8 years agoChecking for valid colorType, alphaType, colorSpace in SkCodec
msarett [Thu, 8 Sep 2016 17:14:04 +0000 (10:14 -0700)]
Checking for valid colorType, alphaType, colorSpace in SkCodec

* Refactor to share code between SkPngCodec and SkWebpCodec
* Didn't end up sharing with SkJpegCodec but did refactor
  that code a bit
* Disallow conversions to F16 with non-linear color spaces
* Fail to decode if we fail to create a SkColorSpaceXform
  (should be an assert soon).  We used to fallback on a
  legacy decode if we failed to create the transform.
* A bunch of name changes

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

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

8 years agoCache the inverse matrix on SkColorSpace. Rename xyz() to toXYZ().
brianosman [Thu, 8 Sep 2016 17:10:11 +0000 (10:10 -0700)]
Cache the inverse matrix on SkColorSpace. Rename xyz() to toXYZ().

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

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

8 years agoGN: add a helper script for running Android builds
mtklein [Thu, 8 Sep 2016 17:03:21 +0000 (10:03 -0700)]
GN: add a helper script for running Android builds

Think of this as the spiritual equivalent of platform_tools/android/bin/android_run_skia, but for GN and easier to type.

Cutting down the debug symbols makes Android builds about 1/4 the size.

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2323833002
DOCS_PREVIEW= https://skia.org/user/quick/gn?cl=2323833002

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

8 years agoPush usage of GrColor4f into OverrideInput
brianosman [Thu, 8 Sep 2016 16:33:50 +0000 (09:33 -0700)]
Push usage of GrColor4f into OverrideInput

Just a change to preserve precision.

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

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

8 years agomost is fine for *SAN bots now
mtklein [Thu, 8 Sep 2016 16:30:20 +0000 (09:30 -0700)]
most is fine for *SAN bots now

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

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

8 years agoremoved const from ASTVarDeclaration::fName to avoid a Chromium build failure
ethannicholas [Thu, 8 Sep 2016 16:19:51 +0000 (09:19 -0700)]
removed const from ASTVarDeclaration::fName to avoid a Chromium build failure
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2325673002

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

8 years agoClean up target_os=llvm now that it does nothing.
mtklein [Thu, 8 Sep 2016 16:19:00 +0000 (09:19 -0700)]
Clean up target_os=llvm now that it does nothing.

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

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

8 years agoAdd GM/slide to simulate Android-style reveal clip
robertphillips [Thu, 8 Sep 2016 16:02:43 +0000 (09:02 -0700)]
Add GM/slide to simulate Android-style reveal clip

Hopefully, this will let us play w/ geometric and shader-based solutions.

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

Committed: https://skia.googlesource.com/skia/+/ffac5c4aae18fc706e4077763c190a89c8507fb0
Review-Url: https://codereview.chromium.org/2316593003

8 years agoTests: DiscardableMemory test no longer relies on global state
halcanary [Thu, 8 Sep 2016 15:58:37 +0000 (08:58 -0700)]
Tests: DiscardableMemory test no longer relies on global state

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

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

8 years agoSkLiteDL: drawAsLayer()
mtklein [Thu, 8 Sep 2016 15:49:08 +0000 (08:49 -0700)]
SkLiteDL: drawAsLayer()

This more or less the API you were thinking?

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

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

8 years agoGN: add sanitize arg
mtklein [Thu, 8 Sep 2016 15:39:34 +0000 (08:39 -0700)]
GN: add sanitize arg

Attempt to take over all *SAN builds.

MSAN has a lot of coordination required between gn/BUILD.gn and gn_flavor.py.
I'd like to follow up to move more of this into gn/BUILD.gn, to make it easier
to use locally.

The compile steps should be much faster now.  We no longer build CMake
and Clang for every run, instead using the clang_linux CIPD package.  This
removes the need for all the third_party/externals/llvm/... dependencies.

Similarly, since we're using the clang_linux package, we no longer depend
on Chrome's Clang, and thus no longer need to sync chromium on these bots.

Instead of packaging up MSAN libraries and llvm-symbolizer in the compile
output, I have the test / perf bots also depend on the clang_linux package.
These do not vary from build to build.

No more need for the xsan.blacklist -include hack: Clang, GN, and Ninja
all track changes to xsan.blacklist without our help.

This has the incidental effect of upgrading the compiler used by *SAN
bots from Clang 3.8 to Clang 3.9.

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

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

8 years agoFlesh out SkOpts namespaces.
mtklein [Thu, 8 Sep 2016 13:59:44 +0000 (06:59 -0700)]
Flesh out SkOpts namespaces.

This makes it easier to see the baseline CPU feature settings for a build when looking at a stack trace or profile.  This fills out all the features we currently
might care about.

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

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

8 years agoAsset management: Download from GS store instead of CIPD
borenet [Thu, 8 Sep 2016 13:55:59 +0000 (06:55 -0700)]
Asset management: Download from GS store instead of CIPD

This avoids strange CIPD symlink/permissions issues

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

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

8 years agoGN: do not set default GN args
mtklein [Thu, 8 Sep 2016 13:49:05 +0000 (06:49 -0700)]
GN: do not set default GN args

It's just visual noise... this should make future gn_flavor.py
changes show fewer incidental diffs.

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

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

8 years agoFurther increase run_benchmark timeout
Ravi Mistry [Thu, 8 Sep 2016 13:08:44 +0000 (09:08 -0400)]
Further increase run_benchmark timeout

Looks like the chromium page sets still hit the 10 min timeout.

BUG=skia:5700

GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2342
# This code is not exercised by trybots.
NOTRY=true

Change-Id: I57aba4c1541a840d7e4e97112a6485abc20aa3c7
Reviewed-on: https://skia-review.googlesource.com/2342
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>

8 years agoAdd color xform support to SkWebpCodec
msarett [Thu, 8 Sep 2016 13:05:35 +0000 (06:05 -0700)]
Add color xform support to SkWebpCodec

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

Committed: https://skia.googlesource.com/skia/+/828ed1777da74692d0c8a5834017929f5aedcc6b
Review-Url: https://codereview.chromium.org/2294993002

8 years agoDelete deprecated GammaNamed
msarett [Thu, 8 Sep 2016 11:57:53 +0000 (04:57 -0700)]
Delete deprecated GammaNamed

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

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

8 years agoGN: default to -O1
mtklein [Thu, 8 Sep 2016 02:04:36 +0000 (19:04 -0700)]
GN: default to -O1

In a GN world we are no longer tied to the Debug/Release dichotomy of
GYP, and extra_cflags makes it trivially easy to override any flags we
set by default.  These two together mean we don't have to make the default
Debug build pointlessly unoptimized.

-O1 takes negligibly longer to compile than -O0, doesn't make debugging
difficult, and the code is considerably better.  DM runs ~4x faster this way.

Backstory: I just re-noticed we do this for our Debug MSAN builds, which has
had a serious wall-time slimming effect.  I was about to restore it to my GN
MSAN builds when I realized, hey, maybe we should do this for all builds.

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

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

8 years agoRename SkColorSpace::GammaNamed to SkColorSpace::RenderTargetGamma
msarett [Thu, 8 Sep 2016 01:55:49 +0000 (18:55 -0700)]
Rename SkColorSpace::GammaNamed to SkColorSpace::RenderTargetGamma

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

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

8 years agoRevert of Add color xform support to SkWebpCodec (patchset #2 id:80001 of https:...
msarett [Thu, 8 Sep 2016 01:53:14 +0000 (18:53 -0700)]
Revert of Add color xform support to SkWebpCodec (patchset #2 id:80001 of https://codereview.chromium.org/2294993002/ )

Reason for revert:
Windows bots hate it when I upload new images.

Original issue's description:
> Add color xform support to SkWebpCodec
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2294993002
>
> Committed: https://skia.googlesource.com/skia/+/828ed1777da74692d0c8a5834017929f5aedcc6b

TBR=scroggo@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/2318253004

8 years agoAdd color xform support to SkWebpCodec
msarett [Thu, 8 Sep 2016 01:05:24 +0000 (18:05 -0700)]
Add color xform support to SkWebpCodec

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

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

8 years agorefactored SkSL VarDeclaration handling
ethannicholas [Wed, 7 Sep 2016 20:37:16 +0000 (13:37 -0700)]
refactored SkSL VarDeclaration handling
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2312233002

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

8 years agoandroid_skp_capture.sh
halcanary [Wed, 7 Sep 2016 19:56:45 +0000 (12:56 -0700)]
android_skp_capture.sh

NOTRY=true
TBR=
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2324543002

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

8 years agoclang_linux: also build an MSAN libc++
mtklein [Wed, 7 Sep 2016 19:26:53 +0000 (12:26 -0700)]
clang_linux: also build an MSAN libc++

This will be used by MSAN bots: build with -stdlib=libc++,
then run with LD_LIBRARY_PATH=/path/to/clang_linux/msan.

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

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

8 years agoDelete SkColorSpace::gammaNamed() from public API
msarett [Wed, 7 Sep 2016 19:03:53 +0000 (12:03 -0700)]
Delete SkColorSpace::gammaNamed() from public API

Move fGammaNamed to SkColorSpace_Base.

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

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

8 years agoMerge building of program desc in Vulkan into one step
egdaniel [Wed, 7 Sep 2016 18:56:59 +0000 (11:56 -0700)]
Merge building of program desc in Vulkan into one step

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

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

8 years agoRevert of Add GM/slide to simulate Android-style reveal clip (patchset #6 id:100001...
robertphillips [Wed, 7 Sep 2016 18:34:05 +0000 (11:34 -0700)]
Revert of Add GM/slide to simulate Android-style reveal clip (patchset #6 id:100001 of https://codereview.chromium.org/2316593003/ )

Reason for revert:
Shader compilation failure

Original issue's description:
> Add GM/slide to simulate Android-style reveal clip
>
> Hopefully, this will let us play w/ geometric and shader-based solutions.
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2316593003
>
> Committed: https://skia.googlesource.com/skia/+/ffac5c4aae18fc706e4077763c190a89c8507fb0

TBR=jvanverth@google.com,djsollen@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/2316303002

8 years agoAdd minimal support for readPixels in raster F16
brianosman [Wed, 7 Sep 2016 18:30:47 +0000 (11:30 -0700)]
Add minimal support for readPixels in raster F16

Still doesn't support doing premul <-> unpremul conversions, but handles
the simple cases (which would previously always fail). Fixes the new gamut
gm (partially) in f16 config.

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

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

8 years agoUse demux API in SkWebpCodec
msarett [Wed, 7 Sep 2016 18:23:28 +0000 (11:23 -0700)]
Use demux API in SkWebpCodec

* Necessary to read ICC profiles
* Will be necessary to implement animation
* Requires consolidated data with length

Doesn't affect decode performance (thought I believe
our performance tests only cover SkStreams with memory
bases).

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

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

8 years agoAdd GM/slide to simulate Android-style reveal clip
robertphillips [Wed, 7 Sep 2016 17:34:06 +0000 (10:34 -0700)]
Add GM/slide to simulate Android-style reveal clip

Hopefully, this will let us play w/ geometric and shader-based solutions.

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

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

8 years agoRestructure flushing relationship between GrContext, GrDrawingManager, and GrResource...
bsalomon [Wed, 7 Sep 2016 17:02:04 +0000 (10:02 -0700)]
Restructure flushing relationship between GrContext, GrDrawingManager, and GrResourceCache.

Consolidates all flush actions into GrDrawingManager and makes GrContext::flush a passthrough.

Removes the unused and untested discard flush variation.

Replaces the indirect overbudget callback mechanism of GrResourceCache with a flag set by resource cache when it wants to flush that is checked after each draw by GrDrawContext.

Modifies GrResourceCache::notifyFlushOccurred() to take a param indicating whether it triggered the
flush that just occurred.

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

Committed: https://skia.googlesource.com/skia/+/1dbb207babecdae8f1f74ed9d9900c73064df744
Review-Url: https://codereview.chromium.org/2307053002

8 years agoSkPDF: remove unused fallback clipping code
halcanary [Wed, 7 Sep 2016 16:05:25 +0000 (09:05 -0700)]
SkPDF: remove unused fallback clipping code

This code is untested and unnecessary.

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

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

8 years agoRun install-sysroot script before 'gn gen' on PDFium bot
borenet [Wed, 7 Sep 2016 15:34:13 +0000 (08:34 -0700)]
Run install-sysroot script before 'gn gen' on PDFium bot

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

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

8 years agoRevert of Make AALinearizingConvexPathRenderer able to handle stroke and fill (patchs...
robertphillips [Wed, 7 Sep 2016 15:29:08 +0000 (08:29 -0700)]
Revert of Make AALinearizingConvexPathRenderer able to handle stroke and fill (patchset #7 id:120001 of https://codereview.chromium.org/2301353004/ )

Reason for revert:
Image quality issues on Android devices

Original issue's description:
> Make AALinearizingConvexPathRenderer able to handle stroke and fill
>
> This is intended to catch stroke-and-fill convex paths with potentially small stroke widths (e.g., .1).
>
> It does have the disconcerting side effect of changing bevel-joined stroke-and-filled degenerate-single-line-rects into plain rects (w/o triangular end-caps).
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2301353004
>
> Committed: https://skia.googlesource.com/skia/+/522bcd99fa65a8abd130880f59b500cf367d0845

TBR=ethannicholas@google.com,jvanverth@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/2318183002

8 years agofix pathops fuzzers
caryclark [Wed, 7 Sep 2016 15:21:09 +0000 (08:21 -0700)]
fix pathops fuzzers

Extreme values trigger asserts that in range
values allow.

Disable asserts and other tests to prevent
extreme values from crashing.

TBR=reed@google.com
BUG=644684. 644680, 644640
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2316173002

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

8 years agoAdd color gamut xform helpers to GrGLSLShaderBuilder
brianosman [Wed, 7 Sep 2016 15:09:10 +0000 (08:09 -0700)]
Add color gamut xform helpers to GrGLSLShaderBuilder

New helper functions inject the necessary shader
function. Texture lookup functions can now insert
the gamut xform at the appropriate place, too.

As written, could be used to transform non-texture
colors (e.g. vertex colors) as well.

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

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

8 years agoGN: fontmgr_custom
mtklein [Wed, 7 Sep 2016 14:52:55 +0000 (07:52 -0700)]
GN: fontmgr_custom

This makes skia_use_fontconfig=false build on Linux.  Instead of using
fontconfig it looks in /usr/share/fonts.

That alone is a nice feature to have, but it's mostly relevant for MSAN,
where we can't link against any uninstrumented system libraries.

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

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

8 years agomade point light shadows
vjiaoblack [Wed, 7 Sep 2016 14:48:12 +0000 (07:48 -0700)]
made point light shadows

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

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

8 years agoMerge GrGLSLProgramDesc into GrProgramDesc
egdaniel [Wed, 7 Sep 2016 14:24:12 +0000 (07:24 -0700)]
Merge GrGLSLProgramDesc into GrProgramDesc

BUG=skia:

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

8 years agoAdd gammaIsLinear() API to SkColorSpace
msarett [Wed, 7 Sep 2016 14:13:27 +0000 (07:13 -0700)]
Add gammaIsLinear() API to SkColorSpace

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

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

8 years agoAdd 6p to other device mapping
kjlubick [Wed, 7 Sep 2016 14:08:52 +0000 (07:08 -0700)]
Add 6p to other device mapping

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

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

8 years agoNew gamut GM, to test gamut conversion in various code-paths
brianosman [Wed, 7 Sep 2016 14:04:44 +0000 (07:04 -0700)]
New gamut GM, to test gamut conversion in various code-paths

After several different strategies, this one appears to work
well. The basic test:

1) For a variety of drawing techniques, we render fixed size
   rectangles. (Solid colors via paint color, bitmap, etc...)
2) For each method in #1, we render to both an sRGB and
   WideGamutRGB offscreen surface. (AdobeRGB isn't wide enough
   to clearly demonstrate if things are working or not).
3) Use readPixels to fetch the raw (still in wide gamut) pixel
   data, then draw that directly to the final canvas.

So, for each pair of squares, they should look clearly
different. Currently, with the GPU backend, only the bicubic
bitmap paths have that behavior. Adding more test cases (and
fixing the ones that are already incorrect) will be the long
tail of gamut transformation.

Current output (with my other patchset, which fixes all
bitmap draws): https://screenshot.googleplex.com/wsL3x7eCtWE.png

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

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

8 years agodocs: Add instructions on how to download isolated intermediaries.
jcgregorio [Wed, 7 Sep 2016 13:23:44 +0000 (06:23 -0700)]
docs: Add instructions on how to download isolated intermediaries.

Screenshot:
  https://screenshot.googleplex.com/2cXAQMqypHv.png

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

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

8 years agoMake AALinearizingConvexPathRenderer able to handle stroke and fill
robertphillips [Wed, 7 Sep 2016 13:03:48 +0000 (06:03 -0700)]
Make AALinearizingConvexPathRenderer able to handle stroke and fill

This is intended to catch stroke-and-fill convex paths with potentially small stroke widths (e.g., .1).

It does have the disconcerting side effect of changing bevel-joined stroke-and-filled degenerate-single-line-rects into plain rects (w/o triangular end-caps).

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

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

8 years agoGN: turn off ccache
mtklein [Wed, 7 Sep 2016 12:12:34 +0000 (05:12 -0700)]
GN: turn off ccache

I just burned 2 days debugging a confusing interaction between ccache
and the -fsanitize-blacklist argument to Clang.  Let's see if we can
live without ccache (swarming affinity + Ninja seems pretty decent).

As a point of reference, the Mac bots have been looking for ccache but
failing to find it.  They're proof this will be fine.

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

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

8 years agoreconfigure dont-clip-to-layer gm to not have transparent pixels in its final output
reed [Tue, 6 Sep 2016 21:57:00 +0000 (14:57 -0700)]
reconfigure dont-clip-to-layer gm to not have transparent pixels in its final output

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

TBR=

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

8 years agoRevert of More robust check for sRGB gamma tables (patchset #2 id:60001 of https...
msarett [Tue, 6 Sep 2016 21:41:42 +0000 (14:41 -0700)]
Revert of More robust check for sRGB gamma tables (patchset #2 id:60001 of https://codereview.chromium.org/2263233003/ )

Reason for revert:
From the previous commit message:
"This check is not fast.  If we find that it doesn't help
us recognize sRGB curves, we should delete it."

Turns out it doesn't help.  Looks to me like the tables are not sRGB.

Original issue's description:
> More robust check for sRGB gamma tables
>
> This is in response to a UMA showing that 5% dst gammas are
> unidentified tables.  We want to see if some of these tables
> should be marked as sRGB.
> https://uma.googleplex.com/p/chrome/histograms?endDate=latest&dayCount=1&histograms=Blink.ColorSpace.Destination&fixupData=true&showMax=true&filters=isofficial%2Ceq%2CTrue&implicitFilters=isofficial
>
> This check is not fast.  If we find that it doesn't help
> us recognize sRGB curves, we should delete it.
>
> BUG=skia:5656
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2263233003
>
> Committed: https://skia.googlesource.com/skia/+/4ff08df15a8042cdb4fc90a82e1044847d0de300

TBR=mtklein@google.com,brianosman@google.com
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=skia:5656

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

8 years ago[SVGDevice] Observe even-odd path fills
fmalita [Tue, 6 Sep 2016 21:37:02 +0000 (14:37 -0700)]
[SVGDevice] Observe even-odd path fills

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

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

8 years agoAdd Vulkan docs
bsalomon [Tue, 6 Sep 2016 21:18:13 +0000 (14:18 -0700)]
Add Vulkan docs

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

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

8 years agoRevert of Restructure flushing relationship between GrContext, GrDrawingManager,...
bsalomon [Tue, 6 Sep 2016 20:49:32 +0000 (13:49 -0700)]
Revert of Restructure flushing relationship between GrContext, GrDrawingManager, and GrResourceCache. (patchset #4 id:60001 of https://codereview.chromium.org/2307053002/ )

Reason for revert:
Causing assertions on bots

Original issue's description:
> Restructure flushing relationship between GrContext, GrDrawingManager, and GrResourceCache.
>
> Consolidates all flush actions into GrDrawingManager and makes GrContext::flush a passthrough.
>
> Removes the unused and untested discard flush variation.
>
> Replaces the indirect overbudget callback mechanism of GrResourceCache with a flag set by resource cache when it wants to flush that is checked after each draw by GrDrawContext.
>
> Modifies GrResourceCache::notifyFlushOccurred() to take a param indicating whether it triggered the
> flush that just occurred.
>
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2307053002
>
> Committed: https://skia.googlesource.com/skia/+/1dbb207babecdae8f1f74ed9d9900c73064df744

TBR=robertphillips@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/2312123003

8 years agoRevert of fix uninit immediate mode member var in GrDrawingManager (patchset #1 id...
bsalomon [Tue, 6 Sep 2016 20:48:41 +0000 (13:48 -0700)]
Revert of fix uninit immediate mode member var in GrDrawingManager (patchset #1 id:1 of https://codereview.chromium.org/2312333002/ )

Reason for revert:
Reverting in order to revert earlier CL

Original issue's description:
> fix uninit immediate mode member var in GrDrawingManager
>
> TBR=robertphillips@google.com
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2312333002
>
> NOTRY=true
>
> Committed: https://skia.googlesource.com/skia/+/ce3b852529ad1f026aad3976f3213c8943554ba2

TBR=robertphillips@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/2311243003

8 years agofix uninit immediate mode member var in GrDrawingManager
bsalomon [Tue, 6 Sep 2016 20:20:19 +0000 (13:20 -0700)]
fix uninit immediate mode member var in GrDrawingManager

TBR=robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2312333002

NOTRY=true

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

8 years agoadded radial lights to SkLights
vjiaoblack [Tue, 6 Sep 2016 20:03:30 +0000 (13:03 -0700)]
added radial lights to SkLights

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

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

8 years agoMove uils and sksl to a common sources GYP file.
brettw [Tue, 6 Sep 2016 19:43:55 +0000 (12:43 -0700)]
Move uils and sksl to a common sources GYP file.

This is for the coalescing of sources in one GYP file to improve GN runtime. If
this is successful, the other sources lists will also be merged into this one
file.

Inlines "../src" and "../include" for skia_source_dir and skia_include_dir. Evaluating these with GYP's variable expansion is annoying since I think another layer of nesting is required. Coding these explicitly is also more clear. This used to be required because Chromium would reference these .gypi files directly with a different path, but this no longer happens.

Removes the chromium defines gypi which is no longer referenced.

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

Committed: https://skia.googlesource.com/skia/+/39f7a10a04a914384944d8bf62621144ac4eeaa3
Review-Url: https://codereview.chromium.org/2302723005

8 years agoRestructure flushing relationship between GrContext, GrDrawingManager, and GrResource...
bsalomon [Tue, 6 Sep 2016 19:38:00 +0000 (12:38 -0700)]
Restructure flushing relationship between GrContext, GrDrawingManager, and GrResourceCache.

Consolidates all flush actions into GrDrawingManager and makes GrContext::flush a passthrough.

Removes the unused and untested discard flush variation.

Replaces the indirect overbudget callback mechanism of GrResourceCache with a flag set by resource cache when it wants to flush that is checked after each draw by GrDrawContext.

Modifies GrResourceCache::notifyFlushOccurred() to take a param indicating whether it triggered the
flush that just occurred.

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

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

8 years agokNumWindows is only used in GPU builds
mtklein [Tue, 6 Sep 2016 18:45:31 +0000 (11:45 -0700)]
kNumWindows is only used in GPU builds

TBR=csmartdalton@google.com

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

CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-MSAN-Trybot

Committed: https://skia.googlesource.com/skia/+/af92a7f85a5fc774838910444a9f2cddc3e43a2c
Review-Url: https://codereview.chromium.org/2305923004

8 years agocheck for null-layer-paint after prev fix to savelayer ops
reed [Tue, 6 Sep 2016 17:16:47 +0000 (10:16 -0700)]
check for null-layer-paint after prev fix to savelayer ops

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

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

8 years agoDelete SkColorSpace::kUnknown_Named, remove fNamed field
msarett [Tue, 6 Sep 2016 17:01:48 +0000 (10:01 -0700)]
Delete SkColorSpace::kUnknown_Named, remove fNamed field

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

Committed: https://skia.googlesource.com/skia/+/54682e856cb66c653bc7e253981a421a2618398e
Review-Url: https://codereview.chromium.org/2302413002

8 years agoImprove usage of window rectangles
csmartdalton [Tue, 6 Sep 2016 17:01:06 +0000 (10:01 -0700)]
Improve usage of window rectangles

* Skips non-AA diff rect elements and replaces them with window
  rectangles.
* Places window rectangles in the interiors of antialiased diff rects.
* Arranges two overlapping window rectangles in a plus shape inside of
  diff rounded rects.
* Enables window rectangles when clearing and generating clip masks.

GTX 960 perf result (with vs. without window rectangles):

                              glinst4                msaa16                 gpu
keymobi_pinterest.skp         0.48 -> 0.17 [ 35%]    2.77 -> 1.49 [ 54%]    0.22 -> 0.16 [ 70%]
keymobi_digg_com.skp          0.42 -> 0.23 [ 55%]    2.34 -> 1.08 [ 46%]    0.25 -> 0.21 [ 83%]
desk_jsfiddlebigcar.skp       0.28 -> 0.16 [ 59%]    1.70 -> 0.96 [ 57%]    0.19 -> 0.14 [ 70%]
top25desk_wordpress.skp       0.45 -> 0.18 [ 40%]    2.78 -> 1.53 [ 55%]    0.21 -> 0.19 [ 94%]
top25desk_weather_com.skp     2.01 -> 1.93 [ 96%]    23.5 -> 2.54 [ 11%]    1.90 -> 1.68 [ 88%]
keymobi_blogger.skp           0.57 -> 0.37 [ 65%]    2.87 -> 1.54 [ 54%]    0.43 -> 0.33 [ 77%]
keymobi_linkedin.skp          0.32 -> 0.17 [ 51%]    1.93 -> 1.04 [ 54%]    0.17 -> 0.15 [ 91%]
keymobi_bing_com_search_...   0.29 -> 0.25 [ 83%]    1.85 -> 1.23 [ 66%]    0.50 -> 0.24 [ 48%]
keymobi_theverge_com_201...   1.00 -> 0.67 [ 68%]    9.46 -> 3.84 [ 41%]    0.72 -> 0.65 [ 90%]
keymobi_sfgate_com_.skp       1.56 -> 1.13 [ 72%]    4.49 -> 2.86 [ 64%]    1.54 -> 1.11 [ 72%]
...
GEOMEAN (All 79 blink skps)   1.04 -> 0.90 [ 86%]    4.22 -> 2.81 [ 67%]    0.95 -> 0.89 [ 94%]

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

Committed: https://skia.googlesource.com/skia/+/db42be9a326c747ff92ed1da8c3536c5b3e8e22b
Review-Url: https://codereview.chromium.org/2289363005

8 years agoWork around VS 2015 Update 3 optimizer internal compiler error
brucedawson [Tue, 6 Sep 2016 16:54:44 +0000 (09:54 -0700)]
Work around VS 2015 Update 3 optimizer internal compiler error

VS 2015 Update 3 comes with a fancy new optimizer and this optimizer
causes an internal compiler error on one skia function. This change
works around the bug by disabling optimize-for-time for that function.

Other options would be to add /d2SSAOptimizer- to the command-line for
the file or project but that would *require* Update 3 which is not yet
desirable.

VS bug report is here:
https://connect.microsoft.com/VisualStudio/feedback/details/3100520
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2308833002

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