bsalomon
28b62e6672
Simplify random_draw_context used by GLProgramsTest
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2165683002
Review-Url: https://codereview.chromium.org/2165683002
2016-07-19 08:38:04 -07:00
reed
7f3ff20843
remove unused MakeFromPixmap
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2158913004
TBR=robertphilips@google.com
Review-Url: https://codereview.chromium.org/2158913004
2016-07-19 08:26:09 -07:00
mtklein
f037d48e29
GN: refactor third_party/gni
...
This fixes the build on Linux (dep on third_party:zlib -> third_party/zlib).
I've moved declare_args() {} back to each .gn file... seems like args want
to be as local as possible in GN land.
Additionally, refactor all the common third_party config and warning flag
changes into a template, third_party. This lets it all live together in a
.gni: at head unwanted_configs can be in a .gni (it's just a variable) but
config("no_warnings") (and thus third_party_configs) cannot, as configs
cannot be part of .gni files.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163653002
Review-Url: https://codereview.chromium.org/2163653002
2016-07-19 08:25:00 -07:00
bsalomon
916e02a6d0
Start from DC rather than texture in GrTexutreParamsAdjuster copy code.
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2158383002
Review-Url: https://codereview.chromium.org/2158383002
2016-07-19 08:12:30 -07:00
brianosman
c4459f6a33
Fix debugging code for tracing texture creation
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2164623002
Review-Url: https://codereview.chromium.org/2164623002
2016-07-19 08:02:21 -07:00
robertphillips
e34f17d236
Make SkFont a bit more useable
...
Split out of https://codereview.chromium.org/2163483002/ (Use SkFont in GrStencilAndCoverTextContext)
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163633002
Review-Url: https://codereview.chromium.org/2163633002
2016-07-19 07:59:22 -07:00
bsalomon
b117ff194f
Convert readSurfacePixels to use a draw context instead of a texture
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2165523003
Review-Url: https://codereview.chromium.org/2165523003
2016-07-19 07:24:40 -07:00
bsalomon
23c4f1acbc
Fix GrGLInterface::validate() to check for GL_OES_sample_shading on ES contexts
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2156343004
Review-Url: https://codereview.chromium.org/2156343004
2016-07-19 06:21:55 -07:00
fmalita
01c97230f8
Delete the legacy SVG parser
...
Unused.
R=reed@google.com ,robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2154193003
CQ_INCLUDE_TRYBOTS=master.client.skia.compile:Build-Ubuntu-GCC-x86_64-Release-CMake-Trybot,Build-Mac-Clang-x86_64-Release-CMake-Trybot
Review-Url: https://codereview.chromium.org/2154193003
2016-07-19 06:12:54 -07:00
mtklein
e817ddf9b3
GN: polyfill is_fuchsia
...
I'll tell you what, I need to practice typing fuchsia out a few hundred
times... I managed to spell it three different ways in this CL.
Plus, gn format BUILD.gn
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2164453003
Review-Url: https://codereview.chromium.org/2164453003
2016-07-19 06:03:22 -07:00
fmalita
fd75dd4086
Delete SkXMLPullParser
...
Unused & not being built.
R=reed@google.com ,robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2163463002
Review-Url: https://codereview.chromium.org/2163463002
2016-07-19 05:14:41 -07:00
robertphillips
5139e501c5
Rename variables in SkCanvas::internalSaveLayer
...
This is split out of https://codereview.chromium.org/2145343005/ (Recast draw_filter_into_device as drawDevice) to, hopefully, make it easier to integrate that CL
TBR=reed@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2162883002
Review-Url: https://codereview.chromium.org/2162883002
2016-07-19 05:10:40 -07:00
kolczyk
718aab1e3f
Fix the assert and clamping in SkMatrix::get*Scale[s]().
...
Follow-up after https://codereview.chromium.org/2143133005/ .
BUG=skia:4718
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2154123003
Review-Url: https://codereview.chromium.org/2154123003
2016-07-19 03:49:14 -07:00
msarett
2812f03d54
Fix rewinding bug in SkJpegCodec
...
Performing a sampled and/or subset decode will create some state
in SkJpegCodec. If we fail to clean up this state properly,
subsequent decodes may try to reuse (and potentailly overflow)
the leftover memory.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2161593003
Committed: https://skia.googlesource.com/skia/+/4ecb8ab556214c9337f56bc36d50e4d7c655ac7a
Review-Url: https://codereview.chromium.org/2161593003
2016-07-18 15:56:08 -07:00
bungeman
401ae2d2a0
Rotate bitmap strikes with FreeType.
...
BUG=skia:3490
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2139703002
Committed: https://skia.googlesource.com/skia/+/31e0c1379e6d0ce48196183e295b929af51fa74e
Review-Url: https://codereview.chromium.org/2139703002
2016-07-18 15:46:28 -07:00
msarett
db00a2a9eb
Revert of Fix rewinding bug in SkJpegCodec (patchset #1 id:1 of https://codereview.chromium.org/2161593003/ )
...
Reason for revert:
Breaking Google3 build. Will reland corrected version.
Original issue's description:
> Fix rewinding bug in SkJpegCodec
>
> Performing a sampled and/or subset decode will create some state
> in SkJpegCodec. If we fail to clean up this state properly,
> subsequent decodes may try to reuse (and potentailly overflow)
> the leftover memory.
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2161593003
>
> Committed: https://skia.googlesource.com/skia/+/4ecb8ab556214c9337f56bc36d50e4d7c655ac7a
TBR=djsollen@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/2155163004
2016-07-18 15:19:48 -07:00
bsalomon
7890b89418
Remove guards in GrGLInterface::validate() for functions that Chromium used to not provide.
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2158983002
Review-Url: https://codereview.chromium.org/2158983002
2016-07-18 14:59:05 -07:00
robertphillips
640789d64b
Push GrPipelineBuilder down to the drawBatch calls in the TextContext
...
This is split out of https://codereview.chromium.org/2092893003/ (Retract PipelineBuilder some more)
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2155983003
Review-Url: https://codereview.chromium.org/2155983003
2016-07-18 14:56:06 -07:00
fmalita
125845553b
[SkXMLParser] Initial text node support
...
Also disable entity processing.
R=bungeman@google.com ,robertphillips@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2154853002
Review-Url: https://codereview.chromium.org/2154853002
2016-07-18 14:47:30 -07:00
fmenozzi
d876a4b549
Add bounds info
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2159853003
Review-Url: https://codereview.chromium.org/2159853003
2016-07-18 13:33:37 -07:00
reed
01a2ff8a32
check for culled-out paths inside SkDraw
...
BUG=629026
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2155213002
Review-Url: https://codereview.chromium.org/2155213002
2016-07-18 13:22:55 -07:00
caryclark
034f243c6d
disable test that fails to compute bounds on nexus 5
...
TBR=jcgregario@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2160713003
Review-Url: https://codereview.chromium.org/2160713003
2016-07-18 12:13:23 -07:00
caryclark
c6b842b76b
disable new test since it fails on skia_fast
...
TBR=jcgregario@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2155243002
Review-Url: https://codereview.chromium.org/2155243002
2016-07-18 11:28:44 -07:00
mtklein
b435963a01
Tweak a couple things I found confusing in ColorSpaceXform unit tests.
...
No coverage changes... just refactoring.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2158033002
Review-Url: https://codereview.chromium.org/2158033002
2016-07-18 11:16:14 -07:00
fmalita
a427cc4d6b
Remove SkDOM::build(const char doc[], size_t len)
...
This flavor is unused, and we have the more general SkStream API.
R=stephana@google.com ,reed@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2154733003
Review-Url: https://codereview.chromium.org/2154733003
2016-07-18 10:56:43 -07:00
brianosman
54f30c13fc
Introduce GrColorSpaceXform, for gamut conversion on textures
...
GrTextureAccess optionally includes an instance, computed from the src
and dst color spaces. In all common cases (no color space for either src
or dst, or same color space for both), no object is allocated.
This change is orthogonal to my attempts to get color space attached to
render targets - regardless of how we choose to do that, this will give
us the source color space at all points where we are connecting src to
dst.
There are many dangling injection points where I've been inserting
nullptr, but I have a record of all of them. Additionally, there are now
three places (the most common simple paths for bitmap/image rendering)
where things are plumbed enough that I expect to have access to the dst
color space (all marked with XFORMTODO).
In addition to getting the dst color space, I need to inject shader code
and uniform uploading for appendTextureLookup and friends.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2154753003
Review-Url: https://codereview.chromium.org/2154753003
2016-07-18 10:53:52 -07:00
borenet
baaea531c2
Convert SK Images to new assets format
...
Depends on https://codereview.chromium.org/2162563002/
BUG=skia:5427
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2155163002
Review-Url: https://codereview.chromium.org/2155163002
2016-07-18 10:36:43 -07:00
msarett
4ecb8ab556
Fix rewinding bug in SkJpegCodec
...
Performing a sampled and/or subset decode will create some state
in SkJpegCodec. If we fail to clean up this state properly,
subsequent decodes may try to reuse (and potentailly overflow)
the leftover memory.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2161593003
Review-Url: https://codereview.chromium.org/2161593003
2016-07-18 10:28:41 -07:00
bsalomon
0b300498b1
Initialize fGammaCorrect in DF Path Renderer unit test
...
TBR=jvanverth@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2157933003
Review-Url: https://codereview.chromium.org/2157933003
2016-07-18 10:09:41 -07:00
caryclark
55888e4417
pathops coincidence and security rewrite
...
Most changes stem from working on an examples bracketed
by #if DEBUG_UNDER_DEVELOPMENT // tiger
These exposed many problems with coincident curves,
as well as errors throughout the code.
Fixing these errors also fixed a number of fuzzer-inspired
bug reports.
* Line/Curve Intersections
Check to see if the end of the line nearly intersects
the curve. This was a FIXME in the old code.
* Performance
Use a central chunk allocator.
Plumb the allocator into the global variable state
so that it can be shared. (Note that 'SkGlobalState'
is allocated on the stack and is visible to children
functions but not other threads.)
* Refactor
Let SkOpAngle grow up from a structure to a class.
Let SkCoincidentSpans grow up from a structure to a class.
Rename enum Alias to AliasMatch.
* Coincidence Rewrite
Add more debugging to coincidence detection.
Parallel debugging routines have read-only logic to report
the current coincidence state so that steps through the
logic can expose whether things got better or worse.
More functions can error-out and cause the pathops
engine to non-destructively exit.
* Accuracy
Remove code that adjusted point locations. Instead,
offset the curve part so that sorted curves all use
the same origin.
Reduce the size (and influence) of magic numbers.
* Testing
The debug suite with verify and the full release suite
./out/Debug/pathops_unittest -v -V
./out/Release/pathops_unittest -v -V -x
expose one error. That error is captured as cubics_d3.
This error exists in the checked in code as well.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2128633003
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2128633003
Review-Url: https://codereview.chromium.org/2128633003
2016-07-18 10:01:36 -07:00
robertphillips
6451a0cea6
Add makeSpecial calls to SkGpuDevice
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2161533003
Review-Url: https://codereview.chromium.org/2161533003
2016-07-18 08:31:31 -07:00
fmenozzi
f023e6879c
Add filename to gradient scrape
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2160583002
Review-Url: https://codereview.chromium.org/2160583002
2016-07-18 08:20:06 -07:00
jcgregorio
eb9a84aa57
Revert of remove unused TableMaskFilter (patchset #1 id:1 of https://codereview.chromium.org/2156463002/ )
...
Reason for revert:
Needed for Android:
frameworks/base/core/jni/android/graphics/MaskFilter.cpp:5:10: fatal error: 'SkTableMaskFilter.h' file not found
Original issue's description:
> remove unused TableMaskFilter
>
> BUG=skia:
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2156463002
>
> TBR=
>
> Committed: https://skia.googlesource.com/skia/+/59779ae8ce316bf8b8082ec2df1683ccd38161f1
TBR=reed@google.com
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=skia:
Review-Url: https://codereview.chromium.org/2156183002
2016-07-18 08:18:51 -07:00
bsalomon
0ae36a2ceb
In GrShape detect that stroked axis-aligned lines are rrects.
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2151313002
Review-Url: https://codereview.chromium.org/2151313002
2016-07-18 07:31:13 -07:00
msarett
490c07d776
Test auto merger
...
TBR=djsollen@google.com
NOTRY=true
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2158793004
Review-Url: https://codereview.chromium.org/2158793004
2016-07-18 07:21:44 -07:00
update-skps
eaf6d41022
Update SKP version
...
Automatic commit by the RecreateSKPs bot.
TBR=
NO_MERGE_BUILDS
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2157823002
Review-Url: https://codereview.chromium.org/2157823002
2016-07-17 01:02:55 -07:00
kolczyk
cea22ae234
Guard SkMatrix::get*Scale[s]() against negative nearly-zero values.
...
BUG=skia:4718
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2143133005
Review-Url: https://codereview.chromium.org/2143133005
2016-07-16 11:52:37 -07:00
bungeman
280d537e28
Revert of Rotate emoji with FreeType. (patchset #5 id:80001 of https://codereview.chromium.org/2139703002/ )
...
Reason for revert:
Causing roll to fail on telemetry_perf_unittests (bencharks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_health.memory_desktop.load:search:taobao (and baidu)) and browser_tests (FindInPageControllerTest.FindInPageSpecialURLS).
This is due to triggering the assert in copyFTBitmap
SkASSERT(dstMask.fBounds.width() == static_cast<int>(srcFTBitmap.width));
when called from inside the block guarded by
if (bitmapTransform.isIdentity())
Original issue's description:
> Rotate bitmap strikes with FreeType.
>
> BUG=skia:3490
> GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2139703002
>
> Committed: https://skia.googlesource.com/skia/+/31e0c1379e6d0ce48196183e295b929af51fa74e
TBR=mtklein@google.com ,reed@google.com
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=skia:3490
Review-Url: https://codereview.chromium.org/2149253005
2016-07-15 18:49:42 -07:00
abarth
6fc8ff024b
Add support for Fuchsia
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2152273002
[mtklein edit from here down]
No public API changes.
TBR=reed@google.com
Review-Url: https://codereview.chromium.org/2152273002
2016-07-15 15:15:15 -07:00
bungeman
31e0c1379e
Rotate bitmap strikes with FreeType.
...
BUG=skia:3490
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2139703002
Review-Url: https://codereview.chromium.org/2139703002
2016-07-15 14:55:35 -07:00
reed
7503d60847
move responsibility for creating raster-device into pdf
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146333004
NOTRY=True
win failure seems unrelated
Review-Url: https://codereview.chromium.org/2146333004
2016-07-15 14:23:30 -07:00
msarett
80d46ccb28
Speculatively fix Android automerger
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2155713004
Review-Url: https://codereview.chromium.org/2155713004
2016-07-15 14:18:49 -07:00
msarett
9ce3a543c9
Add capability for SkColorXform to output half floats
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2147763002
CQ_INCLUDE_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot;master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot
Review-Url: https://codereview.chromium.org/2147763002
2016-07-15 13:54:38 -07:00
egdaniel
7ac5da8534
Dont allocate a new image which already has mip levels, when regenerating vulkan mipmaps
...
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146063008
Review-Url: https://codereview.chromium.org/2146063008
2016-07-15 13:41:42 -07:00
halcanary
eb92cb3e84
SkPdf: smaller color serialization
...
SkPDFUtils now has a special function (SkPDFUtils::AppendColorComponent)
just for writing out (color/255) as a decimal with three digits of
precision.
SkPDFUnion now has a type to represent a color component. It holds a
utint_8, but calls into AppendColorComponent to serialize.
Added a unit test that tests all possible input values.
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2151863003
Review-Url: https://codereview.chromium.org/2151863003
2016-07-15 13:41:28 -07:00
halcanary
f0c30f5566
SkPDF: Join Positioned Text
...
When N sequential positioned glyphs differ in positions by exactly the
advances of the first (N-1) glyphs, join the glyphs into a string
rather than changing the text matrix between each glyph draw.
Decreases PDF output size by about ~1.4%. Potentially more on
text-heavy pages.
A single-typeface PDF of an 27kB ASCII document shaped with harfbuzz:
before: 187743 Bytes
after: 65513 Bytes
difference: -65.1%
Before:
BT
/F0 13 Tf
1 0 0 -1 143.5 61 Tm
<0029> Tj
1 0 0 -1 150.634765 61 Tm
<004C> Tj
1 0 0 -1 154.602050 61 Tm
<0055> Tj
1 0 0 -1 160.245117 61 Tm
<0048> Tj
1 0 0 -1 167.925781 61 Tm
<004B> Tj
1 0 0 -1 176.469726 61 Tm
<0052> Tj
1 0 0 -1 184.518554 61 Tm
<0056> Tj
1 0 0 -1 190.980468 61 Tm
<0048> Tj
ET
After:
BT
/F0 13 Tf
1 0 0 -1 0 0 Tm
143.5 -61 Td <0029004C0055> Tj
16.7451171 0 Td <0048004B005200560048> Tj
ET
Also: update the Text matrix with the `Td` operator, instead of
overwriting it with the the `Tm` operator. In the worst case, when
every glyph is positioned differently than it's advance, this still
makes the command stream smaller:
Before:
...
1 0 0 -1 58.328125 660 Tm <0055> Tj
1 0 0 -1 61.609375 660 Tm <004C> Tj
1 0 0 -1 63.828125 660 Tm <0056> Tj
...
After:
...
3.140625 0 Td <0055> Tj
3.28125 0 Td <004C> Tj
2.21875 0 Td <0056> Tj
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2150393002
Review-Url: https://codereview.chromium.org/2150393002
2016-07-15 13:35:45 -07:00
halcanary
39f988eb41
SkPDF: Always give a default advance for glyphs.
...
Prior to this we assumed the default default was 0. It is
actually 1000, according to the spec.
fixes BUG=skia:5321
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2146403005
Review-Url: https://codereview.chromium.org/2146403005
2016-07-15 12:54:30 -07:00
djsollen
ec58b86437
Fix broken Android framework build.
...
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2153953002
Review-Url: https://codereview.chromium.org/2153953002
2016-07-15 12:52:34 -07:00
robertphillips
04d62182fe
Add copy (when needed) to SkGpuDevice::asSpecial
...
split out of https://codereview.chromium.org/2145343005/ (Recast draw_filter_into_device as drawDevice)
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2157513002
Review-Url: https://codereview.chromium.org/2157513002
2016-07-15 12:21:33 -07:00
benjaminwagner
921e48bf23
Exclude XML and dependencies from Bazel build.
...
Depends on https://codereview.chromium.org/2150353002
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2147303004
Review-Url: https://codereview.chromium.org/2147303004
2016-07-15 11:27:27 -07:00