Code Monkey home page Code Monkey logo

cuda-path-tracer's Introduction

CUDA Path Tracer

Windows Ubuntu

Interactive Path Tracer in CUDA.

Features

  • Sphere and triangle mesh primitives
  • obj file loading
  • BVH (bounding volume hierarchy) acceleration
  • Edge-Avoiding À-Trous Wavelet Transform denoising

Build

You need to have a recent version of C++ compiler (Visual Studio , GCC, or Clang), CMake 3.17+, CUDA Toolkit, and Conan package manager installed.

To install conan, you need have a recent Python installed, and then you can do:

$ pip install conan

Afterwards, you can invoke CMake in command line to build the project

$ mkdir build
$ cd build
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ cmake --build .

or alternatively use your IDE's CMake integration.

Troubleshoot

Path-related errors in Windows

nvcc fatal : Cannot find compiler 'cl.exe' in PATH nvcc fatal : Could not set up the environment for Microsoft Visual Studio

The way NVCC parse Windows PATH environment variable seems to be brittle. A reliable way is to clear the Path variable and only set the location of cl.exe to the path. For example:

Path=C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.29.30133\bin\Hostx64\x64\

Run

The executables should be under the bin directory of the build directory:

  • cuda_pt is the main executable. The usage is cuda_pt [option] <filename>, where <filename> refers to scene files. By default, it executes in interactive mode, but with --output <output filename> option it runs in command line mode.
  • test runs unit tests

Gallery

Denoising

One sample-per-pixel output Edge-Avoiding À-Trous Wavelet Transform

Credit

This project consults the following resources and papers

Dependencies

This project uses the following excellent third-party dependencies

CUDA

  • CUDA SDK
  • Thrust - High level CUDA algorithm library

Asset

Utilities

Testing

Interactive App

License

This repository is released under the MIT license, see License for more information.

cuda-path-tracer's People

Contributors

lesleylai avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

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