Table of Contents

Method Run

Namespace
OpenCvSharp.Text
Assembly
OpenCvSharp.dll

Run(Mat, out string, out Rect[], out string?[], out float[], ComponentLevels)

Recognizes text using a segmentation-based word-spotting classifier CNN. The output text is always one that exists in the dictionary.

public override void Run(Mat image, out string outputText, out Rect[] componentRects, out string?[] componentTexts, out float[] componentConfidences, ComponentLevels componentLevel = ComponentLevels.Word)

Parameters

image Mat

Input image CV_8UC1 or CV_8UC3.

outputText string

Output text of the word spotting, always one that exists in the dictionary.

componentRects Rect[]

Not applicable for word spotting.

componentTexts string[]

Not applicable for word spotting.

componentConfidences float[]

Not applicable for word spotting.

componentLevel ComponentLevels

Must be ComponentLevels.Word.

Run(Mat, Mat, out string, out Rect[], out string?[], out float[], ComponentLevels)

Recognizes text using a segmentation-based word-spotting classifier CNN. The mask parameter is ignored and only available for API compatibility.

public override void Run(Mat image, Mat mask, out string outputText, out Rect[] componentRects, out string?[] componentTexts, out float[] componentConfidences, ComponentLevels componentLevel = ComponentLevels.Word)

Parameters

image Mat

Input image CV_8UC1 or CV_8UC3.

mask Mat

Ignored; only available for compatibility reasons.

outputText string

Output text of the word spotting, always one that exists in the dictionary.

componentRects Rect[]

Not applicable for word spotting.

componentTexts string[]

Not applicable for word spotting.

componentConfidences float[]

Not applicable for word spotting.

componentLevel ComponentLevels

Must be ComponentLevels.Word.