Geometry rendering with Jupyter


to play with simple geometry puzzle (lines,points,polygons, …) I am thinking to write a small geometry library.
Actually I did some first tests with Swig and a PNG wrapper, and can draw images onto a Notebook:

However, I am looking for some examples ideally Swig and C++ based that show how to render something in a Notebook.