Show / Hide Table of Contents

Class WeChatQRCode

WeChat QRCode includes two CNN-based models: A object detection model and a super resolution model. Object detection model is applied to detect QRCode with the bounding box. super resolution model is applied to zoom in QRCode when it is small.

Inheritance
System.Object
DisposableObject
DisposableCvObject
WeChatQRCode
Implements
ICvPtrHolder
Inherited Members
DisposableCvObject.ptr
DisposableCvObject.CvPtr
DisposableObject.DataHandle
DisposableObject.IsDisposed
DisposableObject.IsEnabledDispose
DisposableObject.AllocatedMemory
DisposableObject.AllocatedMemorySize
DisposableObject.Dispose()
DisposableObject.Dispose(Boolean)
DisposableObject.AllocGCHandle(Object)
DisposableObject.AllocMemory(Int32)
DisposableObject.NotifyMemoryPressure(Int64)
DisposableObject.ThrowIfDisposed()
Namespace: OpenCvSharp
Assembly: OpenCvSharp.dll
Syntax
public class WeChatQRCode : DisposableCvObject, ICvPtrHolder

Methods

| Improve this Doc View Source

Create(String, String, String, String)

Initialize the WeChatQRCode. It includes two models, which are packaged with caffe format. Therefore, there are prototxt and caffe models (In total, four paramenters).

Declaration
public static WeChatQRCode Create(string detectorPrototxtPath, string detectorCaffeModelPath, string superResolutionPrototxtPath, string superResolutionCaffeModelPath)
Parameters
Type Name Description
System.String detectorPrototxtPath

prototxt file path for the detector

System.String detectorCaffeModelPath

caffe model file path for the detector

System.String superResolutionPrototxtPath

prototxt file path for the super resolution model

System.String superResolutionCaffeModelPath

caffe file path for the super resolution model

Returns
Type Description
WeChatQRCode
| Improve this Doc View Source

DetectAndDecode(InputArray, out Mat[], out String[])

Both detects and decodes QR code. To simplify the usage, there is a only API: detectAndDecode

Declaration
public void DetectAndDecode(InputArray inputImage, out Mat[] bbox, out string[] results)
Parameters
Type Name Description
InputArray inputImage

supports grayscale or color(BGR) image.

Mat[] bbox

optional output array of vertices of the found QR code quadrangle.Will be empty if not found.

System.String[] results

list of decoded string.

| Improve this Doc View Source

DisposeManaged()

Releases managed resources

Declaration
protected override void DisposeManaged()
Overrides
DisposableObject.DisposeManaged()
| Improve this Doc View Source

DisposeUnmanaged()

Declaration
protected override void DisposeUnmanaged()
Overrides
DisposableCvObject.DisposeUnmanaged()
| Improve this Doc View Source

Get()

Declaration
public override IntPtr Get()
Returns
Type Description
IntPtr

Implements

ICvPtrHolder
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX