st/mesa: add st_convert_image_from_unit() helper