Я хочу создать функцию arrowTo с CanvasRenderingContext2D.prototype. Для этого мне нужно получить координаты последней точки. например,
//...
var ctx = someCanvas.getContext('2d');
ctx.moveTo(10,40);
//the coordinates of the last point are now (10,40)
ctx.lineTo(50,50);
//and now it's (50,50)
//...
Как их получить?