aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkSRGB.cpp
Commit message (Collapse)AuthorAge
* Revert "update SkColor4f::FromColor() to preserve transfer function"Gravatar Robert Phillips2018-07-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 9e229233a67b36a508d3c753a5b93a022369c5f7. Reason for revert: See if blocking Android roll Original change's description: > update SkColor4f::FromColor() to preserve transfer function > > This kills off some sRGB tables, > and lots of call sites can now use SkColor4f::FromColor(). > > It doesn't seem important to keep this test. > > Change-Id: Ia79ec8ace45e80bbc7a1e33f560f59289e61b2fb > Reviewed-on: https://skia-review.googlesource.com/141046 > Commit-Queue: Mike Klein <mtklein@chromium.org> > Reviewed-by: Brian Osman <brianosman@google.com> TBR=mtklein@chromium.org,brianosman@google.com Change-Id: I9d76e4ccf8a101853a7404abb33bdab9e0c64c25 No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://skia-review.googlesource.com/141181 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
* update SkColor4f::FromColor() to preserve transfer functionGravatar Mike Klein2018-07-12
| | | | | | | | | | | | This kills off some sRGB tables, and lots of call sites can now use SkColor4f::FromColor(). It doesn't seem important to keep this test. Change-Id: Ia79ec8ace45e80bbc7a1e33f560f59289e61b2fb Reviewed-on: https://skia-review.googlesource.com/141046 Commit-Queue: Mike Klein <mtklein@chromium.org> Reviewed-by: Brian Osman <brianosman@google.com>
* Optimize mipmap downsample_2_2 in sRGB modeGravatar Matt Sarett2017-03-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reland of: https://skia-review.googlesource.com/c/9386/ Desktop (HP z620) Before: mipmap_build_2048x2048_0_gamma 10.5 ms mipmap_build_2048x2048_1_gamma 77.1 ms After: mipmap_build_2048x2048_0_gamma 10.5 ms mipmap_build_2048x2048_1_gamma 41.0 ms Pixel XL Before: mipmap_build_2048x2048_0_gamma 160 ms mipmap_build_2048x2048_1_gamma 1.5 s After: mipmap_build_2048x2048_0_gamma 160 ms mipmap_build_2048x2048_1_gamma 570 ms Also provides marginal performance improvements for other sRGB downsamples. CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-GCC-ShuttleA-GPU-GTX550Ti-x86_64-Release-Valgrind_PreAbandonGpuContext BUG=skia: Change-Id: Ia82fc2ef795e1bb63a4a9deac5e38f5fde39f651 Reviewed-on: https://skia-review.googlesource.com/9455 Reviewed-by: Matt Sarett <msarett@google.com>
* Revert "Optimize mipmap downsample_2_2 in sRGB mode"Gravatar Derek Sollenberger2017-03-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 3ea01f72f20d4f58bf0dcd420fa5c2724b67ac8d. Reason for revert: triggering errors on the MSAN bots Original change's description: > Optimize mipmap downsample_2_2 in sRGB mode > > Desktop (HP z620) > Before: > mipmap_build_2048x2048_0_gamma 10.5 ms > mipmap_build_2048x2048_1_gamma 77.1 ms > After: > mipmap_build_2048x2048_0_gamma 10.5 ms > mipmap_build_2048x2048_1_gamma 25.1 ms > > Pixel XL > Before: > mipmap_build_2048x2048_0_gamma 160 ms > mipmap_build_2048x2048_1_gamma 1.5 s > After: > mipmap_build_2048x2048_0_gamma 160 ms > mipmap_build_2048x2048_1_gamma 313 ms > > Also provides marginal performance improvements > for other sRGB downsamples. > > BUG=skia: > > Change-Id: Icfcd2ccd69676ccf3822db8042a4698e4464bb71 > Reviewed-on: https://skia-review.googlesource.com/9386 > Commit-Queue: Matt Sarett <msarett@google.com> > Reviewed-by: Mike Klein <mtklein@chromium.org> > TBR=mtklein@chromium.org,mtklein@google.com,msarett@google.com,brianosman@google.com,reed@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Change-Id: I06907fb1691077a03daadc0980e86393bc08d9c5 Reviewed-on: https://skia-review.googlesource.com/9450 Reviewed-by: Derek Sollenberger <djsollen@google.com> Commit-Queue: Derek Sollenberger <djsollen@google.com>
* Optimize mipmap downsample_2_2 in sRGB modeGravatar Matt Sarett2017-03-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Desktop (HP z620) Before: mipmap_build_2048x2048_0_gamma 10.5 ms mipmap_build_2048x2048_1_gamma 77.1 ms After: mipmap_build_2048x2048_0_gamma 10.5 ms mipmap_build_2048x2048_1_gamma 25.1 ms Pixel XL Before: mipmap_build_2048x2048_0_gamma 160 ms mipmap_build_2048x2048_1_gamma 1.5 s After: mipmap_build_2048x2048_0_gamma 160 ms mipmap_build_2048x2048_1_gamma 313 ms Also provides marginal performance improvements for other sRGB downsamples. BUG=skia: Change-Id: Icfcd2ccd69676ccf3822db8042a4698e4464bb71 Reviewed-on: https://skia-review.googlesource.com/9386 Commit-Queue: Matt Sarett <msarett@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org>
* Move sRGB <-> linear conversion components to their own files.Gravatar mtklein2016-07-08
| | | | | | | | | | | | | | | This makes them a little easier to use outside SkColorXform code. I've added some notes about how best to use them and their eccentricities, and added a test. Ultimately any software sRGB <-> linear conversion should funnel somehow through here. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2128893002 CQ_EXTRA_TRYBOTS=client.skia.android:Test-Android-GCC-Nexus5-CPU-NEON-Arm7-Release-Trybot;client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Committed: https://skia.googlesource.com/skia/+/45e58c8807179638980aae8503573b950b844e4c Review-Url: https://codereview.chromium.org/2128893002
* Revert of Move sRGB <-> linear conversion components to their own files. ↵Gravatar mtklein2016-07-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (patchset #5 id:80001 of https://codereview.chromium.org/2128893002/ ) Reason for revert: Monotonicity assert is failing on ARM. (Different rsqrt() and invert() precision?) Will investigate a bit tomorrow... might reland with the test TODO. Original issue's description: > Move sRGB <-> linear conversion components to their own files. > > This makes them a little easier to use outside SkColorXform code. > > I've added some notes about how best to use them and their eccentricities, and added a test. > > Ultimately any software sRGB <-> linear conversion should funnel somehow through here. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2128893002 > CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot > > Committed: https://skia.googlesource.com/skia/+/45e58c8807179638980aae8503573b950b844e4c TBR=reed@google.com,msarett@google.com,mtklein@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2131793002
* Move sRGB <-> linear conversion components to their own files.Gravatar mtklein2016-07-07
This makes them a little easier to use outside SkColorXform code. I've added some notes about how best to use them and their eccentricities, and added a test. Ultimately any software sRGB <-> linear conversion should funnel somehow through here. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2128893002 CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review-Url: https://codereview.chromium.org/2128893002