Commit Graph

24034 Commits

Author SHA1 Message Date
brianosman
971cd496b9 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
2016-09-08 10:10:11 -07:00
mtklein
f3155ad97c 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
2016-09-08 10:03:21 -07:00
brianosman
4cea3b9e9d 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
2016-09-08 09:33:50 -07:00
mtklein
3b10b37a1c 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
2016-09-08 09:30:20 -07:00
ethannicholas
f86809730e 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
2016-09-08 09:19:51 -07:00
mtklein
e19c179281 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
2016-09-08 09:19:00 -07:00
robertphillips
05a4cf5959 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
2016-09-08 09:02:44 -07:00
halcanary
51761d12d0 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
2016-09-08 08:58:37 -07:00
mtklein
f53fcc8cca 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
2016-09-08 08:49:09 -07:00
mtklein
2b3c2a3ff9 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
2016-09-08 08:39:34 -07:00
mtklein
da7136750d 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
2016-09-08 06:59:44 -07:00
borenet
2172d55eb5 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
2016-09-08 06:55:59 -07:00
mtklein
34ffb342f5 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
2016-09-08 06:49:05 -07:00
Ravi Mistry
57d6965562 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>
2016-09-08 13:13:43 +00:00
msarett
e99883f33b 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
2016-09-08 06:05:35 -07:00
msarett
56cbb23436 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
2016-09-08 04:57:53 -07:00
mtklein
5e3a630753 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
2016-09-07 19:04:36 -07:00
msarett
48ba2b8550 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
2016-09-07 18:55:49 -07:00
msarett
2eb00e7b77 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
2016-09-07 18:53:14 -07:00
msarett
828ed1777d 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
2016-09-07 18:05:24 -07:00
ethannicholas
14fe8cc16d refactored SkSL VarDeclaration handling
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2312233002

Review-Url: https://codereview.chromium.org/2312233002
2016-09-07 13:37:16 -07:00
halcanary
ef6a9b7f93 android_skp_capture.sh
NOTRY=true
TBR=
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2324543002

Review-Url: https://codereview.chromium.org/2324543002
2016-09-07 12:56:45 -07:00
mtklein
1a9466799e 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
2016-09-07 12:26:53 -07:00
msarett
600c737b64 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
2016-09-07 12:03:53 -07:00
egdaniel
720dc71cfe 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
2016-09-07 11:56:59 -07:00
robertphillips
62e9b145a1 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
2016-09-07 11:34:05 -07:00
brianosman
c544e7043c 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
2016-09-07 11:30:47 -07:00
msarett
ff2a6c8a70 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
2016-09-07 11:23:28 -07:00
robertphillips
ffac5c4aae 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
2016-09-07 10:34:06 -07:00
bsalomon
b77a907c2f 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
2016-09-07 10:02:04 -07:00
halcanary
5edf2908a3 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
2016-09-07 09:05:26 -07:00
borenet
e72daf6116 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
2016-09-07 08:34:13 -07:00
robertphillips
7a00e8bc98 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
2016-09-07 08:29:08 -07:00
caryclark
b393a49e5f 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
2016-09-07 08:21:09 -07:00
brianosman
77320dbabc 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
2016-09-07 08:09:10 -07:00
mtklein
d2e39dbc6a 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
2016-09-07 07:52:55 -07:00
vjiaoblack
1e5abf15d1 made point light shadows
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2294323003

Review-Url: https://codereview.chromium.org/2294323003
2016-09-07 07:48:12 -07:00
egdaniel
5d8f69f2d4 Merge GrGLSLProgramDesc into GrProgramDesc
BUG=skia:

Review-Url: https://codereview.chromium.org/2318523006
2016-09-07 07:24:12 -07:00
msarett
653212c37e Add gammaIsLinear() API to SkColorSpace
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2319073002

Review-Url: https://codereview.chromium.org/2319073002
2016-09-07 07:13:27 -07:00
kjlubick
eb2a27137e 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
2016-09-07 07:08:52 -07:00
brianosman
2c4b64e92a 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
2016-09-07 07:04:45 -07:00
jcgregorio
e050555bf3 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
2016-09-07 06:23:44 -07:00
robertphillips
522bcd99fa 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
2016-09-07 06:03:48 -07:00
mtklein
b58fe9b899 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
2016-09-07 05:12:34 -07:00
reed
28d1ce5c40 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
2016-09-06 14:57:00 -07:00
msarett
e54f4b7cf3 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
2016-09-06 14:41:42 -07:00
fmalita
221722b7f9 [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
2016-09-06 14:37:02 -07:00
bsalomon
54dd2e244c 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
2016-09-06 14:18:13 -07:00
bsalomon
5eb41fdf94 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
2016-09-06 13:49:32 -07:00
bsalomon
128a958c1f 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
2016-09-06 13:48:41 -07:00