UnityWebRequest 在 Oculus Go 中不起作用



在Oculus Go中使用时,我有一个关于UnityWebRequest的问题。UnityWebRequest在UnityEditor中运行良好。然而,UnityWebRequest在Oculus Go中不起作用。。。它似乎只是没有连接到http url,因为在putty中没有登录。

IEnumerator GetArt()
{
WWWForm form = new WWWForm();
form.AddField("galleryidx", 1);
Debug.Log("get art");
string Url = "http://[awsIPaddress]/vr/enterGallery";
UnityWebRequest request = UnityWebRequest.Post(Url, form);
request.chunkedTransfer = false;
yield return request.SendWebRequest();
if (request.isNetworkError)
{
//show message "no internet "
Debug.Log("no internet");
}
else
{
if (request.isDone)
{
Debug.Log("getting image");
Debug.Log(request.downloadHandler.text);
//using JsonHelper to get json data
allPosts = JsonHelper.getJsonArray<Post>(request.downloadHandler.text);
StartCoroutine(GetArtsImages());
}
}
}

我们的团队确实想解决这个问题,但没有错误消息,所以我们不知道是什么原因导致了这个问题。有什么办法可以解决吗?我们正在使用团结2018.4.15f1。

我们也读过类似的帖子(https://forum.unity.com/threads/unitywebrequest-not-working-for-oculus-quest.830199/(并修改了AndroidManifest。。。但还是一样。

谢谢。

我们刚刚解决了。unity项目android清单文件不包括CCD_ 1。我们还在构建设置中将构建系统更改为内部。

最新更新