karlwessel / mplopengl

OpenGL based backend for matplotlib
MIT License
15 stars 5 forks source link

plt.show() not working? #17

Closed JakkuSakura closed 1 month ago

JakkuSakura commented 4 years ago

I find that plt.show() is not working for mplopengl, even with plt.ion(). Is this a feature or bug? I can use plt.pause() temperorily instead.

import matplotlib
# matplotlib.use("Qt5Agg")
matplotlib.use('module://mplopengl.backend_qtgl')
import numpy as np
from matplotlib import pyplot as plt
sample_size = 100000
X = np.linspace(100079, 100090, sample_size)
Y = np.random.random(sample_size)

fig, (ax1) = plt.subplots(1, 1, sharex=True, sharey=True)

ax1.plot(X, Y, linestyle='solid', marker='*')
plt.ion()
plt.show()
# plt.pause(30)
if __name__ == '__main__':
    pass
karlwessel commented 1 month ago

This seems to have been fixed at some point. At least the example works fine now. (sorry for the late response).