Skip to content

moritzheep/adaptive-screen-meshing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

An Adaptive Screen-Space Meshing Approach for Normal Integration

Moritz Heep, Eduard Zell

University of Bonn, PhenoRob


Note: We have developped a new, anisotropic version that achieves similar compression but preserves details much better, see this repository.


Getting Started

To clone the repository with all its submodules run

$ git clone --recursive https://github.com/moritzheep/adaptive-screen-meshing.git

Prerequisites

Our method uses nvdiffrast to translate between the triangle mesh and the pixel grid. Please make sure that all dependencies of nvdiffrast are met, especially torch. Furthermore, we require OpenCV to be installed.

Docker

We prepared a Docker image to take care of these dependencies and facilitate testing. We still need the nvidia-container-runtime. It can be installed via

$ cd docker
$ .\nvidia-container-runtime.sh

To build the image, run

$ cd docker
$ ./build.sh

Finally, run

$ docker run \
    --runtime=nvidia \
    --gpus all \
    adaptive-screen-meshing

to get a list of options. You can then mount a volume and point towards your input files. All arguments can be appended to the above command and are passed through.

Building

To build the project, run

$ mkdir build
$ cd build
$ cmake ..
$ make

Running

After the build has been completed successfully, you can run

$ src/main \
    -n <path-to-the-normal-map> \
    -m <path-to-the-foreground-mask> \
    -t <path-to-save-the-mesh>

for a quick test. The normal map should be in the .exr format, the mask can be any 8Bit grayscale format supported by OpenCV. The mesh can be saved to any format supported by the pmp-library. We recommend .obj.

You can run src/main to get of full list of all options.

Troubleshooting

If you get meshes that curve in the wrong direction, try flipping the x or y coordinate of your normal map.

Citation

@inproceedings{heep2024screen-space-meshing,
    title={An Adaptive Screen-Space Meshing Approach for Normal Integration},
    author={Moritz Heep and Eduard Zell},
    booktitle = {European Conference on Computer Vision (ECCV)},
    year={2024}
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors