Genvid SDK Unity Package¶
The engine-integration/unity/genvid_sdk.unitypackage
file contains
everything necessary to integrate the Genvid SDK into your game.
If you have already run the Genvid Unity Cube Sample,
then you’ve already installed the Genvid Unity SDK Package. If not, you can
manually install the Genvid Unity SDK Package.
In This Section
Package Contents¶
Genvid/SDK/Plugins/x86/genvid.dll
andGenvid/SDK/Plugins/x64/genvid.dll
- This is our main native DLL for Windows (32-bit and 64-bit versions). It is required for integrating the Genvid Services.
Genvid/SDK/Plugins/GenvidSDKCSharp.dll
- This is the C# wrapper around our Native SDK. It exposes all
the same functionalities as
genvid.dll
and lets you use our SDK through Unity Scripts. Genvid/SDK/Plugins/x86/GenvidPlugin.dll
andGenvid/SDK/Plugins/x64/GenvidPlugin.dll
- This is our Unity Native Plugin (32-bit and 64-bit versions) which lets us enable direct access to the graphics device for optimal video capture. It is not mandatory for integrating Genvid, but allows more efficient video transfer to our SDK.
Genvid/SDK/Scripts/
andGenvid/SDK/Prefabs/
These folders contain scripts and prefabs for integrating Genvid more easily. We use them in our cube sample, but they aren’t mandatory. You can replace them in your project.
We describe these prefabs and scripts in more detail in the Genvid SDK Prefab for Unity section.
Building the Package¶
Important
Before building the plugin, you need to build the
GenvidPlugin.dll
. For that you also must have the Microsoft C++ Compiler installed.
To build the DLL, run the package.py script with the plugin option.
py package.py plugin
The package source is available under /engine-integration/unity
.
Once you’ve built the DLL, you can use the package.py script to build
the full Unity SDK package by using the sdk option.
py package.py sdk
You can also use the pre-built asset package
/engine-integration/unity/genvid_sdk.unitypackage
.
Warning
The Unity Installer only installs the C# tools by default. You need to install C++ support separately to build the Unity package.
Installing the Package¶
You can use the unity.py
script from the cube sample to install the
package in your project. You’ll find it in the /samples/cube/unity
folder.
py unity.py prepare
You can also manually add the Genvid SDK to your Unity project.
Open your project in the Unity Editor.
Select
.Click genvid_sdk.unitypackage located in the
/engine-integration/unity
folder.