AR Face Manager | AR Foundation | 1.5.0-preview.7
docs.unity3d.com
    Show / Hide Table of Contents

    AR Face Manager

    The face manager is a type of trackable manager.

    alt text

    The plane manager will create GameObjects for each detected face in the environment. The system only detects human faces.

    In some implementations, face tracking requires a different camera (e.g., front-facing vs rear-facing) and may be incompatible with other features, such as plane or image tracking. Consider disabling other AR managers which manage trackables. These include

    • Plane Tracking
    • Image Tracking
    • Object Tracking
    • Environment Probes

    Responding to Planes

    Faces can be added, updated, and removed. Once per frame, the facesChanged event may be invoked with Lists of faces that have been added, updated, and removed since the last frame.

    When a face is detected, the AR Face Manager will instantiate the Face Prefab to represent the face. The Face Prefab may be left null, but the face manager ensures the instantiated GameObject has an ARFace component on it. The ARFace component just contains data about the detected face.

    Visualizing Faces

    The face provider may provide a mesh representing the face. The ARFace component exposes vertices, normals, indices, and uvs (texture coordinates). Some or all of these may be available.

    The ARFaceMeshVisualizer component will generate a UnityEngine.Mesh and update the MeshFilter on the same GameObject based on the data provided by the ARFace.

    Check the face subsystem's SubsystemDescriptor (ARFaceManager.descriptor) for provider-specific features.

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023