Inverted QR code sample image

19 views
Skip to first unread message

Charlie Hayes

unread,
Feb 22, 2022, 10:47:24 PMFeb 22
to BoofCV
I was curious if the QR code samples included a malformed example which was inverted (black to white, white to black). I've seen these in the wild and some scanners have trouble with them. I checked out the latest samples referenced in the benchmark script but did not see one that was inverted.

Should be a relatively easy sample to replicate; grab an existing sample, invert the colors, done.

Peter A

unread,
Feb 27, 2022, 10:59:06 AMFeb 27
to boofcv
That edge case isn't handled explicitly yet. For now you will need to invert the image. In almost all situations, this is how you would do that:

PixelMath.minus(255, image, image);

Re-reading what you wrote, do you actually mean inverted should be added to benchmark images? Yeah I agree with that 100%. If you see any inverted images in the wild please take a picture and send it over. I've been collecting images for an expanded version of that benchmark.

On Tue, Feb 22, 2022 at 7:47 PM Charlie Hayes <cosm...@gmail.com> wrote:
I was curious if the QR code samples included a malformed example which was inverted (black to white, white to black). I've seen these in the wild and some scanners have trouble with them. I checked out the latest samples referenced in the benchmark script but did not see one that was inverted.

Should be a relatively easy sample to replicate; grab an existing sample, invert the colors, done.

--
You received this message because you are subscribed to the Google Groups "BoofCV" group.
To unsubscribe from this group and stop receiving emails from it, send an email to boofcv+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/boofcv/7f3d83c6-b7ee-4ea5-871c-69155719af48n%40googlegroups.com.


--
"Now, now my good man, this is no time for making enemies."    — Voltaire (1694-1778), on his deathbed in response to a priest asking that he renounce Satan.
Reply all
Reply to author
Forward
0 new messages