Git Product home page Git Product logo

finengine's Introduction

Fine Engine & Fin Render

License

与游戏引擎进行交互的模块,特别是视频数据的处理与交互。不仅适用于Unity,还可以接入Cocos2d等图形引擎。

涉及OpenGL、OpenCV、视频录制、滤镜、美颜、人脸交换、人脸贴图等技术。

并包含一个简单的OpenGL引擎“FinEngine”

关联项目:FinEngineUnity, 包含了本项目里面Unity内部的代码。

如有帮助请star

参考

  1. 人脸交换:https://github.com/hrastnik/FaceSwap/blob/master/main.cpphttps://yq.aliyun.com/articles/62520
  2. OpenGL : OpenGL® ES 2.0 Programming Guide

注意

  1. 人脸识别模块是商业版权付费的,已过期不可用,So,人脸交换、蒙娜丽莎的微笑等特效也不可以玩了,但是代码和交互数据的方式都在,请参考face_swap分支。
  2. 人脸模块有使用OpenCV,首页的灰度图处理也用到了它。
  3. 有兴趣的朋友可以用dlib等开源人脸检测代码替换本项目的人脸识别模块,欢迎commit
  4. 采用CMake编译C/C++,项目大部分的代码都在C++ native层
  5. 多种GLSL视频渲染滤镜,在finengine的assets下。
  6. UnityTransfer模块,主要利用java nio和共享指针传输视频帧数据,中间有一些坑已填平。此方案同样适用于Cocos2d
  7. 为了更好地理解本项目,可以参考Android传输摄像头视频数据到U3D的优化实战,时间有限只写过这一个,后面会慢慢补充。
  8. 本项目的核心Key Point还有:
    • Unity里面没有双通道纹理,如何将opengl双通道纹理映射成Unity支持的纹理,并实现渲染的。
    • 与Unity共享Open Context的处理。(代码主要在UnityTransfer里面)
    • SurfaceView在native C/C++代码中如何操作与维护
    • 如何录制游戏引擎的视频帧
    • 多屏、多处实时渲染
    • 人脸贴图、人脸交换的opengl实现

Work Flow

Work Flow

其它

本项目的开源协议为gpl-2.0,忍痛开源,祝大家 Happy New Year!

finengine's People

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.