How tro draw fading path
问题 How can I draw Path with fading (opacity or thicknes) line? Something like this. I know there is LinearGradient shader for Paint , but it won't bend along the Path . One possible solution might be to get points along the Path and just draw it by myself through the segments`. But I coouldn't find any method for that either. 回答1: I came up with the following code. The mos important thing is PathMeasure's getPosTan() method. if (getGesturePath() != null) { final short steps = 150; final byte