IEnumerator GetImageFromWWW(string url, imageCallBack imagecallback) { //print ("GetImageFromWWW"); WWW request = new WWW(url); yield return(request); imagecallback(request.texture); }
public Texture2D GetImage(string url, imageCallBack imagecallback) { StartCoroutine(GetImageFromWWW(url, imagecallback)); return(null); }