Skip to content

GodZza/contours

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contours

This is the research prototype implementing the occluding contours extraction method described in the following publication:

Computing Smooth Surface Contours with Accurate Topology. Pierre Bénard, Aaron Hertzmann, Michael Kass. ACM Transactions on Graphics, 2013

Disclaimer: This version of the mesh generation code is not exactly the same as the one used for producing the results in the paper. We had to switch to OpenSubdiv to be able to release it. The precision of the root-finding procedure is lower, which may impact the tesselation.

Note: This is research software. As such, it may fail to run, crash, or otherwise not perform as expected. It is not intended for regular use in any kind of production pipeline.

Dependencies

The code is based on a skimmed and tweaked version of OpenSubdiv and a heavily modified version of Freestyle (included). The mesh generation algorithm is implemented as a RifFilter; you will either need Pixar's RenderMan or 3Delight Studio Pro (free licence available) to build and run it.

Required:

Optional:

Build instructions

Tested on Linux (gcc 4.8) and OS X (clang 5.x), not tested on Windows.

Clone the repository:

git clone https://github.com/benardp/contours

Generate Makefiles and build the project:

Assuming that you want the binaries installed into a "build" directory at the root of the source tree :

cd contours
mkdir build
cd build
cmake ..
make
make install

Usage

We provide scripts to run the mesh generation algorithm and contours extraction code on a sequence of RIB files. We provide two test sequences (torus and Stanford Bunny) on the project web page; you can export other shots using RenderMan or 3Delight for Maya, or 3Dlight/Blender.

The settings are specified in build/scripts/settings.py. You need to provide the local paths to the input and output shots directories on your machine through the variables mainTestShotFolder and mainOutputFolder (mandatory). The shot parameter allows you to choose the sequence that you want to process; it needs to match the name of the subdirectory containing the RIB files.

Then, to run the code:

# from the "build" directory
cd scripts
python npr.py

The output PLY meshes and curves (EPS, PDF and, on OS X, PNG files) are saved in a subdirectory of mainOutputFolder.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 75.9%
  • HTML 19.2%
  • Python 3.2%
  • C 1.3%
  • CMake 0.3%
  • CSS 0.1%