Giter Site home page Giter Site logo

svendsonllc / seamawaredecimater Goto Github PK

View Code? Open in Web Editor NEW

This project forked from songrun/seamawaredecimater

0.0 0.0 0.0 10 MB

Mesh simplification with UV's boundary preserved

Home Page: https://cragl.cs.gmu.edu/seamless/

License: MIT License

C++ 89.74% CMake 10.26%

seamawaredecimater's Introduction

Seam-aware Decimater

This project implements the seam-aware decimation portion of our SIGGRAPH Asia 2017 paper Seamless: Seam erasure and seam-aware decoupling of shape from mesh resolution. Seam-aware decimater simplifies a mesh while preserving its UV's boundary. It allows the same texture to be used across all decimation levels—notably along seams.

Our seam-aware decimation allows seamless texture reuse at all decimation levels (here, approximately 1%). Seams on the original model are shown in purple. Parameterizations are shown inset. Garland and Heckbert [1998] (implemented by MeshLab [Cignoni et al. 2008]) do not preserve seams precisely, leading to artifacts in the texture. Red areas near seams in the inset parameterization indicate this deviation in the parametric domain. Maya [2017] prevents decimation of seams entirely, leading to suboptimal allocation of mesh vertices.

Requirements

This project uses C++ 11, and it depends on:

  • libigl (git clone https://github.com/libigl/libigl.git --recursive)
  • eigen (e.g. brew install eigen)

Compile this project

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

Run this project

./decimater ../models/animal.obj percent-vertices 50
./decimater ../models/animal.obj num-vertices 1000

Note: this library only works on triangle mesh.

Various strictness

Seamless criteria is even stricter than UV shape preservation. I add a "strictness" parameter to satisfy different requirements. Strictness could be 0, 1, or 2. Strictness 0 means no UV shape is preserved, but UV parameters is still part of the metrics. Strictness 1 means UV shape is preserved. Strictness 2 means seam aware decimation which also considers the length ratio criteria. It works like this:

./decimater ../models/animal.obj percent-vertices 50 --strict 1
./decimater ../models/animal.obj num-vertices 1000 --strict 1

The default strictness is 2.

Example

The Animal model is decimated to 3% of its original number of vertices. The boundary of its UV parameterization stays.

seamawaredecimater's People

Contributors

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