Code example for PathMeasure

0
 
public class PathAnimation extends Animation {
    private PathMeasure measure;
    private float[] pos = new float[2];
    public PathAnimation(Path path) {
        measure = new PathMeasure(path, false);
    } 
 
    @Override 
    protected void applyTransformation(float interpolatedTime, Transformation t){
        measure.getPosTan(measure.getLength() * interpolatedTime, pos,null);
        t.getMatrix().setTranslate(pos[0], pos[1]);
    } 
} 
Connect your IDE to all the code out there  Get Codota for Java