Serializing OpenCV Mat_
The earlier answers are good, but they won’t work for non-continuous matrices which arise when you want to serialize regions of interest (among other things). Also, it is unnecessary to serialize elemSize() because this is derived from the type value. Here’s some code that will work regardless of continuity (with includes/namespace) #pragma once #include <boost/archive/text_oarchive.hpp> … Read more