Commit Graph

13257 Commits

Author SHA1 Message Date
yunchao.he
2bff230d83 round and bevel hairline rects show the same as miter hairline rects
So round and bevel hairline rects can generate the vertices and indices the same as miter rects do. The original code behaves the same as bevel rects for round and bevel hairline rects.

This small CL can save (vertices and indices) buffer memory as well as improve performance (draw less triangles).

gm cases show no difference after this CL is applied.

BUG=skia:
R=robertphillips@google.com

Author: yunchao.he@intel.com

Review URL: https://codereview.chromium.org/417113002
2014-07-28 19:18:49 -07:00
cdalton
15ab26d942 Rebaseline needed nvpr gms after text change
Updates a few nvpr expectations for slight pixel diffs after a change
in the math that positions glyphs.

BUG=skia:
R=jvanverth@google.com, bungeman@google.com

Author: cdalton@nvidia.com

Review URL: https://codereview.chromium.org/421423002
2014-07-28 15:39:06 -07:00
krajcevski
d5e46c7893 Generalize compressed blitter into its own templated class
R=robertphillips@google.com

Author: krajcevski@google.com

Review URL: https://codereview.chromium.org/421593004
2014-07-28 14:14:16 -07:00
bsalomon
2354f8432a Test abandoning GL context in dm/nanobench.
Rename GrContext::contextDestroyed to GrContext::abandonContext.

Remove GrContext::resetContext.

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/422903002
2014-07-28 13:48:36 -07:00
bsalomon
4beef91ec0 Revert of Remove relative path to GrColor.h in SkShader.h (https://codereview.chromium.org/422023005/)
Reason for revert:
As Ben suspected, this breaks the chrome build.

Original issue's description:
> Remove relative path to GrColor.h in SkShader.h
>
> Committed: https://skia.googlesource.com/skia/+/939f430f660d26e46116a38d2a8436afbd55dfb9

R=bungeman@google.com, george@mozilla.com
TBR=bungeman@google.com, george@mozilla.com
NOTREECHECKS=true
NOTRY=true

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/423943005
2014-07-28 13:43:04 -07:00
bsalomon
939f430f66 Remove relative path to GrColor.h in SkShader.h
R=bungeman@google.com, george@mozilla.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/422023005
2014-07-28 13:27:35 -07:00
halcanary
186e699efe disable new test on windows
R=bensong@google.com, djsollen@google.com
TBR=bensong@google.com, djsollen@google.com
CQ_EXTRA_TRYBOTS=tryserver.skia:Test-Win7-ShuttleA-HD2000-x86_64-Release-Trybot
NOTREECHECKS=true

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/424833002
2014-07-28 10:54:26 -07:00
halcanary
b1ab5fdd11 If decoder doesn't ouput indexed color, don't check colortable
R=djsollen@google.com, bungeman@google.com
TBR=bungeman@google.com, djsollen@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/427593002
2014-07-28 08:56:35 -07:00
halcanary
7f8aad84de SkDiscardablePixelRef returns correct indexed color on relock.
R=djsollen@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/428603002
2014-07-28 08:23:55 -07:00
bungeman
edb10e79f5 Only lowercase names in Android font config parser.
BUG=chromium:397549
R=tomhudson@chromium.org, tomhudson@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/420223003
2014-07-28 08:19:45 -07:00
djsollen
5a27f49a87 Remove code only used by SkCreateTypefaceForScript which has already been deleted
R=tomhudson@google.com, bungeman@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/425753002
2014-07-28 07:44:55 -07:00
halcanary
a98683bc50 dm prints out number of matching skp files
R=bungeman@google.com, mtklein@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/421713002
2014-07-28 07:21:24 -07:00
Derek Sollenberger
9ee1a4a460 Remove redundant helper function as all clients pass locale
R=tomhudson@google.com

Review URL: https://codereview.chromium.org/426643003
2014-07-28 10:04:55 -04:00
Derek Sollenberger
e83a7ecfd7 Remove unused code now that the android framework has move this logic elsewhere.
R=tomhudson@google.com

Review URL: https://codereview.chromium.org/424663005
2014-07-28 09:54:10 -04:00
borenet
e5ad0dde25 Update SKP version to 60
Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/420133002
2014-07-26 22:45:10 -07:00
borenet
a522b0ed33 Update SKP version to 59
Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/422643002
2014-07-26 00:32:37 -07:00
jvanverth
feceba5e2d Add vertex color support to distance field text.
BUG=skia:
R=bsalomon@google.com

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/421563002
2014-07-25 19:03:34 -07:00
jvanverth
f17bc6cf7a Move vertex buffer setup out of drawPackedGlyph().
This gets a very welcome ~10% speedup on my Mac.

Committed: https://skia.googlesource.com/skia/+/1d38619389cc1100bd516b9acbf17b7bd42d33ce

R=bsalomon@google.com

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/414573002
2014-07-25 16:46:53 -07:00
bungeman
1ef960b01b Fix thread unsafe mutex initialization.
BUG=skia:2779

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

R=robertphillips@google.com, mtklein@google.com, reed@android.com, bsalomon@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/419113002
2014-07-25 15:11:03 -07:00
halcanary
048f422ec6 Fix crash in DM/SKPTask
R=bungeman@google.com

Author: halcanary@google.com

Review URL: https://codereview.chromium.org/416333007
2014-07-25 14:17:35 -07:00
cdalton
b2808cd041 Send less transform data when drawing text with nvpr
Before this change, GrStencilAndCoverTextContext would send 6-float
affine transforms to drawPaths for every glyph. This updates it to
concat the text scale onto the context matrix, and then only send
2-float translates (or 1-float x-translates when possible).

Also adds a glyph_pos_align test to gm that exercises the newly added
codepaths, and starts ignoring a few gm tests with benign pixel diffs
until we can rebaseline.

BUG=skia:
R=bsalomon@google.com, kkinnunen@nvidia.com, jvanverth@google.com, bungeman@google.com

Author: cdalton@nvidia.com

Review URL: https://codereview.chromium.org/406523003
2014-07-25 14:13:57 -07:00
scroggo
fc7063b3a5 Fix image decoder memory overwrite bug.
In SkPNGImageDecoder::onDecodeSubset, use png_read_rows to write to
the scratch memory provided. This is what we should have been doing
anyway. Further, writing directly to the bitmap can cause writing
to the wrong memory since the bitmap may not be as big as the
scratch memory in the case of sampling with a short bitmap.

Bug=b/13921093

R=djsollen@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/423473003
2014-07-25 13:54:43 -07:00
bungeman
d6aeb6dc8f Fix thread unsafe mutex initialization.
BUG=skia:2779
R=robertphillips@google.com, mtklein@google.com, reed@android.com, bsalomon@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/419113002
2014-07-25 11:52:48 -07:00
jvanverth
6c18c80c86 Revert of Move vertex buffer setup out of drawPackedGlyph(). (https://codereview.chromium.org/414573002/)
Reason for revert:
Breaking Ubuntu and Windows bots.

Original issue's description:
> Move vertex buffer setup out of drawPackedGlyph().
>
> This gets a very welcome ~10% speedup on my Mac.
>
> Committed: https://skia.googlesource.com/skia/+/1d38619389cc1100bd516b9acbf17b7bd42d33ce

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

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/419943002
2014-07-25 11:52:16 -07:00
jvanverth
1d38619389 Move vertex buffer setup out of drawPackedGlyph().
This gets a very welcome ~10% speedup on my Mac.

R=bsalomon@google.com

Author: jvanverth@google.com

Review URL: https://codereview.chromium.org/414573002
2014-07-25 11:31:13 -07:00
dandov
50d715476b Added classes SkPatch and SkPatchMesh which help encapsulate and generalize this new primitive. The functionality and responsability of each class is better explained in the comments of the files.
Each patch defines a method genMesh that produces the geometry to draw. To do this they receive a SkPatchMesh object which they need to initialize in order to set up how the data is going to be formatted. Later they call function like setColor or pointAt to set the values at a specific index, the SkMeshPatch object handles the indices based on the format and makes it transparent to the client.

Added a slide to sample app to show how to set up this classes and how they interact.

BUG=skia:
R=jvanverth@google.com, egdaniel@google.com, bsalomon@google.com

Author: dandov@google.com

Review URL: https://codereview.chromium.org/405163003
2014-07-25 10:44:54 -07:00
scroggo
75e62ea9d6 Fix assert in skimage test.
The width and height may not match expected width and height when
sampleSize is not 1.

R=djsollen@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/418363002
2014-07-25 10:26:32 -07:00
krajcevski
4881a4d932 Some small ASTC optimizations
R=robertphillips@google.com

Author: krajcevski@google.com

Review URL: https://codereview.chromium.org/417123003
2014-07-25 10:23:42 -07:00
bsalomon
6d3fe022d6 Rename GrGpuObject to GrGpuResource
R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/418143004
2014-07-25 08:35:45 -07:00
kelvinly
570c392a00 Fix the other microbench schema
BUG=skia:
R=bensong@google.com, jcgregorio@google.com

Author: kelvinly@google.com

Review URL: https://codereview.chromium.org/420723004
2014-07-25 08:30:11 -07:00
krajcevski
b2ef181ed6 Add preliminary ASTC encoder
R=robertphillips@google.com

Author: krajcevski@google.com

Review URL: https://codereview.chromium.org/417933005
2014-07-25 07:33:01 -07:00
bsalomon
c44be0e9e4 Merge GrGpuObject and GrCacheable.
We want to create a new base class for "meta" gr resources as part of the GrResourceCache rewrite and this is an iterim step towards that goal.s

R=robertphillips@google.com

Author: bsalomon@google.com

Review URL: https://codereview.chromium.org/414013005
2014-07-25 07:32:33 -07:00
robertphillips
730c044791 Alter Default & Software path renderers to better handle AA hairline paths
For some (as yet unknown reason) the guard in ConicPathBench that disables the path_hairline_big_AA_conic case isn't working. As an alternate fix, this CL makes the Default path renderer confess its lack of support for conics and allows the Software path renderer to handle non-AA cases. This will work but the real fix is to enable conics in the Default path renderer.

Here is the situation we're seeing in the path_hairline_big_AA_conic case:

the path is a hairline drawn with AA
the render target is multisampled (so AA on the draw gets disabled)

StencilAndCover path renderer doesn't handle hairlines
AAHairLine path renderer only handles AA paths (but can handle conics)
AAConvexPath renderer also only handles AA paths
Default path renderer only handles non-AA paths (but doesn't handle conics)
Software path renderer - was disallowed from handling non-AA paths

BUG=skia:2078
R=bsalomon@google.com

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/418073002
2014-07-25 05:52:38 -07:00
robertphillips
f7be19401b Rebaseline GN & N4 perf trigger flakes
R=borenet@google.com
TBR=borenet@google.com
NOTRY=true
NOTREECHECKS=true

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/419683005
2014-07-25 04:34:40 -07:00
borenet
75770afff8 Update SKP version to 58
Automatic commit by the RecreateSKPs bot.

TBR=

Author: borenet@google.com

Review URL: https://codereview.chromium.org/420693002
2014-07-24 22:58:09 -07:00
Brian Salomon
0925a5784c Add initial baselines for varied_text* GMs
Review URL: https://codereview.chromium.org/416983002
2014-07-24 17:23:44 -04:00
djsollen
bc89329fb5 Enable the SSSE3 compile time check on all platforms (4th attempt)
BUG=skia:2746
R=bungeman@google.com, robertphillips@google.com, mtklein@google.com

Author: djsollen@google.com

Review URL: https://codereview.chromium.org/414033002
2014-07-24 13:53:56 -07:00
epoger
57493ba62a check in empty SKP expectations for a single platform
This should trigger the http://108.170.220.120:10117/builders/Test-Mac10.8-MacMini4.1-GeForce320M-x86_64-Debug
to start recording images from the SKPs.

BUG=skia:1942
NOTRY=True
R=rmistry@google.com
TBR=rmistry

Author: epoger@google.com

Review URL: https://codereview.chromium.org/410423006
2014-07-24 11:46:47 -07:00
epoger
20fa24cb3d roll common DEPS
R=borenet@google.com
TBR=borenet

Author: epoger@google.com

Review URL: https://codereview.chromium.org/411063006
2014-07-24 10:39:01 -07:00
krajcevski
2a413df4da Add ASTC to list of alpha compressed formats
R=bsalomon@google.com, robertphillips@google.com

Author: krajcevski@google.com

Review URL: https://codereview.chromium.org/412113004
2014-07-24 08:16:01 -07:00
bungeman
8d84c99531 SkFontMgr for Android.
Committed: https://skia.googlesource.com/skia/+/4f9a01e03ef3bbe7dd8f9bebdcb3555226087e06

R=djsollen@google.com, tomhudson@google.com, robertphillips@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/414483002
2014-07-24 08:05:10 -07:00
scroggo
307bcea492 skimage expectations for Android-Reference-Unknown
Fixes build.

NOTRY=true
R=borenet@google.com, robertphillips@google.com

Author: scroggo@google.com

Review URL: https://codereview.chromium.org/416083002
2014-07-24 06:55:31 -07:00
robertphillips
a2c79fb412 Suppress Win8 raster verylargebitmap GM flakes
BUG=skia:2775

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

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/418863003
2014-07-24 05:30:39 -07:00
bungeman
f73c237291 Get additional DW font metrics when available.
BUG=chromium:395043
R=eae@chromium.org, caryclark@google.com

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/412993002
2014-07-23 13:31:07 -07:00
bungeman
2da0f85488 Revert of Enable the SSSE3 compile time check on all platforms. (https://codereview.chromium.org/403583002/)
Reason for revert:
This is blocking the roll. Chromium Windows trybots (like win_chromium_x64_rel) are crashing in the SSSE3 code (for example SkCanvasVideoRenderTest.CroppedFrame).

Original issue's description:
> Enable the SSSE3 compile time check on all platforms (3rd attempt)
>
> BUG=skia:2746
>
> Committed: https://skia.googlesource.com/skia/+/933834851f9d48fbd85b728cc92e1f0134bfaa4e

R=halcanary@google.com, mtklein@google.com, djsollen@google.com
TBR=djsollen@google.com, halcanary@google.com, mtklein@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:2746

Author: bungeman@google.com

Review URL: https://codereview.chromium.org/418523002
2014-07-23 11:28:18 -07:00
robertphillips
ddb459e746 Fix some flaky perf triggers
R=borenet@google.com
TBR=borenet@google.com
NOTRY=true
NOTREECHECKS=true

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/416483002
2014-07-23 04:55:10 -07:00
robertphillips
7b82d0f8e6 Revert of SkFontMgr for Android. (https://codereview.chromium.org/414483002/)
Reason for revert:
Reverting to unblock DEPS roll.

Original issue's description:
> SkFontMgr for Android.
>
> Committed: https://skia.googlesource.com/skia/+/4f9a01e03ef3bbe7dd8f9bebdcb3555226087e06

R=djsollen@google.com, tomhudson@google.com, bungeman@google.com
TBR=bungeman@google.com, djsollen@google.com, tomhudson@google.com
NOTREECHECKS=true
NOTRY=true

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/408143010
2014-07-22 16:36:13 -07:00
robertphillips
ba0055b290 Revert "Update fontmgr expectations."
This reverts commit ff4b56b2d5.

R=bungeman@gmail.com
TBR=bungeman@gmail.com
NOTRY=true
NOTREECHECKS=true

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/406323004
2014-07-22 16:34:38 -07:00
bungeman
ff4b56b2d5 Update fontmgr expectations. 2014-07-22 18:21:24 -04:00
piotaixr
76d5b477c9 Now able to set the localMatrix when creating a SkShader from a SkImage
BUG=skia:2771
R=junov@chromium.org, reed@chromium.org, bsalomon@chromium.org, bsalomon@google.com

Author: piotaixr@chromium.org

Review URL: https://codereview.chromium.org/409653003
2014-07-22 15:02:05 -07:00