I am currently trying to animate wildlife movement data through the new QGIS temporal controller. Basic animations are working well. However, I would like the tracks to fade out over time but could only find advice on how to do it through the old time manager. Has someone tried fade out effects with temporal controller or has some recommendation where to look for advice?

2 Answers 2


You can use data driven override for the size, for the transparency and other elements of the style: enter image description here

See this example here of a line that fades out: https://tube.switch.ch/videos/348a75d6

It was done by setting the source for the width of the line to day( "timestamp" - @map_start_time ): thus the number of days between the current frame (based on an attribute timestamp) and the beginning of the animation (the variable @map_start_time). See screenshot 1 below. Based on this, the size is scaled in a way as to become thinner and thinner. You could adapt this to point or polygon layers as well.

The same can be done with color/transparency: set the same expression and define a color ramp with 100% transparency at the beginning (left side) so that the line fades out: see screenshot 2.

See also this video here by Nyall Dawson who developed Temporal Controller. Especially in the second part, you find a detailed demonstration of how to make settings for a point layer: https://youtu.be/vgDg5cRwPRw

Screenshot 1: setting a line width that becomes thinner and thinner with time running by setting the size of the lien to data driven Override / assistant and the settings you see (transform curve is optional to smooth somehow the fading): enter image description here

Screenshot 2, showing fading colors:

enter image description here


If you want to use directly an experession it would be something like this one:

color_hsva(0, 100,100, 
           hour(age(@map_end_time,"timefield")),0,24, 255,0))

where "timefield" is your datetime field. With scale_linear you can transform the age between the map_end_time and your datetimefield in this case Hours between 0-24 into transparency between 0-255. @map_end_time and @map_start_time are variables and will be defined in the layer properties as "event duration". If the eventduration will be 1 day @map_start_time is the beginning of the day where your datetime value will fall in and @map_end_time the end of this day. in the above example the object will fade out withind max 24 hours. So you have to play with several values to get an perfect fade out effect.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.