Sometimes, we may want to play a video so that it's the user's main focus, but allow them to see scene objects in the background.
To achieve this with the VideoPlayer component, we just need to make two changes:
- Change Render Mode to Near Camera Plane (so that the video content is played in front of the scene content).
- To allow the user to partially see through the video, we need to make Video Player semi-transparent. To do so, change its Alpha property to 0.5.
Now, when you run the scene, you'll see the video playing in front of scene content, but you will also be able to see the 3D Cube in the background.
At the time of writing this book, there seem to be issues with the Direct option for Audio Output Mode audio playback for some non-Apple systems. One solution is to add an AudioSource component to the same GameObject that has the VideoPlayer component and to set Audio Output Mode to AudioSource.