Added function to take photo from camera.