Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

OpenCV Transform Shape with Arbitrary Contour into Rectangle

I want to perform book dewarping, the source image is like that:

image description

When I perform the 4 points OpenCV getperspective transform, the result looks like that:

image description

But I have to get rid of the v shape it appears on top part of the book page is given above...

As a summary, I need to perform transform shape with arbitrary contour into rectangle. Are there any algorithms for this in OpenCV?

I need something like this:

image description