Commit Graph

16805 Commits

Author SHA1 Message Date
egdaniel
5d09568a0c Move skp nanobench tile size back to 256x256 to see if it fixes nanobench crashes
Going back to old nanobench tile size to see if the increase to tile is what has been
causing recent nanobench crashes. The crashes seem very nondeterministic and hard to
debug manually.

256x256 is too small of a tile to give accurate gpu results but if this fixes we can try some compromise in the middle

BUG=skia:

Review URL: https://codereview.chromium.org/1022823003
2015-03-19 11:00:09 -07:00
mtklein
bbecae0832 Sk2x
This adds an API, an SSE impl, a portable impl, and some tests for Sk2f/Sk2d/Sk2s.

BUG=skia:

Review URL: https://codereview.chromium.org/1025463002
2015-03-19 10:44:27 -07:00
bungeman
665b038b57 Use typographic font metrics when the font requests.
FreeType always returns the 'hhea' font metrics for ascent and descent,
and ignores the 'OS/2'::fsSelection::UseTypoMetrics bit. (It also
ignores the VDMX table, which makes this change correct.) This change
uses the typographic font metrics when the font requests their use.

Review URL: https://codereview.chromium.org/1020643002
2015-03-19 10:43:57 -07:00
mtklein
f87cbcdf9f Reorg Sk4x to match the pattern of SkPMFloat.
No real changes here, just moving files around:
  - move impl files into src/opts
  - rename _portable _none

BUG=skia:

Review URL: https://codereview.chromium.org/1021713004
2015-03-19 10:19:48 -07:00
reed
65cb2cd2f7 alt SkEvalQuadAt that returns its answer, using Sk2f
BUG=skia:

Review URL: https://codereview.chromium.org/1011493003
2015-03-19 10:18:47 -07:00
reed
e053ca4380 remove unused clip parameter to SkEdge::setClip
BUG=skia:

Review URL: https://codereview.chromium.org/1019183002
2015-03-19 09:49:09 -07:00
reed
3ef71e343b guarded change to SkImageGenerator to make getInfo() const
BUG=skia:

Review URL: https://codereview.chromium.org/1017293002
2015-03-19 08:31:14 -07:00
rmistry
647211f124 Whitespace change to test the CQ
BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/1019313002
2015-03-19 07:56:13 -07:00
jvanverth
a7634619ec Ensure that we use different glyph entries for regular and df text.
Currently if we switch between regular text and df text while using
the same GrContext, they may use the same entry in the Ganesh font cache,
which is incorrect. This change ensures that they will have different entries.

Committed: https://skia.googlesource.com/skia/+/8dc58edd71c11f232860724dfa3b566895478034

Review URL: https://codereview.chromium.org/1020593003
2015-03-19 06:08:31 -07:00
scroggo
9b77ddde08 Run CodecSrc DM.
Rather than making SkCodec an option instead of SkImageDecoder,
create a separate CodecSrc. This allows us to compare the two.

For both CodecSrc and ImageSrc, do not decode to a gpu backend.

BUG=skia:3475

Review URL: https://codereview.chromium.org/978823002
2015-03-19 06:03:39 -07:00
reed
effcba4a4d Revert of replace SkFixedDiv impl with native 64bit math (patchset #2 id:20001 of https://codereview.chromium.org/1022543003/)
Reason for revert:
http://build.chromium.org/p/tryserver.blink/builders/linux_blink_rel/builds/53096

layouttests failures

Original issue's description:
> replace SkFixedDiv impl with native 64bit math
>
> BUG=skia:
> TBR=
>
> Committed: https://skia.googlesource.com/skia/+/7c44ca926bf42b3b2e56131f250c0fd58f87ac71

TBR=
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:

Review URL: https://codereview.chromium.org/1018523008
2015-03-19 04:10:42 -07:00
reed
562d0e1cd2 remove unused SkXRay functions
BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/1016263002
2015-03-18 19:32:47 -07:00
reed
7c44ca926b replace SkFixedDiv impl with native 64bit math
BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/1022543003
2015-03-18 19:04:43 -07:00
jvanverth
1a5041e446 Revert of Ensure that we use different glyph entries for regular and df text. (patchset #2 id:20001 of https://codereview.chromium.org/1020593003/)
Reason for revert:
Bad glyphs in dftext GM.

Original issue's description:
> Ensure that we use different glyph entries for regular and df text.
>
> Currently if we switch between regular text and df text while using
> the same GrContext, they may use the same entry in the Ganesh font cache,
> which is incorrect. This change ensures that they will have different entries.
>
> Committed: https://skia.googlesource.com/skia/+/8dc58edd71c11f232860724dfa3b566895478034

TBR=joshualitt@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1011403005
2015-03-18 15:14:05 -07:00
jvanverth
8dc58edd71 Ensure that we use different glyph entries for regular and df text.
Currently if we switch between regular text and df text while using
the same GrContext, they may use the same entry in the Ganesh font cache,
which is incorrect. This change ensures that they will have different entries.

Review URL: https://codereview.chromium.org/1020593003
2015-03-18 14:46:38 -07:00
mtklein
905d01b95a temporarily stifle Math test on TSAN bot
BUG=skia:3562

Review URL: https://codereview.chromium.org/1017283002
2015-03-18 14:06:56 -07:00
egdaniel
df60355438 Remove recent changes to use temp fbo to do stencil clears.
In order to implement these stencil clears we had to use a work around where we
would bind a color buffer renderbuffer to the fbo before clearing the stencil buffer.
However this workaround seems to cause the win 7 hd2000 machines to all crash on some
memory access issue.

For now we will comment on the change and go back to the old world

BUG=skia:

Review URL: https://codereview.chromium.org/1015223002
2015-03-18 13:26:11 -07:00
senorblanco
4a22a433bf Bump picture version for uniqueID-less SkImageFilter.
Remove writing of the uniqueID, and put reading behind a version check.

BUG=skia:3559

Review URL: https://codereview.chromium.org/1010433003
2015-03-18 13:14:54 -07:00
egdaniel
d803f2731f Revert of Improve tracking of bound FBOs in GrGLGpu. (patchset #17 id:320001 of https://codereview.chromium.org/949263002/)
Reason for revert:
Perf regression on win8 hd7700 gpu skps

Original issue's description:
> Improve tracking of bound FBOs in GrGLGpu.
>
> Committed: https://skia.googlesource.com/skia/+/d2ad8eb5801e2c8c0fa544a6a776bb46eedde2a0
>
> Committed: https://skia.googlesource.com/skia/+/b2af2d8b83ca4774c3b3bb1e49bc72605faa9589
>
> Committed: https://skia.googlesource.com/skia/+/0b70b86a7e9fda52ee7ebc1b9897eeaa09b9abef
>
> Committed: https://skia.googlesource.com/skia/+/6ba6fa15261be591f33cf0e5df7134e4fc6432ac
>
> Committed: https://skia.googlesource.com/skia/+/dc963b9264908f53650c40a97cff414101dd3e88
>
> Committed: https://skia.googlesource.com/skia/+/160f24ce0e8d6dd7ca80b78871e063d4f4609cfb

TBR=bsalomon@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1009563003
2015-03-18 13:01:52 -07:00
msarett
f21ef2776b Do not create empty color table if it does not exist
BUG=skia:

Review URL: https://codereview.chromium.org/1019543003
2015-03-18 12:59:46 -07:00
reed
422677ceab Add Load2/store2 to Sk4x (dumb impl for now)
patch from issue 1001003002 at patchset 1 (http://crrev.com/1001003002#ps1)

BUG=skia:

Review URL: https://codereview.chromium.org/1001453006
2015-03-18 12:56:46 -07:00
senorblanco
24e06d5244 Remove uniqueID from all filter serialization.
(This is essentially a revert of https://codereview.chromium.org/503833002/.)

This was necessary back when SkPaint was flattened even for in-process use. Now that we only flatten SkPaint for cross-process use, there's no need to serialize UniqueIDs.

Note: SkDropShadowImageFilter is being constructed with a croprect and UniqueID (of 0) in Blink. I've made the uniqueID param default to 0 temporarily, until this rolls in and Blink can be changed. (Blink can't be changed first, since unlike the other filters, there's no constructor that takes a cropRect but not a uniqueID.)

BUG=skia:

Review URL: https://codereview.chromium.org/1019493002
2015-03-18 12:11:33 -07:00
reed
6fbfdb1e5e extend neon table as well for gray8
BUG=skia:

Review URL: https://codereview.chromium.org/1021583002
2015-03-18 11:52:35 -07:00
joshualitt
5efb8b8407 Simple patch to have draw path call an internal drawPath
The purpose of this patch is to expose an internal draw path call which text contexts can use.

BUG=skia:

Review URL: https://codereview.chromium.org/1012143005
2015-03-18 11:49:12 -07:00
mtklein
97ca98d74e Let's find out what's up with the TSAN bot test failures.
BUG=skia:

Review URL: https://codereview.chromium.org/1020573002
2015-03-18 11:32:21 -07:00
msarett
eed039b5ff Adding swizzles for bmp:
We now support kN32 and kRGB_565 color types.
    Additionally, we support premul, unpremul, and opaque alpha types.
    Unpremul is currently untested as we cannot currently draw to unpremul.

BUG=skia:

Review URL: https://codereview.chromium.org/1013743003
2015-03-18 11:11:19 -07:00
djsollen
c88e115087 Update to identically match the sources used on Android
Review URL: https://codereview.chromium.org/1020563002
2015-03-18 10:58:02 -07:00
scroggo
fffeedefbb Implement SkCodec::getScaledDimensions.
Left out of a prior CL since no one was calling it...

Review URL: https://codereview.chromium.org/995303004
2015-03-18 10:50:37 -07:00
mtklein
f94fa7112f SkPMFloat: avoid loads and stores where possible.
A store/load pair like this is a redundant no-op:
  store simd_register_a, memory_address
  load  memory_address, simd_register_a

Everyone seems to be good at removing those when using SSE, but GCC and Clang
are pretty terrible at this for NEON.  We end up issuing both redundant
commands, usually to and from the stack.  That's slow.  Let's not do that.

This CL unions in the native SIMD register type into SkPMFloat, so that we can
assign to and from it directly, which is generating a lot better NEON code.  On
my Nexus 5, the benchmarks improve from 36ns to 23ns.

SSE is just as fast either way, but I paralleled the NEON code for consistency.
It's a little terser.  And because it needed the platform headers anyway, I
moved all includes into SkPMFloat.h, again only for consistency.

I'd union in Sk4f too to make its conversion methods a little clearer,
but MSVC won't let me (it has a copy constructor... they're apparently not up
to speed with C++11 unrestricted unions).

BUG=skia:

Review URL: https://codereview.chromium.org/1015083004
2015-03-18 09:51:24 -07:00
bungeman
6f94076da5 Restore GDI text size rounding.
Add call to SkScalarRoundToScalar(). The old code calculated the scale
from the text size, but now the text size is calculated from the scale
(which is arguably the right way to think about it). However, the old
code always rounded the final resulting text size, while the new code
does not.

In the 'no hinting' case, the text size is already rounded to an integer
(so that the rest of the matrix is minimized). In the 'hinted' case, the
entire scale has been removed from the matrix, so the scale value is the
'real' residual size. The old code rounded this size, and the new code
should as well.

BUG=464784

Review URL: https://codereview.chromium.org/1014953002
2015-03-18 08:25:43 -07:00
scroggo
b267fd629b Add comment describing SkColorTable constructor.
Review URL: https://codereview.chromium.org/1011263002
2015-03-18 08:00:27 -07:00
dml
78acf96a67 Indexed PNG decoding: Ensure color table is large enough that the bit depth of the image will not allow reads beyond its end.
BUG=skia:3440
R=rmistry@google.com, scroggo@google.com

Committed: https://skia.googlesource.com/skia/+/493c1ce1cd406ef28683203146274154783452ce

Review URL: https://codereview.chromium.org/948163002
2015-03-18 06:03:30 -07:00
Ravi Mistry
8188840141 Whitespace change to test new GCE compile bot 2015-03-18 08:50:30 -04:00
mtklein
b37cb41a8b Display currently running tests as the keepalive message.
...
( 466MB   550) 31.9ms   gpu gm colorwheelnative
( 466MB   549) 50.1ms   gpu gm colorwheel
( 468MB   548) 512ms    gpu gm colortype_xfermodes
Currently running:
    unit test PathOpsRectsThreaded
    unit test PathOpsSimplifyDegeneratesThreaded
    unit test PathOpsSimplifyQuadralateralsThreaded
    gpu gm colortype

( 468MB   547) 90.8ms   gpu gm colortype
( 469MB   546) 2.03s    unit test PathOpsSimplifyDegeneratesThreaded
...

BUG=skia:

Review URL: https://codereview.chromium.org/1017903002
2015-03-18 05:27:14 -07:00
reed
0c9b1a8d05 add kGray_8_SkColorType
patch from issue 1014783003 at patchset 60001 (http://crrev.com/1014783003#ps60001)

BUG=skia:
TBR=

Review URL: https://codereview.chromium.org/1010343002
2015-03-17 17:44:07 -07:00
bsalomon
160f24ce0e Improve tracking of bound FBOs in GrGLGpu.
Committed: https://skia.googlesource.com/skia/+/d2ad8eb5801e2c8c0fa544a6a776bb46eedde2a0

Committed: https://skia.googlesource.com/skia/+/b2af2d8b83ca4774c3b3bb1e49bc72605faa9589

Committed: https://skia.googlesource.com/skia/+/0b70b86a7e9fda52ee7ebc1b9897eeaa09b9abef

Committed: https://skia.googlesource.com/skia/+/6ba6fa15261be591f33cf0e5df7134e4fc6432ac

Committed: https://skia.googlesource.com/skia/+/dc963b9264908f53650c40a97cff414101dd3e88

Review URL: https://codereview.chromium.org/949263002
2015-03-17 15:55:42 -07:00
Brian Salomon
9251d4e9c6 Use sample count for temp renderbuffer when clearing stenci
TBR=robertphillips@google.com

Review URL: https://codereview.chromium.org/1016903002
2015-03-17 16:03:19 -04:00
mtklein
e2aab90979 DM: disable image src type on Windows.
BUG=skia:

Review URL: https://codereview.chromium.org/1012183002
2015-03-17 12:52:16 -07:00
bsalomon
5cd020f27b Revert of Improve tracking of bound FBOs in GrGLGpu. (patchset #16 id:300001 of https://codereview.chromium.org/949263002/)
Reason for revert:
locally hit assert.

Original issue's description:
> Improve tracking of bound FBOs in GrGLGpu.
>
> Committed: https://skia.googlesource.com/skia/+/d2ad8eb5801e2c8c0fa544a6a776bb46eedde2a0
>
> Committed: https://skia.googlesource.com/skia/+/b2af2d8b83ca4774c3b3bb1e49bc72605faa9589
>
> Committed: https://skia.googlesource.com/skia/+/0b70b86a7e9fda52ee7ebc1b9897eeaa09b9abef
>
> Committed: https://skia.googlesource.com/skia/+/6ba6fa15261be591f33cf0e5df7134e4fc6432ac
>
> Committed: https://skia.googlesource.com/skia/+/dc963b9264908f53650c40a97cff414101dd3e88

TBR=egdaniel@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true

Review URL: https://codereview.chromium.org/1017803002
2015-03-17 12:46:56 -07:00
bsalomon
dc963b9264 Improve tracking of bound FBOs in GrGLGpu.
Committed: https://skia.googlesource.com/skia/+/d2ad8eb5801e2c8c0fa544a6a776bb46eedde2a0

Committed: https://skia.googlesource.com/skia/+/b2af2d8b83ca4774c3b3bb1e49bc72605faa9589

Committed: https://skia.googlesource.com/skia/+/0b70b86a7e9fda52ee7ebc1b9897eeaa09b9abef

Committed: https://skia.googlesource.com/skia/+/6ba6fa15261be591f33cf0e5df7134e4fc6432ac

Review URL: https://codereview.chromium.org/949263002
2015-03-17 12:33:33 -07:00
bsalomon
9d2049db6e Add stencil-only clear bug workaround back but for all devices.
TBR=robertphillips@google.com

Review URL: https://codereview.chromium.org/1010253002
2015-03-17 12:06:19 -07:00
mtklein
eec84e324e Current RSS on linux and android too?
BUG=skia:

Review URL: https://codereview.chromium.org/1009313003
2015-03-17 10:24:49 -07:00
halcanary
5721c9b4a7 Doc: htmlify roles table to allow easier modification
TODO: make sure the table is up to date.
NOTRY=true
DOCS_PREVIEW= https://skia.org/?cl=1011753004

Review URL: https://codereview.chromium.org/1011753004
2015-03-17 09:56:33 -07:00
reed
706d98ef5b imagefilters always need to disable lcd
This prev CL accidentally stopped forcing (indirectly) the pixel-geometry to unknown. https://codereview.chromium.org/1010503002

BUG=467882

Review URL: https://codereview.chromium.org/1012113002
2015-03-17 08:34:38 -07:00
bungeman
d709ea8d14 Remove SkLONGLONG.
All users now define SkLONGLONG.
This fixes a long outstanding TODO now that int64_t is required.

BUG=skia:179

Review URL: https://codereview.chromium.org/1000933003
2015-03-17 07:23:39 -07:00
scroggo
cdeca44619 Revert "Indexed PNG decoding: Ensure color table is large enough that the bit depth of the image will not allow reads beyond its end."
This reverts commit 493c1ce1cd.

NOTRY=true
NOTREECHECKS=true
TBR=egdaniel@google.com,dml@google.com
BUG=skia:

Review URL: https://codereview.chromium.org/1014553003
2015-03-17 05:25:54 -07:00
Leon Scroggins III
493c1ce1cd Indexed PNG decoding: Ensure color table is large enough that the bit depth of the image will not allow reads beyond its end.
BUG=skia:3440
R=rmistry@google.com, scroggo@google.com

Review URL: https://codereview.chromium.org/948163002
2015-03-17 08:14:07 -04:00
scroggo
9552662e9f Option for SkCodec to treat dst as all zeroes.
This recreates SkImageDecoder's feature to skip writing zeroes for
SkCodec.

Review URL: https://codereview.chromium.org/980903002
2015-03-17 05:02:17 -07:00
cdalton
d0a840d4d8 Disable GL_MULTISAMPLE when it's not being used
Updates Gr to disable GL_MULTISAMPLE when drawing to an aliased render
target. This is an important step for NV_framebuffer_mixed_samples,
where just because the color buffer isn't multisampled doesn't mean
other stages in the graphics pipeline aren't. It also removes the need
for the "isLineDraw" workaround that was in GrGLGpu::flushHWAAState.

BUG=skia:

Review URL: https://codereview.chromium.org/1002013006
2015-03-16 17:19:58 -07:00
mtklein
18ef5ebf3b widen leak supression. looks like start_keepalive is sometimes inlined.
BUG=skia:

Review URL: https://codereview.chromium.org/1008873003
2015-03-16 15:06:00 -07:00