-
-
Notifications
You must be signed in to change notification settings - Fork 56.5k
Open
Description
System information (version)
- OpenCV => 4.x
- Operating System / Platform => any
- Compiler => Python 2.x/3.x
Detailed description
When OpenCV functions that processes point a sequence/point cloud is called from Python, it fails to process it because of unsupported shape of array. And so it needs reshape to pass through. If the output of point cloud processing functions is also a point cloud, it also needs to be reshaped in a similar way.
Steps to reproduce
pts = np.array([[10,5],[20,30],[70,20],[50,10]], np.int32)
pts = pts.reshape((-1,1,2))
cv2.polylines(img,[pts],True,(0,255,255))
...
pts = ...
rpts = pts.reshape((1,-1,2))
xfm_pts = cv2.perspectiveTransform(rpts,H).reshape((-1,2))References
reported by @garybradski
Reactions are currently unavailable