diff --git a/include/igl/ambient_occlusion.cpp b/include/igl/ambient_occlusion.cpp index ac918fdad..4dfa163e3 100644 --- a/include/igl/ambient_occlusion.cpp +++ b/include/igl/ambient_occlusion.cpp @@ -123,3 +123,13 @@ IGL_INLINE void igl::ambient_occlusion( aabb.init(V,F); return ambient_occlusion(aabb,V,F,P,N,num_samples,S); } + +#ifdef IGL_STATIC_LIBRARY +// Explicit template specialization +// generated by autoexplicit.sh +template void igl::ambient_occlusion, Eigen::Matrix, Eigen::Matrix >(std::__1::function const&, Eigen::Matrix const&)> const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, int, Eigen::PlainObjectBase >&); +// generated by autoexplicit.sh +template void igl::ambient_occlusion, Eigen::Matrix, Eigen::Matrix >(std::__1::function const&, Eigen::Matrix const&)> const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, int, Eigen::PlainObjectBase >&); +// generated by autoexplicit.sh +template void igl::ambient_occlusion, Eigen::Matrix, Eigen::Matrix >(std::__1::function const&, Eigen::Matrix const&)> const&, Eigen::PlainObjectBase > const&, Eigen::PlainObjectBase > const&, int, Eigen::PlainObjectBase >&); +#endif diff --git a/include/igl/xml/XMLSerializable.h b/include/igl/xml/XMLSerializable.h index 10ed51887..54e569388 100644 --- a/include/igl/xml/XMLSerializable.h +++ b/include/igl/xml/XMLSerializable.h @@ -1,6 +1,7 @@ #ifndef IGL_XML_XMLSERIALIZABLE_H #define IGL_XML_XMLSERIALIZABLE_H +#include "serialize_xml.h" #include "../igl_inline.h" #include "../serialize.h" diff --git a/include/igl/xml/serialization_test.cpp b/include/igl/xml/serialization_test.cpp index 91e1ae4d4..5888075c4 100644 --- a/include/igl/xml/serialization_test.cpp +++ b/include/igl/xml/serialization_test.cpp @@ -8,7 +8,8 @@ //#define IGL_SERIALIZATION_TEST_H //#include -#include +#include "serialize_xml.h" +#include "XMLSerializable.h" namespace igl { diff --git a/include/igl/xml/serialize_xml.cpp b/include/igl/xml/serialize_xml.cpp index fbae678f5..2c676c71b 100644 --- a/include/igl/xml/serialize_xml.cpp +++ b/include/igl/xml/serialize_xml.cpp @@ -9,6 +9,7 @@ #include "serialize_xml.h" #include "../STR.h" #include "../serialize.h" +#include "XMLSerializable.h" #include #include diff --git a/include/igl/xml/serialize_xml.h b/include/igl/xml/serialize_xml.h index bdd6ef7f1..764208aca 100644 --- a/include/igl/xml/serialize_xml.h +++ b/include/igl/xml/serialize_xml.h @@ -17,7 +17,6 @@ #include "../igl_inline.h" -#include "XMLSerializable.h" #include #include @@ -38,6 +37,7 @@ namespace igl { namespace xml { + struct XMLSerializableBase; // serializes the given object either to a xml file or to the provided doc data // // Templates: diff --git a/tutorial/601_Serialization/main.cpp b/tutorial/601_Serialization/main.cpp index cf827ad33..84caba5bf 100755 --- a/tutorial/601_Serialization/main.cpp +++ b/tutorial/601_Serialization/main.cpp @@ -8,22 +8,22 @@ Eigen::MatrixXd V; Eigen::MatrixXi F; -//// derive from igl::Serializable to serialize your own type -//struct State : public igl::Serializable -//{ -// Eigen::MatrixXd V; -// Eigen::MatrixXi F; -// std::vector ids; -// -// // You have to define this function to -// // register the fields you want to serialize -// void InitSerialization() -// { -// this->Add(V , "V"); -// this->Add(F , "F"); -// this->Add(ids, "ids"); -// } -//}; +// derive from igl::Serializable to serialize your own type +struct State : public igl::Serializable +{ + Eigen::MatrixXd V; + Eigen::MatrixXi F; + std::vector ids; + + // You have to define this function to + // register the fields you want to serialize + void InitSerialization() + { + this->Add(V , "V"); + this->Add(F , "F"); + this->Add(ids, "ids"); + } +}; //// alternatively you can do it like the following to have //// a non-intrusive serialization: diff --git a/tutorial/cmake/FindMATLAB.cmake b/tutorial/cmake/FindMATLAB.cmake index 1d9b2a955..6e893f63a 100644 --- a/tutorial/cmake/FindMATLAB.cmake +++ b/tutorial/cmake/FindMATLAB.cmake @@ -203,6 +203,11 @@ SET(MATLAB_LIBRARIES IF(MATLAB_INCLUDE_DIR AND MATLAB_LIBRARIES) SET(MATLAB_FOUND 1) + message(STATUS "Found MATLAB: ${MATLAB_INCLUDE_DIR}") +else() + if (NOT MATLAB_FIND_QUIETLY) + message(FATAL_ERROR "could NOT find MATLAB") + endif (NOT MATLAB_FIND_QUIETLY) ENDIF(MATLAB_INCLUDE_DIR AND MATLAB_LIBRARIES) MARK_AS_ADVANCED(