Breshenhan's line algorithm in ActionScript