[QGIS-Developer] processing temporal animation export in parallel

Dolf Andringa dolfandringa at gmail.com
Tue Feb 22 01:06:25 PST 2022


Hi all,

The temporal animation functionality of QGIS is great. I am currently
playing with it, probably a little out-of-scope, to make a travel animation
on a map. Everything works great, except that at high frame rates and high
resolution, exporting the animation to images is very slow (hours).

I dug into the code a little, and in bool QgsTemporalUtils::exportAnimation
I see:

while ( currentFrame < totalFrames )
{
    ...
    QPainter p( &img );
    QgsMapRendererCustomPainterJob job( ms, &p );
    job.start();
    job.waitForFinished();
    ...
}

Which renders each image in sequence. I am new to QGIS development
specifically, so forgive my ignorance, but could the jobs system be used to
render them in parallel instead? Could this potentially speed up the
process significantly? If this is feasible, I'd gladly make a feature
request, and it also looks like a nice PR I could contribute myself
potentially? I'd love to hear your thoughts.
Cheers,

Dolf.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20220222/f351e944/attachment.html>


More information about the QGIS-Developer mailing list