eigen/doc/snippets/Map_simple.cpp

4 lines
94 B
C++

int array[9];
for (int i = 0; i < 9; ++i) array[i] = i;
cout << Map<Matrix3i>(array) << endl;