
Ask HN: How to turn a series of photos of documents into a PDF? - c_void
I often come across the problem that I need the scan of a physical (machine or handwritten) document (black letters on white sheet) in a situation where there is no scanner available. So taking a picture and convert the jpg into a pdf is often the best&#x2F;only possible solution. Usually I collect all pictures into one folder and apply image magick convert. The hard part is to find the parameters resulting in the best compromiss between quality and size of the final pdf. Here are the main occuring problems:<p>1) You hardly manage to take the picture perfectly from the top of the document. The result is that your rectangle-shaped A4 document is (in best cases) a trapeze on your picture. A good algorithm should recognize the geometry of the sheet and then stretch it to a rectangle and crop the surroundings. Taking the picture on a dark background, this should not be a big problem. For a possibly curled sheet of a college block, you may also take into acount the crossed lines.<p>2) Brightness&#x2F;Contrast should be adjusted. However it may happen that one part of the document is pictured brighter that another one. By choosing extreme values in brightness&#x2F;contrast parts of the background will turn black and other parts of the letters will vanish to white.<p>This should be easily solvable. The brightness difference from background to letter varies abruptly, while the brightness of the background only varies lightly when moving far across the picture. One should probably apply a contrast adjustment of the gradient of the picture first to iron out these artefacts. Then adjust brightness&#x2F;contrast of the &#x27;ironed&#x27; picture.<p>3) Each picture should be treated individually, because the artefacts coming from points 1) and 2)  may vary between the taken pictures<p>As I will hardly be the first person having this problem, I am asking you for your favourite&#x2F;most convenient solution. Do you know a nice tool or have you written a script (maybe even using image magick)?
======
c_void
Okay I should have found out before that there are many good apps solving the
problem. Thank you for your advices anyway! After testing some of them, let me
also answer my question by myself. I tried the apps Simple Scan, Tiny Scanner,
Cam Scanner and Microsoft Office Lens. I skipped Adobe Scan, as I had to
register before being able to use it. (The Free versions of) Simple Scan and
Cam Scanner had too much ads for my taste. I could not find Readdle's Scanner
Pro for Android in Google's playstore. Imo Tiny Scanner worked best for my
particular problem. You can take picture after picture, cropping, stretching
and brightness adjusting is almost automatic. After that you can save the scan
series into a single PDF file. Also of good quality is Open Note Scanner,
which however does only cropping and brightness/contrast adjustment without
stretching, cropping and assembling to a PDF file.

For photographs, paintings and screens I also liked Microsofts Lens, which is
perfect for stretching and cropping without brightness/contrast and monochrome
adjustment.

------
kup0
Depends on the platform, but I've used Readdle's Scanner Pro on iOS and it
does pretty a pretty good job at auto-adjusting the contrast and geometry of
scans, and they can be output to PDF. You can scan multiple pages into one
"document" then export that document.

------
navjack27
There are so many manual ways to do this that aren't that painful. Phone's are
useful for this too, just get the scans on to your phone and some apps do it.

------
towndrunk
Install Microsoft Office Lens. Works great for taking pictures of documents,
white boards etc.

