ACarter ACarter -4 years ago 137
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?

Answer Source
setInterpolator(new BounceInterpolator());
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download