How to create a custom gradient (e.g, implement Paint)?
I am trying to figure out how to create an elliptical gradient (i.e, instead of the color changing from point a to point b with a line function, the color changes from a center point, to a corner point, using an ellipse function).
I found the code to do a circle gradient, but now I need to adapt the logic to make it work for ellipses. Unfortunately, each time I change it, I cannot get the desired results. Here is the link to the code:
Any help is greatly appreciated.