OpenCV  3.4.19
Open Source Computer Vision
Public Member Functions | Protected Attributes | List of all members
cv::QRCodeDetector Class Reference

#include <opencv2/objdetect.hpp>

Public Member Functions

 QRCodeDetector ()
 
 ~QRCodeDetector ()
 
cv::String decode (InputArray img, InputArray points, OutputArray straight_qrcode=noArray())
 Decodes QR code in image once it's found by the detect() method. More...
 
cv::String decodeCurved (InputArray img, InputArray points, OutputArray straight_qrcode=noArray())
 Decodes QR code on a curved surface in image once it's found by the detect() method. More...
 
bool decodeMulti (InputArray img, InputArray points, std::vector< cv::String > &decoded_info, OutputArrayOfArrays straight_qrcode=noArray()) const
 Decodes QR codes in image once it's found by the detect() method. More...
 
bool detect (InputArray img, OutputArray points) const
 Detects QR code in image and returns the quadrangle containing the code. More...
 
cv::String detectAndDecode (InputArray img, OutputArray points=noArray(), OutputArray straight_qrcode=noArray())
 Both detects and decodes QR code. More...
 
cv::String detectAndDecodeCurved (InputArray img, OutputArray points=noArray(), OutputArray straight_qrcode=noArray())
 Both detects and decodes QR code on a curved surface. More...
 
bool detectAndDecodeMulti (InputArray img, std::vector< cv::String > &decoded_info, OutputArray points=noArray(), OutputArrayOfArrays straight_qrcode=noArray()) const
 Both detects and decodes QR codes. More...
 
bool detectMulti (InputArray img, OutputArray points) const
 Detects QR codes in image and returns the vector of the quadrangles containing the codes. More...
 
void setEpsX (double epsX)
 sets the epsilon used during the horizontal scan of QR code stop marker detection. More...
 
void setEpsY (double epsY)
 sets the epsilon used during the vertical scan of QR code stop marker detection. More...
 

Protected Attributes

Ptr< Impl > p
 

Constructor & Destructor Documentation

◆ QRCodeDetector()

cv::QRCodeDetector::QRCodeDetector ( )

◆ ~QRCodeDetector()

cv::QRCodeDetector::~QRCodeDetector ( )

Member Function Documentation

◆ decode()

cv::String cv::QRCodeDetector::decode ( InputArray  img,
InputArray  points,
OutputArray  straight_qrcode = noArray() 
)
Python:
cv.QRCodeDetector.decode(img, points[, straight_qrcode]) -> retval, straight_qrcode

Decodes QR code in image once it's found by the detect() method.

Returns UTF8-encoded output string or empty string if the code cannot be decoded.

Parameters
imggrayscale or color (BGR) image containing QR code.
pointsQuadrangle vertices found by detect() method (or some other algorithm).
straight_qrcodeThe optional output image containing rectified and binarized QR code

◆ decodeCurved()

cv::String cv::QRCodeDetector::decodeCurved ( InputArray  img,
InputArray  points,
OutputArray  straight_qrcode = noArray() 
)
Python:
cv.QRCodeDetector.decodeCurved(img, points[, straight_qrcode]) -> retval, straight_qrcode

Decodes QR code on a curved surface in image once it's found by the detect() method.

Returns UTF8-encoded output string or empty string if the code cannot be decoded.

Parameters
imggrayscale or color (BGR) image containing QR code.
pointsQuadrangle vertices found by detect() method (or some other algorithm).
straight_qrcodeThe optional output image containing rectified and binarized QR code

◆ decodeMulti()

bool cv::QRCodeDetector::decodeMulti ( InputArray  img,
InputArray  points,
std::vector< cv::String > &  decoded_info,
OutputArrayOfArrays  straight_qrcode = noArray() 
) const
Python:
cv.QRCodeDetector.decodeMulti(img, points[, straight_qrcode]) -> retval, decoded_info, straight_qrcode

Decodes QR codes in image once it's found by the detect() method.

Parameters
imggrayscale or color (BGR) image containing QR codes.
decoded_infoUTF8-encoded output vector of string or empty vector of string if the codes cannot be decoded.
pointsvector of Quadrangle vertices found by detect() method (or some other algorithm).
straight_qrcodeThe optional output vector of images containing rectified and binarized QR codes

◆ detect()

bool cv::QRCodeDetector::detect ( InputArray  img,
OutputArray  points 
) const
Python:
cv.QRCodeDetector.detect(img[, points]) -> retval, points

Detects QR code in image and returns the quadrangle containing the code.

Parameters
imggrayscale or color (BGR) image containing (or not) QR code.
pointsOutput vector of vertices of the minimum-area quadrangle containing the code.

◆ detectAndDecode()

cv::String cv::QRCodeDetector::detectAndDecode ( InputArray  img,
OutputArray  points = noArray(),
OutputArray  straight_qrcode = noArray() 
)
Python:
cv.QRCodeDetector.detectAndDecode(img[, points[, straight_qrcode]]) -> retval, points, straight_qrcode

Both detects and decodes QR code.

Parameters
imggrayscale or color (BGR) image containing QR code.
pointsoptional output array of vertices of the found QR code quadrangle. Will be empty if not found.
straight_qrcodeThe optional output image containing rectified and binarized QR code

◆ detectAndDecodeCurved()

cv::String cv::QRCodeDetector::detectAndDecodeCurved ( InputArray  img,
OutputArray  points = noArray(),
OutputArray  straight_qrcode = noArray() 
)
Python:
cv.QRCodeDetector.detectAndDecodeCurved(img[, points[, straight_qrcode]]) -> retval, points, straight_qrcode

Both detects and decodes QR code on a curved surface.

Parameters
imggrayscale or color (BGR) image containing QR code.
pointsoptional output array of vertices of the found QR code quadrangle. Will be empty if not found.
straight_qrcodeThe optional output image containing rectified and binarized QR code

◆ detectAndDecodeMulti()

bool cv::QRCodeDetector::detectAndDecodeMulti ( InputArray  img,
std::vector< cv::String > &  decoded_info,
OutputArray  points = noArray(),
OutputArrayOfArrays  straight_qrcode = noArray() 
) const
Python:
cv.QRCodeDetector.detectAndDecodeMulti(img[, points[, straight_qrcode]]) -> retval, decoded_info, points, straight_qrcode

Both detects and decodes QR codes.

Parameters
imggrayscale or color (BGR) image containing QR codes.
decoded_infoUTF8-encoded output vector of string or empty vector of string if the codes cannot be decoded.
pointsoptional output vector of vertices of the found QR code quadrangles. Will be empty if not found.
straight_qrcodeThe optional output vector of images containing rectified and binarized QR codes

◆ detectMulti()

bool cv::QRCodeDetector::detectMulti ( InputArray  img,
OutputArray  points 
) const
Python:
cv.QRCodeDetector.detectMulti(img[, points]) -> retval, points

Detects QR codes in image and returns the vector of the quadrangles containing the codes.

Parameters
imggrayscale or color (BGR) image containing (or not) QR codes.
pointsOutput vector of vector of vertices of the minimum-area quadrangle containing the codes.

◆ setEpsX()

void cv::QRCodeDetector::setEpsX ( double  epsX)
Python:
cv.QRCodeDetector.setEpsX(epsX) -> None

sets the epsilon used during the horizontal scan of QR code stop marker detection.

Parameters
epsXEpsilon neighborhood, which allows you to determine the horizontal pattern of the scheme 1:1:3:1:1 according to QR code standard.

◆ setEpsY()

void cv::QRCodeDetector::setEpsY ( double  epsY)
Python:
cv.QRCodeDetector.setEpsY(epsY) -> None

sets the epsilon used during the vertical scan of QR code stop marker detection.

Parameters
epsYEpsilon neighborhood, which allows you to determine the vertical pattern of the scheme 1:1:3:1:1 according to QR code standard.

Member Data Documentation

◆ p

Ptr<Impl> cv::QRCodeDetector::p
protected

The documentation for this class was generated from the following file: