augraphy icon indicating copy to clipboard operation
augraphy copied to clipboard

Samples for eventual focus on camera phones and screen sources

Open jboarman opened this issue 3 years ago • 9 comments

Please add sample images here so that we can review those for later focus on their reproduction. These should be images that represent distortions caused by:

  • using a camera phone; or
  • taking pictures from a video / screen source

NOTE: This takes us slightly off our paper-oriented focus, but let's assume for the sake of this ticket that we are printing these images or that we are taking pictures of documents sourced from a screen to run through OCR.

jboarman avatar Oct 18 '21 17:10 jboarman

Lens Glare / Flare Sample

Brighter light sources can cause streaky + hazy effect on a camera lens, commonly known as lens glare or lens flare. The angles of the glare can vary and be singular or multiple glares at different angles. (This may be why polarized lenses are used to reduce or eliminate such glare.)

Lens glare is often cause by bright light sources reflecting within the frame. It can also occur when a lens is dirty with smudges or spots on the surface of the lens that can scatter light and cause unwanted reflections.

In this example, linear glare seems to have a blurry streak that extends brighter / lighter colors both horizontally and at a -45° angle (in this case) against the dark background.

Subtle Lens Glare

image

Harder Edge Flares, Glares and Smudges

image

jboarman avatar Oct 18 '21 17:10 jboarman

Example with Moiré pattern

image

jboarman avatar Oct 18 '21 17:10 jboarman

Example change in focus based on depth from lense

image

jboarman avatar Oct 18 '21 17:10 jboarman

badscreen

shaheryar1 avatar Nov 07 '21 18:11 shaheryar1

Example of a Dirty Screen

image

jboarman avatar Feb 09 '22 22:02 jboarman

Example ambient light or flash reflected from surface of paper

  • shows texture of paper surface
  • makes printed content almost unreadable where light is shining back to the camera, often from a camera phone's flash

image image

jboarman avatar Mar 09 '22 02:03 jboarman

This website applies a pattern overlay using CSS to get a pattern that looks a photo was taken from a screen. There are might even be versions of generated patterns that could be double-applied to simulate moire patterns.

Overlaid Version of Image: image

Original Image: image

Pattern Overlay (super tiny, almost invisible image b/t brackets): [ screen pattern ]

Source URLs: https://www.normascafe.com/locations/ https://www.normascafe.com/spillover/proto/normascafe/images/design/pattern.png https://www.normascafe.com/spillover/proto/normascafe/images/backgrounds/deliverytruck.jpg

jboarman avatar Mar 17 '22 17:03 jboarman

Lots of Maths about Moire:

https://www.spiedigitallibrary.org/journals/optical-engineering/volume-57/issue-03/030803/Moir%C3%A9-effect-in-displays-a-tutorial/10.1117/1.OE.57.3.030803.full?SSO=1

jboarman avatar Apr 24 '22 02:04 jboarman

Reflection Example (screen capture with glare reflected from surface)

image

jboarman avatar May 11 '22 14:05 jboarman

image

jboarman avatar May 11 '23 17:05 jboarman

Added Moire effect here: https://github.com/sparkfish/augraphy/pull/413

Added LCDScreenPattern here: https://github.com/sparkfish/augraphy/pull/419

kwcckw avatar Dec 29 '23 07:12 kwcckw