GithubHelp home page GithubHelp logo

zx1239856 / computer-graphics-2019 Goto Github PK

View Code? Open in Web Editor NEW
9.0 1.0 0.0 62.25 MB

THU Computer Graphics 2019

License: MIT License

CMake 1.01% C++ 87.42% Cuda 10.37% C 1.20%
computer-graphics path-tracing photon-mapping

computer-graphics-2019's Introduction

Photo Realistic Rendering - 2019 Computer Graphics

Basic Functions

  • Multiple parametric objects supported, i.e. plane, sphere, cube and rotary bezier curve
  • Mesh object (loaded via OBJ file)
  • Stackless KD-tree accelaration
  • Axis aligned boundingbox
  • Nvidia CUDA support (much faster than CPU implementation using OpenMP)
  • Surface texture mapping
  • Natural depth of field
  • ...

Supported Render Algorithms

  • Path Tracing with Anti-aliasing (CPU and GPU)
  • Stochastic Progressive Photon Mapping (CPU only)

Dependencies

  • OpenCV (for reading texture image, i.e., jpeg or png)
  • CUDA (if you want to compile GPU version)

Build and Execution

mkdir build && cd build 
cmake ../src -DCMAKE_BUILD_TYPE=release -DBUILD_CUDA=true|false -DBUILD_TEST=true|false ## Enable CUDA or test building according to your need 
make

To render, use the following command

./main PT [out_filename] [width] [height] [num_spp]
./main SPPM [out_filename] [width] [height] [num_rounds] [num_photons_per_round]
./main_gpu [out_filename] [width] [height] [num_spp]

Demo image

Simple Ray Cast

image

Rotary Bezier Curve Demo

image

PT and SPPM Demo

PT

image

SPPM

image

Final GPU Demo

image

For more details, refer to the demo directory.

References

  1. Hachisuka, Toshiya, Shinji Ogaki, and Henrik Wann Jensen. "Progressive photon mapping." In ACM Transactions on Graphics (TOG), vol. 27, no. 5, p. 130. ACM, 2008.
  2. Hachisuka, Toshiya, and Henrik Wann Jensen. "Stochastic progressive photon mapping." In ACM Transactions on Graphics (TOG), vol. 28, no. 5, p. 141. ACM, 2009.
  3. Popov, Stefan, Johannes Günther, Hans‐Peter Seidel, and Philipp Slusallek. "Stackless kd‐tree traversal for high performance GPU ray tracing." In Computer Graphics Forum, vol. 26, no. 3, pp. 415-424. Oxford, UK: Blackwell Publishing Ltd, 2007.

computer-graphics-2019's People

Contributors

zx1239856 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

computer-graphics-2019's Issues

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.