js/highcharts-master/samples/highcharts/studies/flight-routes/demo.js
// Function to return a path with an arc between two points
Function to return a path with an arc between two points
Function to return a path with an arc between two points
function pointsToPath(from, to, invertArc) {
    var arcPointX = (from.x + to.x) / (invertArc ? 2.4 : 1.6),
        arcPointY = (from.y + to.y) / (invertArc ? 2.4 : 1.6);
    return 'M' + from.x + ',' + from.y + 'Q' + arcPointX + ' ' + arcPointY + ',' + to.x + ' ' + to.y;
}
function pointsToPath ( from , to , invertArc ) { var arcPointX = ( from . x + to . x ) / ( invertArc ? 2.4 : 1.6 ) , arcPointY = ( from . y + to . y ) / ( invertArc ? 2.4 : 1.6 ) ; return 'M' + from . x + ',' + from . y + 'Q' + arcPointX + ' ' + arcPointY + ',' + to . x + ' ' + to . y ; }
Function to return a path with an arc between two points
Function to return a path with an arc between two points