Coder Social home page Coder Social logo

whaison / laugh_engine Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jian-ru/laugh_engine

0.0 2.0 0.0 766.7 MB

A Vulkan implementation of real-time PBR renderer

C 15.32% Objective-C 1.74% C++ 81.77% CMake 0.61% GLSL 0.51% Batchfile 0.06%

laugh_engine's Introduction

Laugh Engine

A Vulkan implementation of real-time PBR renderer.


Results

Paper Mill Factory
Mon Valley Canyon

glTF Support

  • glTF, also called the GL Transmission Format, it is a runtime asset dilivery format for GL-based applications. It supports common functionalities of 3D applications such as geometry, texture, skin, and animation. It also allows extension, for example, I used the FRAUNHOFER_materials_pbr extension to load PBR textures.
  • It aims to form a standard/common format for runtime asset dilivery/exchange. In my opinion, it has better documentation than FBX and possess some abilities that some other file formats don't (e.g. scene hierarchy, skin, animation). I believe, if it gets popular, it will be a great convenience to both application developers and artists because less effort will be required to perform application-specific conversion on file formats.
  • In order to show my support, I added glTF support to Laugh Egine. It is now able to load geometry and material data from glTF files.
  • Below are some screen shots of 3D models loaded from glTF files. Thanks to Sketchfab for providing these glTF assets.
Microphone Centurion

Overview

Performance Analysis

  • Precomputation performance

    • It is not real-time but fast enough to be used for interactive editting
    • The increase of execution time from 128x128 to 256x256 is very small. Probably the GPU is not saturated at that time.
    Envrionment Prefiltering BRDF LUT Baking
  • PBR vs. Blinn-Phong

    • PBR using IBL only
    • Blinn-Phong was tested using two point light sources
    • Framebuffer resolution was 1920x1080 with no AA
    • Bloom was on
    • The scene with a Cerberus pistol in it was used for benchmark
    • Basically no addtional cost by using PBR over Blinn-Phong but we get much better quality

  • Anti-Aliasing

    • Increases visual quality (smoother edges and more accurate shading)
    • Decreases performance. For 2xAA, 4xAA, and 8xAA, frame time is increased by 31%, 70%, and 173%, respectively when compared to no AA
    • I did custom resolve in a fragment shader because Laugh Engine is deferred. Right now, I am doing lighting computation on each sample so it is basically SSAA not MSAA. I tried to perform computation only once per material type but the performance was much worse because the code that figures out distinct material types is expensive causes a lot of branching (frame time goes up to 8ms for 4xAA). So I will stick to the current scheme until I find a better way.
    1xAA 2xAA
    4xAA 8xAA

Build Instruction

  • Install LunarG Vulkan SDK
  • If you have Visual Studio 2015, the solution should build out of the box
  • To run the program, you will need to copy the .dlls to executable path or system paths
  • Builds on other platforms are not supported yet

Third-Party Credits

References:

Libraries

Assets

laugh_engine's People

Watchers

whaison avatar James Cloos 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.