Exploring Oculus Lipsync with the Sample Scene

To get started, we recommend opening the supplied demonstration scene LipSync_Demo, located under Assets/Oculus/LipSync/Scenes. This scene provides an introduction to Oculus Lipsync resources and examples of how the library works.

Using the LipSync_Demo scene

You can switch models between a geometry morph target and a texture flip target, and also switch between microphone and our provided sample audio clip using the following controls:

KeyControl
1Select Morph target, Mic input (default).
2Select Texture Flip target, Mic input.
3Select Morph target, Audio Clip.
4Select Texture Flip target, Audio Clip.
5Select Morph target, Precomputed Visemes.
6Select Texture Flip target, Precomputed Visemes.
LToggle loopback on/off to hear your voice with the mic input. Use headphones to avoid feedback. (default is off).
DToggle debug display to show predicted visemes
Left arrowRotate scene object left
` (backtick)Add 100% activation to “sil” viseme on geometry morph target
Tab through \ (QWERTY row of a US keyboard)Add 100% activation to “PP” through “ou” visemes on geometry morph target
Right arrowRotate scene object right
ActionControl
Swipe DownDecrease microphone gain (1-15).
Swipe UpIncrease microphone gain (1-15).
Swipe Forward / Swipe BackwardCycle forward/backward through targets:1. Morph target - mic input 2. Flipbook target - mic input 3. Morph target - audio clip input 4. Flipbook target - audio clip input 5. Morph target - pregenerated visemes 6. Flipbook target - pregenerated visemes Audio clip input plays automatically.
Single TapToggle mic loopback on/off to hear your voice with the mic input.

To preview the scene in the Unity Editor Game View:

  1. Import and launch LipSync_Demo as described above.
  2. Play the LipSync_Demo scene in the Unity Editor Game View.

To preview the scene with a Rift:

  1. Import and launch LipSync_Demo as described above.
  2. In Build Settings, verify that the PC, Mac and Linux Standalone option is selected under Platform.
  3. In Player Settings, select Virtual Reality Supported.
  4. Preview the scene normally in the Unity Game View.

To preview the scene in Gear VR:

  1. Be sure you are able to build and run projects on your Samsung phone (Debug Mode enabled, adb installed, etc.) See the Mobile SDK Setup Guide for more information.
  2. Import and launch LipSync_Demo as described above.
  3. In Build Settings:
    1. Select Android under Platform.
    2. Select Add CurrentsScenes in Build.
    3. Set Texture Compression to ASTC (recommended).
  4. In Player Settings:
    1. Select Virtual Reality Supported.
    2. Specify the Bundle Identifier.
  5. Copy your osig to YOUR-UNITY-PROJECT/Assets/Plugins/Android/assets.
  6. Build and run your project.