diff --git a/comfy_extras/nodes_glsl.py b/comfy_extras/nodes_glsl.py index 75ffb6d80..ef5c1bee0 100644 --- a/comfy_extras/nodes_glsl.py +++ b/comfy_extras/nodes_glsl.py @@ -16,6 +16,11 @@ from utils.install_util import get_missing_requirements_message logger = logging.getLogger(__name__) +# OpenGL modules - initialized lazily when context is created +gl = None +glfw = None +EGL = None + def _check_opengl_availability(): """Early check for OpenGL availability. Raises RuntimeError if unlikely to work.""" @@ -63,11 +68,6 @@ def _check_opengl_availability(): logger.debug("nodes_glsl: running _check_opengl_availability at import time") _check_opengl_availability() -# OpenGL modules - initialized lazily when context is created -gl = None -glfw = None -EGL = None - def _import_opengl(): """Import OpenGL module. Called after context is created."""