zxing-cpp v3.0
Loading...
Searching...
No Matches
ZXing::Quadrilateral< T > Class Template Reference

#include <Quadrilateral.h>

Inherits std::array< T >.

Public Types

using Point = T

Public Member Functions

 Quadrilateral ()=default
 Quadrilateral (T tl, T tr, T br, T bl)
template<typename U>
 Quadrilateral (PointT< U > tl, PointT< U > tr, PointT< U > br, PointT< U > bl)
constexpr Point topLeft () const noexcept
constexpr Point topRight () const noexcept
constexpr Point bottomRight () const noexcept
constexpr Point bottomLeft () const noexcept
double orientation () const

Detailed Description

template<typename T>
class ZXing::Quadrilateral< T >

A simple class representing a quadrilateral defined by its four corner points.

It represents a quadrilateral defined by its four corner points: top-left, top-right, bottom-right, and bottom-left. Those points are relative to the detected symbol i.e. topLeft() will return the coordinates of the top-left corner of the symbol. If e.g. the symbol is rotated 180 degrees, the top-left corner will be the one that is at the bottom-right position in the image.

Member Typedef Documentation

◆ Point

template<typename T>
using ZXing::Quadrilateral< T >::Point = T

Constructor & Destructor Documentation

◆ Quadrilateral() [1/3]

template<typename T>
ZXing::Quadrilateral< T >::Quadrilateral ( )
default

◆ Quadrilateral() [2/3]

template<typename T>
ZXing::Quadrilateral< T >::Quadrilateral ( T tl,
T tr,
T br,
T bl )
inline

◆ Quadrilateral() [3/3]

template<typename T>
template<typename U>
ZXing::Quadrilateral< T >::Quadrilateral ( PointT< U > tl,
PointT< U > tr,
PointT< U > br,
PointT< U > bl )
inline

Member Function Documentation

◆ topLeft()

template<typename T>
Point ZXing::Quadrilateral< T >::topLeft ( ) const
inlineconstexprnoexcept

◆ topRight()

template<typename T>
Point ZXing::Quadrilateral< T >::topRight ( ) const
inlineconstexprnoexcept

◆ bottomRight()

template<typename T>
Point ZXing::Quadrilateral< T >::bottomRight ( ) const
inlineconstexprnoexcept

◆ bottomLeft()

template<typename T>
Point ZXing::Quadrilateral< T >::bottomLeft ( ) const
inlineconstexprnoexcept

◆ orientation()

template<typename T>
double ZXing::Quadrilateral< T >::orientation ( ) const
inline

Return the orientation of the quadrilateral in radians, where 0 means the horizontal center line is parallel to the x-axis and positive values mean a clockwise rotation.


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