NWVisemeMap

csharp
public sealed class NWVisemeMap

Namespace global.

Result of scanning an avatar for viseme blendshapes. Immutable after construction and safe to reuse at runtime.

Fields

OculusVisemeNames

csharp
public static readonly string[] OculusVisemeNames

Blendshape names of the 15 Oculus visemes, in their order (sil, PP, FF, TH, DD, kk, CH, SS, nn, RR, aa, E, ih, oh, ou).

AiueoVisemeNames

csharp
public static readonly string[] AiueoVisemeNames

Blendshape names of the Japanese A, I, U, E, O visemes, in their order.

Properties

Empty

csharp
public static NWVisemeMap Empty { get; }

A map without visemes.

DetectedStandard

csharp
public Standard DetectedStandard { get; }

The viseme standard found on the avatar.

Renderer

csharp
public SkinnedMeshRenderer Renderer { get; }

The renderer holding the viseme blendshapes.

HasVisemes

csharp
public bool HasVisemes { get; }

The avatar has visemes for lip sync.

BlendShapeIndices

csharp
public int[] BlendShapeIndices { get; }

Blendshape indices to drive. The same index may appear more than once when multiple analyzer visemes contribute to the same target shape.

AnalyzerVisemeIndices

csharp
public int[] AnalyzerVisemeIndices { get; }

Analyzer viseme indices matching BlendShapeIndices.

ContributionWeights

csharp
public float[] ContributionWeights { get; }

Contribution multiplier matching BlendShapeIndices.

Methods

Scan

csharp
public static NWVisemeMap Scan(IReadOnlyList<SkinnedMeshRenderer> renderers)

Finds the viseme blendshapes on the avatar's renderers by their names.

CreateManual

csharp
public static NWVisemeMap CreateManual(Standard standard, SkinnedMeshRenderer renderer, IReadOnlyList<string> blendShapeNames)

A map of blendshapes the creator assigned by hand.

FindOculusBlendShapeName

csharp
public static string FindOculusBlendShapeName(Mesh mesh, int visemeIndex)

The name of the blendshape of the Oculus viseme visemeIndex on mesh, or null.

FindAiueoBlendShapeName

csharp
public static string FindAiueoBlendShapeName(Mesh mesh, int visemeIndex)

The name of the blendshape of the A, I, U, E, O viseme visemeIndex on mesh, or null.

Nested types