Initial addition of original viewshed code