From 4199f10ae1408cd34e7712c5175f57f3b95e1ab9 Mon Sep 17 00:00:00 2001 From: Anthony Geay Date: Tue, 5 Dec 2017 17:45:44 +0100 Subject: [PATCH] On the fly --- src/Plugins/MEDWriter/IO/CMakeLists.txt | 2 +- src/Plugins/MEDWriter/IO/VTKToMEDMem.cxx | 32 +----------------------- 2 files changed, 2 insertions(+), 32 deletions(-) diff --git a/src/Plugins/MEDWriter/IO/CMakeLists.txt b/src/Plugins/MEDWriter/IO/CMakeLists.txt index 16dbc23b..2b8c2d99 100644 --- a/src/Plugins/MEDWriter/IO/CMakeLists.txt +++ b/src/Plugins/MEDWriter/IO/CMakeLists.txt @@ -30,7 +30,7 @@ TARGET_LINK_LIBRARIES(vtkMEDWriter VTKToMEDMem) INSTALL(TARGETS vtkMEDWriter RUNTIME DESTINATION ${VTK_INSTALL_RUNTIME_DIR} LIBRARY DESTINATION ${VTK_INSTALL_LIBRARY_DIR} ARCHIVE DESTINATION ${VTK_INSTALL_ARCHIVE_DIR} ) INSTALL(TARGETS VTKToMEDMem EXPORT ${PROJECT_NAME}TargetGroup RUNTIME DESTINATION ${VTK_INSTALL_RUNTIME_DIR} LIBRARY DESTINATION ${VTK_INSTALL_LIBRARY_DIR} ARCHIVE DESTINATION ${VTK_INSTALL_ARCHIVE_DIR} ) -INSTALL(FILES VTKToMEDMem.hxx DESTINATION ${MEDWRITER_INSTALL_HEADERS}) +INSTALL(FILES VTKToMEDMem.hxx VTKMEDTraits.hxx DESTINATION ${MEDWRITER_INSTALL_HEADERS}) SET(_${PROJECT_NAME}_exposed_targets VTKToMEDMem) EXPORT(TARGETS ${_${PROJECT_NAME}_exposed_targets} FILE ${PROJECT_BINARY_DIR}/${PROJECT_NAME}Targets.cmake) diff --git a/src/Plugins/MEDWriter/IO/VTKToMEDMem.cxx b/src/Plugins/MEDWriter/IO/VTKToMEDMem.cxx index c3d20a9e..b6398958 100644 --- a/src/Plugins/MEDWriter/IO/VTKToMEDMem.cxx +++ b/src/Plugins/MEDWriter/IO/VTKToMEDMem.cxx @@ -105,37 +105,7 @@ Fam::Fam(const std::string& name) /////////////////// -template -class MEDFileVTKTraits -{ -public: - typedef void VtkType; - typedef void MCType; -}; - -template<> -class MEDFileVTKTraits -{ -public: - typedef vtkIntArray VtkType; - typedef MEDCoupling::DataArrayInt MCType; -}; - -template<> -class MEDFileVTKTraits -{ -public: - typedef vtkFloatArray VtkType; - typedef MEDCoupling::DataArrayFloat MCType; -}; - -template<> -class MEDFileVTKTraits -{ -public: - typedef vtkDoubleArray VtkType; - typedef MEDCoupling::DataArrayDouble MCType; -}; +#include "VTKMEDTraits.hxx" std::map ComputeMapOfType() { -- 2.39.2