Clarify adjustMatrixAndAppendStages semantics

A false return from adjustMatrixAndAppendStages() currently means we'll
attempt to create a legacy context wrapper stage.

Only two gradient impls can return false, and they don't really want the
same thing:

1) linear returns false when the stops are compressed, to get the "nice"
   legacy blend color behavior

2) two-point radial returns false when it cannot map the center points
   (degenerate matrix); in this case we prolly don't want to draw at all

This setup made sense while we were retrofitting gradients with stages,
but now that all of them support RP, it is confusing to sometimes get
a legacy context wrapper even when we are specifically asked for stages.

I propose we align the semantics with SkShader::onAppendStages(), such
that a false return means "don't draw" rather than "try to draw with a
legacy context".

This means we're giving up the compressed stop behavior for linear, but
that's such an arbitrary corner case that I don't think we care at all.

Change-Id: I01256c4acb81b16fb68e6c74cf8d91ea77b95a3b
Reviewed-on: https://skia-review.googlesource.com/22541
Commit-Queue: Herb Derby <herb@google.com>
Reviewed-by: Herb Derby <herb@google.com>
3 files changed