changing picture to bitmap so can be saved on server