{"id":22726206,"url":"https://github.com/maskedsyntax/doculens","last_synced_at":"2026-02-01T05:32:33.914Z","repository":{"id":193907161,"uuid":"413916667","full_name":"maskedsyntax/doculens","owner":"maskedsyntax","description":"A simple document scanning pipeline implemented in C++ with OpenCV.","archived":false,"fork":false,"pushed_at":"2025-12-03T23:43:57.000Z","size":33077,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-07T04:44:05.743Z","etag":null,"topics":["c","canny-edge-detection","cmake","cmakelist","computer-vision","contour-detection","contours","cpp17","gaussian-blur","makefile","opencv","python3","warping"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/maskedsyntax.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-10-05T17:30:07.000Z","updated_at":"2025-12-03T23:44:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"7f9331db-5c10-4dd0-9e74-314af5bac140","html_url":"https://github.com/maskedsyntax/doculens","commit_stats":null,"previous_names":["aftaab25/documentscanner","maskedsyntax/documentscanner","maskedsyntax/doculens"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/maskedsyntax/doculens","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maskedsyntax%2Fdoculens","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maskedsyntax%2Fdoculens/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maskedsyntax%2Fdoculens/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maskedsyntax%2Fdoculens/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/maskedsyntax","download_url":"https://codeload.github.com/maskedsyntax/doculens/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/maskedsyntax%2Fdoculens/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28970025,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-01T04:44:20.970Z","status":"ssl_error","status_checked_at":"2026-02-01T04:44:19.994Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["c","canny-edge-detection","cmake","cmakelist","computer-vision","contour-detection","contours","cpp17","gaussian-blur","makefile","opencv","python3","warping"],"created_at":"2024-12-10T16:16:07.628Z","updated_at":"2026-02-01T05:32:33.909Z","avatar_url":"https://github.com/maskedsyntax.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DocuLens: A Document Scanner\nA simple document scanning pipeline implemented in C++ with OpenCV.\nThe program detects the largest 4-point contour in each frame of a video or webcam feed, applies a perspective transform, and shows a flattened, top-down “scan” of the document.\n\n## Steps\n* Preprocessing (grayscale -\u003e blur -\u003e Canny -\u003e dilate -\u003e erode)\n* Contour detection and 4-point polygon approximation\n* Automatic ordering of detected points\n* Perspective warp to get a top-down scan\n* 2×2 stacked debug view (original, threshold, contour view, warped result)\n* Live processing from video file or webcam\n\n## Requirements\n* C++17\n* OpenCV 4.x\n* CMake \u003e= 3.10\n\nInstall OpenCV (on Linux):\n```bash\nsudo apt install libopencv-dev\n```\n\n## Build\nRun `build.sh` to build the project.\n\n## Run\n```bash\n./build/document_scanner ./assets/testvideo.mp4\n```\n\n## Output Windows\n\nThe program displays two windows:\n1. Work Flow (2×2 grid)\n* Original frame\n* Thresholded frame\n* Contours\n* Warped (scanned) document\n\n2. Result\n* Clean final warp of the detected document\n\nPress `q` to quit.\n\n\u003e [!NOTE]\n\u003e No ML, just pure classical OpenCV contour detection. Hence, works best with well-lit videos where the document edge is clear.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaskedsyntax%2Fdoculens","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmaskedsyntax%2Fdoculens","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmaskedsyntax%2Fdoculens/lists"}