Unity Integration Best Practices

This section covers some best practices for working with the Genvid Unity prefab.

Use a root scene for the Genvid prefab

The root scene ensures that the Genvid prefab is present only once in your application. This keeps the Genvid prefab alive between scenes, so you don’t need to place it on any other scene. When there are several instances of the Genvid prefab, it causes various issues with the stream.

Build your application to use DirectX 11

The Genvid prefab video-capture only works with DirectX 11, so you need to use it while running your application. You can force your game to use DirectX 11 by running it with the option -force-d3d11, but it’s not normally needed.

Use the correct type of video capture to show or hide the HUD

The HUD displays when you use Automatic video capture. The HUD won’t be visible if you use Texture video capture.

Build your application only when the Genvid stack is stopped

When the Genvid stack is running, we use the Genvid.dll to run services. When you perform a build while the stack is running, there is no guarantee that the files will be copied properly. Make sure to stop all the jobs before performing a build with your application either from the Cluster-UI monitor screen or the Genvid Cluster-api window inside Unity.