8

I would like to draw a circle filled with blended color with gradient. However, the existing android.graphics.Shader subclasses cannot meet my need. In short, I would like to control the color of each pixel in the circle myself. Is it possible to implement a custom Shadar object by extending android.graphics.Shader?

Mason Fong
  • 121
  • 1
  • 3

1 Answers1

3

I am not sure about subclassing android.graphics.Shader

But if you are using OpenGl ES 2.0 you can write your own Shader using GLSL which gives you very high flexibilty.

Maybe have a look at this question.

Community
  • 1
  • 1
micha
  • 47,774
  • 16
  • 73
  • 80