Home
last modified time | relevance | path

Searched refs:NB_SAMPLES (Results 1 – 2 of 2) sorted by relevance

/frameworks/base/core/java/android/widget/
DScroller.java104 private static final int NB_SAMPLES = 100; field in Scroller
105 private static final float[] SPLINE_POSITION = new float[NB_SAMPLES + 1];
106 private static final float[] SPLINE_TIME = new float[NB_SAMPLES + 1];
117 for (int i = 0; i < NB_SAMPLES; i++) {
118 final float alpha = (float) i / NB_SAMPLES;
144 SPLINE_POSITION[NB_SAMPLES] = SPLINE_TIME[NB_SAMPLES] = 1.0f;
315 final int index = (int) (NB_SAMPLES * t); in computeScrollOffset()
318 if (index < NB_SAMPLES) { in computeScrollOffset()
319 final float t_inf = (float) index / NB_SAMPLES; in computeScrollOffset()
320 final float t_sup = (float) (index + 1) / NB_SAMPLES; in computeScrollOffset()
DOverScroller.java594 private static final int NB_SAMPLES = 100; field in OverScroller.SplineOverScroller
595 private static final float[] SPLINE_POSITION = new float[NB_SAMPLES + 1];
596 private static final float[] SPLINE_TIME = new float[NB_SAMPLES + 1];
605 for (int i = 0; i < NB_SAMPLES; i++) {
606 final float alpha = (float) i / NB_SAMPLES;
632 SPLINE_POSITION[NB_SAMPLES] = SPLINE_TIME[NB_SAMPLES] = 1.0f;
667 final int index = (int) (NB_SAMPLES * x); in adjustDuration()
668 if (index < NB_SAMPLES) { in adjustDuration()
669 final float x_inf = (float) index / NB_SAMPLES; in adjustDuration()
670 final float x_sup = (float) (index + 1) / NB_SAMPLES; in adjustDuration()
[all …]