change path drawing algorithm