How to warp a rectangular object to fit its larger bounding box
问题 Given this image: I'd like to make it such that it will rotate and stretch to fully fit in the bounding box with no whitespace on the outside of the largest rectangular box. It should also account for worse perspective case, like in the links I list later on. Basically, while it is not noticeable, the rectangle is rotated a little bit, and I'd like to fix that distortion. However, I got an error when attempting to retrieve the four points of the contour. I have made sure and utilized contour