Android examples for Graphics:Path Point
Get point between p1 and p2 by percent.
//package com.java2s; import android.graphics.PointF; public class Main { public static PointF getPointByPercent(PointF p1, PointF p2, float percent) { return new PointF(evaluateValue(percent, p1.x, p2.x), evaluateValue(percent, p1.y, p2.y)); }// w w w . j a va 2 s . c om public static float evaluateValue(float fraction, Number start, Number end) { return start.floatValue() + (end.floatValue() - start.floatValue()) * fraction; } }