Perspec How to Fix Perspective in Photos in a Couple of Clicks
Sound familiar? You photographed an important document or whiteboard notes, but the image is all distorted — corners are skewed, text is tilted. Manually fixing this in graphic editors is time-consuming and tedious. Perspec solves this problem with one mouse movement.
What Perspec Can Do
This cross-platform application (macOS/Linux) can:
- Automatically aligns perspective in photos of documents, whiteboards, building facades
- Lets you manually specify corners for precise correction
- Supports batch processing via command line
- Converts images to B/W or grayscale for better readability
→
How It Works
- Open the application
- Drag the photo into the window
- Mark the four corners of the area you want to align
- Press Enter — Perspec does the rest
The interface is so simple that even a child can figure it out:
Technical Features
Under the hood, Perspec uses:
- Haskell for core logic (a rare case of practical use of this language)
- ImageMagick for image processing
- Automatic correction algorithms (OTSU for B/W, perspective transformations)
Here's what a typical conversion command looks like:
magick input.jpg -distort Perspective '8,35 0,0 27,73 0,66 90,72 63,66 67,10 63,0' -crop 63x66+0+0 output.jpg
Use Cases
- Document digitization — turn a stack of papers into neat PDF files
- Whiteboard notes archiving — save brainstorming sessions and lectures
- Photogrammetry — preparing images for 3D modeling
- Old photo restoration — straightening yellowed snapshots
Installation
For macOS, the easiest way is to use Homebrew:
brew install --cask ad-si/tap/perspec
Or download a pre-built release from the releases page.
Alternatives
If you need something more powerful, check out:
- Hasscan — document scanner based on OpenCV
- Awesome Scanning — collection of similar tools
Perspec is one of those rare tools that does exactly one thing, but does it perfectly. If you regularly need to tidy up photos of documents or whiteboards, it will save you hours of manual work. At the same time, the project remains simple and easy to use — no complex settings or cluttered interfaces.
Related projects