Commit Graph

48812 Commits

Author SHA1 Message Date
Julia Lavrova
73905c3db2 Removing fOffsets array from Run; optimizing copyTo
Change-Id: I4df661f800436ddb2b2bdb0cf19017e651332971
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295236
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2020-06-09 19:49:36 +00:00
Herb Derby
990a04ecd5 remove unused and unimplemented calls
Change-Id: If261aab20066c807ccf6d31b588af780af12189e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295318
Commit-Queue: Herb Derby <herb@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Auto-Submit: Herb Derby <herb@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-06-09 18:58:56 +00:00
Herb Derby
64688229fd move the bulk of GrTextContext to GrRenderTargetContext
This is the major portion of GrTextContext. In a later CL options will
be broken out as GrSDFControl. And createOp_TestingOnly will be moved
to GrAtlasTextOp.

Change-Id: Ia5f3d69b928e6312db10448f422543a6ab5d86be
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295077
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-06-09 18:32:45 +00:00
Brian Osman
8c4067737d Remove SkValidatingReadBuffer.h
We did the rename in 2017, no one references this header at this time.

Change-Id: I3df8975bb861e543213177fa4467be5c7e36d195
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295242
Commit-Queue: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
Auto-Submit: Brian Osman <brianosman@google.com>
Reviewed-by: Mike Klein <mtklein@google.com>
2020-06-09 18:19:55 +00:00
Jorge Betancourt
6c4b67d13b remove arcore from apps project directory
arcore is untouched and impedes builds of other apps in platform-tools

Change-Id: I92b603de318b956c116fa0a065a26d2217755b68
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294736
Commit-Queue: Jorge Betancourt <jmbetancourt@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2020-06-09 17:46:47 +00:00
Adlai Holler
25df1f7f88 Don't fill last render task map with nullptrs
Bug: skia:10320
Change-Id: I8d388c273f37f3dd104a2940032966b477d9a92a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295199
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-06-09 17:41:27 +00:00
Greg Daniel
8a6e53ad22 Disable support for sample locations in vulkan.
Bug: skia:10346
Change-Id: Ie741fcf84a8c71d663f240d49c35fdbc5cb812e1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295088
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2020-06-09 17:05:27 +00:00
Mike Klein
d3927e40f1 Revert "Reland "Add JavaInputStreamAdaptor files into third_party directory.""
This reverts commit 237f794e64.

Reason for revert: blocking the Google3 roll.

I think you may need to land third_party/aosp/LICENSE first, set up the BUILD file to point out code in third_party/aosp is covered by third_party/aosp/LICENSE, and then let the code roll in?

Original change's description:
> Reland "Add JavaInputStreamAdaptor files into third_party directory."
> 
> This is a reland of cf8b723ffd
> 
> The reland is necessary to satisfy the google3 roller.
> 
> Original change's description:
> > Add JavaInputStreamAdaptor files into third_party directory.
> >
> > This code needs to be migrated out of the main Skia directory due to its
> > use of the Apache 2.0 license. A followup CL will remove these files
> > from their current home at platform_tools/android/apps/skottie/src/
> > main/cpp.
> >
> > Change-Id: I939b05afcebb29e1deab1d4ae1b38012f719cf7e
> > Bug: skia:10310
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295082
> > Reviewed-by: Ben Wagner <bungeman@google.com>
> > Reviewed-by: Weston Tracey <westont@google.com>
> > Commit-Queue: John Stiles <johnstiles@google.com>
> 
> Bug: skia:10310, skia:10353
> Change-Id: I3ac62b626825df624a5418e496989facef6b6099
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295201
> Commit-Queue: John Stiles <johnstiles@google.com>
> Reviewed-by: Weston Tracey <westont@google.com>

TBR=bungeman@google.com,westont@google.com,johnstiles@google.com

Change-Id: I7f8de31419d86933a79036b48032c4a7ea18dd3a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10310, skia:10353
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295283
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-06-09 16:55:29 +00:00
Brian Osman
8441a7c44b In GrColorInfo, compute color xform from sRGB at construction time
The lazy caching of this was unnecessarily complicated, and most color
infos will need this to be constructed eventually.

Bug: skia:10352
Change-Id: I18a8e22ba80a0062488e83ec72f2e4fcd3161995
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295238
Reviewed-by: Mike Klein <mtklein@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2020-06-09 16:41:07 +00:00
Michael Ludwig
28e5f11178 Don't recompute clipped op bounds in setupDstProxyView
I happened to notice this when refactoring the various clipping code,
it was performing almost the same operations as op_bounds() and redoing
intersection work handled in GrClip::apply() and setClippedBounds().

Change-Id: Ie9ec13a6ca0e4c9717e7a94e025e7237a6236a45
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/290825
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2020-06-09 16:36:27 +00:00
Mike Klein
45f36b5b55 ignore SK_DISABLE_READBUFFER
Its effect is small and we want to rely on SkReadBuffer being available.

Size changes:

    - canvaskit uncompressed: 6,864,481 --> 6,864,481  (  no change  )
    - canvaskit   compressed: 2,667,117 --> 2,667,117  (  no change  )
    -   pathkit uncompressed:   329,187 -->   330,679  (+ 1.5K, +0.5%)
    -   pathkit   compressed:   134,158 -->   134,672  (+ 0.5K, +0.4%)
    -   flutter             : 1,302,108 --> 1,322,568  (+20.0K, +1.6%)

The Flutter change is the biggest mystery, as bloaty only pegs
SkReadBuffer as 3.9K.  The rest must come from other files including
SkReadBuffer.h not being able to see and inline away SkReadBuffer
routines?  Feels like SK_DISABLE_EFFECT_DESERIALIZATION isn't trimming
enough?

PS 4-6 have an idea to push SK_DISABLE_EFFECT_DESERIALIZATION further.

Change-Id: Ifda3ccb82dd0636cfed6bb826fb185a7bca2cbe0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295061
Commit-Queue: Mike Klein <mtklein@google.com>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
2020-06-09 16:16:57 +00:00
Brian Osman
5c9d18170b Make SK_DISABLE_EFFECT_SERIALIZATION trim out more code
This shrinks uncompressed CanvasKit by just over 15K

Change-Id: I2495b235cdbc201811195c93b9f3b31409dfd9c3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295198
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-06-09 15:45:07 +00:00
Mike Klein
8f45e4d1b5 use type name as identifier instead of factory
This allows serializable types that can't be deserialized, e.g. for
creating font descriptors even with effect deserialization disabled.

Change-Id: I70a38ce2e34b192e5c87f6a341d090e5e444fc70
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295193
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-06-09 15:36:27 +00:00
John Stiles
237f794e64 Reland "Add JavaInputStreamAdaptor files into third_party directory."
This is a reland of cf8b723ffd

The reland is necessary to satisfy the google3 roller.

Original change's description:
> Add JavaInputStreamAdaptor files into third_party directory.
>
> This code needs to be migrated out of the main Skia directory due to its
> use of the Apache 2.0 license. A followup CL will remove these files
> from their current home at platform_tools/android/apps/skottie/src/
> main/cpp.
>
> Change-Id: I939b05afcebb29e1deab1d4ae1b38012f719cf7e
> Bug: skia:10310
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295082
> Reviewed-by: Ben Wagner <bungeman@google.com>
> Reviewed-by: Weston Tracey <westont@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

Bug: skia:10310, skia:10353
Change-Id: I3ac62b626825df624a5418e496989facef6b6099
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295201
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Weston Tracey <westont@google.com>
2020-06-09 15:31:18 +00:00
Mike Klein
cb1cf47bb8 Revert "remove unnecessary hsw opts"
This reverts commit 88c6d72b42.

Reason for revert: needs restructuring

Original change's description:
> remove unnecessary hsw opts
> 
> These are copies of the ssse3 versions of these routines.
> Instead of copying those routines, just use them.
> 
> Add inline to _portable methods to stifle warnings that
> they are unused when compiling for HSW.
> 
> Change-Id: I655a844473bb3336dd2d1a80c1390259261b6243
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294295
> Reviewed-by: Shuangshuang Zhou <shuangshuang.zhou@intel.com>
> Commit-Queue: Mike Klein <mtklein@google.com>

TBR=mtklein@google.com,shuangshuang.zhou@intel.com

Change-Id: I35ab7dcb28043edaabd8e5e153aefed481e4ce0c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295190
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-06-09 15:08:59 +00:00
Brian Salomon
a01ec53bdd Remove axis alignment restriction on small CPU blur
Note that the calling code still won't cache the filtered mask if matrix
does not preserve axis alignment.

Change-Id: Ib11a7146e937e88b1968621ba49966e56beeb731
Bug: chromium:1087705
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295197
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
2020-06-09 14:53:03 +00:00
John Stiles
9d79ac6b81 Revert "Add JavaInputStreamAdaptor files into third_party directory."
This reverts commit cf8b723ffd.

Reason for revert: reverting and relanding to make the google3
roller happy

Original change's description:
> Add JavaInputStreamAdaptor files into third_party directory.
> 
> This code needs to be migrated out of the main Skia directory due to its
> use of the Apache 2.0 license. A followup CL will remove these files
> from their current home at platform_tools/android/apps/skottie/src/
> main/cpp.
> 
> Change-Id: I939b05afcebb29e1deab1d4ae1b38012f719cf7e
> Bug: skia:10310
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295082
> Reviewed-by: Ben Wagner <bungeman@google.com>
> Reviewed-by: Weston Tracey <westont@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

TBR=bungeman@google.com,westont@google.com,johnstiles@google.com

Change-Id: Ib3cbad92b8c5616735a013d06e3345ac50f78c84
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10310, skia:10353
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295200
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-09 14:44:04 +00:00
Ben Wagner
cb40620540 Document skia::textlayout::Run is non-assignable.
This class has a const member and so is non-assignable. Make it obvious
to the reader that this is a property to be preserved instead of just an
accident.

Change-Id: If269f3aea95b98a8d5c05971af53d222a2525f2f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295055
Auto-Submit: Ben Wagner <bungeman@google.com>
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2020-06-09 14:30:14 +00:00
Mike Klein
88c6d72b42 remove unnecessary hsw opts
These are copies of the ssse3 versions of these routines.
Instead of copying those routines, just use them.

Add inline to _portable methods to stifle warnings that
they are unused when compiling for HSW.

Change-Id: I655a844473bb3336dd2d1a80c1390259261b6243
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294295
Reviewed-by: Shuangshuang Zhou <shuangshuang.zhou@intel.com>
Commit-Queue: Mike Klein <mtklein@google.com>
2020-06-09 14:21:03 +00:00
Michael Ludwig
7910a8f761 Account for surface origin in Dawn scissor rect
Bug: chromium:1091734
Change-Id: I1299c849be05cc96772c7341ce903ccfc3992d3a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295083
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
2020-06-09 13:10:11 +00:00
skia-autoroll
cc23d95f5f Roll Chromium from 734187142549 to 608bc0c55214 (450 revisions)
7341871425..608bc0c552

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/chromium-skia-autoroll
Please CC bungeman@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Perf-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Release-All-CommandBuffer;skia/skia.primary:Test-Mac10.13-Clang-MacBookPro11.5-GPU-RadeonHD8870M-x86_64-Debug-All-CommandBuffer
Tbr: bungeman@google.com
Change-Id: I189a253c17ff90b276207227d939aa812eda237e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295165
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-06-09 04:52:31 +00:00
skia-autoroll
5a520eafa1 Roll ANGLE from d80adf4e137d to dbb18b53c4b4 (14 revisions)
d80adf4e13..dbb18b53c4

2020-06-09 syoussefi@chromium.org Add texture base-level related tests
2020-06-09 cnorthrop@google.com Unmap buffers targeted by glBufferData
2020-06-09 cnorthrop@google.com Capture/Replay: Don't assert when reading combined depth/stencil
2020-06-08 cnorthrop@google.com Perf: Ensure last frame is replayed for traces
2020-06-08 nguyenmh@google.com Fix ExceedMaxVertexAtomicCounters test crash with FrameCapture
2020-06-08 timvp@google.com Implement EGL_CreatePlatformWindowSurface()
2020-06-08 tobine@google.com doc: Update CONTRIBUTORS
2020-06-08 amaiorano@google.com Fix copy texture to sRGB in ANGLE/VK
2020-06-08 jmadill@chromium.org Build both standalone and Chromium gTest targets.
2020-06-08 jdarpinian@chromium.org Workaround broken copyTexImage2D on iOS
2020-06-08 jmadill@chromium.org Vulkan: Don't invalidate index buffers on vertex change.
2020-06-08 yang.gu@intel.com Fix assertion when running tests without suffix on Windows
2020-06-08 angle-autoroll@skia-public.iam.gserviceaccount.com Roll SPIRV-Tools from 74130f2d3ab1 to 7c213720bb46 (4 revisions)
2020-06-08 angle-autoroll@skia-public.iam.gserviceaccount.com Roll Vulkan-Tools from 5b40c4aa0dba to 9d7880c7a075 (1 revision)

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 bungeman@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-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: bungeman@google.com
Test: Test: Android CtsDeqpTestCases, CQTest: Test: Angry Birds 2 MECTest: Test: angle_end2end_tests --gtest_filter=BufferDataTestES3.BufferDataUnmap/*
Change-Id: Ie5f462ea561525b5d251a7cc5fba277bfa6c1237
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295164
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-06-09 04:37:21 +00:00
skia-autoroll
8621f13b13 Roll dawn from a2fe30579783 to 0a79bee135cd (5 revisions)
https://dawn.googlesource.com/dawn.git/+log/a2fe30579783..0a79bee135cd

2020-06-08 yunchao.he@intel.com Vulkan: Combine all pass barriers in a single call
2020-06-08 cwallez@chromium.org Fix use of bytesPerRows=0 in CppHelloTriangle
2020-06-08 xinghua.cao@intel.com Reland "Check FP16 support on vulkan backend"
2020-06-08 jiawei.shao@intel.com Add validations on the texture-to-texture copies within same texture
2020-06-08 enga@chromium.org D3D12: Properly compute rowsPerImage for lazy texture clear

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/dawn-skia-autoroll
Please CC cwallez@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/+doc/master/autoroll/README.md

Cq-Include-Trybots: skia/skia.primary:Build-Debian10-Clang-x86_64-Debug-Dawn
Bug: None
Tbr: cwallez@google.com
Change-Id: I717e1f843b3a404dee4ee0886fa24e6278aac3c7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295125
Reviewed-by: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
Commit-Queue: skia-autoroll <skia-autoroll@skia-public.iam.gserviceaccount.com>
2020-06-09 04:30:31 +00:00
Ben Wagner
c14701a512 Remove SkStream_mac.cpp.
This file is a stub. References from supported builds have been removed,
so remove the file.

Change-Id: I21ad98df7157a698fb967fee22d989048f41864f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294937
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2020-06-08 22:26:24 +00:00
Ben Wagner
7c1f3fabf5 Remove SkFontHost_mac.cpp.
This file is now just a stub. Remove it.

Change-Id: I3156c1f2218ebb69a52558e0d139309e1c108b74
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294916
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2020-06-08 22:25:40 +00:00
Mike Reed
d449f51616 minor reordering of fields to save space
must smaller things at the end
mark const what can be const
removed some =default constructors (to fix warnings)

This CL removes 24 bytes on a 64bit build

Change-Id: I6fb8fba6146b0293755b8f2d743a730159f5b04d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295087
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Julia Lavrova <jlavrova@google.com>
2020-06-08 22:21:19 +00:00
John Stiles
75da65158b Update GrLumaColorFilterEffect to use a child FP.
We are updating FPs to receive their input via a child FP where
possible, instead of relying on the input color.

Change-Id: I377fbf676185caa8c8a5b60b7a58bf98dc6d4da7
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295078
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 21:30:36 +00:00
John Stiles
fe64410954 Remove PremulInput and GrPremulInputFragmentProcessor.fp from Skia.
This FP was unused and not referenced anywhere in the codebase.

Change-Id: I27f963d7c26382101b585f356a75d84cef5ab237
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295080
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 21:04:46 +00:00
John Stiles
ea380a70b6 Fix housekeeper 'check generated files' warning.
Change-Id: Id3bb4b69394377aa5f24e0720181616be83afd5e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295085
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2020-06-08 21:03:45 +00:00
Adlai Holler
d71b7b05ba Move lastRenderTask into drawing manager
Bug: skia:10320
Change-Id: I5a25d8c0bf00b379a37c479e79d4ff16403e9dfe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294339
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-06-08 20:49:16 +00:00
Stephen White
d4b8bf91b4 Dawn: implement GrBackendTexture::isSameTexture().
Bug: skia:10345
Change-Id: Iae15dd92f6f488dce1fb1afe9728be1b0996270c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295084
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Stephen White <senorblanco@chromium.org>
2020-06-08 20:22:30 +00:00
John Stiles
cf8b723ffd Add JavaInputStreamAdaptor files into third_party directory.
This code needs to be migrated out of the main Skia directory due to its
use of the Apache 2.0 license. A followup CL will remove these files
from their current home at platform_tools/android/apps/skottie/src/
main/cpp.

Change-Id: I939b05afcebb29e1deab1d4ae1b38012f719cf7e
Bug: skia:10310
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295082
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Weston Tracey <westont@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 20:08:30 +00:00
Julia Lavrova
e2c83a323a Optimize findLimitingClusters
This method is called every time we paint a styled text range to find its cluster range.
Instead of scanning all the clusters in the run we can use
a helper table that for every UTF8 byte keeps its cluster.
(So the most important part of the change is this table in Paragraph)
Should have done it long time ago but fixing bugs seemed to be more
important than performance.

Change-Id: I309f18ace4654b140a8532fef415c0280ea09d08
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295005
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Mike Reed <reed@google.com>
2020-06-08 19:45:09 +00:00
John Stiles
7b1355e509 Revert "Reland "Move JavaInputStreamAdaptor into third_party and add a LICENSE file.""
This reverts commit fee069880d.

Reason for revert: google3 roller is glitchy today, try again later

Original change's description:
> Reland "Move JavaInputStreamAdaptor into third_party and add a LICENSE file."
> 
> This is a reland of eac2d518bd
> 
> The aosp folder was added to the google3 roller include_patterns list:
> http://cl/315274044
> 
> Original change's description:
> > Move JavaInputStreamAdaptor into third_party and add a LICENSE file.
> >
> > Change-Id: I723b15fbcf3343559fb5a3fe3015cf3db96e2841
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294696
> > Reviewed-by: Heather Miller <hcm@google.com>
> > Commit-Queue: John Stiles <johnstiles@google.com>
> 
> Change-Id: I27ac16c3ac05fbee1473af886379e95492302d50
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295000
> Reviewed-by: Heather Miller <hcm@google.com>
> Reviewed-by: John Stiles <johnstiles@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

TBR=djsollen@google.com,hcm@google.com,johnstiles@google.com

Change-Id: I8c620c47a8c6c7f3e081fe786a17396a40236105
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295081
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 19:18:15 +00:00
Adlai Holler
f54dbf71e8 Clean up SkShaper_coretext.cpp & SkCGBase.h
- Use SkUniqueCFRef.
- Use CFShow to print dictionary.
- Use CGFLOAT_IS_DOUBLE define.
- Use kCFAllocatorDefault consistently.

Change-Id: If0276cab0182d33aacf1060a734b8b025e16f99e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295010
Commit-Queue: Adlai Holler <adlai@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
Auto-Submit: Adlai Holler <adlai@google.com>
2020-06-08 19:04:54 +00:00
Julia Lavrova
d470f40272 Dealing with another crash when some fonts are unresolved
Only happens when resources/fonts have certain fonts
Bugs: skia:10255

Change-Id: Ib346f8d005685290c90886c455def14bb5d49f79
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294997
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2020-06-08 18:58:33 +00:00
John Stiles
2fbe61779a Update Gr(Circle|Ellipse)Effect to use a child FP.
We are updating FPs to receive their input via a child FP where
possible, instead of relying on the input color.

Change-Id: If02385558f4af3d9e5a0412975bd7d0be9c39a7f
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294402
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Jim Van Verth <jvanverth@google.com>
2020-06-08 18:31:31 +00:00
Herb Derby
d29207a24f move painter to GrRenderTargetContext from TextTarget
Change-Id: Ie477d8463c958438358efe2aebc636f465ca9e54
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295076
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Herb Derby <herb@google.com>
2020-06-08 18:25:51 +00:00
John Stiles
fee069880d Reland "Move JavaInputStreamAdaptor into third_party and add a LICENSE file."
This is a reland of eac2d518bd

The aosp folder was added to the google3 roller include_patterns list:
http://cl/315274044

Original change's description:
> Move JavaInputStreamAdaptor into third_party and add a LICENSE file.
>
> Change-Id: I723b15fbcf3343559fb5a3fe3015cf3db96e2841
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294696
> Reviewed-by: Heather Miller <hcm@google.com>
> Commit-Queue: John Stiles <johnstiles@google.com>

Change-Id: I27ac16c3ac05fbee1473af886379e95492302d50
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295000
Reviewed-by: Heather Miller <hcm@google.com>
Reviewed-by: John Stiles <johnstiles@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 16:44:04 +00:00
John Stiles
d060c9d8a7 Define sample(null) as returning the inputColor unchanged.
This is more useful than returning half4(1), and there was no existing
code that passed null to sample(), so this will not be a breaking
change.

This change will allow us to replace this boilerplate:
  half4 color = (inputFP != null) ? sample(inputFP, sk_InColor)
                                  : sk_InColor;
With:
  half4 color = sample(inputFP, sk_InColor);

Change-Id: I7bb1580299af99afccbd3a5fdf4cb1d5c4c96da9
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295002
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 16:40:40 +00:00
Florin Malita
26ae40f668 Reland "[skrive] Initial parser plumbing"
This reverts commit e923ae1be4.


Original change's description:
> Revert "[skrive] Initial parser plumbing"
> 
> This reverts commit 00a96f2c99.
> 
> Reason for revert: breaking wuffs 
> 
> Original change's description:
> > [skrive] Initial parser plumbing
> > 
> > TBR=
> > Change-Id: If96d81840b5bb3bc8c6e26f8aacca4d9dd8896e3
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/293677
> > Reviewed-by: Florin Malita <fmalita@chromium.org>
> > Commit-Queue: Florin Malita <fmalita@chromium.org>
> 
> TBR=fmalita@chromium.org,reed@google.com
> 
> Change-Id: I63258d560cc8ee8d069e6417d987342a74a3f0c2
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295001
> Reviewed-by: Florin Malita <fmalita@chromium.org>
> Commit-Queue: Florin Malita <fmalita@chromium.org>

TBR=fmalita@chromium.org,reed@google.com

# Not skipping CQ checks because this is a reland.

Change-Id: I0a671bb7476ee92c365fbea1f156c73c6954fe40
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295003
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2020-06-08 16:38:59 +00:00
Ben Wagner
94aed0be1f Use "und" in place of HB_LANGUAGE_INVALID.
Buffers with HB_LANGUAGE_INVALID race since it will force
hb_buffer_guess_segment_properties to call hb_language_get_default which
is not thread safe. The user is required to pass a language string to
the shaper, but it may be malformed and hb_language_from_string may
return HB_LANGUAGE_INVALID. Detect this and use "und" as the language,
since the language really isn't known (RFC5646 4.1 5).

Bug: skia:10323
Change-Id: Icf2389e606eb1b635d7535e57be10cca23bf9d33
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294999
Reviewed-by: Mike Klein <mtklein@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2020-06-08 16:24:00 +00:00
Herb Derby
cf992d6422 simplify GrTextContext
ComputeScalerContextFlags and ComputeCanonicalColor used to be shared
between GPU and the diff canvas. Now that everything has been centralized
They can be moved into the single implementation.

Change-Id: Ic4d56c26c15c698eaacf4fbee7f1f10668f8a97a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294603
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
2020-06-08 15:45:09 +00:00
Florin Malita
e923ae1be4 Revert "[skrive] Initial parser plumbing"
This reverts commit 00a96f2c99.

Reason for revert: breaking wuffs 

Original change's description:
> [skrive] Initial parser plumbing
> 
> TBR=
> Change-Id: If96d81840b5bb3bc8c6e26f8aacca4d9dd8896e3
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/293677
> Reviewed-by: Florin Malita <fmalita@chromium.org>
> Commit-Queue: Florin Malita <fmalita@chromium.org>

TBR=fmalita@chromium.org,reed@google.com

Change-Id: I63258d560cc8ee8d069e6417d987342a74a3f0c2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/295001
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2020-06-08 15:22:15 +00:00
John Stiles
f79ef18e11 Update GrAARectEffect to use a child FP.
We are updating FPs to receive their input via a child FP where
possible, instead of relying on the input color.

Change-Id: I7eed35821024de9dbb6aecceeef02f391aa5ad88
Bug: skia:10217
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294298
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: John Stiles <johnstiles@google.com>
2020-06-08 15:14:12 +00:00
Mike Reed
f6c48c0b51 inline Cluster::run()
Change-Id: I3d418e52df43c49a9c6b8519d47ca173f6ff3b9f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294996
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2020-06-08 15:04:12 +00:00
Florin Malita
00a96f2c99 [skrive] Initial parser plumbing
TBR=
Change-Id: If96d81840b5bb3bc8c6e26f8aacca4d9dd8896e3
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/293677
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
2020-06-08 14:23:34 +00:00
Greg Daniel
03535f4f22 No longer move queue index of VkImage back to initial state on release.
From what I can tell no one is currently depending on this feature and
continuing to support it is starting to become a pain. Clients will
be able to manually request VkImages (via flush api) go back to their
original queue, so there is a path if someone really needs this.

Bug: skia:10254
Change-Id: I91283bba451fa9bf52b466f587d3f7c5c9365242
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294657
Reviewed-by: Jim Van Verth <jvanverth@google.com>
Commit-Queue: Greg Daniel <egdaniel@google.com>
2020-06-08 14:21:19 +00:00
Herb Derby
750e565bcc calculate text color closer to use
Now that the code calculates the vertices much later, the early
calculation of color is not needed.

Change-Id: I290b497eff7f863045f99f663bcde8446a721d84
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/294709
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2020-06-08 14:10:56 +00:00
Michael Ludwig
9cced93b7a Handle color and stencil clears in GrClearOp
With prior changes, it became "clear" that GrClearOp and
GrClearStencilClipOp behaved very similarly, except that the stencil
op did not have any onCombine logic.

This just combines them in to a single clear op that will call the
render pass's clear and stencil clear functions as needed. I also
implemented combine logic to apply color and stencil clears in a single
op if the scissor state was compatible (although there's no render pass
API to combine the two clears into a single GPU function).

Change-Id: I8aa749fe64cc487d187854fd0acf6b03b86f1356
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/290822
Commit-Queue: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
2020-06-08 14:05:16 +00:00