interpolation point by pixels
===

I need to offset one point on line by certain pixels.

    public static function interpolate(pt1:Point, pt2:Point, f:Number):Point
    {
         var x:Number = f * pt1.x + (1 - f) * pt2.x;
         var y:Number = f * pt1.y + (1 - f) * pt2.y;
    
         return new Point(x, y);
    }

This function can interpolate point by percent if "f" is 0.5 the point will be in the center of line pt1 and pt2. Is there a way to make this with pixels?