FaceGen SDK Manual - FAQ

Clamping controls to reasonable values

If you want clamping, we recommend only clamping caricature and asymmetry values.

Clamping individual controls is not recommended. A given control value may look fine by itself but bad in combination with a correlated control.

To achieve interactive clamping, you need to clamp the caricature (shape and color) and asymmetry (shape) values for the all-races distribution. If the given caricature value is larger than a limit, say 3, then set it back to 3.

Note that this will make your sliders non-deterministic; after clamping, they will not take on the exact values you originally specified.

We recommend clamping shape (caricature and asymmetry) at 3.0 and color at 2.0, since users enjoy some room for creative expression.

Moving slider X without affecting slider Y

You may not really want to do this. This is because many of the sliders are correlated. For example, if slider X is lip thickness and slider Y is age, then decreasing the lip thickness has to affect the age value since lips get thinner as we age.

If you decide you still need a control like this, there are two ways to go about it; inverting the covariance matrix between them, and using a non-deterministic control. The latter is easier if you're already doing it for clamping.

Inverting the covariance matrix is what FaceGen uses to keep gender and age controls independent (details). It works well since those particular controls are not very correlated. The age/gender code can be copied with minor modifications for the controls you want to apply it to. The problem with this approach is that if the controls are closely correlated, the results can be unexpected.

Non-deterministic controls are simpler mathematically, but change the user interface. The user moves the X control but it doesn't move all the way to the desired value. To do this just removing the component of the X delta which is parallel to the Y control (all in face space): \[ \mathbf{x'=x_0+\Delta(1-\frac{\Delta\cdot y}{\left \| \Delta \right \|\left \| y \right \|})} \]

Generating female faces.

For best results generating female faces, use the 'FANRACE_ALL' selection. Generating female faces from specific races is achieved in a way that can sometimes result in beard shadowing for females.

If you need random female faces from specific racial groups, best results can be obtained by repeatedly generating faces from the 'FANRACE_ALL' group until one is found with a racial control value close to the desired one.

Rendering faces

Faces look odd when the camera is too close (ie wide-angle lens) or when the camera too far (ie strong zoom lens)

This is because the human eye effectively has a medium-angle lens (our periphal vision doesn't count here, since it has so little resolution), so that's how we're used to seeing faces.

When choosing a vantage point for your face creation tool, make sure not to have it too close or you'll get the classic wide-angle narrow face and large nose look. In real-world units, you typically want to have your camera 5-10 feet from the subject.

Genetic interface

The 'genetic' interface in Modeller is achieved by randomly perturbing a base face coordinate (shown in the centre of the grid) to create the variations seen around the edge of the grid.

To create each variation a on the base face coordinate c with randomness factor f ∈ (0,1):

  1. Generate a random face coordinate, r.
  2. Interpolate between them by a=f r+(1-f)c.

Fantasy Races

In this case, integrate your head using the 'fg3t' tool as described above, but then swap in your original base mesh (.TRI) and texture image (.PNG) instead of the FaceGen-generated one.

You may want to exaggerate the controls, as the subtle changes between human faces will be less apparent against a radically different base shape and color.

Increase the numerical range the linear controls map to, and increase the clamping values if you have clamping.