added new image, fixed bounds check