Merge branch 'feat/x-files' into 'main'

Use X-macros to generate all combinations of supported Eigen Matrix types

Co-authored-by: Joel Falcou <joel.falcou@lri.fr>

See merge request oss/rotgen!8
This commit is contained in:
Joel Falcou 2025-05-26 14:49:20 +02:00
parent a76020e274
commit 8647639c0d
24 changed files with 1176 additions and 1111 deletions

49
src/matrix.cpp Normal file
View file

@ -0,0 +1,49 @@
//==================================================================================================
/*
ROTGEN - Runtime Overlay for Eigen
Copyright : CODE RECKONS
SPDX-License-Identifier: BSL-1.0
*/
//==================================================================================================
#include <rotgen/detail/generators.hpp>
#include <rotgen/impl/matrix.hpp>
#include <Eigen/Dense>
namespace rotgen
{
#define SIZE 64
#define TYPE double
#define STORAGE_ORDER Eigen::ColMajor
#define MATRIX ROTGEN_MATRIX_NAME(matrix_impl,SIZE,_col)
#include "matrix_model.cpp"
#undef MATRIX
#undef STORAGE_ORDER
#define STORAGE_ORDER Eigen::RowMajor
#define MATRIX ROTGEN_MATRIX_NAME(matrix_impl,SIZE,_row)
#include "matrix_model.cpp"
#undef MATRIX
#undef STORAGE_ORDER
#undef SIZE
#undef TYPE
#define SIZE 32
#define TYPE float
#define STORAGE_ORDER Eigen::ColMajor
#define MATRIX ROTGEN_MATRIX_NAME(matrix_impl,SIZE,_col)
#include "matrix_model.cpp"
#undef MATRIX
#undef STORAGE_ORDER
#define STORAGE_ORDER Eigen::RowMajor
#define MATRIX ROTGEN_MATRIX_NAME(matrix_impl,SIZE,_row)
#include "matrix_model.cpp"
#undef MATRIX
#undef STORAGE_ORDER
#undef SIZE
#undef TYPE
}