Hi all,
I've got a contour for a flat, irregular shape with ~ten, 2D, points. I'd like to project just that contour, not the whole image, into a normal view and then find area, etc.
I know the contour is OK because drawContours has the expected result. The rotation matrix, Rot3D, works with warpPerspective on the full image (I play with the rotations for the background in a calibration step, then try to use the same rotation matrix here. It is a (3, 3, CV_32FC1) ).
I simplified everything to this code: `
vector<Point> foo = { { 0, 0 }, { 0, 1 }, { 1, 1 }, { 1, 0 } };
vector<Point> bar;
bar.resize(foo.size());
perspectiveTransform(foo, bar, Rot3D);
` which fails an assertion check on 'depth == CV32F...' in matmul.cpp, line 2115.
I don't think I have any flexibility on the rotation matrix data type...what to do?