qr_threshold_shortcut_: (Internal) Image thresholding, with some shortcuts

View source: R/utils.R

qr_threshold_shortcut_R Documentation

(Internal) Image thresholding, with some shortcuts

Description

This is an internal function used by qr_scan_js_from_corners and qr_scan_cpp. It's a wrapper around image_threshold which skips running the function call if the arguments indicate essentially unchanged images, such as pushing the blackest 0% of pixels to black, or the whitest 100% of pixels to white.

Usage

qr_threshold_shortcut_(mgk, type, threshold, ...)

Arguments

mgk

A magick image object.

type

Type of thresholding, either black or white.

threshold

Pixel intensity threshold.

...

Additional arguments passed through (channels).


brianwdavis/quadrangle documentation built on Feb. 27, 2023, 6:36 p.m.