The inner polygons connect the endpoints of each verb. (i.e., they are
the path that would result from collapsing all curves to single
lines.) Requiring it to be simple means the tessellator will abort if
there is any self intersection or double winding.
This exciting new mode will be used by the GPU tessellator. It will
stencil the curves only, then draw the inner polygon directly to the
canvas. This gives us most the advantage of CPU tessellation, at a
fraction of the cost. And the tessellated inner polygon can
potentially be cached and reused independent of the view matrix.
Change-Id: I4c70b18c6f8b011396e00a5b08997cdf9846c9af
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266422
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
I made this be kApprox here:
https://skia-review.googlesource.com/c/skia/+/264838
to resolve a TODO. However, it uses more memory and after thinking about
it I'm not sure why it was a TODO to use an approximate texture for a
cached texture. If it's worth caching it's probably worth making a trim
texture.
Bug: chromium:1044017
Change-Id: Iac8302291592231875f5619b33e8ee6e13a92a64
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267444
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
This makes it line-up with the coretext version.
Bug: skia:9836
Change-Id: I39f51e56ecb0d55ab970a8fa247bede9f4f0f394
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267445
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
Ensures the tessellator's triangles always wind in the same direction
as if the path had been triangulated as a simple fan (a la red book).
Change-Id: I1275a6dc9c2673e5f710ca46c357409dcd233162
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/263390
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Stephen White <senorblanco@chromium.org>
We replace all uses of the function with asSurfaceProxyViewRef.
Bug: skia:9556
Change-Id: I23d425531d78e30fc401b04169d5dc96072cdd80
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267181
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Adds a test to load different font types. Currently supported:
- .ttf
- .otf
- .ttc
Not supported:
- .woff
- .woff2
This only increases code size by ~4kb, so that big glyph table
has still been successfully removed.
Bug: skia:9829
Change-Id: I0231578b2abf4f36df57ff8073b7697d16606373
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267180
Reviewed-by: Ben Wagner <bungeman@google.com>
Obsolete since I added the dylib SkVM JIT mode.
Change-Id: I124f83cd365fd542ca92fab7f187b003ad2e1c90
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267279
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Couple ways to do this masking, but since we basically
need the same for decal, seems easiest to send it up to
the common code and handle it all together.
Change-Id: Idf806d7feab12a9caf339febd30dd3a2432ec038
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267244
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Change-Id: I685f4fd9e4c5b01a9b727a21f525721f025957a2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266421
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Stephen White <senorblanco@chromium.org>
To make this change cleaner, GrMakeCachedBitmapProxy now returns a view
and all its callers updated.
Additionally some effects were updated to fully use views in cases
where they had to be updated anyways to support SpecialImages and there
wasn't much additional work to pass them around everywhere.
Bug: skia:9556
Change-Id: Ie5a631cdec481391437e2f74275f958d15676780
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267176
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
We had full constant eval of these already; this adds a bunch of
degenerate cases when one argument is known to be true or false.
Change-Id: Ic0535d8a99357947fd73bd9f719eec4645dc919d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267243
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Instead in proxyProvider we just have a create a bitmap call which
does no special fallback or logic. All the callers now go through
GrBitmapTextureMaker which handles and special fallbacks or caching
support that we need.
Change-Id: I71bb896cc78f64f9d6d54b54af2490d48e0f5af5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266842
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
We can look at the luma to test correctness,
which lets G8 destinations be tested correctly.
Change-Id: I412381e5b2829258f0f9f340fb28ff88344e7f02
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267225
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Basically the same as SkRasterPipeline version.
Need to thread uniforms through for scale/bias.
Change-Id: I27fd91469d9108d155a751dad71047eded4b6692
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267223
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Copying the color type from the RTCs is incorrect because we may have
fallen back to GL_RGBA8 if GL_R8 is not renderable.
Change-Id: Ie8effabfe60c2410d200b1775f463d5edb13fe81
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267179
Commit-Queue: Brian Salomon <bsalomon@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
Auto-Submit: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
- Add sqrt(), vsqrtps for x86.
- Hook into SkRadialGradient.
Change-Id: I66a4598e30fe16610c59a512f7d962323ee5134a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267196
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Currently when the GPU resources are freed, the generation counters
are reset back to 1. This could allow stale data to be retained in the
SubRun texture coordinates. In addition, it confuses managing the
GrStrikes.
Use monotonic counters so that no number is ever repeated. This allows
for a simple check of equality without any additional checks or constrinats.
Bug: chromium:1045016
Change-Id: Ib58abf9a99107a37927fa73aef88a95900f70a5f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266618
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Today's shader hash changes if the unordered set of {r,g,b,a} values we
produce changes, but is not sensitive to simple order changes like
sampling RGBA vs BGRA.
Folding in a hash of each value's ID in order will fix this.
This has been difficult to track down (thread-local caches),
so I've added a GM that reliably reproduces the bug.
Live demo: https://fiddle.skia.org/c/30f2e5b731c2e53a6f092424c585ca41
Bug: skia:9819
Change-Id: Iceb09d89eb036735028ae97dc79c576787199ac5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267119
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
This CL adds testing for some edge cases in compressed texture handling
Bug: skia:9680
Change-Id: I4915f46bca9e2fb5c827a51152f28dc1e9d22942
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266201
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
This will allow usage of emscripten 1.39.6 to build
Change-Id: I089f47fa4fa38bf55c5071f5d711856c8ab422b8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267080
Reviewed-by: Kevin Lubick <kjlubick@google.com>
The atlas generation number is used avoid checking if each glyph has
a valid plot location. If the atlas generation number ever misses
an eviction of a plot, then some glyph atlas coordinates will be considered
valid when in fact they are stale.
Fix: Always check the texture coordinates of every glyph. Don't use the
atlas generation numbering to reduce work.
Bug: chromium:1045016
Change-Id: I287d3bbcd0a5d679327002595ae50e0f775dca12
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267096
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Herb Derby <herb@google.com>
Mostly this is really just removing strictly unused bits.
Removing SkNO_RETURN_HINT() from SK_ABORT() isn't quite
strictly unused, but I think maybe it's moot since we
added SkUNREACHABLE to the end of SK_ABORT().
Change-Id: I1b23a7f1cb325723b359762b0879110a2c82575f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267071
Commit-Queue: Brian Salomon <bsalomon@google.com>
Auto-Submit: Mike Klein <mtklein@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Change-Id: I54038b34cb10322ec688f24e3869a7481d2e2c66
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267070
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
After the update to emscripten 1.39.6, source maps don't
work on ASMJS builds and debugger needed the same change
of the default MAIN_MODULE setting as canvaskit and pathkit.
Change-Id: Ifb920dee998ae41fd500adca587b1ad20cfef584
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/267076
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Split GrDawnImageInfo into GrDawnTextureInfo and GrDawnRenderTargetInfo.
The former holds only a wgpu::Texture, and the latter holds only a
wgpu::TextureView. This split is necessary because Dawn SwapChains now
vend TextureViews, not Textures.
The TextureView held by GrDawnRenderTargetInfo is always 1-mip, since
it's a requirement for rendering to a texture in Dawn.
Change-Id: Id6e99b5e4bf18f97e939170856a665e2038253ea
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/254810
Commit-Queue: Stephen White <senorblanco@chromium.org>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Primary goal: API compatibility with SkShaper but reduce code size on iOS.
Change-Id: I6ee8f49827a029569010a69308541b74a21ac3e2
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266854
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
This is intended to make using compressed textures easier since developers can just provided compressed data and it will be uploaded to the GPU in some way, shape or form.
TBR=reed@google.com
Change-Id: I8c672ccc7db5cd098f629c3469ae7cbdc7436392
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266939
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
fcef6dcb6a..086aded3cb
git log fcef6dcb6ab2..086aded3cb74 --date=short --first-parent --format='%ad %ae %s'
2020-01-27 syoussefi@chromium.org Return the correct location count for matrices in structs
2020-01-27 courtneygo@google.com Vulkan: Allow user to specify preferred device
2020-01-27 syoussefi@chromium.org Fix atomicAdd validation w.r.t to swizzles
2020-01-27 jonahr@google.com Expose eglGetMscRateCHROMIUM from EGL_CHROMIUM_sync_control
2020-01-27 syoussefi@chromium.org Vulkan: updateActiveImages: process each image once
2020-01-27 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/vulkan-loader/src 37d3a235af2c..310fb8617946 (1 commits)
2020-01-27 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/spirv-tools/src b97057e7f747..1b3441036a8f (6 commits)
2020-01-27 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/SwiftShader 5ef91b82cbed..748ad200897b (6 commits)
2020-01-27 angle-autoroll@skia-public.iam.gserviceaccount.com Roll third_party/vulkan-tools/src 93ab50fc27de..b181c1a7ddb5 (4 commits)
Created with:
gclient setdep -r third_party/externals/angle2@086aded3cb74
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/angle-skia-autoroll
Please CC reed@google.com on the revert to ensure that a human
is aware of the problem.
To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md
Cq-Include-Trybots: skia/skia.primary:Build-Debian9-Clang-x86_64-Release-ANGLE;skia/skia.primary:Test-Win10-Clang-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-Golo-GPU-QuadroP400-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC5i7RYH-GPU-IntelIris6100-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC6i5SYK-GPU-IntelIris540-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUC8i5BEK-GPU-IntelIris655-x86_64-Debug-All-ANGLE;skia/skia.primary:Test-Win10-Clang-NUCD34010WYKH-GPU-IntelHD4400-x86_64-Debug-All-ANGLE
Bug: None
Tbr: reed@google.com
Change-Id: If098f3433234678a7f813eff27ac2c6d8be9cdc6
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/266981
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>