CCIMXDesktop
 
Loading...
Searching...
No Matches
Processor::ContoursQuery Namespace Reference

The ContoursQuery namespace provides enumeration and mapping utilities for contour detection methods. More...

Enumerations

enum class  Method { CHAIN_APPROX_NONE , CHAIN_APPROX_SIMPLE , CHAIN_APPROX_TC89_L1 , CHAIN_APPROX_TC89_KCOS }
 Enumeration of different contour approximation methods. More...
 

Variables

const std::map< std::string, Methodmappings
 String-to-enum mapping for contour approximation methods.
 

Detailed Description

The ContoursQuery namespace provides enumeration and mapping utilities for contour detection methods.

Enumeration Type Documentation

◆ Method

Enumeration of different contour approximation methods.

These correspond to OpenCV's chain approximation flags used in contour detection.

Enumerator
CHAIN_APPROX_NONE 

All points are stored.

CHAIN_APPROX_SIMPLE 

Compresses horizontal, vertical, and diagonal segments.

CHAIN_APPROX_TC89_L1 

Teh-Chin approximation algorithm (L1).

CHAIN_APPROX_TC89_KCOS 

Teh-Chin approximation algorithm (K-cosine).

Variable Documentation

◆ mappings

const std::map<std::string, Method> Processor::ContoursQuery::mappings
Initial value:
= {
{ "ALL_POINT(CHAIN_APPROX_NONE)", Method::CHAIN_APPROX_NONE },
{ "LINE(CHAIN_APPROX_SIMPLE)", Method::CHAIN_APPROX_SIMPLE },
{ "L1(CHAIN_APPROX_TC89_L1)", Method::CHAIN_APPROX_TC89_L1 },
{ "KCOS(CHAIN_APPROX_TC89_KCOS)", Method::CHAIN_APPROX_TC89_KCOS }
}

String-to-enum mapping for contour approximation methods.