Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QTriangulatingStroker Class Reference

#include <qtriangulatingstroker_p.h>

+ Collaboration diagram for QTriangulatingStroker:

Public Member Functions

 QTriangulatingStroker ()
 
void process (const QVectorPath &path, const QPen &pen, const QRectF &clip, QPainter::RenderHints hints)
 
int vertexCount () const
 
const float * vertices () const
 
void setInvScale (qreal invScale)
 

Detailed Description

Definition at line 29 of file qtriangulatingstroker_p.h.

Constructor & Destructor Documentation

◆ QTriangulatingStroker()

QTriangulatingStroker::QTriangulatingStroker ( )
inline

Definition at line 32 of file qtriangulatingstroker_p.h.

Member Function Documentation

◆ process()

void QTriangulatingStroker::process ( const QVectorPath & path,
const QPen & pen,
const QRectF & clip,
QPainter::RenderHints hints )

'LineToElement' may be skipped if it doesn't move the center point of the line. We should make sure that we don't end up with a lost 'MoveToElement' in the vertex buffer, not connected to anything. Since the buffer uses degenerate triangles trick to split the primitives, this spurious MoveToElement will create artifacts when rendering.

Definition at line 47 of file qtriangulatingstroker.cpp.

References CURVE_FLATNESS, QPainterPath::CurveToElement, Qt::FlatCap, QPen::isCosmetic(), QPainterPath::LineToElement, Qt::MiterJoin, QPen::miterLimit(), QPainterPath::MoveToElement, Q_ASSERT, Q_PI, qFastCos(), qFastSin(), qpen_capStyle(), qpen_joinStyle(), qpen_widthf(), QDataBuffer< Type >::reset(), Qt::RoundCap, Qt::RoundJoin, skipDuplicatePoints(), and Qt::SquareCap.

Referenced by QOpenGL2PaintEngineExPrivate::stroke(), and QQuickShapeGenericRenderer::triangulateStroke().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setInvScale()

void QTriangulatingStroker::setInvScale ( qreal invScale)
inline

Definition at line 41 of file qtriangulatingstroker_p.h.

Referenced by QQuickShapeGenericRenderer::triangulateStroke(), and QOpenGL2PaintEngineExPrivate::updateMatrix().

+ Here is the caller graph for this function:

◆ vertexCount()

int QTriangulatingStroker::vertexCount ( ) const
inline

Definition at line 38 of file qtriangulatingstroker_p.h.

Referenced by QOpenGL2PaintEngineExPrivate::stroke(), and QQuickShapeGenericRenderer::triangulateStroke().

+ Here is the caller graph for this function:

◆ vertices()

const float * QTriangulatingStroker::vertices ( ) const
inline

Definition at line 39 of file qtriangulatingstroker_p.h.

Referenced by QOpenGL2PaintEngineExPrivate::stroke(), and QQuickShapeGenericRenderer::triangulateStroke().

+ Here is the caller graph for this function:

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