Collision Checker
vector2d_export_streams.h
Go to the documentation of this file.
1 #pragma once
2 
3 // warning: to be included only with a serialize_.cc file: unsafe streaming
4 // operator redefinition for a generic version see also:
5 // https://stackoverflow.com/questions/20786220/eigen-library-initialize-matrix-with-data-from-file-or-existing-stdvector
6 
7 #include <Eigen/Dense>
8 #include <istream>
9 
10 inline std::istream &operator>>(std::istream &in, Eigen::Vector2d &vec) {
11  in >> vec[0];
12  in >> vec[1];
13 
14  return in;
15 }
16 
17 inline std::ostream &operator<<(std::ostream &out, const Eigen::Vector2d &vec) {
18  out << vec[0];
19  out << " ";
20  out << vec[1];
21  return out;
22 }
std::istream & operator>>(std::istream &in, Eigen::Vector2d &vec)
std::ostream & operator<<(std::ostream &out, const Eigen::Vector2d &vec)