How can i reverse this animation?
path = new AnimatorPath();
path.moveTo(0, 0);
path.curveTo(-200, 200, -400, 100, -600, 50);
anim = ObjectAnimator.ofObject(this, "fabLoc", new PathEvaluator(), path.getPoints().toArray());
anim.setInterpolator(new AccelerateInterpolator());
anim.setDuration(ANIMATION_DURATION);
anim.start();
i tried in this way but it's not working:
List<PathPoint> points = new ArrayList<>(path.getPoints());
Collections.reverse(points);
anim = ObjectAnimator.ofObject(this, "fabLoc", new PathEvaluator(),
points.toArray());
and when i click in the button i created that should reverse the animation nothing happens