Avatar SDK Unity Cloud plugin  3.0.1
Realistic avatar generation toolset for Unity3D
How to use Oculus LipSync with Avatar SDK

We describe the steps below for the "Oculus LipSync" unity plugin v20.0.0. For other versions the steps may be different.

1. Download and import "Oculus LipSync Unity" plugin into your project with Avatar SDK:
Oculus LipSync

2. Run the "05_parameters_sample_cloud" sample located under "itseez3d/avatar_sdk/sample_cloud/05_parameters_sample_cloud/scenes".

3. Select one of blendshape sets: "base/visems_17" or "base/visems_15" and generate avatar. "base/visems_15" blendshapes are available for Head 1.2 and Head 2.0 pipelines whereas "base/visems_17" are for the Animated Face.

blendshapes_sets_15_17.jpg

4. Once the avatar is loaded, press the "Create prefab" button. The prefab with the avatar will be created that can be used for lipsync.

5. Create an empty scene.

6. Add to the scene created prefab with the avatar.

7. Add to the scene "LipSyncInterface" prefab located under "Oculus/LipSync/prefabs".

8. You have to add the following scripts to the avatar game object: "OVR Lip Sync Context", "OVR Lip Sync Mic Input", "OVR Lip Sync Context Morph Target".

ovr_scripts.jpg

9. It is time to configure Blend Targets for "OVR Lip Sync Context Morph Target" script.
- Set "itSeez3D Head" as a Skinned Mesh Renderer.
- Set "Viseme To Blend Targets" to the corresponding blendshapes indices from the "itSeez3D Head".
Visemes order is: sil, PP, FF, TH, DD, kk, CH, SS, nn, RR, aa, E, IH, oh, ou.

oculus_visemes_15.jpg
For base/visemes_15
oculus_visemes_17.jpg
For base/visemes_17

10. The "Oculus LipSync" plugin always uses index 15 (OVRLipSync.VisemeCount) for the Lauhter blendshape. Actual index of the Laughter blendshape is different. So we suggest to disable a usage of the Laughter blendshape by disabling the body of the SetLaughterToMorphTarget method from the "Assets/Oculus/LipSync/Scripts/OVRLipSyncContextMorphTarget.cs" script.

ovr_disable_luaghter_in_code.jpg

11. Now everything is configured. You can run the sample scene in VR mode. The audio source will be taken from the microphone and precomputed blendshapes will be rendered in real-time.

12. The sample unity package (for Unity 2019.4.10f1 ) can be downloaded from here: Avatar SDK with Oculus LipSync Unity sample