{"id":15631210,"url":"https://github.com/junyanz/facedemo","last_synced_at":"2025-09-07T23:31:27.697Z","repository":{"id":72158697,"uuid":"48897786","full_name":"junyanz/FaceDemo","owner":"junyanz","description":"A simple 3D face alignment and warping demo.","archived":false,"fork":false,"pushed_at":"2020-08-05T01:24:41.000Z","size":19475,"stargazers_count":198,"open_issues_count":1,"forks_count":73,"subscribers_count":19,"default_branch":"master","last_synced_at":"2024-12-26T19:07:36.893Z","etag":null,"topics":["3d-face","computer-vision","face-swap"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/junyanz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-01-02T03:49:58.000Z","updated_at":"2024-08-25T09:03:02.000Z","dependencies_parsed_at":null,"dependency_job_id":"d46f2151-5f2c-4aa6-8514-79fd14429967","html_url":"https://github.com/junyanz/FaceDemo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/junyanz%2FFaceDemo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/junyanz%2FFaceDemo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/junyanz%2FFaceDemo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/junyanz%2FFaceDemo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/junyanz","download_url":"https://codeload.github.com/junyanz/FaceDemo/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":232262339,"owners_count":18496434,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["3d-face","computer-vision","face-swap"],"created_at":"2024-10-03T10:39:31.755Z","updated_at":"2025-01-02T22:10:25.787Z","avatar_url":"https://github.com/junyanz.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FaceDemo: a simple 3D face alignment and warping demo\nInput: face image/video  \n\n\u003cimg src='data/bush.jpg' width=224\u003e\n\nOutput: Textured 3D face model  \n\n\u003cimg src='data/demo.gif' width=224\u003e\n\n\n## Overview\nThis is the author's implementation of 3D face alignment and warping method described in:  \n[Mirror Mirror: Crowdsourcing Better Portraits](http://efrosprojects.eecs.berkeley.edu/mirrormirror/)  \n[Jun-Yan Zhu](https://www.cs.cmu.edu/~junyanz/), [Aseem Agarwala](http://www.agarwala.org/), [Alexei A. Efros](https://people.eecs.berkeley.edu/~efros/), [Eli Shechtman](https://research.adobe.com/person/eli-shechtman/), [Jue Wang](http://www.juew.org/)  \nIn ACM Transactions on Graphics (Proceedings of SIGGRAPH Asia 2014)  \n\n[Project Page](http://efrosprojects.eecs.berkeley.edu/mirrormirror/)\n\nPlease cite our paper if you use our code for your research.\n```\n@article{zhu2014mirror,\n author = {Jun-Yan Zhu and Aseem Agarwala and Alexei A Efros and Eli Shechtman and Jue Wang},\n title = {Mirror Mirror: Crowdsourcing Better Portraits},\n journal = {ACM Transactions on Graphics (SIGGRAPH Asia 2014)},\n volume = {33},\n number = {6},\n year = {2014},\n}\n\n```\n\nGiven an image or a video sequence that contains a face, the program can align and warp the face to a 3D face model. The user can further rotate/translate the face, and adjust the camera projection (perspective projection or orthogonal projection). The program also provides different OpenGL rendering options. See **\"Usage\"** for details.\n\nContact: Jun-Yan Zhu (junyanz@berkeley.edu)\n## Requirements\n* OpenCV:\n```bash\nsudo apt-get install libopencv-dev\n```\n* OpenGL and GLUT:\n```bash\nsudo apt-get install libglu1-mesa-dev freeglut3-dev mesa-common-dev\nsudo apt-get install libxmu-dev libxi-dev\n```\n* CLM Tracker by Jason Saragih (included)\n\n## Getting Started (Linux)\n* Download and unzip the code.\n\n* Run the following command.\n```bash\nmkdir cbuild\ncd cbuild\ncmake -DCMAKE_BUILD_TYPE=Release  ../\nmake\n```\n\n\n## Usage\n1. Command line interface: `./FaceDemo mode filePath`  \n   - Example (image): `./FaceDemo image ./data/bush.jpg`  \n   - Example (video): `./FaceDemo video ./data/eli.avi`  \n2. The program displays three windows:\n  - The \"Detected Points\" window shows the original input frame with the detected feature points.\n   - The \"3D Face\" window shows a 3D face model rendered by OpenGL.\n   - The \"Projected Face\" window shows a 2D projection result of the 3D face model. The program projects the 3D face back to the original image.\n3. User Interaction: \"3D Face\" window takes the user's keyboard input.\n   - shift + arrow keys: translate the face.\n   - arrow keys: rotate the face.\n   - `+/-`: zoom in/out\n   - `p`:  toggle between a perspective projection and an orthogonal projection.\n   - `s`:  toggle between flat and smooth shading.\n   - `w`:  toggle between filled and wireframe mode.\n   - `t`:  toggle between static mode and transformation mode: for static mode, the 3D face model doesn't rotate and translate.\n   - `q`:  quit the program\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjunyanz%2Ffacedemo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjunyanz%2Ffacedemo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjunyanz%2Ffacedemo/lists"}