Added gradient test images, fixed my gradient calculations and added VERTICAL, HORIZONTAL, and BOTH options (to the existing UP, DOWN, LEFT, and RIGHT).