# This is normal- GREMEDY_string_marker is only available with OpenGL debuggers log("Unable to import GREMEDY OpenGL extension. Debug output will be more limited.") log("OpenGL debugging settings: "+ "GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s"+ "gl_debug_callback=%s, "+ "glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s, glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS, gl_debug_callback, glInitStringMarkerGREMEDY, glStringMarkerGREMEDY, glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) from ctypes import c_char_p try: import OpenGL_accelerate #@UnresolvedImport except: OpenGL_accelerate = None zerocopy_upload = bool(OpenGL_accelerate) and envbool("XPRA_ZEROCOPY_OPENGL_UPLOAD", True) and is_pyopengl_memoryview_safe(OpenGL_version.__version__, OpenGL_accelerate.__version__) try: memoryview_type = memoryview except: memoryview_type = None try: buffer_type = buffer except: #not defined in py3k.. buffer_type = None if os.name=="posix": from xpra.gtk_common.error import xsync paint_context_manager = xsync else:
# This is normal- GREMEDY_string_marker is only available with OpenGL debuggers log("Unable to import GREMEDY OpenGL extension. Debug output will be more limited.") log("OpenGL debugging settings: "+ "GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s"+ "gl_debug_callback=%s, "+ "glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s, glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS, gl_debug_callback, glInitStringMarkerGREMEDY, glStringMarkerGREMEDY, glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) from ctypes import c_char_p try: import OpenGL_accelerate #@UnresolvedImport except: OpenGL_accelerate = None zerocopy_upload = bool(OpenGL_accelerate) and os.environ.get("XPRA_ZEROCOPY_OPENGL_UPLOAD", "1")=="1" and is_pyopengl_memoryview_safe(OpenGL_version.__version__, OpenGL_accelerate.__version__) try: memoryview_type = memoryview except: memoryview_type = None try: buffer_type = buffer except: #not defined in py3k.. buffer_type = None # Texture number assignment # The first four are used to update the FBO, # the FBO is what is painted on screen. TEX_Y = 0
log( "OpenGL debugging settings: " + "GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s" + "gl_debug_callback=%s, " + "glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s, glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS, gl_debug_callback, glInitStringMarkerGREMEDY, glStringMarkerGREMEDY, glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) from ctypes import c_char_p try: import OpenGL_accelerate #@UnresolvedImport except: OpenGL_accelerate = None zerocopy_upload = bool(OpenGL_accelerate) and envbool( "XPRA_ZEROCOPY_OPENGL_UPLOAD", True) and is_pyopengl_memoryview_safe( OpenGL_version.__version__, OpenGL_accelerate.__version__) try: memoryview_type = memoryview except: memoryview_type = None try: buffer_type = buffer except: #not defined in py3k.. buffer_type = None def set_texture_level(): #only really needed with some drivers (NVidia) glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_BASE_LEVEL, 0) #may cause errors with older drivers:
log( "OpenGL debugging settings: " + "GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s" + "gl_debug_callback=%s, " + "glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s, glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS, gl_debug_callback, glInitStringMarkerGREMEDY, glStringMarkerGREMEDY, glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) from ctypes import c_char_p try: import OpenGL_accelerate except: OpenGL_accelerate = None zerocopy_upload = os.environ.get( "XPRA_ZEROCOPY_OPENGL_UPLOAD", "1") == "1" and is_pyopengl_memoryview_safe( OpenGL_version.__version__) and OpenGL_accelerate try: memoryview_type = memoryview except: memoryview_type = None try: buffer_type = buffer except: #not defined in py3k.. buffer_type = None # Texture number assignment # 1 = Y plane # 2 = U plane # 3 = V plane # 4 = RGB updates
log(" GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS) log(" gl_debug_callback=%s", gl_debug_callback) log(" glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s", glInitStringMarkerGREMEDY, glStringMarkerGREMEDY) log(" glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) zerocopy_upload = False if envbool("XPRA_ZEROCOPY_OPENGL_UPLOAD", True): try: import OpenGL_accelerate #@UnresolvedImport assert OpenGL_accelerate except ImportError: pass else: zerocopy_upload = is_pyopengl_memoryview_safe(OpenGL_version.__version__, OpenGL_accelerate.__version__) try: buffer_type = buffer except NameError: #not defined in py3k.. buffer_type = None if POSIX: from xpra.gtk_common.error import xsync paint_context_manager = xsync else: paint_context_manager = DummyContextManager() def set_texture_level(target=GL_TEXTURE_RECTANGLE_ARB): #only really needed with some drivers (NVidia)
# This is normal- GREMEDY_string_marker is only available with OpenGL debuggers log("Unable to import GREMEDY OpenGL extension. Debug output will be more limited.") log("OpenGL debugging settings: "+ "GL_DEBUG_OUTPUT=%s, GL_DEBUG_OUTPUT_SYNCHRONOUS=%s"+ "gl_debug_callback=%s, "+ "glInitStringMarkerGREMEDY=%s, glStringMarkerGREMEDY=%s, glInitFrameTerminatorGREMEDY=%s, glFrameTerminatorGREMEDY=%s", GL_DEBUG_OUTPUT, GL_DEBUG_OUTPUT_SYNCHRONOUS, gl_debug_callback, glInitStringMarkerGREMEDY, glStringMarkerGREMEDY, glInitFrameTerminatorGREMEDY, glFrameTerminatorGREMEDY) from ctypes import c_char_p try: import OpenGL_accelerate #@UnresolvedImport except: OpenGL_accelerate = None zerocopy_upload = bool(OpenGL_accelerate) and envbool("XPRA_ZEROCOPY_OPENGL_UPLOAD", True) and is_pyopengl_memoryview_safe(OpenGL_version.__version__, OpenGL_accelerate.__version__) try: buffer_type = buffer except: #not defined in py3k.. buffer_type = None def set_texture_level(): #only really needed with some drivers (NVidia) #may cause errors with older drivers: try: glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MIN_FILTER, GL_LINEAR) except: pass