QGIS API Documentation  3.13.0-Master (13337b20cd)
Public Member Functions | List of all members
QgsMeshVectorTraceAnimationGenerator Class Reference

A wrapper for QgsMeshParticuleTracesField used to render the particles. More...

#include <qgsmeshtracerenderer.h>

Public Member Functions

 QgsMeshVectorTraceAnimationGenerator (const QgsTriangularMesh &triangularMesh, const QgsMeshDataBlock &dataSetVectorValues, const QgsMeshDataBlock &scalarActiveFaceFlagValues, bool dataIsOnVertices, const QgsRenderContext &rendererContext, const QgsRectangle &layerExtent, double magMax)
 Constructor to use from QgsMeshVectorRenderer. More...
 
 QgsMeshVectorTraceAnimationGenerator (QgsMeshLayer *layer, const QgsRenderContext &rendererContext)
 Constructor to use with Python binding. More...
 
 QgsMeshVectorTraceAnimationGenerator (const QgsMeshVectorTraceAnimationGenerator &other)
 Copy constructor. More...
 
 ~QgsMeshVectorTraceAnimationGenerator ()=default
 Destructor. More...
 
QImage imageRendered ()
 Moves all the particles using frame per second (fps) to calculate the displacement and return the rendered frame. More...
 
QgsMeshVectorTraceAnimationGeneratoroperator= (const QgsMeshVectorTraceAnimationGenerator &other)
 Assignment operator. More...
 
void seedRandomParticles (int count)
 seeds particles in the vector fields More...
 
void setFPS (int FPS)
 Sets the number of frames per seconds that will be rendered. More...
 
void setMaxSpeedPixel (int max)
 Sets the max number of pixels that can be go through by the particles in 1 second. More...
 
void setMinimumTailLength (int l)
 Sets the minimum tail length. More...
 
void setParticlesColor (const QColor &c)
 Sets colors of particle. More...
 
void setParticlesLifeTime (double particleLifeTime)
 Sets maximum life time of particles in seconds. More...
 
void setParticlesSize (double width)
 Sets particle size in px. More...
 
void setTailFactor (double fct)
 Sets the tail factor, used to adjust the length of the tail. 0 : minimum length, >1 increase the tail. More...
 
void setTailPersitence (double p)
 Sets the visual persistence of the tail. More...
 

Detailed Description

A wrapper for QgsMeshParticuleTracesField used to render the particles.

Available for Python binding

Since
QGIS 3.12

Definition at line 553 of file qgsmeshtracerenderer.h.

Constructor & Destructor Documentation

◆ QgsMeshVectorTraceAnimationGenerator() [1/3]

QgsMeshVectorTraceAnimationGenerator::QgsMeshVectorTraceAnimationGenerator ( const QgsTriangularMesh triangularMesh,
const QgsMeshDataBlock dataSetVectorValues,
const QgsMeshDataBlock scalarActiveFaceFlagValues,
bool  dataIsOnVertices,
const QgsRenderContext rendererContext,
const QgsRectangle layerExtent,
double  magMax 
)

Constructor to use from QgsMeshVectorRenderer.

◆ QgsMeshVectorTraceAnimationGenerator() [2/3]

QgsMeshVectorTraceAnimationGenerator::QgsMeshVectorTraceAnimationGenerator ( QgsMeshLayer layer,
const QgsRenderContext rendererContext 
)

Constructor to use with Python binding.

◆ QgsMeshVectorTraceAnimationGenerator() [3/3]

QgsMeshVectorTraceAnimationGenerator::QgsMeshVectorTraceAnimationGenerator ( const QgsMeshVectorTraceAnimationGenerator other)

Copy constructor.

◆ ~QgsMeshVectorTraceAnimationGenerator()

QgsMeshVectorTraceAnimationGenerator::~QgsMeshVectorTraceAnimationGenerator ( )
default

Destructor.

Member Function Documentation

◆ imageRendered()

QImage QgsMeshVectorTraceAnimationGenerator::imageRendered ( )

Moves all the particles using frame per second (fps) to calculate the displacement and return the rendered frame.

◆ operator=()

QgsMeshVectorTraceAnimationGenerator& QgsMeshVectorTraceAnimationGenerator::operator= ( const QgsMeshVectorTraceAnimationGenerator other)

Assignment operator.

◆ seedRandomParticles()

void QgsMeshVectorTraceAnimationGenerator::seedRandomParticles ( int  count)

seeds particles in the vector fields

◆ setFPS()

void QgsMeshVectorTraceAnimationGenerator::setFPS ( int  FPS)

Sets the number of frames per seconds that will be rendered.

◆ setMaxSpeedPixel()

void QgsMeshVectorTraceAnimationGenerator::setMaxSpeedPixel ( int  max)

Sets the max number of pixels that can be go through by the particles in 1 second.

◆ setMinimumTailLength()

void QgsMeshVectorTraceAnimationGenerator::setMinimumTailLength ( int  l)

Sets the minimum tail length.

◆ setParticlesColor()

void QgsMeshVectorTraceAnimationGenerator::setParticlesColor ( const QColor &  c)

Sets colors of particle.

◆ setParticlesLifeTime()

void QgsMeshVectorTraceAnimationGenerator::setParticlesLifeTime ( double  particleLifeTime)

Sets maximum life time of particles in seconds.

◆ setParticlesSize()

void QgsMeshVectorTraceAnimationGenerator::setParticlesSize ( double  width)

Sets particle size in px.

◆ setTailFactor()

void QgsMeshVectorTraceAnimationGenerator::setTailFactor ( double  fct)

Sets the tail factor, used to adjust the length of the tail. 0 : minimum length, >1 increase the tail.

◆ setTailPersitence()

void QgsMeshVectorTraceAnimationGenerator::setTailPersitence ( double  p)

Sets the visual persistence of the tail.


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