Convert OpenCV CvBox2D
to a MATLAB struct
#include "opencvmex.hpp"
mxArray
*ocvCvBox2DToMxArray(const CvBox2D *in);
in
Pointer to OpenCV CvBox2D
.
Pointer to a MATLAB® structure, mxArray
, that represents a rectangle.
The structure must have five scalar-valued fields: x_center
, y_center
, width
, height
,
and angle
. The (x_center
, y_center
)
fields represent the center of the rectangle.
The ocvCvBox2DToMxArray
function converts
a rectangle data structure from an OpenCV CvBox2D
to
a MATLAB struct.