Implement SkHighContrastFilter
authorDominic Mazzoni <dmazzoni@chromium.org>
Tue, 14 Feb 2017 19:15:31 +0000 (11:15 -0800)
committerSkia Commit-Bot <skia-commit-bot@chromium.org>
Thu, 16 Feb 2017 02:34:44 +0000 (02:34 +0000)
commit394d414452a5d654731b0b5a3669f8e2420048b3
tree78dca199a9b3fb2abb5b62e0dcc537cb7c257348
parente1caee1ad884def91b8afb50e5672f1f0ee278f1
Implement SkHighContrastFilter

This is a color filter to apply several contrast adjustments for users
with low vision, including inverting the colors (in either RGB or HSL
space), applying gamma correction, converting to grayscale, and increasing
the contrast.

BUG=skia:6235

CQ_INCLUDE_TRYBOTS=skia.primary:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD

Change-Id: Icb8f3e290932d8bcd9387fb1f39dd20767e15cf6
Reviewed-on: https://skia-review.googlesource.com/7460
Commit-Queue: Mike Klein <mtklein@chromium.org>
Reviewed-by: Mike Reed <reed@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
gm/highcontrastfilter.cpp [new file with mode: 0644]
gn/effects.gni
gn/gm.gni
gn/tests.gni
include/effects/SkHighContrastFilter.h [new file with mode: 0644]
src/core/SkRasterPipeline.h
src/effects/SkHighContrastFilter.cpp [new file with mode: 0644]
src/opts/SkRasterPipeline_opts.h
src/ports/SkGlobalInitialization_default.cpp
tests/HighContrastFilterTest.cpp [new file with mode: 0644]