Seam Carving to reduce image size using mask