Skip to main content
Version: 5.x
Supported on
Snapchat
Camera Kit

Face Expressions

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.

Take a look at the Face Expression example which allows you to use Face Expression to drive a 3D model’s face using blendshapes.

The Expressions

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 0.0 or 1.0.

You can see the use of every expression in Face Expression and what they look like in the Face Mesh example.

Create the Face Expression

You can access the Face Expression data through Face Mesh. To create Face Mesh, in the Scene Hierarchy panel press the + > 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');

Take a look at the list of expressions in the API page.

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 object itself must always be active in order to receive information about the face.

Was this page helpful?
Yes
No