DirectWrite can now produce system font typefaces which are variations,
so mark these as multiple masters so printing knows what to do.
BUG=chromium:697916
Change-Id: Idf09ebba3c7002a09ff2e4a2dbae13dbce4e79d4
Reviewed-on: https://skia-review.googlesource.com/12101
Commit-Queue: Ben Wagner <bungeman@google.com>
Reviewed-by: Hal Canary <halcanary@google.com>
It should be allowed for the client to upload original data to a texture via
writePixels and then we just regenerate the mipmaps. I think it also resonable
to limit this to either writting to all levels or just the top level.
Bug: skia:
Change-Id: I66943cca54c2a7187a781788653948fb69c17c68
Reviewed-on: https://skia-review.googlesource.com/11798
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Factors out a function F from_byte(U8) too.
Change-Id: Ib739ccbd509ddf25d2bfb7751ba6eaf51b16c12f
Reviewed-on: https://skia-review.googlesource.com/11791
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Motivation: We may want to make SkMultiPictureDocument.h public in the
future.
Change-Id: Ie97b88d51a179c2283155d65bcadee32178115ca
Reviewed-on: https://skia-review.googlesource.com/11402
Commit-Queue: Hal Canary <halcanary@google.com>
Reviewed-by: Herb Derby <herb@google.com>
BUG=chromium:538133
BUG=chromium:359065
Change-Id: I8208efc63579e0f1ebb77680beae2cd08cdba547
Reviewed-on: https://skia-review.googlesource.com/11681
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Hal Canary <halcanary@google.com>
I think this happens to fix the particular issue in the attached bug.
memcpy() is kind of the swiss army knife as far as strict aliasing is
concerned... you're always allowed to use it.
The generated code for writeToMemory() is unchanged, and
readFromMemory() gets a bit better looking.
BUG=skia:5105
Change-Id: Ib5bf96600f1138650c004ced2d696e9a4ba83ca7
Reviewed-on: https://skia-review.googlesource.com/11682
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
I don't think we've tried this since switching to GN,
where we decided to just go with jsimd_none.c on all x86 bots.
CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-MSAN,Perf-Ubuntu-Clang-GCE-CPU-AVX2-x86_64-Debug-MSAN
BUG=skia:4550
Change-Id: Iff4be3b640fb77d1094565a5db4d32778e7f2b4f
Reviewed-on: https://skia-review.googlesource.com/11680
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Here we use 64-bit gather instructions for HSW,
which I think we haven't done before.
Change-Id: I7b22b3cc0b7a151952518bb9afb90624ebdb4a22
Reviewed-on: https://skia-review.googlesource.com/11602
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Change-Id: Iefa8044bac0555c5fff370217a6270b4f3c64300
Reviewed-on: https://skia-review.googlesource.com/11582
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This is all the gathers except index 8 and f16, which aren't conceptually hard
but I want to land separately.
Change-Id: I525f2496e55451041bd6ea07985858fda7b56a40
Reviewed-on: https://skia-review.googlesource.com/11524
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
boxBlurInterp showed up hot when running Speedometer. I noticed that
BoxBlur calls boxBlurInterp repeatedly, the call does not get inlined,
and the function could be simplified a bit if 'transpose' is a
compile-time constant.
In particular, dst_x_stride or dst_y_stride now become a constant 1,
which simplifies the dptr updates.
Bug: skia:none
Change-Id: I8782e5b133a2195328e13878aca8a749af150b86
Reviewed-on: https://skia-review.googlesource.com/11362
Reviewed-by: Stephen White <senorblanco@chromium.org>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Change-Id: I70bd64d114a2460534bcb51d356e13d9bc3b8603
Reviewed-on: https://skia-review.googlesource.com/11491
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This moves all the values that gather_8888, gather_a8, etc. need to
the front of SkImageShaderContext, and dereferences the color table.
This should be a no-op, but will make these stages easier to write
in SkJumper.
Change-Id: I0dff97d5113d14e941e7b717cd85f0036764eb88
Reviewed-on: https://skia-review.googlesource.com/11492
Reviewed-by: Herb Derby <herb@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This doesn't change any of the generated .S files, but it does cut a few
misc. sections from the intermediate .o files. It's nice to get those
sections out of the way, and one day we might be able to find ways to
cut everything but .text... that'd allow us to switch the supicious
section sniffing code from a blacklist (no .const, no .literal, etc.) to
a more foolproof whitelist (.text or bust).
The remaining sections are only in ELF objects (aarch64.o, vfp4.o):
.comment (notes the version of Clang/LLVM that compiled it)
.note.GNU-stack (we manually add this back in build_stages.py)
and vfp4.o has two more sections that I don't understand yet:
.ARM.exidx (I'd have thought -fno-unwind-tables would cut this)
.ARM.attributes
While doing this, I've tried to make the ARM flags a bit more compact.
Change-Id: I30ef6acb2a917ec938c5358c3f970fe04b6d7afa
Reviewed-on: https://skia-review.googlesource.com/11485
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Use more consistent structure between the two functions.
BUG=skia:5853
Change-Id: I82465bee30025574d0d6fad9e287b187d75fff8d
Reviewed-on: https://skia-review.googlesource.com/10042
Reviewed-by: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Bug: skia:
Change-Id: Iffb123001a77049c6581f63bbc69c62f241a87f8
Reviewed-on: https://skia-review.googlesource.com/11405
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
typo in function header makes it appear
that a buffer overflow may occur
R=djsollen@google.com
Bug: b/36605271
Change-Id: Iab6d08ae71f49c46736dc025791faefdeb74df5e
Reviewed-on: https://skia-review.googlesource.com/11454
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Eric Boren <borenet@google.com>
Change-Id: I71d85ffe29bc11678ff1e696fa4a2c93d0b4fcbe
Reviewed-on: https://skia-review.googlesource.com/11446
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Its alignment (sometimes 4, sometimes 16) has proven to be error-prone.
This also means we don't really need LazyCtx::load().
I think I only had it there to make sure we were doing unaligned loads
of F4; the better way is to just never declare the data as aligned...
The generated code isn't quite as good, but I can live with it.
Change-Id: I5d57a580ca12c94ca84a5e8b72a66cf8d0c829eb
Reviewed-on: https://skia-review.googlesource.com/11406
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This makes it easier for me to read.
Change-Id: I6936c31981a2af6b7d3d7db9e60d36010fefa7ec
Reviewed-on: https://skia-review.googlesource.com/11445
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
replayClips has been disabled (broken) for a while.
This CL just attempts to hide the api (will remove
once android's callsite is removed)
Bug: skia:
Change-Id: I35b412addfc0a08ea888a62609888b9b54dce2a6
Reviewed-on: https://skia-review.googlesource.com/11401
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
This is in service of: https://skia-review.googlesource.com/c/11125/ (Add parallel proxyID to StencilOps & RenderTargetOpList) where I want a better choke point for texture creation to improve discard handling.
This is a re-reland of: https://skia-review.googlesource.com/c/11200/ (Rm readPixels from GrSurface & move read/writeSurfacePixels to GrContextPriv)
Change-Id: Icfb9dd223418dd460405efd2bfd9d1c356beed1a
Reviewed-on: https://skia-review.googlesource.com/11412
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
(1) Some clients want us to write ICC profiles, even though they
have not opted into linear unpremultiplication. This CL allows
that behavior.
(2) We should not assert that the transfer function must be linear
or srgb. Particularly in non-linear blending modes, skia is
willing to support a larger set of transfer functions.
(3) We still need to require linear or srgb when in kRespect transfer
function mode. We have not yet implemented linear unpremultiplies
for arbitrary transfer functions.
Bug: skia:
Change-Id: Idce9f07c3d36eca4d78ede5e2650b2cab412904c
Reviewed-on: https://skia-review.googlesource.com/11349
Commit-Queue: Matt Sarett <msarett@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
This reverts commit e87d7781db.
Reason for revert: Not the cause of the crashes.
Original change's description:
> Revert "Add support for writing ICC profiles to webp encoder"
>
> This reverts commit 0c9d0b4e03.
>
> Reason for revert: Looks like it's breaking a number of bots.
>
> Original change's description:
> > Add support for writing ICC profiles to webp encoder
> >
> > Bug: skia:
> > Change-Id: If0a8f84ed88da96924370b841f2283c0ff8e32ab
> > Reviewed-on: https://skia-review.googlesource.com/10212
> > Commit-Queue: Matt Sarett <msarett@google.com>
> > Reviewed-by: Leon Scroggins <scroggo@google.com>
> >
>
> TBR=msarett@google.com,scroggo@google.com,reviews@skia.org,jzern@google.com
> NOPRESUBMIT=true
> NOTREECHECKS=true
> NOTRY=true
>
> Change-Id: Ic06ad9f19a4d743b34f8d3bd33f171b9d74badcb
> Reviewed-on: https://skia-review.googlesource.com/11408
> Reviewed-by: Jim Van Verth <jvanverth@google.com>
> Commit-Queue: Jim Van Verth <jvanverth@google.com>
>
TBR=jvanverth@google.com,msarett@google.com,scroggo@google.com,reviews@skia.org,jzern@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Change-Id: I42f6ddefaf87c87b155640950b52a456952130ec
Reviewed-on: https://skia-review.googlesource.com/11410
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
This reverts commit 0c9d0b4e03.
Reason for revert: Looks like it's breaking a number of bots.
Original change's description:
> Add support for writing ICC profiles to webp encoder
>
> Bug: skia:
> Change-Id: If0a8f84ed88da96924370b841f2283c0ff8e32ab
> Reviewed-on: https://skia-review.googlesource.com/10212
> Commit-Queue: Matt Sarett <msarett@google.com>
> Reviewed-by: Leon Scroggins <scroggo@google.com>
>
TBR=msarett@google.com,scroggo@google.com,reviews@skia.org,jzern@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Change-Id: Ic06ad9f19a4d743b34f8d3bd33f171b9d74badcb
Reviewed-on: https://skia-review.googlesource.com/11408
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Jim Van Verth <jvanverth@google.com>
Nothing too tricky here.
Change-Id: I2a10548efc75a6fd875fcb242790880d9b9a28fd
Reviewed-on: https://skia-review.googlesource.com/11388
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Matt Sarett <msarett@google.com>
I believe that the best fix is to move this entire function into the
framework and call SkPixmap::readPixels() from there. Given that,
we have already branched, I think this is the simplest fix.
(1) We never added F16 support. Enable F16. This involves assigning
color spaces to src and dst pixmaps so that the conversion makes
sense.
(2) SkPixmap::readPixels() does not support parametric transfer
functions. Fortunately, the framework never uses copyTo() to
do color space conversions. We should at least support the
case where the src color space matches the dst color space.
Bug: skia:
Change-Id: I129b7c02249eed34a9ec4aa0ca736aadccc19777
Reviewed-on: https://skia-review.googlesource.com/11387
Commit-Queue: Matt Sarett <msarett@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
These can't really be done with SkJumper.
Change-Id: Ic357f00695eacd2766f6dfb9a3be13b0c07c3650
Reviewed-on: https://skia-review.googlesource.com/11386
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Change-Id: I2d58538ab071b217d8dbbf2d802493d9045eabf2
Reviewed-on: https://skia-review.googlesource.com/11384
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
This reverts commit aaee31f18c.
Reason for revert: possible valgrind leak
Original change's description:
> Rm readPixels from GrSurface & move read/writeSurfacePixels to GrContextPriv (take 2)
>
> This is in service of: https://skia-review.googlesource.com/c/11125/ (Add parallel proxyID to StencilOps & RenderTargetOpList) where I want a better choke point for texture creation to improve discard handling.
>
> This is a reland of: https://skia-review.googlesource.com/c/11200/ (Rm readPixels from GrSurface & move read/writeSurfacePixels to GrContextPriv)
>
> Change-Id: Icd0a90d2beb483dc24ed87c3bace9c817019e148
> Reviewed-on: https://skia-review.googlesource.com/11326
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Robert Phillips <robertphillips@google.com>
>
TBR=bsalomon@google.com,robertphillips@google.com,reviews@skia.org
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Change-Id: Ia0b92bf6402cb5f9607310d356f43bff2e3e75eb
Reviewed-on: https://skia-review.googlesource.com/11361
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Nobody calls this or overrides this.
Bug: skia:
Change-Id: I6235e4c7bcdc45523ce7f63842635c79e00d2dc4
Reviewed-on: https://skia-review.googlesource.com/11357
Commit-Queue: Matt Sarett <msarett@google.com>
Reviewed-by: Mike Reed <reed@google.com>
- Refactor runtime lookup of Vulkan functions
- Support Magma surfaces
- Add build flags to toggle Vulkan support
BUG=skia:
Change-Id: Ic71965c453507882521443006c4155c7481a9a3f
Reviewed-on: https://skia-review.googlesource.com/9342
Commit-Queue: Greg Daniel <egdaniel@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Reviewed-by: Michael Jurka <mikejurka@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
When comparing against gasp ranges always use the rounded (gdi) size.
Previously the truncated size was used, but it appears other
implementations are using the rounded size.
BUG=chromium:706693
Change-Id: I185cdf5b905261038e5150a04eef1b99bf73d875
Reviewed-on: https://skia-review.googlesource.com/11354
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>