aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
Commit message (Collapse)AuthorAge
* Reland "strip down SkICC.cpp"Gravatar Mike Klein2018-05-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 27fe397bc0cc1b091f9f85863c62b88156239cf0. Reason for revert: time to fly. Original change's description: > Revert "strip down SkICC.cpp" > > This reverts commit eab50eb9c6117c2a9d0e5648f89cebbb4dbd9d30 > and this tiny bit of e61b969a07ba3ebe9e47e61381ad16c5d2c549a2: > > https://skia-review.googlesource.com/c/skia/+/127122/3/tests/ICCTest.cpp > > Change-Id: I4306e5118a4e5eb88c05078186a28bd443fd76f7 > Reviewed-on: https://skia-review.googlesource.com/127305 > Reviewed-by: Mike Klein <mtklein@chromium.org> > Commit-Queue: Mike Klein <mtklein@chromium.org> TBR=mtklein@chromium.org,brianosman@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Change-Id: I93a6cfb66f0da0e098fdcb77ac1cd619e41614b1 Reviewed-on: https://skia-review.googlesource.com/129446 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* Revert "IWYU for tests starting with 'D'."Gravatar Mike Klein2018-05-22
| | | | | | | | | | | | | | | | | | | | | | | | This reverts commit b5f2897ab5be37e86ccce4ed474a2e02001a9040. Reason for revert: looks like this broke the build for DM in Google3. Need more include dirs there? Original change's description: > IWYU for tests starting with 'D'. > > Change-Id: I9189e4b56ce1635b627119733447c2ed4220753d > Reviewed-on: https://skia-review.googlesource.com/129319 > Reviewed-by: Herb Derby <herb@google.com> > Commit-Queue: Ben Wagner <bungeman@google.com> TBR=bsalomon@google.com,bungeman@google.com,herb@google.com Change-Id: I01aac7dae6114685a0652cbde3defccc8a42caea No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/129443 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* Revert "remove fragile hack in addOval to avoid computing bounds"Gravatar Mike Klein2018-05-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit bc721ba4be626e3ba753f55341a7019d98044102. Reason for revert: I think we'll want to reland with guards for layout tests. https://test-results.appspot.com/data/layout_results/linux_trusty_blink_rel/29630/layout-test-results/results.html Original change's description: > remove fragile hack in addOval to avoid computing bounds > > Bug: skia: > Change-Id: Ide917f54633370f1fce46a115fa923794b981e2e > Reviewed-on: https://skia-review.googlesource.com/129461 > Reviewed-by: Mike Klein <mtklein@google.com> > Commit-Queue: Mike Reed <reed@google.com> TBR=mtklein@google.com,reed@google.com Change-Id: Ibadac8bbeca2b162d696e7cca51d580121afe71f No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/129442 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* drawPosText no longer obeys paint alignmentGravatar Herb Derby2018-05-21
| | | | | | | Change-Id: Iac498b54dea4aa1b203d2b9c58e15bb5f2147f82 Reviewed-on: https://skia-review.googlesource.com/129462 Commit-Queue: Herb Derby <herb@google.com> Reviewed-by: Ben Wagner <bungeman@google.com>
* ccpr: Abstract the draws list in a separate classGravatar Chris Dalton2018-05-21
| | | | | | | | Bug: skia: Change-Id: I583c1bdc470e5830d041955d14b164fc00d5d014 Reviewed-on: https://skia-review.googlesource.com/129227 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Chris Dalton <csmartdalton@google.com>
* remove fragile hack in addOval to avoid computing boundsGravatar Mike Reed2018-05-21
| | | | | | | | Bug: skia: Change-Id: Ide917f54633370f1fce46a115fa923794b981e2e Reviewed-on: https://skia-review.googlesource.com/129461 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Reed <reed@google.com>
* IWYU for tests starting with 'D'.Gravatar Ben Wagner2018-05-21
| | | | | | | Change-Id: I9189e4b56ce1635b627119733447c2ed4220753d Reviewed-on: https://skia-review.googlesource.com/129319 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
* Reland "Remove GrBackendObject and all related functions from Skia."Gravatar Greg Daniel2018-05-21
| | | | | | | | | | | | | | | | | | | This is a reland of ccd4cfc23ebbbecbc6b292359352aad335ad7b73 Original change's description: > Remove GrBackendObject and all related functions from Skia. > > Bug: skia: > Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073 > Reviewed-on: https://skia-review.googlesource.com/125822 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Greg Daniel <egdaniel@google.com> Bug: skia: Change-Id: Ibd1b9bd04b36840d9d872e2f0970dd6bac378bc9 Reviewed-on: https://skia-review.googlesource.com/129380 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* remove defines and add commasGravatar Cary Clark2018-05-21
| | | | | | | | | | | | | | | | | | | | | | | | Preparation for generating bookmaker files for all remaining interfaces Standardize enum and enum classes by including a comma after the last entry. Replace flatten-related #define in public interfaces with their equivalent. The motivation is to give documentation something to refer to. An alternative would be to move part or all of this out of the public interface; something I can work on in a follow-up CL. R=reed@google.com,bsalomon@google.com Bug: skia:6898 Change-Id: I4b865f6ec3d8f5d31e50448fef7d2714510302f0 Reviewed-on: https://skia-review.googlesource.com/129312 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Cary Clark <caryclark@skia.org>
* Revert "remove toString"Gravatar Cary Clark2018-05-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 5191880cbf3ee4d122b0d11b4945fbab0784fda7. Reason for revert: broke flutter Original change's description: > remove toString > > toString may have been used by obsolete debugger only > find out if that is so > > R=​brianosman@google.com,bsalomon@google.com > > Docs-Preview: https://skia.org/?cl=119894 > Bug:830651 > Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd > Reviewed-on: https://skia-review.googlesource.com/119894 > Commit-Queue: Cary Clark <caryclark@google.com> > Reviewed-by: Brian Salomon <bsalomon@google.com> TBR=bsalomon@google.com,brianosman@google.com,caryclark@google.com,caryclark@skia.org Change-Id: I9f81de6c3615ee0608bcea9081b77239b4b8816c No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: 830651 Reviewed-on: https://skia-review.googlesource.com/129340 Reviewed-by: Cary Clark <caryclark@google.com> Commit-Queue: Cary Clark <caryclark@google.com>
* remove toStringGravatar Cary Clark2018-05-20
| | | | | | | | | | | | | | toString may have been used by obsolete debugger only find out if that is so R=brianosman@google.com,bsalomon@google.com Docs-Preview: https://skia.org/?cl=119894 Bug:830651 Change-Id: I737f19b7d3fbc869bea2f443fa3b5ed7c1393ffd Reviewed-on: https://skia-review.googlesource.com/119894 Commit-Queue: Cary Clark <caryclark@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
* tweak conservative bounds value to save aberrant cubicGravatar Mike Reed2018-05-18
| | | | | | | | Bug: 844457 Change-Id: Ia3c7c0592df59022cf04f6747b1fe30975431ea4 Reviewed-on: https://skia-review.googlesource.com/129200 Reviewed-by: Cary Clark <caryclark@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Add convenience overload of SkPointPriv::SetRectTriStrip that takes SkRectGravatar Brian Salomon2018-05-18
| | | | | | | Change-Id: Idf5bfafaf19c20f074f12d706b8b8984c5935e6d Reviewed-on: https://skia-review.googlesource.com/129185 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* GrTessellator: fix for zombie edge fuzzer crash.Gravatar Stephen White2018-05-18
| | | | | | | | | | | | | | | | While splitting one edge, merge_collinear_edges() may in rare cases merge the other edge of the intersection out of existence. split_edge() then brings these dead edges partially back to life, leaving the mesh in an inconsistent state. The fix is to null out the top and bottom pointers of dead edges to mark them as dead, and only split living edges. Bug: skia:7911 Change-Id: I1c0b59581acfcd0b8191f2d129b33f7d0d1a2516 Reviewed-on: https://skia-review.googlesource.com/129181 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Stephen White <senorblanco@chromium.org>
* Make SkStream readers report failure.Gravatar Ben Wagner2018-05-18
| | | | | | | | | | This also fixes an issue noticed while making this change where SkFontDescriptor improperly round trips negative axis values. Change-Id: Iacc5929a185659dcacc18c802c4908e4f34c6899 Reviewed-on: https://skia-review.googlesource.com/128341 Commit-Queue: Ben Wagner <bungeman@google.com> Reviewed-by: Leon Scroggins <scroggo@google.com>
* fonts: Handle fallback to using paths for text rendering for remoting.Gravatar Khushal2018-05-17
| | | | | | | | | | | | | | | | | | SkRemoteGlyphCache only sends images for glyphs, even for cases where the gpu falls back to drawing text as paths. This includes cases in SkDraw::ShouldDrawTextAsPaths and when the glyph exceeds the max bounds that can fit on the atlas. Fix this by identifying these cases in the renderer and sending paths instead. Note: We still don't handle distance field text correctly. R=herb@google.com, bsalomon@google.com Bug: skia:7913 Change-Id: I17d4eccbeaa2e995ae67b61c76cebd27f8280329 Reviewed-on: https://skia-review.googlesource.com/128203 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Khusal Sagar <khushalsagar@chromium.org>
* Fix srcBounds computation in SkMatrixConvolutionImageFilterGravatar Robert Phillips2018-05-17
| | | | | | | | | | | Note that this does change the behavior of the cropRect for the repeated case. The cropRect now only acts as a hard clip on the output. BUG= skia:7766 Change-Id: I1d66678bc797cd4835701cd20c36e68b22ac880a Reviewed-on: https://skia-review.googlesource.com/127338 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* Rewrite GrQuad to use separate arrays of x and y values to be Sk4f friendly.Gravatar Brian Salomon2018-05-17
| | | | | | | Change-Id: Ie2ad197c5f17849fe6e034b60bc7ec18a00edb24 Reviewed-on: https://skia-review.googlesource.com/128842 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* mapRect should not fiddle with nonfinite values.Gravatar Cary Clark2018-05-17
| | | | | | | | | Docs-Preview: https://skia.org/?cl=128682 Bug: skia:7967 Change-Id: Ic43387b7705ee8385b8df2430886484ff856077c Reviewed-on: https://skia-review.googlesource.com/128682 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* fonts: Fix memory accounting for deserialized glyphs.Gravatar Khushal2018-05-15
| | | | | | | | | | | | | | | When deserializing glyphs in the SkRemoteGlyphCache, we allocate from the arena for the SkGlyphCache but don't account for it in the total memory used by the cache. Fix that and avoid exposing the SkArenaAlloc from SkGlyphCache, since that can result in such brittle use. R=herb@google.com Bug: 829622 Change-Id: Iecff9ce6e0ed2c641957535363edec3e3fad178d Reviewed-on: https://skia-review.googlesource.com/128112 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Khusal Sagar <khushalsagar@chromium.org>
* handle huge normalize requests (including non-finite x or y)Gravatar Mike Reed2018-05-14
| | | | | | | | Bug: oss-fuzz:8023 Change-Id: I622b6e335d9efbe599fa9047b3a6fcee1664aa4a Reviewed-on: https://skia-review.googlesource.com/124581 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
* Minor refactoring to image filtersGravatar Robert Phillips2018-05-14
| | | | | | | | | | This pulls the boring parts out of: https://skia-review.googlesource.com/c/skia/+/127338 (Fix srcBounds computation in SkMatrixConvolutionImageFilter) TBR=bsalomon@google.com Change-Id: Iade788fcc96c4c16989d13e7592030a6a1d3f170 Reviewed-on: https://skia-review.googlesource.com/127573 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Make GrCaps and GrShaderCaps private.Gravatar Brian Salomon2018-05-11
| | | | | | | | | Moves getCaps() from GrContext to GrContextPriv and removes unused refCaps(). Change-Id: Ic6a8951b656c0d1b2773eae73bff8e88af819866 Reviewed-on: https://skia-review.googlesource.com/127389 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
* Revert "Remove GrBackendObject and all related functions from Skia."Gravatar Brian Osman2018-05-10
| | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit ccd4cfc23ebbbecbc6b292359352aad335ad7b73. Reason for revert: Fuchsia not building again. (Flutter roll may have been reverted?) Original change's description: > Remove GrBackendObject and all related functions from Skia. > > Bug: skia: > Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073 > Reviewed-on: https://skia-review.googlesource.com/125822 > Reviewed-by: Brian Salomon <bsalomon@google.com> > Commit-Queue: Greg Daniel <egdaniel@google.com> TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com Change-Id: Ie2c518b84b0c9513c0c622082de2831088b1ad8d No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia: Reviewed-on: https://skia-review.googlesource.com/127480 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
* Revert "strip down SkICC.cpp"Gravatar Mike Klein2018-05-10
| | | | | | | | | | | | This reverts commit eab50eb9c6117c2a9d0e5648f89cebbb4dbd9d30 and this tiny bit of e61b969a07ba3ebe9e47e61381ad16c5d2c549a2: https://skia-review.googlesource.com/c/skia/+/127122/3/tests/ICCTest.cpp Change-Id: I4306e5118a4e5eb88c05078186a28bd443fd76f7 Reviewed-on: https://skia-review.googlesource.com/127305 Reviewed-by: Mike Klein <mtklein@chromium.org> Commit-Queue: Mike Klein <mtklein@chromium.org>
* non-linear blending first stepsGravatar Mike Klein2018-05-10
| | | | | | | | | | | | | | | | | | | | | | | Code: - Add a non-linear blending bit and makeNonlinearBlending() to SkColorSpace - remove enough F16=linear checks to make it possible to create surfaces and encode pngs with nonlinear F16 Testing: - add "esrgb" software config to DM, run it - add "srgbnl" software config, run it - deemphasize importance of "srgb" config on bots - update unit tests to reflect relaxed F16 constraints - add a new unit test file with _really_ basic tests, and a new unit test that's not working yet Bug: skia:7942 Change-Id: I8ac042bdf9f3d791765393b68fd9256375184d83 Reviewed-on: https://skia-review.googlesource.com/127325 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
* rm SkColorSpace_NewGravatar Mike Klein2018-05-10
| | | | | | | | | | We think we can evolve SkColorSpace_XYZ into the One True SkColorSpace. Change-Id: If93493145d78b388f3a0739cc7ccd6e232380733 Reviewed-on: https://skia-review.googlesource.com/127326 Auto-Submit: Mike Klein <mtklein@chromium.org> Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Brian Osman <brianosman@google.com>
* Remove GrBackendObject and all related functions from Skia.Gravatar Greg Daniel2018-05-10
| | | | | | | | Bug: skia: Change-Id: I59434b7477c0bc26fd982bd81eb97ab94bbba073 Reviewed-on: https://skia-review.googlesource.com/125822 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* SkColorSpace::Make(const skcms_ICCProfile&)Gravatar Mike Klein2018-05-09
| | | | | | | | Change-Id: Ib12208d6c148f143fdd0b54538d852b97616a72d Reviewed-on: https://skia-review.googlesource.com/127122 Commit-Queue: Mike Klein <mtklein@chromium.org> Auto-Submit: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* strip down SkICC.cppGravatar Mike Klein2018-05-09
| | | | | | | | | | | | | | | | Most of SkICC{.h,.cpp} is unused and gone. I've renamed the part that's left to SkWriteICCProfile() and tweaked its API just a little, leaving SkICC:WriteToICC() a wrapper around it. Most of the tests in ICCTest.cpp are moot and deleted, but a few looked somewhat valuable so I've kept them with a little modification. Change-Id: Ia1bb4c772af679885e17dac53d213c315ad0828c Reviewed-on: https://skia-review.googlesource.com/127022 Auto-Submit: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Mike Klein <mtklein@chromium.org>
* Revert "Revert "SkAdvancedTypefaceMetrics: factor out GlyphToUnicode""Gravatar Hal Canary2018-05-09
| | | | | | | | | This reverts commit 97c1108607584b6050a6880d6ce22846e4913a92. Change-Id: Ic3c6addc64ced39766bbee3e10b4d88faf61ba2f Reviewed-on: https://skia-review.googlesource.com/127021 Reviewed-by: Hal Canary <halcanary@google.com> Commit-Queue: Hal Canary <halcanary@google.com>
* Revert "SkAdvancedTypefaceMetrics: factor out GlyphToUnicode"Gravatar Greg Daniel2018-05-09
| | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 1c2bcd8b14e029a70e88b1e81acd29553cab0d1c. Reason for revert: breaking chrome roll Original change's description: > SkAdvancedTypefaceMetrics: factor out GlyphToUnicode > > Change-Id: Iedce8c1ea2c405d5ab64ccac353970d5cd2b9d63 > Reviewed-on: https://skia-review.googlesource.com/126507 > Commit-Queue: Hal Canary <halcanary@google.com> > Reviewed-by: Ben Wagner <bungeman@google.com> TBR=halcanary@google.com,bungeman@google.com,reed@google.com Change-Id: Ib1ff8484ffd09cdb88d461ac00745aa32c191124 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/127000 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* SkAdvancedTypefaceMetrics: factor out GlyphToUnicodeGravatar Hal Canary2018-05-09
| | | | | | | Change-Id: Iedce8c1ea2c405d5ab64ccac353970d5cd2b9d63 Reviewed-on: https://skia-review.googlesource.com/126507 Commit-Queue: Hal Canary <halcanary@google.com> Reviewed-by: Ben Wagner <bungeman@google.com>
* Treat SkFILEStream's fOriginalOffset as the startGravatar Leon Scroggins III2018-05-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: b/78866720 ::rewind() rewinds to fOriginalOffset ::seek(position) seeks to position + fOriginalOffset ::move(offset) will not move < fOriginalOffset ::getPosition() returns position relative to fOriginalOffset ::getLength() returns full size minus fOriginalOffset ::duplicate() and ::fork() pass on fOriginalOffset Android may create an SkFILEStream using a file descriptor whose offset is at the beginning of the data that Android cares about. Treat all positions in SkFILEStream as relative to that original offset. This allows AnimatedImageDrawable to read directly from the SkFILEStream, rather than using an SkFrontBufferedStream and forcing SkGifCodec to cache data for later use. This fixes a TODO that was introduced in https://skia-review.googlesource.com/c/skia/+/9498 and takes it a step further. In that CL, bungeman@ and I discussed the change and decided to "leave this alone for now to avoid changing behavior". Doing a code search today, the only two callers want the new behavior. Change-Id: I9211394d5b730adf528fac0df0af7a664b1295be Reviewed-on: https://skia-review.googlesource.com/126511 Reviewed-by: Ben Wagner <bungeman@google.com> Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Leon Scroggins <scroggo@google.com>
* track bounds of top-level control opsGravatar Mike Klein2018-05-07
| | | | | | | | | | | | | | | | We don't need an explicit save-restore block to determine the bounds of top-level control operations... the implicit save-restore that all picutres have should logically work the same way. The commented test failed before this and passes now. Bug: skia:7735 Change-Id: Ibd31a3a9b0b48042ab3869a6bb57bc8d8bb78c09 Reviewed-on: https://skia-review.googlesource.com/126460 Commit-Queue: Mike Klein <mtklein@chromium.org> Commit-Queue: Brian Osman <brianosman@google.com> Auto-Submit: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* Don't use getDeviceClipBounds() to bound pic ops.Gravatar Mike Klein2018-05-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The values returned by SkCanvas::getDeviceClipBounds() are in the right space, but have extra constraints on them that are not desirable for bounding the logical bounds of draw operations: - they are integral - they are non-negative We've been intersecting the bounds of each operation with these bounds, which means we're mixing these bogus constraints into the bounds of each recorded operation. This percolates up to the SkPicutre cull rect too. The most egregious way to see the problem is to record a draw op entirely in negative space... it'll come back with empty logical bounds rather than its correct (negative-space) bounds. I've added a test for this, and another test I also think should be passing but left making it so as a follow up. I've had to disable a couple tests asserting clips affect the bounds. :/ A possible follow-up might go back to using the clips to tighten the bounds of the ops, just so long as we take the original user bounds and map them with the CTM through to device space ourselves, rather than relying on the recording canvas' clip stack. I think this means we'd need to maintain our own stack of device-space float SkRect clip bounds while calculating these op bounds. Bug: skia:7735 Change-Id: I6bf15f6b2a9ba4329a4eeae7f9d57aa8729ec1bb Reviewed-on: https://skia-review.googlesource.com/126002 Commit-Queue: Mike Klein <mtklein@chromium.org> Commit-Queue: Brian Osman <brianosman@google.com> Auto-Submit: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* Remove fCacheKeys from SkImageFilter.Gravatar Ben Wagner2018-05-04
| | | | | | | | | | | No public API changes. Bug: skia:7666, skia:7887 Change-Id: I8ac4ec37dd3d0fcc050bc977db41439a8e18895f Reviewed-on: https://skia-review.googlesource.com/125500 Commit-Queue: Ben Wagner <benjaminwagner@google.com> Reviewed-by: Mike Klein <mtklein@google.com> Auto-Submit: Ben Wagner <benjaminwagner@google.com>
* Remove legacy guard flagsGravatar Yuqian Li2018-05-03
| | | | | | | | | Bug: skia: Change-Id: I3b526f2caec6766faea72cdc89550f50e17c71d2 Reviewed-on: https://skia-review.googlesource.com/125746 Reviewed-by: Cary Clark <caryclark@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Yuqian Li <liyuqian@google.com>
* fonts: Cleanup header guard and stray printfs.Gravatar Khushal2018-05-03
| | | | | | | | | | R=herb@google.com Change-Id: I9d2865438f61f8e246f3a5e3548c0befbf402bc1 Reviewed-on: https://skia-review.googlesource.com/125643 Auto-Submit: Khusal Sagar <khushalsagar@chromium.org> Commit-Queue: Herb Derby <herb@google.com> Reviewed-by: Herb Derby <herb@google.com>
* Add internal grsurface flag to track if using gl rectangle or external texture.Gravatar Greg Daniel2018-05-02
| | | | | | | | Bug: skia: Change-Id: I84963833bbc3ae957c919a19f6e78fce2c9de7ef Reviewed-on: https://skia-review.googlesource.com/125294 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
* fonts: Reland push font remoting.Gravatar Khushal2018-05-02
| | | | | | | | | | | | | | | | | | | This relands the following changes: 1) https://skia-review.googlesource.com/c/skia/+/120283 2) https://skia-review.googlesource.com/c/skia/+/125029 3) https://skia-review.googlesource.com/c/skia/+/125140 The original changes had to be reverted due to a memory leak in SkBaseDevice from SkTextBlobCacheDiffCanvas. This has been addressed by https://skia-review.googlesource.com/c/skia/+/125160 TBR=herb@google.com Bug: skia:7515, 831354 Change-Id: I73f4fcb1c397f31bf01553ff48c71ed2d6dd0770 Reviewed-on: https://skia-review.googlesource.com/125326 Commit-Queue: Khusal Sagar <khushalsagar@chromium.org> Reviewed-by: Khusal Sagar <khushalsagar@chromium.org>
* Reland "Remove devKerning"Gravatar Herb Derby2018-05-02
| | | | | | | | | | | | | | | | | | | | | | This is a reland of c86c5c0144b85d0bc8ec791f9609ee2d4e7d835a Original change's description: > Remove devKerning > > Dev kerning is not supported by any scalers. This is > mostly removed. The remaining fields fRsbDelta and > fLsbDelta are kept to keep Android compiling. > > Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809 > Reviewed-on: https://skia-review.googlesource.com/124921 > Reviewed-by: Ben Wagner <bungeman@google.com> > Commit-Queue: Herb Derby <herb@google.com> Change-Id: Ibf5fac5f1442c7e62392d5146ad460da27b10d5c Reviewed-on: https://skia-review.googlesource.com/125300 Reviewed-by: Herb Derby <herb@google.com> Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Herb Derby <herb@google.com>
* Take sk_sp<SkDevice> instead of SkDevice*Gravatar Herb Derby2018-05-02
| | | | | | | | | Change-Id: I0b296bf5b80adc19758a3dc99160be9d2ed05680 Reviewed-on: https://skia-review.googlesource.com/125160 Commit-Queue: Herb Derby <herb@google.com> Commit-Queue: Mike Reed <reed@google.com> Reviewed-by: Mike Reed <reed@google.com> Auto-Submit: Herb Derby <herb@google.com>
* Revert "fonts: Set up remote glyph caching to push fonts."Gravatar Mike Klein2018-05-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 101d56359a5a5dc3b8a2a4149ac171e25eb0bec0. Reason for revert: 5 of 5 Original change's description: > fonts: Set up remote glyph caching to push fonts. > > Currently the SkStrikeClient is designed to pull fonts from the server > on demand, and to pre-fetch a batched request by analyzing the ops using > a SkTextBlobCacheDiffCanvas. This change modifies the design to support > a push based model, where the server pushes fonts required by the client > and sets up the requisite SkGlyphCaches on the client prior to > rasterizing the ops. > > This model still relies on the SkTextBlobCacheDiffCanvas for analyzing > the glyphs required for rasterizing an op. The glyph caches required for > raster are locked and missing glyphs to be sent to the client are tracked > by the SkStrikeServer. The embedder can serialize this font data at any > point, but must ensure that this data is deserialized by the > SkStrikeClient at the remote end, before rasterizing any ops analyzed > prior to serialization. Any refs on the caches are released once the > font data is serialized by the server. > > The locking of glyph caches relies on the embedder providing discardable > handles. These handles can be created on the server and serialized to be > sent to the client, and map to an instance of SkGlyphCache. This allows > the server to control the lifetime of the caches on the client. > > Bug: skia:7515 > Change-Id: Id39f346b47b60899778404bbd0429ee811d0e53b > Reviewed-on: https://skia-review.googlesource.com/120283 > Commit-Queue: Khusal Sagar <khushalsagar@chromium.org> > Reviewed-by: Herb Derby <herb@google.com> TBR=mtklein@google.com,herb@google.com,khushalsagar@chromium.org Change-Id: If72caf968ddcbf70b8b9d71782a2339a118ed202 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia:7515 Reviewed-on: https://skia-review.googlesource.com/125264 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* Revert "Remove devKerning"Gravatar Mike Klein2018-05-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit c86c5c0144b85d0bc8ec791f9609ee2d4e7d835a. Reason for revert: 4 of 5 Original change's description: > Remove devKerning > > Dev kerning is not supported by any scalers. This is > mostly removed. The remaining fields fRsbDelta and > fLsbDelta are kept to keep Android compiling. > > Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809 > Reviewed-on: https://skia-review.googlesource.com/124921 > Reviewed-by: Ben Wagner <bungeman@google.com> > Commit-Queue: Herb Derby <herb@google.com> TBR=bungeman@google.com,herb@google.com,reed@google.com Change-Id: If865f702868192a1b72cd811baa996dd1282bbce No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/125263 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* Revert "fonts: Bandaid fix for desc mismatch in SkRemoteGlyphCache."Gravatar Mike Klein2018-05-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit ef4142a9bc5fb5fe3158139e18f41e7da867ff93. Reason for revert: 2 of 5 Original change's description: > fonts: Bandaid fix for desc mismatch in SkRemoteGlyphCache. > > Since the typeface proxies on the client don't perform the same > filtering done on the server during SkDescriptor generation, it causes > the desc mismatches during raster. Disable this filtering on the server > until this is resolved. > > Bug: 831354 > Change-Id: I5683372fb497a4874dede5aec9c734cd1392872c > Reviewed-on: https://skia-review.googlesource.com/125140 > Commit-Queue: Khusal Sagar <khushalsagar@chromium.org> > Reviewed-by: Herb Derby <herb@google.com> TBR=herb@google.com,khushalsagar@chromium.org Change-Id: I8e732f57aa49323c186e3c4ea6120ff1caf8e25b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: 831354 Reviewed-on: https://skia-review.googlesource.com/125261 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
* fonts: Bandaid fix for desc mismatch in SkRemoteGlyphCache.Gravatar Khushal2018-05-01
| | | | | | | | | | | | | Since the typeface proxies on the client don't perform the same filtering done on the server during SkDescriptor generation, it causes the desc mismatches during raster. Disable this filtering on the server until this is resolved. Bug: 831354 Change-Id: I5683372fb497a4874dede5aec9c734cd1392872c Reviewed-on: https://skia-review.googlesource.com/125140 Commit-Queue: Khusal Sagar <khushalsagar@chromium.org> Reviewed-by: Herb Derby <herb@google.com>
* Remove devKerningGravatar Herb Derby2018-05-01
| | | | | | | | | | | Dev kerning is not supported by any scalers. This is mostly removed. The remaining fields fRsbDelta and fLsbDelta are kept to keep Android compiling. Change-Id: If1a9ee9bb599d4e1bdf4b3751ac0c65246350809 Reviewed-on: https://skia-review.googlesource.com/124921 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Herb Derby <herb@google.com>
* Fix index overflow check for rewriting fans as triangles.Gravatar Brian Salomon2018-05-01
| | | | | | | | | | Not only could the old test cause int overflow, it was just wrong. Bug: skia:8085 Change-Id: Id6b81f4aa1b115f0dbfd2266aee8fab5d5d30aee Reviewed-on: https://skia-review.googlesource.com/124779 Reviewed-by: Chris Dalton <csmartdalton@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
* fonts: Set up remote glyph caching to push fonts.Gravatar Khushal2018-05-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently the SkStrikeClient is designed to pull fonts from the server on demand, and to pre-fetch a batched request by analyzing the ops using a SkTextBlobCacheDiffCanvas. This change modifies the design to support a push based model, where the server pushes fonts required by the client and sets up the requisite SkGlyphCaches on the client prior to rasterizing the ops. This model still relies on the SkTextBlobCacheDiffCanvas for analyzing the glyphs required for rasterizing an op. The glyph caches required for raster are locked and missing glyphs to be sent to the client are tracked by the SkStrikeServer. The embedder can serialize this font data at any point, but must ensure that this data is deserialized by the SkStrikeClient at the remote end, before rasterizing any ops analyzed prior to serialization. Any refs on the caches are released once the font data is serialized by the server. The locking of glyph caches relies on the embedder providing discardable handles. These handles can be created on the server and serialized to be sent to the client, and map to an instance of SkGlyphCache. This allows the server to control the lifetime of the caches on the client. Bug: skia:7515 Change-Id: Id39f346b47b60899778404bbd0429ee811d0e53b Reviewed-on: https://skia-review.googlesource.com/120283 Commit-Queue: Khusal Sagar <khushalsagar@chromium.org> Reviewed-by: Herb Derby <herb@google.com>