Sign in to follow this  
Matt Carr

Cluster rendering with Unity

Recommended Posts

Matt Carr    347
We're potentially going to be working with some display systems requiring a rendering cluster in the near future and I'd like to use Unity since we've used it on previous projects effectively. I'm not especially knowledgable about cluster rendering at this stage, so I was hoping that perhaps someone here might be able to fill in the blanks. From what I know about the hardware we would run on, they have hardware frame locking between the systems (NVIDIA Quadro cards I'm guessing). Where my knowledge on the subject fails is at the point of knowing what else is required (if anything) on the software side to have synced display from all the systems. I'd then need to figure out if whatever is required could be done in Unity. Also, I don't see any issue with using Unity's networking to keep the camera and dynamic object transform info synced, but maybe I'm assuming too much there. I would think that perhaps updating should take place at some consistant delta and the random seed should be synced at launch, but other than that the systems should be able to run the application autonomously while receiving input info from the server and occasional authoritative transform data checks. If anyone could shed some light on this for me then I'd be grateful. I'm hoping the time required to get this working with Unity will be significantly less than creating a workable engine/framework with something like OpenSceneGraph which has cluster rendering support built in. The answer I'm hoping for is "run with V-Sync on and the hardware frame locking will take care of the rest", but I won't cross my fingers.

Share this post


Link to post
Share on other sites
hplus0603    11347
As long as the time for an individual frame is lower than the vertical refresh (60 Hz / 16 ms), and you're on a loss-less network, then that could work just fine.
If your frame time is longer (or variable), then you probably need to get everyone to render, but not swap -- instead just wait for a packet. Then send a UDP broadcast packet that everyone hears and uses to swap to the newly rendered framebuffer. If Unity gives you control over framebuffer swap, then it could probably work fine.

Share this post


Link to post
Share on other sites
Matt Carr    347
Thanks for the info. I don't have the display systems or hardware to test with, but I've done some tests over the network here. Unity has a "OnRenderImage" function that is typically used to apply post processing effects to the rendered result and I can start a "Coroutine" in Unity that halts that function until packets from all the other cluster systems is received.

From my tests over the LAN here (not the greatest), doing this with 2 PCs still allowed app to run at over 900FPS, so I don't see network latency being a bottleneck.

I'll need to do more testing and introduce more systems to the cluster, but so far so good.

Thanks for you help and if anyone else has any info that'll burst my bubble then please let me know. I'll most likely post more about any progress I make on the Unity forums and on my GameDev journal (it's about time I posted to it).

Share this post


Link to post
Share on other sites
hplus0603    11347
Btw: other concepts you may want to google for include "Multi-pipe rendering" and "distributed scene graphs." I know that Vega Prime used to do pretty much what you're trying to do, although I don't know what kind of hardware they targeted.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this