From 765032fc0bcf7ee4169d1354326c6250b5edd97a Mon Sep 17 00:00:00 2001 From: Ogi Moore Date: Tue, 16 Feb 2021 22:19:38 -0800 Subject: [PATCH] Do not upload texture every paintGL call --- pyqtgraph/widgets/RawImageWidget.py | 1 + 1 file changed, 1 insertion(+) diff --git a/pyqtgraph/widgets/RawImageWidget.py b/pyqtgraph/widgets/RawImageWidget.py index e72f1b12..ca9db363 100644 --- a/pyqtgraph/widgets/RawImageWidget.py +++ b/pyqtgraph/widgets/RawImageWidget.py @@ -132,6 +132,7 @@ if HAVE_OPENGL: glTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, image.shape[1], image.shape[0], 0, GL_RGBA, GL_UNSIGNED_BYTE, image) glDisable(GL_TEXTURE_2D) + self.uploaded = True def paintGL(self): glClear(GL_COLOR_BUFFER_BIT)