python 3.5 - Extracting part of a 2D image in OpenCV -
my goal take image above , "open" along center 9 black doublets in straight line rather in circle. have tried using cv2.topolar() function in opencv image quite distorted, can seen below:
i attempting try different approach now. center, access each of doublet individually, pizza slice, , place them side side
initially thinking of slicing each doublet using 2 lines center of image mid point between doublets on either side.
my question is: how can draw contours center of image edge of image, passing through mid point between 2 doublet. if can draw one, know angle between 2 such consecutive contour 40 degrees.
any appreciated!
i noted few problems here:
- the topolar() conversion might have been around center of image file, not center of object. causes part of distortion. if share code, try playing code , improving it.
2.the object elliptical, not circular. means still have wave after correcting above problem.
- if don't mind semi-automatic solution, use opencv mouse events specify first line , let program use 40 degree angle calculate rest.
Comments
Post a Comment