Code Monkey home page Code Monkey logo

facial-expressions-unity's Introduction

facial-expressions-unity

Abstract facial expressions system of human models for Unity.

Features

  • Blink system (eyelid animation)
    • Support blend shape on SkinnedMeshRenderer.
    • Support Animator.
    • Provide procedural blink animation generation with random.
  • LipSync system (lip animation)
    • Support blend shape on SkinnedMeshRenderer.
    • Support Animator.
    • Provide audio volume based lip sync.
  • Emotion system
    • Support blend shape on SkinnedMeshRenderer.
    • Support Animator.
    • Support generic emotion definition.
    • Provide basic emotion defined by Paul Ekman.

Design

Core APIs are as follows:

  • Data
    • XXXSample : Set of morphing target and weight.
    • XXXAnimationFrame : Set of XXXSample and duration just a frame.
  • Morpher
    • IXXXMprpher : Morphs models by specified XXXSample.
  • Animator
    • ISequencialXXXAnimator : Animates models by specified collection of XXXAnimationFrame.
    • IFramewiseXXXAnimator : Animates models by inner state per game engine frame.

Morpher and animator is abstracted by interfaces.

It is possible to implement them according to how you want to control yur human model.

Extensions for other libraries

  • VRM
    • Blink, lip and emotion animators for VRM model.
  • VOICEVOX
    • VOICEVOX audio query based lip animation.
  • uLipSync
    • Voice analysis based lip animation by uLipSync.

How to import by Unity Package Manager

Add following dependencies to your Packages/manifest.json:

{
  "dependencies": {
    "com.mochineko.facial-expressions": "https://github.com/mochi-neko/facial-expressions-unity.git?path=/Assets/Mochineko/FacialExpressions#0.4.4",
    "com.mochineko.relent": "https://github.com/mochi-neko/Relent.git?path=/Assets/Mochineko/Relent#0.2.0",
    "com.mochineko.relent.extensions.unitask": "https://github.com/mochi-neko/Relent.git?path=/Assets/Mochineko/Relent.Extensions/UniTask#0.2.0",
    "com.cysharp.unitask": "https://github.com/Cysharp/UniTask.git?path=src/UniTask/Assets/Plugins/UniTask",
    ...
  }
}

.

All dependencies are in package.json.

How to import extensions

If you use VOICEVOX extension, please add following dependencies:

{
  "dependencies": {
    "com.mochineko.facial-expressions.extensions.voicevox": "https://github.com/mochi-neko/facial-expressions-unity.git?path=/Assets/Mochineko/FacialExpressions.Extensions/VOICEVOX#0.4.4",
    "com.mochineko.voicevox-api": "https://github.com/mochi-neko/VOICEVOX-API-unity.git?path=/Assets/Mochineko/VOICEVOX_API#0.2.2",
    ...
  }
}

.

If you use VRM extension, please add following dependencies:

{
  "dependencies": {
    "com.mochineko.facial-expressions.extensions.vrm": "https://github.com/mochi-neko/facial-expressions-unity.git?path=/Assets/Mochineko/FacialExpressions.Extensions/VRM#0.4.4",
    "com.vrmc.gltf": "https://github.com/vrm-c/UniVRM.git?path=/Assets/UniGLTF#v0.108.0",
    "com.vrmc.vrm": "https://github.com/vrm-c/UniVRM.git?path=/Assets/VRM10#v0.108.0",
    "com.vrmc.vrmshaders": "https://github.com/vrm-c/UniVRM.git?path=/Assets/VRMShaders#v0.108.0",
    ...
  }
}

.

If you use uLipSync extension, please add following dependencies:

{
  "dependencies": {
    "com.mochineko.facial-expressions.extensions.ulipsync": "https://github.com/mochi-neko/facial-expressions-unity.git?path=/Assets/Mochineko/FacialExpressions.Extensions/uLipSync#0.4.4",
    "com.hecomi.ulipsync": "https://github.com/hecomi/uLipSync.git#upm",
    "com.neuecc.unirx": "https://github.com/neuecc/UniRx.git?path=Assets/Plugins/UniRx/Scripts",
    ...
  }
}

.

Samples

Change log

See CHANGELOG.

3rd Party Notices

See NOTICE.

License

Licensed under the MIT license.

facial-expressions-unity's People

Contributors

mochi-neko avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.