jpg to base64 ios readdir