ACarter ACarter - 2 months ago 6x
Android Question

Set the interpolator for android animations in Java

This seems very simple: I'm trying to set the interpolator to be used for an animation in my App. I need to set this in the Java code, not the XML (It will change according to various things).

From the android website, I've found


However, I'm not sure how to use this.

I've tried just feeding in the interpolar name (ie.
), but this did nothing.

I tried
, but Intellisense said
anim cannot be resolved or is not a field

So how can I set the interpolator from the Java?

setInterpolator(new BounceInterpolator());