all tutorial examples compile with static lib
Former-commit-id: b418eb9451
This commit is contained in:
@@ -83,5 +83,9 @@ IGL_INLINE void igl::cotmatrix(
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::cotmatrix<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 4, 0, -1, 4>, double>(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 4, 0, -1, 4> > const&, Eigen::SparseMatrix<double, 0, int>&);
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::cotmatrix<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 3, 0, -1, 3>, double>(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 3, 0, -1, 3> > const&, Eigen::SparseMatrix<double, 0, int>&);
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::cotmatrix<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, double>(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::SparseMatrix<double, 0, int>&);
|
||||
#endif
|
||||
|
||||
@@ -97,5 +97,9 @@ IGL_INLINE void igl::cotmatrix_entries(
|
||||
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::cotmatrix_entries<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 4, 0, -1, 4>, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 4, 0, -1, 4> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::cotmatrix_entries<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 3, 0, -1, 3>, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
template void igl::cotmatrix_entries<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
#endif
|
||||
|
||||
@@ -71,4 +71,5 @@ template void igl::edge_lengths<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen:
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::edge_lengths<Eigen::Matrix<float, -1, 3, 1, -1, 3>, Eigen::Matrix<unsigned int, -1, -1, 1, -1, -1>, Eigen::Matrix<float, -1, 3, 1, -1, 3> >(Eigen::PlainObjectBase<Eigen::Matrix<float, -1, 3, 1, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<unsigned int, -1, -1, 1, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<float, -1, 3, 1, -1, 3> >&);
|
||||
template void igl::edge_lengths<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
template void igl::edge_lengths<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 4, 0, -1, 4>, Eigen::Matrix<double, -1, 6, 0, -1, 6> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 4, 0, -1, 4> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 6, 0, -1, 6> >&);
|
||||
#endif
|
||||
|
||||
@@ -52,4 +52,5 @@ IGL_INLINE void igl::gaussian_curvature(
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
template void igl::gaussian_curvature<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
template void igl::gaussian_curvature<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, Eigen::Matrix<double, -1, 1, 0, -1, 1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 1, 0, -1, 1> >&);
|
||||
#endif
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#define IGL_COMPUTE_LIM_H
|
||||
#include <igl/igl_inline.h>
|
||||
#include <Eigen/Core>
|
||||
#include <Eigen/Sparse>
|
||||
|
||||
namespace igl
|
||||
{
|
||||
@@ -110,4 +111,4 @@ namespace igl
|
||||
# include "compute_lim.cpp"
|
||||
#endif
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -160,5 +160,9 @@ IGL_INLINE void igl::massmatrix(
|
||||
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::massmatrix<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 4, 0, -1, 4>, double>(Eigen::MatrixBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::MatrixBase<Eigen::Matrix<int, -1, 4, 0, -1, 4> > const&, igl::MassMatrixType, Eigen::SparseMatrix<double, 0, int>&);
|
||||
// generated by autoexplicit.sh
|
||||
template void igl::massmatrix<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 3, 0, -1, 3>, double>(Eigen::MatrixBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> > const&, Eigen::MatrixBase<Eigen::Matrix<int, -1, 3, 0, -1, 3> > const&, igl::MassMatrixType, Eigen::SparseMatrix<double, 0, int>&);
|
||||
template void igl::massmatrix<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, double>(Eigen::MatrixBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::MatrixBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, igl::MassMatrixType, Eigen::SparseMatrix<double, 0, int>&);
|
||||
#endif
|
||||
|
||||
@@ -59,13 +59,13 @@ inline igl::PlanarizerShapeUp<DerivedV, DerivedF>::PlanarizerShapeUp(const Eigen
|
||||
const Eigen::PlainObjectBase<DerivedF> &F_,
|
||||
const int maxIter_,
|
||||
const double &threshold_):
|
||||
numV(V_.rows()),
|
||||
numF(F_.rows()),
|
||||
Vin(V_),
|
||||
Fin(F_),
|
||||
weightsSqrt(Eigen::Matrix<typename DerivedV::Scalar, Eigen::Dynamic, 1>::Ones(numF,1)),
|
||||
maxIter(maxIter_),
|
||||
threshold(threshold_),
|
||||
numF(F_.rows()),
|
||||
numV(V_.rows()),
|
||||
weightsSqrt(Eigen::Matrix<typename DerivedV::Scalar, Eigen::Dynamic, 1>::Ones(numF,1))
|
||||
threshold(threshold_)
|
||||
{
|
||||
// assemble stacked vertex position vector
|
||||
Vv.setZero(3*numV,1);
|
||||
@@ -198,7 +198,7 @@ inline void igl::PlanarizerShapeUp<DerivedV, DerivedF>::planarize(Eigen::PlainOb
|
||||
{
|
||||
igl::quad_planarity(Vout, Fin, planarity);
|
||||
typename DerivedV::Scalar nonPlanarity = planarity.cwiseAbs().maxCoeff();
|
||||
std::cerr<<"iter #"<<iter<<": max non-planarity: "<<nonPlanarity<<std::endl;
|
||||
//std::cerr<<"iter #"<<iter<<": max non-planarity: "<<nonPlanarity<<std::endl;
|
||||
if (nonPlanarity<threshold)
|
||||
break;
|
||||
assembleP();
|
||||
@@ -231,3 +231,8 @@ IGL_INLINE void igl::planarize_quad_mesh(const Eigen::PlainObjectBase<DerivedV>
|
||||
PlanarizerShapeUp<DerivedV, DerivedF> planarizer(Vin, Fin, maxIter, threshold);
|
||||
planarizer.planarize(Vout);
|
||||
}
|
||||
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template instanciation
|
||||
template void igl::planarize_quad_mesh<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, int, double const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
|
||||
#endif
|
||||
|
||||
@@ -27,4 +27,5 @@ IGL_INLINE void igl::quad_planarity(
|
||||
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
template void igl::quad_planarity<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1>, Eigen::Matrix<double, -1, 1, 0, -1, 1> >(Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 1, 0, -1, 1> >&);
|
||||
#endif
|
||||
|
||||
@@ -210,6 +210,8 @@ IGL_INLINE bool igl::readOFF(
|
||||
#ifdef IGL_STATIC_LIBRARY
|
||||
// Explicit template specialization
|
||||
// generated by autoexplicit.sh
|
||||
template bool igl::readOFF<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, -1, 0, -1, -1> >(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> >&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> >&);
|
||||
// generated by autoexplicit.sh
|
||||
template bool igl::readOFF<Eigen::Matrix<double, -1, -1, 0, -1, -1>, Eigen::Matrix<int, -1, -1, 0, -1, -1> >(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> >&);
|
||||
template bool igl::readOFF<Eigen::Matrix<double, -1, 3, 1, -1, 3>, Eigen::Matrix<unsigned int, -1, -1, 1, -1, -1> >(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 1, -1, 3> >&, Eigen::PlainObjectBase<Eigen::Matrix<unsigned int, -1, -1, 1, -1, -1> >&);
|
||||
template bool igl::readOFF<Eigen::Matrix<double, -1, 3, 0, -1, 3>, Eigen::Matrix<int, -1, 3, 0, -1, 3> >(std::string, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, 3, 0, -1, 3> >&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 3, 0, -1, 3> >&);
|
||||
|
||||
@@ -12,7 +12,9 @@
|
||||
#include <vector>
|
||||
#include <string>
|
||||
#include <Eigen/Core>
|
||||
#ifndef TETLIBRARY
|
||||
#define TETLIBRARY
|
||||
#endif
|
||||
#include "tetgen.h" // Defined REAL
|
||||
|
||||
namespace igl
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
#define IGL_HEADER_ONLY
|
||||
#include <igl/readOFF.h>
|
||||
#include <igl/writeOBJ.h>
|
||||
#include <iostream>
|
||||
@@ -11,9 +10,9 @@ int main(int argc, char *argv[])
|
||||
// Load a mesh in OFF format
|
||||
igl::readOFF("../shared/cube.off", V, F);
|
||||
|
||||
// Plot the vertices and faces matrices
|
||||
std::cerr << "Vertices: " << std::endl << V << std::endl;
|
||||
std::cerr << "Faces: " << std::endl << F << std::endl;
|
||||
// Print the vertices and faces matrices
|
||||
std::cout << "Vertices: " << std::endl << V << std::endl;
|
||||
std::cout << "Faces: " << std::endl << F << std::endl;
|
||||
|
||||
// Save the mesh in OBJ format
|
||||
igl::writeOBJ("cube.obj",V,F);
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
#define IGL_HEADER_ONLY
|
||||
#include <igl/readOFF.h>
|
||||
#include <igl/viewer/Viewer.h>
|
||||
#include <igl/jet.h>
|
||||
@@ -17,10 +16,10 @@ int main(int argc, char *argv[])
|
||||
viewer.set_mesh(V, F);
|
||||
|
||||
// Use the x coordinate as a scalar field over the surface
|
||||
Eigen::VectorXd x = V.col(2);
|
||||
Eigen::VectorXd Z = V.col(2);
|
||||
|
||||
// Compute per-vertex colors
|
||||
igl::jet(x,true,C);
|
||||
igl::jet(Z,true,C);
|
||||
|
||||
// Add per-vertex colors
|
||||
viewer.set_colors(C);
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
#define IGL_HEADER_ONLY
|
||||
#include <igl/readOFF.h>
|
||||
#include <igl/viewer/Viewer.h>
|
||||
#include <sstream>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#include <igl/readOBJ.h>
|
||||
#include <igl/readOFF.h>
|
||||
#include <igl/readDMAT.h>
|
||||
#include <igl/viewer/Viewer.h>
|
||||
#include <igl/barycenter.h>
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
#define IGL_HEADER_ONLY
|
||||
#include <igl/readOFF.h>
|
||||
#include <igl/matlab/matlabinterface.h>
|
||||
#include <igl/viewer/Viewer.h>
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
#include "mex.h"
|
||||
|
||||
#define IGL_HEADER_ONLY
|
||||
#include <igl/readOBJ.h>
|
||||
#include <igl/matlab/prepare_lhs.h>
|
||||
#include <Eigen/Core>
|
||||
|
||||
@@ -74,6 +74,12 @@ if(LIBIGL_USE_STATIC_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLEMBREE_LIBRARY})
|
||||
find_package(Embree REQUIRED)
|
||||
|
||||
FIND_LIBRARY( LIBIGLLIM_LIBRARY NAMES igllim PATHS ${LIBIGL_LIB_DIRS})
|
||||
if(NOT LIBIGLLIM_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
endif(NOT LIBIGLLIM_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLLIM_LIBRARY})
|
||||
|
||||
FIND_LIBRARY( LIBIGLMATLAB_LIBRARY NAMES iglmatlab PATHS ${LIBIGL_LIB_DIRS})
|
||||
if(NOT LIBIGLMATLAB_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
@@ -92,11 +98,25 @@ if(LIBIGL_USE_STATIC_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
endif(NOT LIBIGLSVD3X3_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLSVD3X3_LIBRARY})
|
||||
|
||||
FIND_LIBRARY( LIBIGLTETGEN_LIBRARY NAMES igltetgen PATHS ${LIBIGL_LIB_DIRS})
|
||||
if(NOT LIBIGLTETGEN_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
endif(NOT LIBIGLTETGEN_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLTETGEN_LIBRARY})
|
||||
|
||||
FIND_LIBRARY( LIBIGLTRIANGLE_LIBRARY NAMES igltriangle PATHS ${LIBIGL_LIB_DIRS})
|
||||
if(NOT LIBIGLTRIANGLE_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
endif(NOT LIBIGLTRIANGLE_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLTRIANGLE_LIBRARY})
|
||||
|
||||
FIND_LIBRARY( LIBIGLVIEWER_LIBRARY NAMES iglviewer PATHS ${LIBIGL_LIB_DIRS})
|
||||
if(NOT LIBIGLVIEWER_LIBRARY)
|
||||
set(LIBIGL_FOUND FALSE)
|
||||
endif(NOT LIBIGLVIEWER_LIBRARY)
|
||||
set(LIBIGL_LIBRARIES ${LIBIGL_LIBRARIES} ${LIBIGLVIEWER_LIBRARY})
|
||||
|
||||
find_package(OpenMP)
|
||||
if (OPENMP_FOUND)
|
||||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
|
||||
|
||||
@@ -1 +1 @@
|
||||
fd25f13c73a1b570b6618b89c3e8fbb0add2e6ee
|
||||
f9f3805758e1b5e3e93dcc985f565fc191fb1860
|
||||
Reference in New Issue
Block a user