From 9df413d9be09a0a8162bbdf8e64b6892c3ed96ac Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 27 Oct 2016 17:14:07 +0530 Subject: [PATCH] Nicer error message if the ARB_copy_image extension is absent --- kitty/shaders.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/kitty/shaders.py b/kitty/shaders.py index 7134b2bbe..03cd67a67 100644 --- a/kitty/shaders.py +++ b/kitty/shaders.py @@ -6,6 +6,7 @@ from functools import lru_cache from OpenGL.arrays import ArrayDatatype import OpenGL.GL as gl +from OpenGL.GL.ARB.copy_image import glCopyImageSubData # only present in opengl core >= 4.3 from .fonts import render_cell, cell_size @@ -60,8 +61,8 @@ class Sprites: ynum = self.ynum if self.z == 0: ynum -= 1 # Only copy the previous rows - gl.glCopyImageSubData(self.texture_id, tgt, 0, 0, 0, 0, tex, tgt, 0, 0, 0, 0, - width, ynum * self.cell_height, self.last_num_of_layers) + glCopyImageSubData(self.texture_id, tgt, 0, 0, 0, 0, tex, tgt, 0, 0, 0, 0, + width, ynum * self.cell_height, self.last_num_of_layers) gl.glDeleteTextures([self.texture_id]) self.last_num_of_layers = znum self.texture_id = tex