LottieInterpolatedValue(T startValue, T endValue) { this(startValue, endValue, new LinearInterpolator()); }
public static Interpolator getLinearInterpolator() { if (linear == null) { linear = new LinearInterpolator(); } return linear; }
public void setStartInterpolator(Interpolator startInterpolator) { mStartInterpolator = startInterpolator; if (mStartInterpolator == null) { mStartInterpolator = new LinearInterpolator(); } }
public void setStartInterpolator(Interpolator startInterpolator) { mStartInterpolator = startInterpolator; if (mStartInterpolator == null) { mStartInterpolator = new LinearInterpolator(); } }
public void setStartInterpolator(Interpolator startInterpolator) { mStartInterpolator = startInterpolator; if (mStartInterpolator == null) { mStartInterpolator = new LinearInterpolator(); } }
public void setEndInterpolator(Interpolator endInterpolator) { mEndInterpolator = endInterpolator; if (mEndInterpolator == null) { mEndInterpolator = new LinearInterpolator(); } } }
public void setStartInterpolator(Interpolator startInterpolator) { mStartInterpolator = startInterpolator; if (mStartInterpolator == null) { mStartInterpolator = new LinearInterpolator(); } }
public void setEndInterpolator(Interpolator endInterpolator) { mEndInterpolator = endInterpolator; if (mEndInterpolator == null) { mEndInterpolator = new LinearInterpolator(); } } }
public void setStartInterpolator(Interpolator startInterpolator) { mStartInterpolator = startInterpolator; if (mStartInterpolator == null) { mStartInterpolator = new LinearInterpolator(); } }
public ProgressDrawable() { mValueAnimator = ValueAnimator.ofInt(30, 3600); mValueAnimator.setDuration(10000); mValueAnimator.setInterpolator(new LinearInterpolator()); mValueAnimator.setRepeatCount(ValueAnimator.INFINITE); mValueAnimator.setRepeatMode(ValueAnimator.RESTART); }
private Animation inFromRightAnimation() { Animation inFromRight = new TranslateAnimation( Animation.RELATIVE_TO_PARENT, +1.0f, Animation.RELATIVE_TO_PARENT, 0.0f, Animation.RELATIVE_TO_PARENT, 0.0f, Animation.RELATIVE_TO_PARENT, 0.0f); inFromRight.setDuration(500); inFromRight.setInterpolator(new LinearInterpolator()); return inFromRight; }
private Animation outToLeftAnimation() { Animation outToLeft = new TranslateAnimation( Animation.RELATIVE_TO_PARENT, 0.0f, Animation.RELATIVE_TO_PARENT, -1.0f, Animation.RELATIVE_TO_PARENT, 0.0f, Animation.RELATIVE_TO_PARENT, 0.0f); outToLeft.setDuration(500); outToLeft.setInterpolator(new LinearInterpolator()); return outToLeft; } }
@Implementation protected static Interpolator loadInterpolator(Context context, int id) { return new LinearInterpolator(); }
public void initRotateAnimation(float start) { mObjectAnimator = ObjectAnimator.ofFloat(this, "rotation", start, 360f + start); mObjectAnimator.setDuration(DEFAULT_DURATION); mObjectAnimator.setInterpolator(new LinearInterpolator()); mObjectAnimator.setRepeatCount(ObjectAnimator.INFINITE); }
private void setupAnimators() { mRenderAnimator = ValueAnimator.ofFloat(0.0f, 1.0f); mRenderAnimator.setRepeatCount(Animation.INFINITE); mRenderAnimator.setRepeatMode(Animation.RESTART); mRenderAnimator.setDuration(mDuration); //fuck you! the default interpolator is AccelerateDecelerateInterpolator mRenderAnimator.setInterpolator(new LinearInterpolator()); mRenderAnimator.addUpdateListener(mAnimatorUpdateListener); }
public void onCreate(Bundle savedInstanceState) { final Animation animation = new AlphaAnimation(1, 0); // Change alpha from fully visible to invisible animation.setDuration(500); // duration - half a second animation.setInterpolator(new LinearInterpolator()); // do not alter animation rate animation.setRepeatCount(Animation.INFINITE); // Repeat animation infinitely animation.setRepeatMode(Animation.REVERSE); // Reverse animation at the end so the button will fade back in final Button btn = (Button) findViewById(R.id.your_btn); btn.startAnimation(animation); btn.setOnClickListener(new OnClickListener() { @Override public void onClick(final View view) { view.clearAnimation(); } }); }
RotateAnimation anim = new RotateAnimation(0f, 350f, 15f, 15f); anim.setInterpolator(new LinearInterpolator()); anim.setRepeatCount(Animation.INFINITE); anim.setDuration(700); // Start animating the image final ImageView splash = (ImageView) findViewById(R.id.splash); splash.startAnimation(anim); // Later.. stop the animation splash.setAnimation(null);
@Before public void setUp() { overScroller = new OverScroller(ApplicationProvider.getApplicationContext(), new LinearInterpolator()); }
@Override public ValueAnimator onCreateAnimation() { float fractions[] = new float[]{0f, 1f}; return new SpriteAnimatorBuilder(this). rotate(fractions, 0, 360). duration(2000). interpolator(new LinearInterpolator()). build(); }
@Override public ValueAnimator onCreateAnimation() { float fractions[] = new float[]{0f, 0.1f, 0.25f, 0.75f, 0.9f, 1f}; return new SpriteAnimatorBuilder(this). alpha(fractions, 0, 0, 255, 255, 0, 0). rotateX(fractions, -180, -180, 0, 0, 0, 0). rotateY(fractions, 0, 0, 0, 0, 180, 180). duration(2400). interpolator(new LinearInterpolator()) .build(); } }