What you have asked is too general and difficult to do it perfectly (Due to curved edges , and bad white balance in the picture). The basic try in edge detection can be done with Canny Edge detection.
But the bill does not have exact rectangular edge , and the paper is bent. The best way you can develop a solution is to make a Camscanner like application , which uses OpenCV in it.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.