Commit Graph

27668 Commits

Author SHA1 Message Date
Chris Dalton
4343654bc4 Improve accuracy of cubic classification
- Updates the logic to reflect the Loop-Blinn paper instead of the GPU
  gems website.
- Removes the threshold for detecting local cusps. The serpentine
  codepath works for these cusps anyway, so what we really want to know
  is whether the discriminant is negative.
- Makes sure to not scale the inflection function by 1/0.
- Shifts the inflection function coefficients in d[] so they match the
  paper.
- Stores the cubic discriminant in d[0].

Bug: skia:
Change-Id: I909a522a0fd27c9c8dfbc27d968bc43eeb7a416f
Reviewed-on: https://skia-review.googlesource.com/13304
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-04-14 15:14:11 +00:00
Ravi Mistry
028c3d77ea Add documentation for android-o-roll.skia.org
BUG=skia:6438
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=13475
Change-Id: I7d76d66b9b665fafc5c89bd4620517ebb9d2b076

Change-Id: I7d76d66b9b665fafc5c89bd4620517ebb9d2b076
Reviewed-on: https://skia-review.googlesource.com/13475
Reviewed-by: Matt Sarett <msarett@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2017-04-14 14:38:56 +00:00
Cary Clark
389c557338 fix pathops_unittest test strings
Using std::string is tons faster than SkString;
multiple callers to std::string don't run into
thread contention but SkString does.

R=csmartdalton@google.com

Change-Id: I0357c6a9c73856bfffbb76e65c275acdfe7d8159
Reviewed-on: https://skia-review.googlesource.com/13471
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
2017-04-14 14:37:16 +00:00
Matt Sarett
479366cd14 Let region decoders query the type and color space
b/36905374, b/32984164
Test: CtsGraphicsTestCases

Written by: romainguy@

Change-Id: Ief4bba6ec3cd3446224199d05f06ffcffaaa72b5
Reviewed-on: https://skia-review.googlesource.com/13472
Reviewed-by: Matt Sarett <msarett@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
2017-04-14 13:59:35 +00:00
Brian Osman
7a34dca6c8 Do non-deterministic FP opt testing on all bots
Bug: skia:6395
Change-Id: Ic5065bfc91cac83495836cd6d2a7cc059423c96e
Reviewed-on: https://skia-review.googlesource.com/13412
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-04-14 13:36:15 +00:00
Mike Klein
8671428f62 refine .type ...,%function
.type is an ELF thing, not understood by Mach.
So do the same sort of #define trick we do for HIDDEN.

This expands the use of .type ...,%function to everywhere
that supports it, rather than just where we needed it.
Feels cozier this way.

CQ_INCLUDE_TRYBOTS=skia.primary:Build-Mac-Clang-arm-Debug-iOS,Build-Mac-Clang-arm-Release-iOS,Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Release,Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Debug

Change-Id: Iaff01b0f3f70ceedf743d7a553915792cdd7e569
Reviewed-on: https://skia-review.googlesource.com/13469
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Herb Derby <herb@google.com>
2017-04-13 22:20:31 +00:00
Heather Miller
00055df70f Update Skia milestone to 60
BUG=skia:

Change-Id: I1354ff96f5ff62c02af1d9cf39f0a971da077b17
Reviewed-on: https://skia-review.googlesource.com/13465
Reviewed-by: Heather Miller <hcm@google.com>
Commit-Queue: Heather Miller <hcm@google.com>
2017-04-13 21:22:43 +00:00
Mike Klein
965451ed83 jumper, explicitly tag functions as functions
This helps the linker decide to rewrite bl -> blx when linking
Thumb2 SkJumper.o code with ARM SkJumper_generated.o.

The reason Android wasn't failing is because it somehow figured
out to do this without these .type directives.  We use a different
toolchain for ChromeOS builds that I guess needs more handholding.

BUG=skia:6471

CQ_INCLUDE_TRYBOTS=skia.primary:Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Release,Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Debug

Change-Id: I4a5c50b6ab7683512776c70aec6e9a75a0999787
Reviewed-on: https://skia-review.googlesource.com/13464
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-13 21:21:43 +00:00
Mike Reed
818580d81b remove code directly involved in lock/unlock in SkPixelRef
Bug: skia:6481
Change-Id: I3c301ad42b082e04e233aa32d77862036fe998fa
Reviewed-on: https://skia-review.googlesource.com/13463
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-04-13 20:44:24 +00:00
Mike Reed
c756c7acfe make picture-imagegenerator more robust on requested infos
This new unittest would assert before this fix.

Bug: skia:6501
Change-Id: I351ad03f29bccc054f72bfcb838174830dbd008c
Reviewed-on: https://skia-review.googlesource.com/13413
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Matt Sarett <msarett@google.com>
2017-04-13 19:53:12 +00:00
Brian Osman
d2ca59a1cd Further unify logic in readSurfacePixels and writeSurfacePixels
Hoist simple failure checks to the beginning, apply logic in the same
sequence in both functions. Factor out some common logic. Remove redundant
checking inside other helper functions (that are only used from here).

I'm inching towards better sRGB and color-conversion support in these
functions, but I don't want that intertwined with the legacy premul
software fallback. Next step is probably to diverge at the top-level,
and keep the current code as "legacy" versions, with new versions that
don't have the fallback logic, only used for configs and color space
scenarios where it doesn't matter.

Bug: skia:5853
Change-Id: I327be5f0186a16ceda9440670fb0646acaef7766
Reviewed-on: https://skia-review.googlesource.com/13337
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Matt Sarett <msarett@google.com>
2017-04-13 18:43:16 +00:00
Herb Derby
9428a37255 Move GrAtlasGlyphCache over to SkArenaAlloc from SkVarAlloc.
Change-Id: Ibeee7235d30c68be9fd4f68ecf30a65c7ecb78f5
Reviewed-on: https://skia-review.googlesource.com/13020
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2017-04-13 18:33:02 +00:00
Mike Klein
6ad59789e7 c100p bots: put a bandaid on broken Thumb
BUG=skia:6471

CQ_INCLUDE_TRYBOTS=skia.primary:Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Release,Test-ChromeOS-Clang-Chromebook_C100p-GPU-MaliT764-arm-Debug

Change-Id: I3faa28c69510fbb33d40abbfb59bf3a7ba5ddb77
Reviewed-on: https://skia-review.googlesource.com/13407
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-13 18:22:03 +00:00
Mike Reed
79f2db2a21 remove old-pixelref-api flag from android
call sites have been updated in master

Bug: skia:6481
Change-Id: I7f341cb511126a71fe3077bed3eaa55dc7ff76c3
Reviewed-on: https://skia-review.googlesource.com/13440
Reviewed-by: Mike Reed <reed@google.com>
2017-04-13 18:10:55 +00:00
Mike Klein
2af5d68e11 disable this test on NoGPU bots
It fails at line 336:
  REPORTER_ASSERT(reporter, configs[i]->getBackend().equals(expectedConfigs[i].backend));

Change-Id: Iab71162b9d7b5454d200cb373026992eac92adf8
Reviewed-on: https://skia-review.googlesource.com/13406
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-13 17:05:37 +00:00
Eric Boren
2ce36ea09e Add infra/bots/Makefile to simplify test/train
eg.
$ make test
or
$ make train

Update docs accordingly.

Bug: skia:
Change-Id: I069fa686833f0a78f398bd85eb8bb44025cae0d5
Reviewed-on: https://skia-review.googlesource.com/13327
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2017-04-13 17:01:17 +00:00
Mike Klein
9866817d5f make ShadowUtils unit test pass on no-GPU builds
It thinks it should fail, but it doesn't.

Change-Id: Ie97f57dd7a9040a817b59186b2f8fa704bdda3e9
Reviewed-on: https://skia-review.googlesource.com/13404
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-13 16:59:39 +00:00
Herb Derby
0d63e4e4a8 Use a simpler method for calculating atan
Change-Id: I675851350c02c85f3f212c214766b3e8a6761dc9
Reviewed-on: https://skia-review.googlesource.com/13402
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Herb Derby <herb@google.com>
2017-04-13 16:48:59 +00:00
Mike Klein
f71b33846a re-disable lld on MSAN bots
When using lld, calls to clock_gettime() end up in the real libc
clock_gettime().  When using ld, calls to clock_gettime() end up in
__interceptor_clock_gettime().

Don't know why yet.

Change-Id: I41f54218eb961e07ed2ef2c37b864e9aeeb49662
Reviewed-on: https://skia-review.googlesource.com/13403
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-13 16:42:19 +00:00
Eric Boren
ade6920037 Change infra recipe module to use the Go asset
Bug: skia:
Change-Id: Ib2fa0b971f201ea2f16afd0467d7882b66b4047c
Reviewed-on: https://skia-review.googlesource.com/13331
Reviewed-by: Joe Gregorio <jcgregorio@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
2017-04-13 16:26:22 +00:00
Robert Phillips
e440721a86 Remove GrRenderTargetOpList::discard & move functionality to GrRenderTargetContext
Change-Id: If84ffb7b01543a44179837d683c0a4c004e52f63
Reviewed-on: https://skia-review.googlesource.com/13335
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2017-04-13 15:42:59 +00:00
Mike Reed
1335a0561e remove dead code around replayClips
Bug: skia:
Change-Id: I208bf41846265524d86f65de660311199fefc158
Reviewed-on: https://skia-review.googlesource.com/13338
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-04-13 15:42:09 +00:00
Mike Klein
0a4b4100c1 Set skia_enable_gpu=false on MSAN builds.
This should get us past the crash at startup.

The next problem I'd expect to see, if any, should involve HumanizeMS()
and chrono::steady_clock::now().

Change-Id: I14dbe6bedd6939c1a355db8dba74ab0853db7706
Reviewed-on: https://skia-review.googlesource.com/13401
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2017-04-13 15:30:49 +00:00
Greg Daniel
fc978fde48 Store the GrBackend we are using on GrContext
As we start adding more functionality to external clients and passing
data around, we will need to know what backend we are working with at
a layer higher that GrGpu.

TBR=bsalomon@google.com

Bug: skia:
Change-Id: Ifee527ea0c1046469401a39e0500f84a46bb3081
Reviewed-on: https://skia-review.googlesource.com/13275
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2017-04-13 15:19:57 +00:00
Robert Phillips
178ce3eddd Make all GrRenderTargetOpList ops store a GrRenderTarget pointer
Change-Id: I39652b4b8b2ba96b5206304dfc51395283c3fe16
Reviewed-on: https://skia-review.googlesource.com/13332
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
2017-04-13 14:40:13 +00:00
Mike Klein
2a5c66666e try -B
Change-Id: I4e03d668197d76feb71113f47bae24fdd2fc6b6f
Reviewed-on: https://skia-review.googlesource.com/13334
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2017-04-13 14:33:46 +00:00
Brian Osman
2d2da4f9ee Do sRGB premul/unpremul on the GPU
Previously, the early check would decide that sRGB pixel configs were okay
(because they're 8888-unorm). Then we'd go to make the effect and decide
that we didn't want them to work. This led to the software fallback.

The software fallback was obviously slower, but also doing non-linear
premul/unpremul operations. Eventually, whether or not the premul is
linear should be dictated by the destination color space, but for now,
this is an improvement (and only affects the one GM that tests this
feature).

Bug: skia:
Change-Id: I0cf1ad5a7f552135ac1da728c6db2977652a433b
Reviewed-on: https://skia-review.googlesource.com/13321
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2017-04-13 13:57:50 +00:00
Chris Dalton
59163ba06c Access EGL_KHR_fence_sync via eglGetProcAddress
Bug: skia:6497
Change-Id: Icf04de6b1facc94e8c45085575cb45189c6c649c
Reviewed-on: https://skia-review.googlesource.com/13306
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-04-13 13:28:03 +00:00
Kevin Lubick
ea0f845bf6 Update clang_linux to version 4
Bug: skia:
Change-Id: Iab4fcd7b8f17fa7bf478e879a325759e0c622b1a
Reviewed-on: https://skia-review.googlesource.com/13120
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2017-04-13 13:01:42 +00:00
Mike Reed
96d5b9a273 remove unused fURI from pixelref
Bug: skia:
Change-Id: Ib25569862063b765b823b68ffdc22349a606f940
Reviewed-on: https://skia-review.googlesource.com/13324
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-04-13 03:05:39 +00:00
Mike Reed
9fa7403652 locking methods should only be virtual in legacy mode
However, they should not be pure-virtual, otherwise the client can't migrate to the new
api independent of undef-ing the flag.

Bug: skia:6481
Change-Id: I3c9107b145c4c53297891224946b080ce729f9b0
Reviewed-on: https://skia-review.googlesource.com/13272
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-04-12 19:45:00 +00:00
csmartdalton
0f47a25cac Fix cubic KLM solving
Fixes calc_inverse_transpose_power_basis_matrix() to look for the
determinant with the largest ABSOLUTE VALUE.

BUG=skia:

Change-Id: I70e26cc7ab9955d2e094fb7581f0ec9f5e0ae2d9
Reviewed-on: https://skia-review.googlesource.com/13081
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
2017-04-12 19:36:40 +00:00
Kevin Lubick
5bc818173a Add job for Acer chromebook (TegraK1)
Known issue: Nanobench fails with
/home/chronos/user/bin/nanobench: symbol lookup error: 
/home/chronos/user/bin/nanobench: undefined symbol: eglCreateSyncKHR

Bug: skia:6468
NOTRY=true
Change-Id: Idb1291c2da835d093826022f4cab4069e28c5964
Reviewed-on: https://skia-review.googlesource.com/13188
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
2017-04-12 19:13:37 +00:00
Ben Wagner
b0b1d23c7e Add Win IntelHD4400 bot.
Bug: skia:6488
NOTRY=true

Change-Id: Icab4bf478925fb48f7facd6c9883a2753d04aaac
Reviewed-on: https://skia-review.googlesource.com/13191
Reviewed-by: Eric Boren <borenet@google.com>
Commit-Queue: Ben Wagner <benjaminwagner@google.com>
2017-04-12 18:58:49 +00:00
Mike Klein
0a9044950c jumper, bilinear and bicubic sampling stages
This splits SkImageShaderContext into three parts:
   - SkJumper_GatherCtx: always, already done
   - SkJumper_SamplerCtx: when bilinear or bicubic
   - MiscCtx: other little bits (the matrix, paint color, tiling limits)

Thanks for the snazzy allocator that allows this Herb!

Both SkJumper and SkRasterPipeline_opts.h should be speaking all the
same types now.

I've copied the comments about bilinear/bicubic to SkJumper with little
typo fixes and clarifications.

Change-Id: I4ba7b7c02feba3f65f5292169a22c060e34933c6
Reviewed-on: https://skia-review.googlesource.com/13269
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-12 18:57:09 +00:00
Greg Daniel
50130e427c Allow including of vulkan.h as a required public api when using vulkan.
Bug: skia:
Change-Id: I3ac382edc12144dcda9ef168f752b14878e0e5ac
Reviewed-on: https://skia-review.googlesource.com/13262
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
2017-04-12 18:24:25 +00:00
Mike Reed
4ccd862d29 android-only api to reset the fields of a pixelref
BUG=skia:6494

Change-Id: I97c8a93849a13f0c5fd57c8a150ecc2ce363d8f3
Reviewed-on: https://skia-review.googlesource.com/13250
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2017-04-12 17:46:17 +00:00
Ravi Mistry
6d2cf4726c Update Android autoroller documentation
BUG=skia:5538
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=13266
Change-Id: I76fa8db5ea9916fab2ef0f8058157dac96d52517

Change-Id: I76fa8db5ea9916fab2ef0f8058157dac96d52517
Reviewed-on: https://skia-review.googlesource.com/13266
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
2017-04-12 17:03:17 +00:00
Kevin Lubick
671cd72c0a Add jobs for Samsung Chromebook Plus
Also refactor the cipd package used to compile these, as it can be reused.

Bug: skia:
NOTRY=true
Change-Id: I53cf5b7fdfcb8cafd50791a0beaaf557fafa65c3
Reviewed-on: https://skia-review.googlesource.com/13252
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Eric Boren <borenet@google.com>
2017-04-12 16:51:21 +00:00
Cary Clark
e0b728726d fix drawDRRect for fuzzer
make assert abort instead

Bug: skia:6450
Change-Id: I23ff51124fa8f069f2c7e5260f800017d7475d46
Reviewed-on: https://skia-review.googlesource.com/13197
Commit-Queue: Cary Clark <caryclark@google.com>
Reviewed-by: Hal Canary <halcanary@google.com>
2017-04-12 16:48:31 +00:00
Mike Klein
994ef97339 make all gather_*() use SkJumper_GatherCtx
SkJumper_GatherCtx is a prefix of SkImageShaderContext, so
this is a no-op.  It helps to keep things straight, and I
do want to split apart the GatherCtx from a new SamplingCtx.

Change-Id: I9c5f436b096624c2809e1f810e9bcd6c6b00b883
Reviewed-on: https://skia-review.googlesource.com/13264
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-12 16:44:31 +00:00
Eric Boren
8e02684311 Add/edit README files for infra/recipes
Bug: skia:6473
Change-Id: I050df47a5a3f633263f0ca6258e83e96b78d7957
Reviewed-on: https://skia-review.googlesource.com/13123
Commit-Queue: Eric Boren <borenet@google.com>
Reviewed-by: Stephan Altmueller <stephana@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Reviewed-by: Ben Wagner <benjaminwagner@google.com>
2017-04-12 16:41:01 +00:00
Matt Sarett
547a7272fa Fix SkLocalMatrixShader::isAImage() to respect local matrix and image local matrix
Fixes cts tests.

b/37161109
b/37237678

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-MSAN

Bug: skia:
Change-Id: I438b8b17f4c7c5bfcb50dfa22af1ddb97b905088
Reviewed-on: https://skia-review.googlesource.com/13261
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Matt Sarett <msarett@google.com>
2017-04-12 16:36:51 +00:00
Matt Sarett
719528ab47 Revert "Revert "SkColorSpaceXformer: Preserve local matrix on shaders""
This reverts commit a50a11c17e.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Revert "SkColorSpaceXformer: Preserve local matrix on shaders"
> 
> This reverts commit 5d884b5628.
> 
> Reason for revert: Wrong thing to revert
> 
> Original change's description:
> > SkColorSpaceXformer: Preserve local matrix on shaders
> > 
> > Also, do not drop unknown shaders.
> > 
> > Fixes cts tests.
> > 
> > b/37161109
> > b/37237678
> > 
> > Bug: skia:
> > Change-Id: I0fd817a4d6461ede0ccdcb8f3cccb255b646b864
> > Reviewed-on: https://skia-review.googlesource.com/13246
> > Commit-Queue: Matt Sarett <msarett@google.com>
> > Commit-Queue: Mike Klein <mtklein@chromium.org>
> > Reviewed-by: Mike Klein <mtklein@chromium.org>
> > 
> 
> TBR=mtklein@chromium.org,mtklein@google.com,msarett@google.com,reviews@skia.org
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
> 
> Change-Id: I34e02785ac43a04f8452c458680ea1d6518818a6
> Reviewed-on: https://skia-review.googlesource.com/13258
> Reviewed-by: Matt Sarett <msarett@google.com>
> Commit-Queue: Matt Sarett <msarett@google.com>
> 

TBR=mtklein@chromium.org,mtklein@google.com,msarett@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I2dfac7d41caf0e32d3bb5f3f330fff4970c0545e
Reviewed-on: https://skia-review.googlesource.com/13260
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
2017-04-12 15:53:47 +00:00
Matt Sarett
e5fec21787 Revert "Fix SkLocalMatrixShader::isAImage() to respect local matrix and image local matrix"
This reverts commit e5efa51b2a.

Reason for revert: MSAN

Original change's description:
> Fix SkLocalMatrixShader::isAImage() to respect local matrix and image local matrix
> 
> Fixes cts tests.
> 
> b/37161109
> b/37237678
> 
> Bug: skia:
> Change-Id: Ida9ac5e4261e8a6b22e8cdc0e585e0e7929dbbfd
> Reviewed-on: https://skia-review.googlesource.com/13249
> Commit-Queue: Mike Klein <mtklein@chromium.org>
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> 

TBR=mtklein@chromium.org,mtklein@google.com,msarett@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I2b78c7b32997344136c784dc77675dafca37565e
Reviewed-on: https://skia-review.googlesource.com/13259
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
2017-04-12 15:49:51 +00:00
Matt Sarett
a50a11c17e Revert "SkColorSpaceXformer: Preserve local matrix on shaders"
This reverts commit 5d884b5628.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> SkColorSpaceXformer: Preserve local matrix on shaders
> 
> Also, do not drop unknown shaders.
> 
> Fixes cts tests.
> 
> b/37161109
> b/37237678
> 
> Bug: skia:
> Change-Id: I0fd817a4d6461ede0ccdcb8f3cccb255b646b864
> Reviewed-on: https://skia-review.googlesource.com/13246
> Commit-Queue: Matt Sarett <msarett@google.com>
> Commit-Queue: Mike Klein <mtklein@chromium.org>
> Reviewed-by: Mike Klein <mtklein@chromium.org>
> 

TBR=mtklein@chromium.org,mtklein@google.com,msarett@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Change-Id: I34e02785ac43a04f8452c458680ea1d6518818a6
Reviewed-on: https://skia-review.googlesource.com/13258
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
2017-04-12 15:48:41 +00:00
Mike Klein
5a8da16719 tidy up ok help
-m, -s, and -w are now vias.

No real need to advertise -h given that if you just run ok with no
arguments it prints the help, but to be friendly accept -h and --help.

Change-Id: Id23936106cfea7d670cf0eb9773a5851055576f1
Reviewed-on: https://skia-review.googlesource.com/13254
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
2017-04-12 15:34:40 +00:00
Mike Klein
db1cbcb4b5 jumper, rgb<->hsl
I've rearranged while porting, I hope making the logic clearer.
Exactly one gm is affected, highcontrastfilter.

The most interesting line is this, from hsl_to_rgb:

  F t2 = if_then_else(t < 0.0_f, t + 1.0_f,

I had to write 0.0_f (instead of the usual 0) to force Clang to compare
against a zero register instead of a 16-byte zero constant in memory.
Register pressure is high in hsl_to_rgb, so something must have kicked
in to prefer memory over zeroing a register.

No big deal.  It makes the code read more symmetrically anyway.

Change-Id: I1a5ced72216234587760c6f803fb69315d18fae0
Reviewed-on: https://skia-review.googlesource.com/13242
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Herb Derby <herb@google.com>
2017-04-12 15:31:03 +00:00
Leon Scroggins III
e132e7be5f Add SkCodec methods for individual frames
Add a version of getFrameInfo that returns information about a single
frame, allowing a client to skip creating the entire vector.

Add getFrameCount, for determining the number of frames in the image.

Reimplement std::vector<FrameInfo> getFrameInfo with the new methods.

Updates to the test:
- getFrameInfo(size_t, FrameInfo*) fails before parsing
- Test both versions of getFrameInfo
- Recreate the codec between tests, to test parsing

Change-Id: I77c19087f2f8dcf2c536d80167b18ad1ca96ae94
Reviewed-on: https://skia-review.googlesource.com/13190
Reviewed-by: Matt Sarett <msarett@google.com>
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Chris Blume <cblume@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
2017-04-12 15:22:43 +00:00
Matt Sarett
e5efa51b2a Fix SkLocalMatrixShader::isAImage() to respect local matrix and image local matrix
Fixes cts tests.

b/37161109
b/37237678

Bug: skia:
Change-Id: Ida9ac5e4261e8a6b22e8cdc0e585e0e7929dbbfd
Reviewed-on: https://skia-review.googlesource.com/13249
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
2017-04-12 15:11:03 +00:00