New GM that exercises gamma-correctness in various parts of the pipeline.
authorbrianosman <brianosman@google.com>
Fri, 26 Feb 2016 19:57:23 +0000 (11:57 -0800)
committerCommit bot <commit-bot@chromium.org>
Fri, 26 Feb 2016 19:57:23 +0000 (11:57 -0800)
commite5824b90da4568544ecbf71ba5d690095b31307e
tree28d1836813e236e33f1da9c9b3e878aedc89b3c6
parenteb79eea617d6d4ef6951206e51643ec4ef891920
New GM that exercises gamma-correctness in various parts of the pipeline.

Attempts to render 50% grey through many different techniques. Only the first one (black/white dither) is guaranteed to be correct. This serves as ground-truth for all the others (independent of whatever your display may or may not be doing when viewing the output of the GM).

Current tests:
- Texture bilerp
- Texture scale (ie mipmaps)
- Simple paint color
- Gradient
- A handful of Xfer modes
- 50% grey bitmaps, both linear and sRGB
- Bitmaps wrapped in shaders, which hits a different raster code path

TODO:
- Test coverage (rather than alpha)?
- Text, Blur, etc...?

Re-landing this without the blitter selection change, which may have caused a regression. Also updated the text color so it's legible against both black (SampleApp) and white (gold).

BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1740213003

Review URL: https://codereview.chromium.org/1740213003
gm/gamma.cpp [new file with mode: 0644]