Reading a Grid of QR Codes¶
This code snippet shows how to read QRcodes that are disposed in a 5 by 3 grid with 10% overlap between grid cells.
C++¶
#include <eVision/EasyQRCode/EQRCodeReader.h>
using namespace eVision;
EImageBW8 srcImage;
ERectangleRegion gridRegion;
EQRCodeReader reader;
// Reading succeeds
EQRCodeGrid grid = reader.Read(srcImage, gridRegion, 3, 5, 0.1f);
std::vector<EQRCode> codesMiddleCell = grid.GetResults(1, 2);
See also
C#¶
using eVision;
EImageBW8 srcImage = new EImageBW8();
ERectangleRegion gridRegion = new ERectangleRegion();
EQRCodeReader reader = new EQRCodeReader();
// Reading succeeds
EQRCodeGrid grid = reader.Read(srcImage, gridRegion, 3, 5, 0.1f);
EQRCode[] codesMiddleCell = grid.GetResults(1, 2);
See also
Python¶
import eVision
src_image = eVision.EImageBW8()
grid_region = eVision.ERectangleRegion()
reader = eVision.EQRCodeReader()
# Reading succeeds
grid = reader.Read(src_image, grid_region, 3, 5, 0.1)
codes_middle_cell = grid.GetResults(1, 2)
See also