The Face Expression Effect allows you to get information about the current expression of the user’s face--such as whether they are currently blinking their left eye, opening their mouth, and more.
Tip: Take a look at the Face Expression template which allows you to use Face Expression to drive a 3D model’s face using blendshapes.
There are 51 expressions available overall, each of them corresponds to specific user emotion or facial muscle movement. For each of them, there is a "weight" parameter. Weight is a number which indicates how strong this expression is.
For example -
EyeBlinkLeft has a weight closer to
0.0 when the user's left eye is fully open, and goes up when the user blinks. It's different and unique for every face, so there is no guarantee that it ever reaches
Create the Face Expression
You can access the Face Expression data through Face Mesh. To create Face Mesh, in the Objects panel press the
+ button > Face Mesh.
Access the Current Expression
Once you have the Face Mesh added to your scene, you can access information about the current face’s expression through script.
In a script you can access the faceMesh by creating an input for RenderMeshVisual:
// @input Component.RenderMeshVisual faceMesh
Then, you can access information about the different expressions by accessing its control. For example to get information on a specific expression you can do this by :
var weight = script.faceMesh.mesh.control.getExpressionWeightByName(“MouthClose”)
To learn more about what you can do with Face Expression, take a look at the API page.
Tip: If you don’t actually want to actually use Face Mesh, you can add a transparent material to hide the Face Mesh. However, the face mesh must always be active in order to receive information about the face.
Still Looking for help?Visit Support