Search code examples
c#unity-game-enginevirtual-reality

Unity game build: How to set Resolution higher than screen maximum?


I'm working on a project that does serverside rendering and thereby streams the images from a Windows 10 server (maximum resolution 1920x1080) to an Android 7 client (maximum resolution 2960x1440). The used framework is the TrinusVr library.

As I have understood, the Trinus framework streams whatever is in the game view to the client. In the Unity Editor I have the pleasure to be able to set any arbitrary resolution; of course when I put a resolution greater than what my screen can do, on the server side I see a scaled down version of the image in the game view. However, on the client it would use exactly this high resolution.

Now for the built game: Of course I tried using

Screen.SetResolution

to set high resolutions in the built game, too. Too high resolutions though will always be clamped down to the maximum resolution of my screen.

So is there any way, to have it like in the Unity Editor: a scaled down image on the server and the high resolution image on the client? Does anybody know another way to achieve this using the trinus lib?

Thank you


Solution

  • You might be able to use the camera's Target Eye parameter, combined with a higher resolution render texture. But then you'd need at least one more render pass to render the lower-resolution version, which could be too costly for VR.