Add callback called each time before drawing by opengl. Add testing code into Viewer.display().