As the title, only white image is printed.
below is my codes
import numpy as np
from vispy import io, scene
c = scene.SceneCanvas(keys='interactive', bgcolor='w', dpi=96)
view = c.central_widget.add_view()
xx, yy = np.arange(-1,1,.02),np.arange(-1,1,.02)
X,Y = np.meshgrid(xx,yy)
R = np.sqrt(X**2+Y**2)
Z = lambda t : 0.1*np.sin(10*R-2*np.pi*t)
surf = scene.visuals.SurfacePlot(xx, yy, Z(0), color=[0.5, 0.5, 0.5], shading='smooth')
view.add(surf)
img = c.render()
io.write_png("vispytest.png", img)
I'm using Xvfb on Linux.
Xvfb :1 -screen 0 2500x1500x24 -auth localhost
Thank you.