VR 应用程序(Unity with TrinusVR lib)Windows 构建:连接重置
VR application (Unity with TrinusVR lib) Windows build: Connection reset
我正在使用 Unity 2018.2.8f1 和 TrinusVR 库(一个执行服务器端渲染的框架)开发 VR 应用程序。当我在编辑器中按下播放或为 Linux 构建时,它按预期工作。然而,当使用 Windows 构建时,只有大约一帧被传输到客户端,然后连接被重置。在客户端上显示错误:
Error streaming video error: java.net.SocketException: Connection reset
Error Error delivering sensor data: java.net.SocketException: Connection reset
深入查看服务器日志,似乎此重置是由空引用异常引起的:
Disconnected (Reason: ERROR:ERR_IMG_PROC:Could not deliver frame to client.
System.TypeInitializationException: The type initializer for 'ManagedToNativeWrapper' threw an exception. --->
System.NullReferenceException: Object reference not set to an instance of an object
at System.Drawing.ComIStreamMarshaler+ManagedToNativeWrapper..cctor () [0x00049] in :0`
有人知道这里有什么问题吗?有人见过这个问题吗?
您可以在此处找到完整的日志文件(Windows 10 服务器和 android 7 客户端):
https://transfernow.net/419cp2m92898
谢谢
事实证明,这实际上是 Windows 上 .NET 版本的问题,因为 trinus 库是为旧版本制作的。在“编辑”>“项目设置”>“播放器”的“其他设置”部分设置正确的参数可解决:
- 脚本运行时版本:.NET 3.5 等效版本
- Api 兼容级别:.NET 2.0
我正在使用 Unity 2018.2.8f1 和 TrinusVR 库(一个执行服务器端渲染的框架)开发 VR 应用程序。当我在编辑器中按下播放或为 Linux 构建时,它按预期工作。然而,当使用 Windows 构建时,只有大约一帧被传输到客户端,然后连接被重置。在客户端上显示错误:
Error streaming video error: java.net.SocketException: Connection reset
Error Error delivering sensor data: java.net.SocketException: Connection reset
深入查看服务器日志,似乎此重置是由空引用异常引起的:
Disconnected (Reason: ERROR:ERR_IMG_PROC:Could not deliver frame to client. System.TypeInitializationException: The type initializer for 'ManagedToNativeWrapper' threw an exception. ---> System.NullReferenceException: Object reference not set to an instance of an object at System.Drawing.ComIStreamMarshaler+ManagedToNativeWrapper..cctor () [0x00049] in :0`
有人知道这里有什么问题吗?有人见过这个问题吗?
您可以在此处找到完整的日志文件(Windows 10 服务器和 android 7 客户端): https://transfernow.net/419cp2m92898
谢谢
事实证明,这实际上是 Windows 上 .NET 版本的问题,因为 trinus 库是为旧版本制作的。在“编辑”>“项目设置”>“播放器”的“其他设置”部分设置正确的参数可解决:
- 脚本运行时版本:.NET 3.5 等效版本
- Api 兼容级别:.NET 2.0