Skip to content

Commit

Permalink
Merge branch 'bindings' into python_bindings
Browse files Browse the repository at this point in the history
  • Loading branch information
skoch9 committed Jun 2, 2016
1 parent 71091ca commit 35cb709
Show file tree
Hide file tree
Showing 15 changed files with 1,591 additions and 33 deletions.
1 change: 1 addition & 0 deletions README.md
Expand Up @@ -195,6 +195,7 @@ Eurographics/ACM Symposium on Geometry Processing software award. Here are a
few labs/companies/institutions using libigl:

- [Adobe Research](http://www.adobe.com/technology/)
- [Electronic Arts, Inc](http://www.ea.com)
- [Mesh](http://meshconsultants.ca/), consultants, Canada
- [Pixar Research](http://graphics.pixar.com/research/)
- [Spine by Esoteric Software](http://esotericsoftware.com/) is an animation tool dedicated to 2D characters.
Expand Down
1 change: 1 addition & 0 deletions include/igl/list_to_matrix.cpp
Expand Up @@ -146,5 +146,6 @@ template bool igl::list_to_matrix<double, Eigen::Matrix<double, -1, -1, 0, -1, -
template bool igl::list_to_matrix<double, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(std::vector<double, std::allocator<double> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
template bool igl::list_to_matrix<double, Eigen::Matrix<double, -1, -1, 0, -1, -1> >(std::vector<double, std::allocator<double> > const&, Eigen::PlainObjectBase<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&);
template bool igl::list_to_matrix<unsigned long, Eigen::Matrix<int, -1, -1, 0, -1, -1> >(std::vector<unsigned long, std::allocator<unsigned long> > const&, Eigen::PlainObjectBase<Eigen::Matrix<int, -1, -1, 0, -1, -1> >&);
template bool igl::list_to_matrix<unsigned __int64, class Eigen::Matrix<int, -1, -1, 0, -1, -1> >(class std::vector<unsigned __int64, class std::allocator<unsigned __int64> > const &, class Eigen::PlainObjectBase<class Eigen::Matrix<int, -1, -1, 0, -1, -1> > &);
#endif
#endif
10 changes: 5 additions & 5 deletions include/igl/round.cpp
@@ -1,9 +1,9 @@
// This file is part of libigl, a simple c++ geometry processing library.
//
//
// Copyright (C) 2013 Alec Jacobson <alecjacobson@gmail.com>
//
// This Source Code Form is subject to the terms of the Mozilla Public License
// v. 2.0. If a copy of the MPL was not distributed with this file, You can
//
// This Source Code Form is subject to the terms of the Mozilla Public License
// v. 2.0. If a copy of the MPL was not distributed with this file, You can
// obtain one at http://mozilla.org/MPL/2.0/.
#include "round.h"
#include <cmath>
Expand All @@ -13,7 +13,7 @@
template <typename DerivedX >
IGL_INLINE DerivedX igl::round(const DerivedX r)
{
return (r > 0.0) ? floor(r + 0.5) : ceil(r - 0.5);
return (r > 0.0) ? std::floor(r + 0.5) : std::ceil(r - 0.5);
}

template < typename DerivedX, typename DerivedY>
Expand Down
8 changes: 4 additions & 4 deletions include/igl/viewer/Viewer.cpp
Expand Up @@ -346,13 +346,13 @@ namespace viewer
T,t Toggle filled faces
Z Snap to canonical view
[,] Toggle between rotation control types (e.g. trackball, two-axis
valuator with fixed up)
valuator with fixed up))"
#ifdef IGL_VIEWER_WITH_NANOGUI
R"(
; Toggle vertex labels
: Toggle face labels
: Toggle face labels)"
#endif
)");
);
std::cout<<usage;
#endif
}
Expand Down
32 changes: 23 additions & 9 deletions index.html
Expand Up @@ -14,9 +14,9 @@

<h1 id="libigl-asimplecgeometryprocessinglibrary">libigl - A simple C++ geometry processing library</h1>

<figure>
<img src="libigl-teaser.png" alt="" />
</figure>
<p><a href="https://travis-ci.org/libigl/libigl"><img src="https://travis-ci.org/libigl/libigl.svg?branch=master" alt="Build Status" /></a>
<a href="https://ci.appveyor.com/project/danielepanozzo/libigl-6hjk1"><img src="https://ci.appveyor.com/api/projects/status/mf3t9rnhco0vhly8?svg=true" alt="Build status" /></a>
<img src="libigl-teaser.png" alt="" /></p>

<p><a href="https://github.com/libigl/libigl/">https://github.com/libigl/libigl/</a></p>

Expand Down Expand Up @@ -51,6 +51,9 @@ <h1 id="libigl-asimplecgeometryprocessinglibrary">libigl - A simple C++ geometry
group prototypes a lot in MATLAB, and we have a useful <a href="matlab-to-eigen.html">MATLAB to libigl+Eigen
conversion table</a>.</p>

<p>We regularly test compiling our library on Mac OS X with clang, Linux with gcc
and Windows with Visual Studio 2015 Community Edition.</p>

<h2 id="tutorial">Tutorial</h2>

<p>As of version 1.0, libigl includes an introductory
Expand Down Expand Up @@ -168,7 +171,7 @@ <h2 id="gitsubmodules">Git Submodules</h2>
subrepos:</p>

<pre><code class="bash">git pull
git submodule update -- recursive
git submodule update --recursive
</code></pre>

<h2 id="unittesting">Unit testing</h2>
Expand Down Expand Up @@ -199,7 +202,7 @@ <h2 id="attribution">Attribution</h2>
title = {{libigl}: A simple {C++} geometry processing library},
author = {Alec Jacobson and Daniele Panozzo and others},
note = {http://libigl.github.io/libigl/},
year = {2015},
year = {2016},
}
</code></pre>

Expand All @@ -210,23 +213,34 @@ <h2 id="projectsuniversitiesusinglibigl">Projects/Universities using libigl</h2>
few labs/companies/institutions using libigl:</p>

<ul>
<li><a href="http://www.adobe.com/technology/">Adobe Research</a></li>
<li><a href="http://meshconsultants.ca/">Mesh</a>, consultants, Canada</li>
<li><a href="http://graphics.pixar.com/research/">Pixar Research</a></li>
<li><a href="http://esotericsoftware.com/">Spine by Esoteric Software</a> is an animation tool dedicated to 2D characters.</li>
<li>Columbia University, <a href="http://www.cs.columbia.edu/cg/">Columbia Computer Graphics Group</a>, USA</li>
<li><a href="http://www.graphics.cornell.edu/">Cornell University</a>, USA</li>
<li><a href="http://dcgi.felk.cvut.cz/">Czech Technical University in Prague</a>, Czech</li>
<li>EPF Lausanne, <a href="http://lgg.epfl.ch/people.php">Computer Graphics and Geometry Laboratory</a>, Switzerland</li>
<li>ETH Zurich, <a href="http://igl.ethz.ch/">Interactive Geometry Lab</a> and <a href="http://ait.inf.ethz.ch/">Advanced Technologies Lab</a>, Swizterland</li>
<li>George Mason University, <a href="http://cs.gmu.edu/~ygingold/">CraGL</a>, USA</li>
<li><a href="http://www.ust.hk/">Hong Kong University of Science and Technology</a>, USA</li>
<li><a href="http://www.ust.hk/">Hong Kong University of Science and Technology</a>, Hong Kong</li>
<li><a href="http://www.nii.ac.jp/en/">National Institute of Informatics</a>, Japan</li>
<li>New York University, <a href="http://mrl.nyu.edu/">Media Research Lab</a>, USA</li>
<li>NYUPoly, <a href="http://game.engineering.nyu.edu/">Game Innovation Lab</a>, USA</li>
<li><a href="http://www.telecom-paristech.fr/en/formation-et-innovation-dans-le-numerique.html">Telecom ParisTech</a>, Paris, France</li>
<li><a href="https://www.cg.tu-berlin.de">TU Berlin</a>, Germany</li>
<li><a href="http://www.tudelft.nl/en/">TU Delft</a>, Netherlands</li>
<li><a href="https://www.tuwien.ac.at/en/tuwien_home/">TU Wien</a>, Austria</li>
<li><a href="http://www.telecom-paristech.fr/en/formation-et-innovation-dans-le-numerique.html">Telecom ParisTech</a>, Paris, France</li>
<li><a href="http://mtm.ufsc.br/~leo/">Universidade Federal de Santa Catarina</a>, Brazil</li>
<li><a href="http://www.usi.ch/en">Università della Svizzera Italiana</a>, Switzerland</li>
<li><a href="http://vecg.cs.ucl.ac.uk/">University College London</a>, England</li>
<li><a href="http://vis.berkeley.edu/">University of California Berkeley</a>, USA</li>
<li><a href="http://www.cam.ac.uk/">University of Cambridge</a>, England</li>
<li><a href="http://cg.cis.upenn.edu/">University of Pennsylvania</a>, USA</li>
<li><a href="http://www.cs.utexas.edu/users/evouga/">University of Texas at Austin</a>, USA</li>
<li><a href="https://www.csc.uvic.ca/Research/graphics/">University of Victoria</a>, Canada</li>
<li><a href="http://www.usi.ch/en">Università della Svizzera Italiana</a>, Switzerland</li>
<li><a href="http://www.univ-tlse3.fr/">Université Toulouse III Paul Sabatier</a>, France</li>
<li><a href="http://www.math.zju.edu.cn/cagd/">Zhejiang University</a>, China</li>
</ul>

<h2 id="contact">Contact</h2>
Expand All @@ -248,7 +262,7 @@ <h2 id="contact">Contact</h2>

<h2 id="copyright">Copyright</h2>

<p>2015 Alec Jacobson, Daniele Panozzo, Christian Schüller, Olga Diamanti, Qingnan
<p>2016 Alec Jacobson, Daniele Panozzo, Christian Schüller, Olga Diamanti, Qingnan
Zhou, Nico Pietroni, Stefan Brugger, Kenshi Takayama, Wenzel Jakob, Nikolas De
Giorgis, Luigi Rocca, Leonardo Sacht, Kevin Walliman, Olga Sorkine-Hornung, and others.</p>

Expand Down
10 changes: 1 addition & 9 deletions optional/index.html
Expand Up @@ -50,14 +50,6 @@ <h4 id="warnings">Warnings</h4>
<p>These are (admittedly unpopular) functions that have never been used by us
statically so we haven&#8217;t explicit instantiations (yet).</p>

<h4 id="examples">Examples</h4>

<p>You can make a slew of examples by issuing:</p>

<pre><code>cd ../examples
make
</code></pre>

<h4 id="external">External</h4>

<p>Finally there are a number of external libraries that we include in
Expand Down Expand Up @@ -316,7 +308,7 @@ <h3 id="drawbacksofcompressed.h.cpppair">Drawbacks of compressed .h/.cpp pair</h
{
Eigen::MatrixXd V;
Eigen::MatrixXi F;
return (argc&gt;=2 &amp;amp;&amp;amp; igl::read_triangle_mesh(argv[1],V,F)?0:1);
return (argc&gt;=2 &amp;&amp; igl::read_triangle_mesh(argv[1],V,F)?0:1);
}
</code></pre>

Expand Down
2 changes: 1 addition & 1 deletion python/CMakeLists.txt
Expand Up @@ -30,7 +30,7 @@ if (UNIX)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -fPIC")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC")
if (NOT ${U_CMAKE_BUILD_TYPE} MATCHES DEBUG)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -flto")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden")
endif()
endif()

Expand Down
64 changes: 64 additions & 0 deletions python/python_shared.cpp
Expand Up @@ -24,6 +24,70 @@ PYBIND11_PLUGIN(pyigl) {
.. autosummary::
:toctree: _generate
principal_curvature
local_basis
signed_distance
cotmatrix
floor
slice
per_face_normals
ARAPEnergyType
readOFF
per_vertex_normals
sortrows
barycenter
jet
cat
eigs
per_corner_normals
massmatrix
colon
fit_rotations
rotate_vectors
read_triangle_mesh
SolverStatus
gaussian_curvature
avg_edge_length
barycentric_coordinates
lscm
find_cross_field_singularities
upsample
slice_mask
point_mesh_squared_distance
parula
setdiff
comb_frame_field
map_vertices_to_circle
writeOBJ
active_set
AABB
per_edge_normals
covariance_scatter_matrix
boundary_facets
compute_frame_field_bisectors
edge_lengths
readOBJ
cut_mesh_from_singularities
readDMAT
doublearea
min_quad_with_fixed
writeMESH
unique
arap
cross_field_missmatch
grad
slice_into
slice_tets
n_polyvector
harmonic
boundary_loop
polar_svd
comb_cross_field
invert_diag
readMESH
copyleft_comiso_miq
copyleft_comiso_nrosy
)pyigldoc");

python_export_vector(m);
Expand Down
3 changes: 3 additions & 0 deletions python/scripts/Problematic_functions
@@ -0,0 +1,3 @@
boundary_facets
boundary_loop
colon

0 comments on commit 35cb709

Please sign in to comment.