Krita Source Code Documentation
Loading...
Searching...
No Matches
PointsFetcherOp Struct Reference

Public Member Functions

void nextLine ()
 
 PointsFetcherOp (const QPolygonF &cagePolygon)
 
void processPoint (int col, int row, int prevCol, int prevRow, int colIndex, int rowIndex)
 

Public Attributes

QPolygonF m_cagePolygon
 
int m_numValidPoints
 
QVector< QPointF > m_points
 
QVector< bool > m_pointValid
 
int m_polygonDirection
 

Detailed Description

Definition at line 101 of file kis_cage_transform_worker.cpp.

Constructor & Destructor Documentation

◆ PointsFetcherOp()

PointsFetcherOp::PointsFetcherOp ( const QPolygonF & cagePolygon)
inline

Definition at line 103 of file kis_cage_transform_worker.cpp.

104 : m_cagePolygon(cagePolygon),
106 {
108 }
int polygonDirection(const QVector< T > &polygon)

References m_polygonDirection, and KisAlgebra2D::polygonDirection().

Member Function Documentation

◆ nextLine()

void PointsFetcherOp::nextLine ( )
inline

Definition at line 133 of file kis_cage_transform_worker.cpp.

133 {
134 }

◆ processPoint()

void PointsFetcherOp::processPoint ( int col,
int row,
int prevCol,
int prevRow,
int colIndex,
int rowIndex )
inline

Definition at line 110 of file kis_cage_transform_worker.cpp.

112 {
113
114 Q_UNUSED(prevCol);
115 Q_UNUSED(prevRow);
116 Q_UNUSED(colIndex);
117 Q_UNUSED(rowIndex);
118
119 QPointF pt(col, row);
120
121 if (m_cagePolygon.containsPoint(pt, Qt::OddEvenFill)) {
123
124 m_points << pt;
125 m_pointValid << true;
127 } else {
128 m_points << pt;
129 m_pointValid << false;
130 }
131 }
void adjustIfOnPolygonBoundary(const QPolygonF &poly, int polygonDirection, QPointF *pt)

References KisAlgebra2D::adjustIfOnPolygonBoundary(), m_cagePolygon, m_numValidPoints, m_points, m_pointValid, and m_polygonDirection.

Member Data Documentation

◆ m_cagePolygon

QPolygonF PointsFetcherOp::m_cagePolygon

Definition at line 138 of file kis_cage_transform_worker.cpp.

◆ m_numValidPoints

int PointsFetcherOp::m_numValidPoints

Definition at line 140 of file kis_cage_transform_worker.cpp.

◆ m_points

QVector<QPointF> PointsFetcherOp::m_points

Definition at line 137 of file kis_cage_transform_worker.cpp.

◆ m_pointValid

QVector<bool> PointsFetcherOp::m_pointValid

Definition at line 136 of file kis_cage_transform_worker.cpp.

◆ m_polygonDirection

int PointsFetcherOp::m_polygonDirection

Definition at line 139 of file kis_cage_transform_worker.cpp.


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