The Millicast Unity package allows game developers to publish and view streams from the Millicast service from within their Unity games. For example, users can publish scenes captured from their in-game cameras, as well as audio sources, for other viewers to subscribe to, as well as rendering video and audio streams incoming from the service onto textures and audio sources.
The API (class) Documentation can be found here. The Dolby.io tutorials and further documentation can be found here.
This package uses Unity WebRTC as a dependency, and therefore requires the following:
It is recommended to use the latest Long-Term Support (LTS) version of Unity, see the post in Unity blog for LTS versions.
This version of the package is compatible with the following versions of the Unity Editor:
To build the apk file for Android platform, you need to configure player settings below.
If using URP, users needs to convert the materials to URP by selecting the Materials
folder under Samples
and go to Edit > Render Pipeline > Universal Render Pipeline
. According to your needs, select Upgrade Selected Materials to URP Materials.
Virtual Stereo Subscriber This scene demonstrates a simple subscriber usage of virtualized stereo speakers, where the left channel is played on the left speaker, and the right channel is played on the right one.
We currently support the OpenGLES3 Graphics API on Android Devices. Vulkan Graphics API is not supported.
If you encounter any crashes or difficulty deploying, check your project's player settings and update as below.
Player Settings -> Other Settings
Un-tick Auto Graphics API
Under Graphics APIs:
remove Vulkan
Add or select OpenGLES3
Optionally Leave below options unticked:
Currently, publishing with simulcast only works with VP8 and on Windows machines. Attempting to publish with simulcast on other platforms will cause a crash due to a bug in Unity WebRTC.
Using H264 on Windows requires an Nvidia GPU as the Unity WebRTC implementation uses a hardware encoder only. Make sure to have up-to-date drivers. Head over to the Unity WebRTC documentation to learn more about the video codecs supported by Unity WebRTC and thus by us. If you have issues on Windows where the stream is not being viewed on the web browser when publishing using H264, it is likely an issue with an out-dated driver.
AudioSource
selected in a VideoPlayer
does not work as intended.