Extension of libigl which allows to also read the texture of wrl-files in Python as igl.read_triangle_mesh(wrFilePath, V, F, TC)
|
11 年之前 | |
---|---|---|
documentation | 11 年之前 | |
examples | 11 年之前 | |
file-formats | 11 年之前 | |
include | 11 年之前 | |
scripts | 11 年之前 | |
tutorial | 11 年之前 | |
.gitignore | 11 年之前 | |
.mailmap | 11 年之前 | |
ACKNOWLEDGEMENTS | 11 年之前 | |
LICENSE | 11 年之前 | |
LICENSE.GPL | 11 年之前 | |
LICENSE.MPL2 | 11 年之前 | |
Makefile | 11 年之前 | |
Makefile.conf | 11 年之前 | |
README.md | 11 年之前 | |
RELEASE_HISTORY.txt | 11 年之前 | |
VERSION.txt | 11 年之前 | |
exclude.lst | 11 年之前 | |
libigl-dependency-diagram.ai.REMOVED.git-id | 11 年之前 | |
libigl-logo.ai.REMOVED.git-id | 12 年之前 | |
libigl-logo.jpg | 12 年之前 | |
libigl-teaser.pdf.REMOVED.git-id | 11 年之前 | |
matlab-to-eigen.html | 11 年之前 | |
style.css | 11 年之前 | |
style_guidelines.html | 11 年之前 | |
todos.txt | 11 年之前 | |
tutorial.html | 11 年之前 |
http://igl.ethz.ch/projects/libigl/ https://github.com/alecjacobson/libigl/
Copyright 2013 - Alec Jacobson, Daniele Panozzo, Olga Diamanti, Kenshi Takayama, Leo Sacht
This is first and foremost a header library. Each header file should contain a single function. The function may have multiple prototypes. All functions should use the igl namespace and should adhere to the conventions and styles listed below.
IGL_NO_OPENGL
)IGL_NO_ANTTWEAKBAR
) Last tested 1.16 (seelibigl is designed to work "out-of-the-box" as a headers only library. To
include libigl in your project. You need only include the libigl/include/
directory in your include path and define the IGL_HEADER_ONLY
macro. To
compile a hello-word example.cpp:
#include <Eigen/Dense>
#include <igl/readOBJ.h>
#include <iostream>
int main(int argc, char * argv[])
{
if(argc>1)
{
Eigen::MatrixXd V;
Eigen::MatrixXi F;
igl::readOBJ(argv[1],V,F);
std::cout<<"Hello, mesh with "<<V.rows()<<" vertices!"<<std::endl;
}else{
std::cout<<"Hello, world!"<<std::endl;
}
return 0;
}
using gcc (replacing appropriate paths):
g++ -DIGL_HEADER_ONLY -I/usr/local/igl/libigl/include \
-I/opt/local/include/eigen3 example.cpp -o example
Then run this example with:
./example examples/shared/TinyTorus.obj
libigl is developed most often on Mac OS X, though has current users in Linux and Windows.
libigl may also be compiled to a static library. This is advantageous when building a project with libigl, since the header only directive can slow down compile times.
To build the entire libigl library producing lib/libigl.a, issue:
make lib
You may need to edit Makefile.conf accordingly. Best to give yourself an
IGL_USERNAME
and add a custom install suite for yourself. Then you can enable
appropriate extras.
Once you've set up an IGL_USERNAME
and enabled extras within Makefile.conf.
You can build the extra libraries (into lib/ligiglpng.a, lib/libiglmatlab.a,
lib/libigltetgen.a, lib/libiglmosek.a, etc.) by issuing:
make extras
You can make a slew of examples by issuing:
make examples
Finally there are a number of external libraries that we include in ./external/ because they are either difficult to obtain or they have been patched for easier use with libigl. Please see the respective readmes in those directories.
To build the a static AntTweakBar library on Mac OS X issue:
cd external/AntTweakBar/src
make -f Makefile.osx.igl
To build the tetgen library and executable on Mac OS X issue:
cd external/tetgen
make clean
rm -f obj/*.o
make -f Makefile.igl tetgen
rm -f obj/*.o
make -f Makefile.igl tetlib
To build the igl version of the medit executable on Mac OS X issue:
cd external/medit
make -C libmesh
make -f Makefile.igl medit
To build the embree library and executables on Mac OS X issue:
cd external/embree
mkdir build
cd build
cmake ..
# Or using a different compiler
#cmake .. -DCMAKE_C_COMPILER=/opt/local/bin/gcc -DCMAKE_CXX_COMPILER=/opt/local/bin/g++
make
# Could also install embree to your root, but libigl examples don't expect
# this
#sudo make install
To build the a static tinyxml2 library on Mac OS X issue:
cd external/tinyxml2
cmake .
make
To build the a static YImg library on Mac OS X issue:
cd external/yimg
make
You may need to install libpng. Systems with X11 might find this already
installed at /usr/X11/lib
.
To build a static library (.lib) on windows, open Visual Studio 2010.
To get started, we advise that you take a look at a few examples:
./examples/hello-world/
./examples/meshio/
./examples/basic-topology/
./examples/ReAntTweakBar/
Further documentation for developers is listed in tutorial.html, style_guidelines.html
See LICENSE.txt
Zip this directory without .git litter and binaries using:
git archive —prefix=libigl/ -o libigl.zip master
libigl is a group endeavor led by Alec Jacobson and Daniele Panozzo. Please contact alecjacobson@gmail.com if you have questions or comments. We are happy to get feedback! Enjoy!
If you find bugs or have problems please use our github issue tracking page.