commit | 0bd783f951a004ccca175b166f2b30a0fd18a6f6 | [log] [tgz] |
---|---|---|
author | Brian Osman <brianosman@google.com> | Wed Jan 04 12:54:07 2017 -0500 |
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | Wed Jan 04 18:28:26 2017 +0000 |
tree | 3d0188619d3b4524e506e3a174ebbb61650db682 | |
parent | e151bdb357c21b833718b369fe8fbd7fd57ae474 [diff] |
Clamp premul colors correctly after a gamut change Textures that we sample on the GPU are always premul, so we should actually clamp to alpha. Colors that are xformed on the CPU are always unpremul, so clamping to [0,1] is correct. Add a comment explaining that. BUG=skia: Change-Id: I180f2d410f24afc78bd03ab8636a83fb443d68e2 Reviewed-on: https://skia-review.googlesource.com/6581 Commit-Queue: Brian Osman <brianosman@google.com> Reviewed-by: Mike Klein <mtklein@chromium.org>