Skip to content

Commit

Permalink
added extern templates for tet_io.
Browse files Browse the repository at this point in the history
Signed-off-by: Étienne Schmitt <[email protected]>
  • Loading branch information
etienneschmitt committed Mar 30, 2016
1 parent 6b639f3 commit 5373664
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
40 changes: 40 additions & 0 deletions cgogn/io/tet_io.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*******************************************************************************
* CGoGN: Combinatorial and Geometric modeling with Generic N-dimensional Maps *
* Copyright (C) 2015, IGG Group, ICube, University of Strasbourg, France *
* *
* This library is free software; you can redistribute it and/or modify it *
* under the terms of the GNU Lesser General Public License as published by the *
* Free Software Foundation; either version 2.1 of the License, or (at your *
* option) any later version. *
* *
* This library is distributed in the hope that it will be useful, but WITHOUT *
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or *
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License *
* for more details. *
* *
* You should have received a copy of the GNU Lesser General Public License *
* along with this library; if not, write to the Free Software Foundation, *
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. *
* *
* Web site: http://cgogn.unistra.fr/ *
* Contact information: [email protected] *
* *
*******************************************************************************/

#define CGOGN_IO_DLL_EXPORT
#define IO_TET_IO_CPP_

#include <io/tet_io.h>

namespace cgogn
{
namespace io
{

template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, Eigen::Vector3d>;
template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, Eigen::Vector3f>;
template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, geometry::Vec_T<std::array<float64,3>>>;
template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, geometry::Vec_T<std::array<float32,3>>>;

} // namespace io
} // namespace cgogn
7 changes: 7 additions & 0 deletions cgogn/io/tet_io.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,13 @@ class TetVolumeImport : public VolumeImport<MAP_TRAITS>
}
};

#if defined(CGOGN_USE_EXTERNAL_TEMPLATES) && (!defined(IO_TET_IO_CPP_))
extern template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, Eigen::Vector3d>;
extern template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, Eigen::Vector3f>;
extern template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, geometry::Vec_T<std::array<float64,3>>>;
extern template class CGOGN_IO_API TetVolumeImport<DefaultMapTraits, geometry::Vec_T<std::array<float32,3>>>;
#endif // defined(CGOGN_USE_EXTERNAL_TEMPLATES) && (!defined(IO_TET_IO_CPP_))

} // namespace io
} // namespace cgogn

Expand Down

0 comments on commit 5373664

Please sign in to comment.