From 8efe11569845a3c3bd7cd4a532a9499961e66d87 Mon Sep 17 00:00:00 2001 From: Onek8 Date: Wed, 28 May 2025 02:21:24 +0000 Subject: [PATCH] Update leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py --- leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py b/leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py index 01ef600..4e1484a 100644 --- a/leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py +++ b/leenkx/blender/lnx/lightmapper/utility/gui/Viewport.py @@ -28,7 +28,11 @@ class ViewportDraw: w = 400 h = 200 - self.shader = gpu.shader.from_builtin('2D_IMAGE') + if bpy.app.version[0] == 3: + self.shader = gpu.shader.from_builtin('2D_IMAGE') + else: + self.shader = gpu.shader.from_builtin('IMAGE') + self.batch = batch_for_shader( self.shader, 'TRI_FAN', {