Image aspect ratio is maintained while fitting to canvas