Template Function otyca::row_to_col_major(const std::vector<T>&, std::vector<T>&, int, int)

Function Documentation

template<typename T>
void otyca::row_to_col_major(const std::vector<T> &rowMajor, std::vector<T> &colMajor, int rows, int cols)

Converts a row-major vector to a column-major vector.

Template Parameters:

T – Type of elements in the vector.

Parameters:
  • rowMajor – Input row-major vector.

  • colMajor – Output column-major vector.

  • rows – Number of rows.

  • cols – Number of columns.