Make consistent isRadiusIncreasing decision
This should not affect anything for now. But it may prevent some future problems where someone accidentally changed isRadiusIncreasing implementation, and getting confused by the unexpected shading behavior. Bug: skia: Change-Id: I45e83f4bc9eefbdc1ad1c196a43444e24c782711 Reviewed-on: https://skia-review.googlesource.com/115162 Reviewed-by: Greg Daniel <egdaniel@google.com> Commit-Queue: Yuqian Li <liyuqian@google.com>
This commit is contained in:
parent
3b68882918
commit
ec46871a0c
@ -239,7 +239,7 @@ protected:
|
||||
const char* p = coords2D.c_str();
|
||||
|
||||
if (effect.getType() == Type::kRadial) {
|
||||
char sign = effect.diffRadius() < 0 ? '-' : '+';
|
||||
char sign = effect.isRadiusIncreasing() ? '+' : '-';
|
||||
fragBuilder->codeAppendf("half %s = %clength(%s) - %s;", tName, sign, p, p0.c_str());
|
||||
} else {
|
||||
// output will default to transparent black (we simply won't write anything
|
||||
|
Loading…
Reference in New Issue
Block a user