Git Product home page Git Product logo

supersaiyanar's Introduction

SuperSaiyanAR

Super Saiyan Augmented Reality With OpenCV and Dlib

Prerequisites

Install: OpenCV, Dlib and Gif2Numpy

pip install opencv-python
pip install dlib 
pip install gif2numpy

Download: CNN Dlib Face Detector - mmod_human_face_detector.dat

Run

After connecting the webcam, run the following scripts:-

python3 cnn_face_detect.py # Run cnn face detector
python3 facial_landmarks.py # Run facial landmarks predictor
python3 hairar.py # Run super saiyan ar application

Note: In the AR application, open your mouth to activate supersaiyan animations.

Dlib Facial Landmarks

Screenshot

  • The center point of the hair and aura images were calculated using the location of landmark points 27 and 30.
  • The width of the overlay images were calculated based on distance between landmark points 0 and 16.
  • To check if the mouth is opened, we compare the average distance of lip landmark points: [(50,61),(51,62),(52,63)] with average distance of mouth landmark points: [(61,67), (62, 66), (63, 65)].
  • For animating the aura glow, four consecutive frames of the original animated gif were used for overlay in a cyclical order.

supersaiyanar's People

Contributors

anilsathyan7 avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  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.