10 Recording Interactive Widget Sessions

As well as using generative scripts to create media assets, we can also record activity carried out within a widget as a rich media object.

See also: Alternative Presentation Modes: Jupyter Graffiti for an example of how to record “live replayable” interactive notebook sessions and tutorials.

10.1 ipywebrtc

The maartenbreddels/ipywebrtc package allows you to create a MediaStream out of any ipywidget, video file, image file, audio file or connected webcam/camera.

The MediaStream can then be used to record a movie, image snapshot or audio fragment, streamed to peers using a simple chat function, or used as a texture in a 3D interactve ipyvolume widget.