visbrain.objects.HypnogramObj.record_animation

HypnogramObj.record_animation(name, n_pic=10, bgcolor=None)[source]

Record an animated object and save as a *.gif file.

Note that this method :

  • Can only be used with 3D objects.
  • Requires the python package imageio
Parameters:
name : string

Name of the gif file (e.g ‘myfile.gif’)

n_pic : int | 10

Number of pictures to use to render the gif.

bgcolor : string, tuple, list | None

Background color.