Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-opengl for openSUSE:Factory 
checked in at 2022-03-26 22:32:14
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-opengl (Old)
 and      /work/SRC/openSUSE:Factory/.python-opengl.new.1900 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-opengl"

Sat Mar 26 22:32:14 2022 rev:28 rq:965075 version:3.1.6

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-opengl/python-opengl.changes      
2021-03-25 14:52:02.640468301 +0100
+++ /work/SRC/openSUSE:Factory/.python-opengl.new.1900/python-opengl.changes    
2022-03-26 22:32:38.746083417 +0100
@@ -1,0 +2,6 @@
+Sat Mar 26 19:20:43 UTC 2022 - Dirk M??ller <dmuel...@suse.com>
+
+- update to 3.1.6:
+  * python 3.8-3.10 support 
+
+-------------------------------------------------------------------

Old:
----
  PyOpenGL-3.1.5.tar.gz

New:
----
  PyOpenGL-3.1.6.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-opengl.spec ++++++
--- /var/tmp/diff_new_pack.DMDa7X/_old  2022-03-26 22:32:39.322084205 +0100
+++ /var/tmp/diff_new_pack.DMDa7X/_new  2022-03-26 22:32:39.326084210 +0100
@@ -1,7 +1,7 @@
 #
-# spec file for package python-opengl
+# spec file
 #
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2022 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -27,7 +27,7 @@
 %endif
 %define tarname PyOpenGL
 Name:           python-opengl%{psuffix}
-Version:        3.1.5
+Version:        3.1.6
 Release:        0
 Summary:        OpenGL bindings for Python
 License:        BSD-3-Clause

++++++ PyOpenGL-3.1.5.tar.gz -> PyOpenGL-3.1.6.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/EGL/EXT/device_enumeration.py 
new/PyOpenGL-3.1.6/OpenGL/EGL/EXT/device_enumeration.py
--- old/PyOpenGL-3.1.5/OpenGL/EGL/EXT/device_enumeration.py     2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/EGL/EXT/device_enumeration.py     2022-02-19 
23:44:47.000000000 +0100
@@ -20,4 +20,7 @@
     return extensions.hasGLExtension( _EXTENSION_NAME )
 
 
-### END AUTOGENERATED SECTION
\ No newline at end of file
+### END AUTOGENERATED SECTION
+
+eglQueryDevicesEXT.extension = None
+eglQueryDevicesEXT.force_extension = True 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/EGL/debug.py 
new/PyOpenGL-3.1.6/OpenGL/EGL/debug.py
--- old/PyOpenGL-3.1.5/OpenGL/EGL/debug.py      2020-01-04 03:07:10.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/EGL/debug.py      2022-02-19 23:44:47.000000000 
+0100
@@ -35,11 +35,11 @@
     linux workstations.
     """
     with open(filename, "w") as f:
-        h, w, c = buf.shape
-        print("P3", file=f)
-        print("# ascii ppm file created by pyopengl", file=f)
-        print("%i %i" % (w, h), file=f)
-        print("255", file=f)
+        (h, w, c) = buf.shape
+        f.write("P3\n")
+        f.write("# ascii ppm file created by pyopengl\n")
+        f.write("%i %i\n" % (w, h))
+        f.write("255\n")
         for y in range(h - 1, -1, -1):
             for x in range(w):
                 pixel = buf[y, x]
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/GL/images.py 
new/PyOpenGL-3.1.6/OpenGL/GL/images.py
--- old/PyOpenGL-3.1.5/OpenGL/GL/images.py      2020-01-04 03:07:10.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/GL/images.py      2022-02-19 23:44:47.000000000 
+0100
@@ -69,6 +69,7 @@
 } )
 
 images.TYPE_TO_ARRAYTYPE.update( {
+    GL_3_0.GL_HALF_FLOAT : GL_3_0.GL_HALF_FLOAT,
     GL_1_2.GL_UNSIGNED_BYTE_3_3_2 : GL_1_1.GL_UNSIGNED_BYTE,
     GL_1_2.GL_UNSIGNED_BYTE_2_3_3_REV : GL_1_1.GL_UNSIGNED_BYTE,
     GL_1_2.GL_UNSIGNED_SHORT_4_4_4_4 : GL_1_1.GL_UNSIGNED_SHORT,
@@ -235,7 +236,7 @@
         GL_1_1.glGetTexLevelParameteriv( target, level, 
GL_1_1.GL_TEXTURE_HEIGHT, dim )
         dims.append( dim.value )
         if target != GL_1_1.GL_TEXTURE_2D:
-            GL_1_1.glGetTexLevelParameteriv( target, level, 
GL_1_1.GL_TEXTURE_DEPTH, dim )
+            GL_1_1.glGetTexLevelParameteriv( target, level, 
GL_1_2.GL_TEXTURE_DEPTH, dim )
             dims.append( dim.value )
     return dims
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/__init__.py 
new/PyOpenGL-3.1.6/OpenGL/__init__.py
--- old/PyOpenGL-3.1.5/OpenGL/__init__.py       2019-11-25 03:18:31.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/__init__.py       2022-02-19 23:44:47.000000000 
+0100
@@ -211,11 +211,15 @@
 # Declarations of plugins provided by PyOpenGL itself
 from OpenGL.plugins import PlatformPlugin, FormatHandler
 PlatformPlugin( 'nt', 'OpenGL.platform.win32.Win32Platform' )
-PlatformPlugin( 'linux2', 'OpenGL.platform.glx.GLXPlatform' )
 PlatformPlugin( 'darwin', 'OpenGL.platform.darwin.DarwinPlatform' )
+PlatformPlugin( 'linux2', 'OpenGL.platform.glx.GLXPlatform' )
+PlatformPlugin( 'linux', 'OpenGL.platform.glx.GLXPlatform' )
 PlatformPlugin( 'posix', 'OpenGL.platform.glx.GLXPlatform' )
+PlatformPlugin( 'x11', 'OpenGL.platform.glx.GLXPlatform' ) # xdg session type
 PlatformPlugin( 'osmesa', 'OpenGL.platform.osmesa.OSMesaPlatform')
 PlatformPlugin( 'egl', 'OpenGL.platform.egl.EGLPlatform')
+PlatformPlugin( 'wayland', 'OpenGL.platform.egl.EGLPlatform') # xdg session 
type
+PlatformPlugin( 'xwayland', 'OpenGL.platform.egl.EGLPlatform') # xdg session 
type, but use egl even though normally you'd expect GLX
 
 import sys
 if sys.version_info[0] < 3:
@@ -284,6 +288,7 @@
     'numpy.int16',
     'numpy.int32',
     'numpy.int64',
+    'numpy.float16',
     'numpy.float32',
     'numpy.float64',
     'numpy.float128',
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/arrays/_arrayconstants.py 
new/PyOpenGL-3.1.6/OpenGL/arrays/_arrayconstants.py
--- old/PyOpenGL-3.1.5/OpenGL/arrays/_arrayconstants.py 2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/arrays/_arrayconstants.py 2022-02-19 
23:44:47.000000000 +0100
@@ -29,12 +29,14 @@
     GL_INT: 4,
     GL_UNSIGNED_INT: 4,
     GL_UNSIGNED_INT64: 8,
+    GL_HALF_FLOAT: 2,
     GL_FLOAT: 4,
     GL_DOUBLE: 8,
 }
 
 ARRAY_TO_GL_TYPE_MAPPING = {
     'c': GL_UNSIGNED_BYTE,
+    'e': GL_HALF_FLOAT,
     'f': GL_FLOAT,
     'b': GL_BYTE,
     'i': GL_INT,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/arrays/arraydatatype.py 
new/PyOpenGL-3.1.6/OpenGL/arrays/arraydatatype.py
--- old/PyOpenGL-3.1.5/OpenGL/arrays/arraydatatype.py   2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/arrays/arraydatatype.py   2022-02-19 
23:44:47.000000000 +0100
@@ -201,6 +201,11 @@
         baseType = _types.GLclampf
         typeConstant = _types.GL_FLOAT
 
+    class GLfloat16Array(ArrayDatatype, ctypes.POINTER(_types.GLushort)):
+        """Array datatype for float16 as GLushort types"""
+        baseType = _types.GLushort
+        typeConstant = _types.GL_HALF_FLOAT
+
     class GLfloatArray( ArrayDatatype, ctypes.POINTER(_types.GLfloat )):
         """Array datatype for GLfloat types"""
         baseType = _types.GLfloat
@@ -282,6 +287,7 @@
     GLclampdArray = ADT( GL_1_1.GL_DOUBLE, _types.GLclampd )
     GLclampfArray = ADT( GL_1_1.GL_FLOAT, _types.GLclampf )
     GLdoubleArray = ADT( GL_1_1.GL_DOUBLE, _types.GLdouble )
+    GLfloat16Array = ADT( GL_1_1.GL_HALF_FLOAT, _types.GLushort )
     GLfloatArray = ADT( GL_1_1.GL_FLOAT, _types.GLfloat )
     GLbyteArray = ADT( GL_1_1.GL_BYTE, _types.GLbyte )
     GLcharArray = GLcharARBArray = ADT( GL_1_1.GL_BYTE, _types.GLchar )
@@ -299,7 +305,9 @@
 
 EGLAttribArray = GLintArray
 
+
 GL_CONSTANT_TO_ARRAY_TYPE = {
+    GL_1_1.GL_HALF_FLOAT : GLfloat16Array,
     GL_1_1.GL_DOUBLE : GLclampdArray,
     GL_1_1.GL_FLOAT : GLclampfArray,
     GL_1_1.GL_FLOAT : GLfloatArray,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/arrays/numpymodule.py 
new/PyOpenGL-3.1.6/OpenGL/arrays/numpymodule.py
--- old/PyOpenGL-3.1.5/OpenGL/arrays/numpymodule.py     2020-01-04 
03:07:10.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/arrays/numpymodule.py     2022-02-19 
23:44:47.000000000 +0100
@@ -236,6 +236,7 @@
 ARRAY_TO_GL_TYPE_MAPPING = {
     lookupDtype('d'): GL_1_1.GL_DOUBLE,
     lookupDtype('f'): GL_1_1.GL_FLOAT,
+    lookupDtype('e'): _types.GL_HALF_FLOAT,
     lookupDtype('i'): GL_1_1.GL_INT,
     lookupDtype(SHORT_TYPE): GL_1_1.GL_SHORT,
     lookupDtype(USHORT_TYPE): GL_1_1.GL_UNSIGNED_SHORT,
@@ -249,6 +250,7 @@
 GL_TYPE_TO_ARRAY_MAPPING = {
     GL_1_1.GL_DOUBLE: lookupDtype('d'),
     GL_1_1.GL_FLOAT:lookupDtype('f'),
+    _types.GL_HALF_FLOAT: lookupDtype('e'),
     GL_1_1.GL_INT: lookupDtype('i'),
     GL_1_1.GL_BYTE: lookupDtype('b'),
     GL_1_1.GL_SHORT: lookupDtype(SHORT_TYPE),
@@ -257,6 +259,7 @@
     GL_1_1.GL_UNSIGNED_SHORT: lookupDtype(USHORT_TYPE),
     _types.GL_VOID_P: lookupDtype('P'),
     None: None,
+    'e': lookupDtype('e'),
     'f': lookupDtype('f'),
     'd': lookupDtype('d'),
     'i': lookupDtype('i'),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/images.py 
new/PyOpenGL-3.1.6/OpenGL/images.py
--- old/PyOpenGL-3.1.5/OpenGL/images.py 2019-11-25 03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/images.py 2022-02-19 23:44:47.000000000 +0100
@@ -138,7 +138,9 @@
     """
     if _configflags.UNSIGNED_BYTE_IMAGES_AS_STRING:
         if type == _simple.GL_UNSIGNED_BYTE:
-            if hasattr( data, 'tostring' ):
+            if hasattr( data, 'tobytes' ):
+                return data.tobytes()
+            elif hasattr( data, 'tostring' ):
                 return data.tostring()
             elif hasattr( data, 'raw' ):
                 return data.raw 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/platform/__init__.py 
new/PyOpenGL-3.1.6/OpenGL/platform/__init__.py
--- old/PyOpenGL-3.1.5/OpenGL/platform/__init__.py      2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/platform/__init__.py      2022-02-19 
23:44:47.000000000 +0100
@@ -20,9 +20,29 @@
 from OpenGL.plugins import PlatformPlugin
 from OpenGL import _configflags
 
+XDG = 'XDG_SESSION_TYPE'
+WAYLAND_DISPLAY = 'WAYLAND_DISPLAY'
+
 def _load( ):
     """Load the os.name plugin for the platform functionality"""
-    key = (os.environ.get( 'PYOPENGL_PLATFORM'), sys.platform,os.name)
+    # Linux override keys...
+    guessing_key = None
+    if (
+        sys.platform in ('linux','linux2') 
+        and not 'PYOPENGL_PLATFORM' in os.environ
+    ):
+        if 'WAYLAND_DISPLAY' in os.environ:
+            guessing_key = 'wayland'
+        elif 'DISPLAY' in os.environ:
+            guessing_key = 'linux'
+
+    key = (
+        os.environ.get( 'PYOPENGL_PLATFORM'), 
+        os.environ.get( 'XDG_SESSION_TYPE','').lower(),
+        guessing_key,
+        sys.platform,
+        os.name,
+    )
     plugin  = PlatformPlugin.match( key )
     plugin_class = plugin.load()
     plugin.loaded = True
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/platform/egl.py 
new/PyOpenGL-3.1.6/OpenGL/platform/egl.py
--- old/PyOpenGL-3.1.5/OpenGL/platform/egl.py   2020-01-04 03:07:10.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/platform/egl.py   2022-02-19 23:44:47.000000000 
+0100
@@ -34,7 +34,7 @@
             for name in ('OpenGL','GL'):
                 lib = ctypesloader.loadLibrary(
                     ctypes.cdll,
-                    'GL', 
+                    name, 
                     mode=ctypes.RTLD_GLOBAL 
                 )
                 if lib:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/plugins.py 
new/PyOpenGL-3.1.6/OpenGL/plugins.py
--- old/PyOpenGL-3.1.5/OpenGL/plugins.py        2019-11-25 03:18:31.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/plugins.py        2022-02-19 23:44:47.000000000 
+0100
@@ -1,4 +1,6 @@
 """Simple plug-in mechanism to provide replacement for setuptools plugins"""
+import logging 
+log = logging.getLogger(__name__)
 
 class Plugin( object ):
     """Base class for plugins to be loaded"""
@@ -14,7 +16,12 @@
         """Attempt to load and return our entry point"""
         try:
             return importByName( self.import_path )
-        except ImportError:
+        except ImportError as err:
+            log.warning(
+                'Unable to import %s: %s',
+                self.import_path,
+                err
+            )
             return None
     @classmethod
     def match( cls, *args ):
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/raw/GL/_glgets.py 
new/PyOpenGL-3.1.6/OpenGL/raw/GL/_glgets.py
--- old/PyOpenGL-3.1.5/OpenGL/raw/GL/_glgets.py 2019-11-25 03:18:31.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/raw/GL/_glgets.py 2022-02-19 23:44:47.000000000 
+0100
@@ -1361,7 +1361,7 @@
 _m[0x8B87] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB
 _m[0x8B85] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ATTACHED_OBJECTS_ARB
 _m[0x8764] = (1,) # GL_OBJECT_BUFFER_SIZE_ATI
-_m[0x8765] = (1,) # GL_OBJECT_BUFFER_USAGE_ATI TOOD: this is the *same* 
constant as GL_BUFFER_USAGE, but it has a *different* semantic, argh
+_m[0x8765] = (4,) # GL_OBJECT_BUFFER_USAGE_ATI
 _m[0x8B81] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_COMPILE_STATUS_ARB
 _m[0x8B80] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_DELETE_STATUS_ARB
 _m[0x8B84] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_INFO_LOG_LENGTH_ARB
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/raw/GL/_types.py 
new/PyOpenGL-3.1.6/OpenGL/raw/GL/_types.py
--- old/PyOpenGL-3.1.5/OpenGL/raw/GL/_types.py  2019-11-25 03:18:31.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/raw/GL/_types.py  2022-02-19 23:44:47.000000000 
+0100
@@ -84,12 +84,12 @@
 GLfixed = _defineType('GLfixed', ctypes.c_int32, int )
 GLclampx = _defineType('GLclampx', ctypes.c_int32, int )
 
-if hasattr(ctypes, 'c_ptrdiff_t'): # maybe some day...
-    GLsizei = _defineType( 'GLsizei', ctypes.c_ptrdiff_t, int )
-elif hasattr(ctypes, 'c_ssize_t'): # 2.7+ should have this
-    GLsizei = _defineType( 'GLsizei', ctypes.c_ssize_t, int )
-else: # really old, likely never hit these days
-    GLsizei = _defineType( 'GLsizei', ctypes.c_long, int )
+# This is explicitly called out as equivalent to a uint
+GLsizei = _defineType( 'GLsizei', ctypes.c_uint, long )
+# Signed 2's complement binary integer with sizeof( void * )
+GLintptr = _defineType( 'GLintptr', ctypes.c_ssize_t, int )
+# Unsigned size-of-x
+GLsizeiptr = _defineType( 'GLsizeiptr', ctypes.c_size_t, int )
 
 GLubyte = ctypes.c_ubyte
 GLubyte_3 = GLubyte * 3
@@ -109,8 +109,8 @@
 GLint64 = GLint64EXT = _defineType('GLint64', ctypes.c_int64, long )
 
 # ptrdiff_t, actually...
-GLsizeiptrARB = GLsizeiptr = GLsizei
-GLvdpauSurfaceNV = GLintptrARB = GLintptr = GLsizei
+GLsizeiptrARB = GLsizeiptr
+GLvdpauSurfaceNV = GLintptrARB = GLintptr
 size_t = ctypes.c_size_t
 int32_t = ctypes.c_int32
 int64_t = ctypes.c_int64
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/raw/GLES1/_glgets.py 
new/PyOpenGL-3.1.6/OpenGL/raw/GLES1/_glgets.py
--- old/PyOpenGL-3.1.5/OpenGL/raw/GLES1/_glgets.py      2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/raw/GLES1/_glgets.py      2022-02-19 
23:44:47.000000000 +0100
@@ -1361,7 +1361,7 @@
 _m[0x8B87] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB
 _m[0x8B85] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ATTACHED_OBJECTS_ARB
 _m[0x8764] = (1,) # GL_OBJECT_BUFFER_SIZE_ATI
-_m[0x8765] = (1,) # GL_OBJECT_BUFFER_USAGE_ATI
+_m[0x8765] = (4,) # GL_OBJECT_BUFFER_USAGE_ATI
 _m[0x8B81] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_COMPILE_STATUS_ARB
 _m[0x8B80] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_DELETE_STATUS_ARB
 _m[0x8B84] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_INFO_LOG_LENGTH_ARB
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/raw/GLES2/_glgets.py 
new/PyOpenGL-3.1.6/OpenGL/raw/GLES2/_glgets.py
--- old/PyOpenGL-3.1.5/OpenGL/raw/GLES2/_glgets.py      2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/raw/GLES2/_glgets.py      2022-02-19 
23:44:47.000000000 +0100
@@ -1361,7 +1361,7 @@
 _m[0x8B87] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB
 _m[0x8B85] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ATTACHED_OBJECTS_ARB
 _m[0x8764] = (1,) # GL_OBJECT_BUFFER_SIZE_ATI
-_m[0x8765] = (1,) # GL_OBJECT_BUFFER_USAGE_ATI
+_m[0x8765] = (4,) # GL_OBJECT_BUFFER_USAGE_ATI
 _m[0x8B81] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_COMPILE_STATUS_ARB
 _m[0x8B80] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_DELETE_STATUS_ARB
 _m[0x8B84] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_INFO_LOG_LENGTH_ARB
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/raw/GLES3/_glgets.py 
new/PyOpenGL-3.1.6/OpenGL/raw/GLES3/_glgets.py
--- old/PyOpenGL-3.1.5/OpenGL/raw/GLES3/_glgets.py      2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/OpenGL/raw/GLES3/_glgets.py      2022-02-19 
23:44:47.000000000 +0100
@@ -1361,7 +1361,7 @@
 _m[0x8B87] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB
 _m[0x8B85] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_ATTACHED_OBJECTS_ARB
 _m[0x8764] = (1,) # GL_OBJECT_BUFFER_SIZE_ATI
-_m[0x8765] = (1,) # GL_OBJECT_BUFFER_USAGE_ATI
+_m[0x8765] = (4,) # GL_OBJECT_BUFFER_USAGE_ATI
 _m[0x8B81] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_COMPILE_STATUS_ARB
 _m[0x8B80] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_DELETE_STATUS_ARB
 _m[0x8B84] = (1,)#TODO Review 
http://www.opengl.org/registry/specs//ARB/shader_objects.txt # 
GL_OBJECT_INFO_LOG_LENGTH_ARB
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/OpenGL/version.py 
new/PyOpenGL-3.1.6/OpenGL/version.py
--- old/PyOpenGL-3.1.5/OpenGL/version.py        2020-01-04 03:07:10.000000000 
+0100
+++ new/PyOpenGL-3.1.6/OpenGL/version.py        2022-02-19 23:44:47.000000000 
+0100
@@ -1,2 +1,2 @@
 """Declares the current version for use in setuptools and the like"""
-__version__ = '3.1.5'
+__version__ = '3.1.6'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/PKG-INFO new/PyOpenGL-3.1.6/PKG-INFO
--- old/PyOpenGL-3.1.5/PKG-INFO 2020-01-04 03:31:06.000000000 +0100
+++ new/PyOpenGL-3.1.6/PKG-INFO 2022-02-20 00:00:00.717962300 +0100
@@ -1,89 +1,12 @@
 Metadata-Version: 2.1
 Name: PyOpenGL
-Version: 3.1.5
+Version: 3.1.6
 Summary: Standard OpenGL bindings for Python
 Home-page: http://pyopengl.sourceforge.net
 Author: Mike C. Fletcher
 Author-email: mcfle...@vrplumber.com
 License: BSD
 Download-URL: http://sourceforge.net/projects/pyopengl/files/PyOpenGL/
-Description: PyOpenGL and PyOpenGL_Accelerate
-        =================================
-        
-        PyOpenGL is normally distributed via PyPI using standard pip::
-        
-            $ pip install PyOpenGL PyOpenGL_accelerate
-        
-        You can install this repository by branching/cloning and running
-        setup.py::
-        
-            $ cd pyopengl
-            $ python setup.py develop
-            $ cd accelerate
-            $ python setup.py develop
-        
-        Note that to compile PyOpenGL_accelerate you will need to have 
-        a functioning Python extension-compiling environment.
-        
-        Learning PyOpenGL
-        -----------------
-        
-        If you are new to PyOpenGL, you likely want to start with the 
OpenGLContext `tutorial page`_.
-        Those tutorials require OpenGLContext, (which is a big wrapper 
including a whole
-        scenegraph engine, VRML97 parser, lots of demos, etc) you can install 
that with::
-        
-            $ pip2.7 install "OpenGLContext-full==3.1.1"
-        
-        Or you can clone it (including the tutorial sources) with::
-        
-            $ git clone https://github.com/mcfletch/openglcontext.git
-        
-        or (for GitHub usage)::
-        
-            $ git clone https://github.com/mcfletch/pyopengl.git
-            
-        The `documentation pages`_ are useful for looking up the parameters 
and semantics of 
-        PyOpenGL calls.
-        
-        .. _`tutorial page`: 
http://pyopengl.sourceforge.net/context/tutorials/index.html
-        .. _`documentation pages`: 
http://pyopengl.sourceforge.net/documentation/
-        
-        
-        Running Tests
-        --------------
-        
-        You can run the PyOpenGL test suite from a source-code checkout, you 
will need:
-        
-        * git (for the checkout)
-        * GLUT (FreeGLUT)
-        * GLExtrusion library (libgle)
-        * GLU (normally available on any OpenGL-capable machine)
-        * tox (`pip install tox`)
-        
-        Running the test suite from a top-level checkout looks like::
-        
-            $ tox
-        
-        The result being a lot of tests being run in a matrix of environments.
-        All of the environment will pull in pygame, some will also pull in 
-        numpy. Some will have accelerate, and some will not.
-        
-        .. image:: https://travis-ci.org/mcfletch/pyopengl.svg?branch=master
-            :target: https://travis-ci.org/mcfletch/pyopengl
-            :alt: Travis Tests
-        
-        .. image:: 
https://ci.appveyor.com/api/projects/status/MikeCFletcher/pyopengl/branch/master
-            :target: https://ci.appveyor.com/project/MikeCFletcher/pyopengl
-            :alt: Appveyor Build
-        
-        .. image:: https://img.shields.io/pypi/v/pyopengl.svg
-            :target: https://pypi.python.org/pypi/pyopengl
-            :alt: Latest PyPI Version
-        
-        .. image:: https://img.shields.io/pypi/dm/pyopengl.svg
-            :target: https://pypi.python.org/pypi/pyopengl
-            :alt: Monthly download counter
-        
 Keywords: Graphics,3D,OpenGL,GLU,GLUT,GLE,GLX,EXT,ARB,Mesa,ctypes
 Platform: UNKNOWN
 Classifier: License :: OSI Approved :: BSD License
@@ -93,3 +16,82 @@
 Classifier: Topic :: Software Development :: Libraries :: Python Modules
 Classifier: Intended Audience :: Developers
 Description-Content-Type: text/x-rst
+
+PyOpenGL and PyOpenGL_Accelerate
+=================================
+
+PyOpenGL is normally distributed via PyPI using standard pip::
+
+    $ pip install PyOpenGL PyOpenGL_accelerate
+
+You can install this repository by branching/cloning and running
+setup.py::
+
+    $ cd pyopengl
+    $ python setup.py develop
+    $ cd accelerate
+    $ python setup.py develop
+
+Note that to compile PyOpenGL_accelerate you will need to have 
+a functioning Python extension-compiling environment.
+
+Learning PyOpenGL
+-----------------
+
+If you are new to PyOpenGL, you likely want to start with the OpenGLContext 
`tutorial page`_.
+Those tutorials require OpenGLContext, (which is a big wrapper including a 
whole
+scenegraph engine, VRML97 parser, lots of demos, etc) you can install that 
with::
+
+    $ pip2.7 install "OpenGLContext-full==3.1.1"
+
+Or you can clone it (including the tutorial sources) with::
+
+    $ git clone https://github.com/mcfletch/openglcontext.git
+
+or (for GitHub usage)::
+
+    $ git clone https://github.com/mcfletch/pyopengl.git
+    
+The `documentation pages`_ are useful for looking up the parameters and 
semantics of 
+PyOpenGL calls.
+
+.. _`tutorial page`: 
http://pyopengl.sourceforge.net/context/tutorials/index.html
+.. _`documentation pages`: http://pyopengl.sourceforge.net/documentation/
+
+
+Running Tests
+--------------
+
+You can run the PyOpenGL test suite from a source-code checkout, you will need:
+
+* git (for the checkout)
+* GLUT (FreeGLUT)
+* GLExtrusion library (libgle)
+* GLU (normally available on any OpenGL-capable machine)
+* tox (`pip install tox`)
+
+Running the test suite from a top-level checkout looks like::
+
+    $ tox
+
+The result being a lot of tests being run in a matrix of environments.
+All of the environment will pull in pygame, some will also pull in 
+numpy. Some will have accelerate, and some will not.
+
+.. image:: https://travis-ci.org/mcfletch/pyopengl.svg?branch=master
+    :target: https://travis-ci.org/mcfletch/pyopengl
+    :alt: Travis Tests
+
+.. image:: https://ci.appveyor.com/api/projects/status/github/mcfletch/pyopengl
+    :target: https://ci.appveyor.com/project/MikeCFletcher/pyopengl
+    :alt: Appveyor Build
+
+.. image:: https://img.shields.io/pypi/v/pyopengl.svg
+    :target: https://pypi.python.org/pypi/pyopengl
+    :alt: Latest PyPI Version
+
+.. image:: https://img.shields.io/pypi/dm/pyopengl.svg
+    :target: https://pypi.python.org/pypi/pyopengl
+    :alt: Monthly download counter
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/PyOpenGL.egg-info/PKG-INFO 
new/PyOpenGL-3.1.6/PyOpenGL.egg-info/PKG-INFO
--- old/PyOpenGL-3.1.5/PyOpenGL.egg-info/PKG-INFO       2020-01-04 
03:31:05.000000000 +0100
+++ new/PyOpenGL-3.1.6/PyOpenGL.egg-info/PKG-INFO       2022-02-20 
00:00:00.000000000 +0100
@@ -1,89 +1,12 @@
 Metadata-Version: 2.1
 Name: PyOpenGL
-Version: 3.1.5
+Version: 3.1.6
 Summary: Standard OpenGL bindings for Python
 Home-page: http://pyopengl.sourceforge.net
 Author: Mike C. Fletcher
 Author-email: mcfle...@vrplumber.com
 License: BSD
 Download-URL: http://sourceforge.net/projects/pyopengl/files/PyOpenGL/
-Description: PyOpenGL and PyOpenGL_Accelerate
-        =================================
-        
-        PyOpenGL is normally distributed via PyPI using standard pip::
-        
-            $ pip install PyOpenGL PyOpenGL_accelerate
-        
-        You can install this repository by branching/cloning and running
-        setup.py::
-        
-            $ cd pyopengl
-            $ python setup.py develop
-            $ cd accelerate
-            $ python setup.py develop
-        
-        Note that to compile PyOpenGL_accelerate you will need to have 
-        a functioning Python extension-compiling environment.
-        
-        Learning PyOpenGL
-        -----------------
-        
-        If you are new to PyOpenGL, you likely want to start with the 
OpenGLContext `tutorial page`_.
-        Those tutorials require OpenGLContext, (which is a big wrapper 
including a whole
-        scenegraph engine, VRML97 parser, lots of demos, etc) you can install 
that with::
-        
-            $ pip2.7 install "OpenGLContext-full==3.1.1"
-        
-        Or you can clone it (including the tutorial sources) with::
-        
-            $ git clone https://github.com/mcfletch/openglcontext.git
-        
-        or (for GitHub usage)::
-        
-            $ git clone https://github.com/mcfletch/pyopengl.git
-            
-        The `documentation pages`_ are useful for looking up the parameters 
and semantics of 
-        PyOpenGL calls.
-        
-        .. _`tutorial page`: 
http://pyopengl.sourceforge.net/context/tutorials/index.html
-        .. _`documentation pages`: 
http://pyopengl.sourceforge.net/documentation/
-        
-        
-        Running Tests
-        --------------
-        
-        You can run the PyOpenGL test suite from a source-code checkout, you 
will need:
-        
-        * git (for the checkout)
-        * GLUT (FreeGLUT)
-        * GLExtrusion library (libgle)
-        * GLU (normally available on any OpenGL-capable machine)
-        * tox (`pip install tox`)
-        
-        Running the test suite from a top-level checkout looks like::
-        
-            $ tox
-        
-        The result being a lot of tests being run in a matrix of environments.
-        All of the environment will pull in pygame, some will also pull in 
-        numpy. Some will have accelerate, and some will not.
-        
-        .. image:: https://travis-ci.org/mcfletch/pyopengl.svg?branch=master
-            :target: https://travis-ci.org/mcfletch/pyopengl
-            :alt: Travis Tests
-        
-        .. image:: 
https://ci.appveyor.com/api/projects/status/MikeCFletcher/pyopengl/branch/master
-            :target: https://ci.appveyor.com/project/MikeCFletcher/pyopengl
-            :alt: Appveyor Build
-        
-        .. image:: https://img.shields.io/pypi/v/pyopengl.svg
-            :target: https://pypi.python.org/pypi/pyopengl
-            :alt: Latest PyPI Version
-        
-        .. image:: https://img.shields.io/pypi/dm/pyopengl.svg
-            :target: https://pypi.python.org/pypi/pyopengl
-            :alt: Monthly download counter
-        
 Keywords: Graphics,3D,OpenGL,GLU,GLUT,GLE,GLX,EXT,ARB,Mesa,ctypes
 Platform: UNKNOWN
 Classifier: License :: OSI Approved :: BSD License
@@ -93,3 +16,82 @@
 Classifier: Topic :: Software Development :: Libraries :: Python Modules
 Classifier: Intended Audience :: Developers
 Description-Content-Type: text/x-rst
+
+PyOpenGL and PyOpenGL_Accelerate
+=================================
+
+PyOpenGL is normally distributed via PyPI using standard pip::
+
+    $ pip install PyOpenGL PyOpenGL_accelerate
+
+You can install this repository by branching/cloning and running
+setup.py::
+
+    $ cd pyopengl
+    $ python setup.py develop
+    $ cd accelerate
+    $ python setup.py develop
+
+Note that to compile PyOpenGL_accelerate you will need to have 
+a functioning Python extension-compiling environment.
+
+Learning PyOpenGL
+-----------------
+
+If you are new to PyOpenGL, you likely want to start with the OpenGLContext 
`tutorial page`_.
+Those tutorials require OpenGLContext, (which is a big wrapper including a 
whole
+scenegraph engine, VRML97 parser, lots of demos, etc) you can install that 
with::
+
+    $ pip2.7 install "OpenGLContext-full==3.1.1"
+
+Or you can clone it (including the tutorial sources) with::
+
+    $ git clone https://github.com/mcfletch/openglcontext.git
+
+or (for GitHub usage)::
+
+    $ git clone https://github.com/mcfletch/pyopengl.git
+    
+The `documentation pages`_ are useful for looking up the parameters and 
semantics of 
+PyOpenGL calls.
+
+.. _`tutorial page`: 
http://pyopengl.sourceforge.net/context/tutorials/index.html
+.. _`documentation pages`: http://pyopengl.sourceforge.net/documentation/
+
+
+Running Tests
+--------------
+
+You can run the PyOpenGL test suite from a source-code checkout, you will need:
+
+* git (for the checkout)
+* GLUT (FreeGLUT)
+* GLExtrusion library (libgle)
+* GLU (normally available on any OpenGL-capable machine)
+* tox (`pip install tox`)
+
+Running the test suite from a top-level checkout looks like::
+
+    $ tox
+
+The result being a lot of tests being run in a matrix of environments.
+All of the environment will pull in pygame, some will also pull in 
+numpy. Some will have accelerate, and some will not.
+
+.. image:: https://travis-ci.org/mcfletch/pyopengl.svg?branch=master
+    :target: https://travis-ci.org/mcfletch/pyopengl
+    :alt: Travis Tests
+
+.. image:: https://ci.appveyor.com/api/projects/status/github/mcfletch/pyopengl
+    :target: https://ci.appveyor.com/project/MikeCFletcher/pyopengl
+    :alt: Appveyor Build
+
+.. image:: https://img.shields.io/pypi/v/pyopengl.svg
+    :target: https://pypi.python.org/pypi/pyopengl
+    :alt: Latest PyPI Version
+
+.. image:: https://img.shields.io/pypi/dm/pyopengl.svg
+    :target: https://pypi.python.org/pypi/pyopengl
+    :alt: Monthly download counter
+
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/PyOpenGL.egg-info/SOURCES.txt 
new/PyOpenGL-3.1.6/PyOpenGL.egg-info/SOURCES.txt
--- old/PyOpenGL-3.1.5/PyOpenGL.egg-info/SOURCES.txt    2020-01-04 
03:31:05.000000000 +0100
+++ new/PyOpenGL-3.1.6/PyOpenGL.egg-info/SOURCES.txt    2022-02-20 
00:00:00.000000000 +0100
@@ -2868,6 +2868,7 @@
 src/xmlreg.py
 tests/basetestcase.py
 tests/check_crash_on_glutinit.py
+tests/check_egl_device_enumeration.py
 tests/check_egl_es1.py
 tests/check_egl_es2.py
 tests/check_egl_opengl.py
@@ -2883,6 +2884,8 @@
 tests/check_glutinit_single.py
 tests/check_glutwindow.py
 tests/check_glx.py
+tests/check_import_err.py
+tests/check_leak_on_discontiguous_array.py
 tests/egl_ext_enumerate.py
 tests/egltest.py
 tests/feedbackvarying.py
@@ -2892,6 +2895,7 @@
 tests/gh_bug6_check.py
 tests/glsl_version.py
 tests/importtests.py
+tests/linewidth.py
 tests/os_egl.py
 tests/osdemo.py
 tests/performance.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/readme.rst 
new/PyOpenGL-3.1.6/readme.rst
--- old/PyOpenGL-3.1.5/readme.rst       2019-12-28 16:27:47.000000000 +0100
+++ new/PyOpenGL-3.1.6/readme.rst       2022-02-19 23:44:47.000000000 +0100
@@ -63,7 +63,7 @@
     :target: https://travis-ci.org/mcfletch/pyopengl
     :alt: Travis Tests
 
-.. image:: 
https://ci.appveyor.com/api/projects/status/MikeCFletcher/pyopengl/branch/master
+.. image:: https://ci.appveyor.com/api/projects/status/github/mcfletch/pyopengl
     :target: https://ci.appveyor.com/project/MikeCFletcher/pyopengl
     :alt: Appveyor Build
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/check_egl_device_enumeration.py 
new/PyOpenGL-3.1.6/tests/check_egl_device_enumeration.py
--- old/PyOpenGL-3.1.5/tests/check_egl_device_enumeration.py    1970-01-01 
01:00:00.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/check_egl_device_enumeration.py    2022-02-19 
23:44:47.000000000 +0100
@@ -0,0 +1,28 @@
+#! /usr/bin/env python
+import logging
+import os_egl
+from OpenGL.EGL import *
+from OpenGL.EGL.EXT.device_enumeration import eglQueryDevicesEXT
+log = logging.getLogger(__name__)
+
+def main():
+    devices = (EGLDeviceEXT * 10)()
+    count = EGLint()
+    major, minor = EGLint(), EGLint()
+    if eglQueryDevicesEXT(10,devices,count):
+        log.info("%s devices enumerated", count)
+        for i,device in enumerate(devices[:count.value]):
+            display = eglGetDisplay(device)
+            if not eglInitialize(display,major,minor):
+                log.info("Could not initialise, skipping")
+                continue
+            log.info("Display #%d, Version %s.%s",i,major.value,minor.value)
+            for key in [
+                EGL_VENDOR,
+            ]:
+                log.info("#%d %s", i, eglQueryString(display,key))
+#        display = eglGetDisplay(EGL_DEFAULT_DISPLAY)
+
+if __name__ == "__main__":
+    logging.basicConfig(level=logging.INFO)
+    main()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/check_egl_platform_ext.py 
new/PyOpenGL-3.1.6/tests/check_egl_platform_ext.py
--- old/PyOpenGL-3.1.5/tests/check_egl_platform_ext.py  2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/check_egl_platform_ext.py  2022-02-19 
23:44:47.000000000 +0100
@@ -24,7 +24,7 @@
         )
         print(dpy)
         if EGL_1_5.eglGetPlatformDisplay:
-            dpy = platform_base.eglGetPlatformDisplay(
+            dpy = EGL_1_5.eglGetPlatformDisplay(
                 platform_gbm.EGL_PLATFORM_GBM_MESA, 
                 ctypes.c_void_p(dev), 
                 ctypes.c_void_p(0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/check_import_err.py 
new/PyOpenGL-3.1.6/tests/check_import_err.py
--- old/PyOpenGL-3.1.5/tests/check_import_err.py        1970-01-01 
01:00:00.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/check_import_err.py        2022-02-19 
23:44:47.000000000 +0100
@@ -0,0 +1,4 @@
+"""Check github #43 import error on win32 nt"""
+import logging 
+logging.basicConfig(level=DEBUG)
+from OpenGL.GLU import *
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/PyOpenGL-3.1.5/tests/check_leak_on_discontiguous_array.py 
new/PyOpenGL-3.1.6/tests/check_leak_on_discontiguous_array.py
--- old/PyOpenGL-3.1.5/tests/check_leak_on_discontiguous_array.py       
1970-01-01 01:00:00.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/check_leak_on_discontiguous_array.py       
2022-02-19 23:44:47.000000000 +0100
@@ -0,0 +1,32 @@
+"""Test for github issue #47"""
+from __future__ import print_function
+import OpenGL
+OpenGL.SIZE_1_ARRAY_UNPACK = False # just for convenience
+OpenGL.ERROR_ON_COPY = False # we are checking a leak in the copying
+import pygamegltest
+import numpy as np
+from OpenGL.GL import *
+from OpenGL.GL import shaders
+from sys import getrefcount
+
+@pygamegltest.pygametest(name="Texture image 2d leak check")
+def main():
+    data = np.zeros([256,256,3],dtype='b')
+    glEnable(GL_TEXTURE_2D)
+    textures = glGenTextures(1)
+    glBindTexture(GL_TEXTURE_2D, textures[0])
+    reversed_data = data[::-1]
+    assert not reversed_data.flags['C_CONTIGUOUS']
+    rc1 = getrefcount(reversed_data)
+    for i in range(100):
+        glTexImage2D(
+            GL_TEXTURE_2D, 
+            0, 
+            GL_RGB, 
+            256, 256, 0, GL_RGB,GL_UNSIGNED_BYTE, reversed_data)
+    rc2 = getrefcount(reversed_data)
+    assert rc1 == rc2, (rc1, rc2)
+
+
+if __name__ == "__main__":
+    main()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/egl_ext_enumerate.py 
new/PyOpenGL-3.1.6/tests/egl_ext_enumerate.py
--- old/PyOpenGL-3.1.5/tests/egl_ext_enumerate.py       2020-01-04 
03:07:10.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/egl_ext_enumerate.py       2022-02-19 
23:44:47.000000000 +0100
@@ -24,4 +24,6 @@
             print('No device_query extension available')
 
 if __name__ == "__main__":
+    import logging
+    logging.basicConfig(level=logging.DEBUG)
     main()
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/linewidth.py 
new/PyOpenGL-3.1.6/tests/linewidth.py
--- old/PyOpenGL-3.1.5/tests/linewidth.py       1970-01-01 01:00:00.000000000 
+0100
+++ new/PyOpenGL-3.1.6/tests/linewidth.py       2020-03-10 20:39:33.000000000 
+0100
@@ -0,0 +1,37 @@
+import glfw
+from OpenGL.GL import *
+if not glfw.init():
+    sys.exit()
+glfw.window_hint(glfw.SAMPLES, 4)
+glfw.window_hint(glfw.CONTEXT_VERSION_MAJOR, 1)
+glfw.window_hint(glfw.CONTEXT_VERSION_MINOR, 4)
+window = glfw.create_window(800, 600, "Hello World", None, None)
+if not window:
+    sys.exit()
+glfw.make_context_current(window)
+glEnable(GL_BLEND)
+# glDisable(GL_BLEND)
+glClearColor(1.0/255.0*68.0, 1.0/255.0*68.0, 1.0/255.0*68.0, 1.0)
+glClear(GL_COLOR_BUFFER_BIT)
+glViewport(0, 0, 800, 600)
+glMatrixMode(GL_PROJECTION)
+glLoadIdentity()
+glOrtho(0.0, 800.0, 600.0, 0.0, 0.0, 1.0)
+ 
+def drawOneLine(x1, y1, x2, y2, width):
+    glDisable(GL_LINE_SMOOTH);
+    glLineWidth(width)
+    glBegin(GL_LINES)
+    glVertex2f(x1, y1)
+    glVertex2f(x2, y2)
+    glEnd()
+   
+if __name__ == "__main__":
+    while not glfw.window_should_close(window):
+        glfw.poll_events()            
+        glClear(GL_COLOR_BUFFER_BIT)
+        for y in range(1,20):
+            drawOneLine(10,20*y+.5,100,20*y+.5,y*.5)
+        glfw.swap_buffers(window)
+    glfw.destroy_window(window)
+    glfw.terminate()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/os_egl.py 
new/PyOpenGL-3.1.6/tests/os_egl.py
--- old/PyOpenGL-3.1.5/tests/os_egl.py  2020-01-04 03:07:10.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/os_egl.py  2022-02-19 23:44:47.000000000 +0100
@@ -224,6 +224,7 @@
         glGetString,
         GL_VENDOR,
         GL_EXTENSIONS,
+        GL_VERSION,
         glFinish,
     )
 
@@ -231,6 +232,7 @@
     glClearColor(1.0, 1.0, 1.0, 1.0)
     glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)
     log.info("Vendor: %s", glGetString(GL_VENDOR))
+    log.info("Vendor: %s", glGetString(GL_VERSION))
     log.info("Extensions: %s", glGetString(GL_EXTENSIONS))
     glFinish()
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/osdemo.py 
new/PyOpenGL-3.1.6/tests/osdemo.py
--- old/PyOpenGL-3.1.5/tests/osdemo.py  2019-12-28 20:05:44.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/osdemo.py  2022-02-19 23:44:47.000000000 +0100
@@ -143,6 +143,7 @@
     z = glGetIntegerv(GL_DEPTH_BITS)
     s = glGetIntegerv(GL_STENCIL_BITS)
     a = glGetIntegerv(GL_ACCUM_RED_BITS)
+    print("OpenGL Version: %s"%(extensions.GLQuerier.getVersion()))
     print("Depth=%d Stencil=%d Accum=%d" % (z, s, a))
 
     print("Width=%d Height=%d" % (OSMesaGetIntegerv(OSMESA_WIDTH),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/test_arraydatatype.py 
new/PyOpenGL-3.1.6/tests/test_arraydatatype.py
--- old/PyOpenGL-3.1.5/tests/test_arraydatatype.py      2019-11-25 
03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/test_arraydatatype.py      2022-02-19 
23:44:47.000000000 +0100
@@ -290,6 +290,7 @@
     @pytest.mark.skipif( not np, reason="Numpy not available")
     def test_byte_count_numpy( self ):
         for a,expected in [
+            (np.array([1,2],dtype='e'),4),
             (np.array([1,2],dtype='f'),8),
             (np.array([1,2],dtype='d'),16),
             (np.array([1,2],dtype='B'),2),
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/test_core.py 
new/PyOpenGL-3.1.6/tests/test_core.py
--- old/PyOpenGL-3.1.5/tests/test_core.py       2020-01-04 03:07:10.000000000 
+0100
+++ new/PyOpenGL-3.1.6/tests/test_core.py       2022-02-19 23:44:47.000000000 
+0100
@@ -242,10 +242,13 @@
                         assert mapped.value == expected, (param, mapped, 
expected)
                     else:
                         mapped = glGetBufferParameteriv(GL_ARRAY_BUFFER, param)
-                        if param != GL_BUFFER_USAGE or 
OpenGL.SIZE_1_ARRAY_UNPACK:
-                            assert mapped == expected, (param, mapped, 
expected)
+                        if param == GL_BUFFER_USAGE:
+                            assert mapped[0] == expected, (param, mapped, 
expected)
                         else:
-                            assert mapped[0] == expected, (param, mapped[0], 
expected)
+                            if OpenGL.SIZE_1_ARRAY_UNPACK:
+                                assert mapped == expected, (param, mapped, 
expected)
+                            else:
+                                assert mapped[0] == expected, (param, 
mapped[0], expected)
             finally:
                 glBindBuffer(GL_ARRAY_BUFFER, 0)
                 glDeleteVertexArrays(1,vertex_array)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/test_vbo_memusage.py 
new/PyOpenGL-3.1.6/tests/test_vbo_memusage.py
--- old/PyOpenGL-3.1.5/tests/test_vbo_memusage.py       2020-01-04 
03:07:10.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/test_vbo_memusage.py       2022-02-19 
23:44:47.000000000 +0100
@@ -1,45 +1,54 @@
 import pygamegltest
 import os
+
 # We have to import at least *one* VBO implementation...
 from OpenGL import GL, arrays
 from OpenGL.arrays import vbo
+
 try:
     import psutil
 except ImportError:
     psutil = None
 try:
-    unicode 
+    unicode
 except NameError:
-    unicode = str 
+    unicode = str
     long = int
 import pytest
 import gc
+
 try:
     import numpy as np
 except ImportError:
     np = None
 
+
 def get_current_memory():
     return psutil.Process(os.getpid()).memory_info().rss
 
-@pytest.mark.skipif(not psutil,reason='No psutil available')
-@pytest.mark.skipif(not np,reason='No Numpy available')
+
+@pytest.mark.skipif(not psutil, reason="No psutil available")
+@pytest.mark.skipif(not np, reason="No Numpy available")
 @pygamegltest.pygametest()
 def test_sf_2980896():
     """Test SF#2980896 report of memory leak on VBO transfer"""
     data = arrays.GLfloatArray.zeros((1000,))
     memory = get_current_memory()
-    for i in range(100): 
+    for i in range(100):
         new_vbo = vbo.VBO(data)
         with new_vbo:
             # data is transferred to the VBO
             assert new_vbo is not None, new_vbo
         new_vbo.delete()
-        del new_vbo 
+        del new_vbo
         gc.collect()
         GL.glFinish()
-        if i  < 1: 
+        if i < 1:
             # the *first* call can load lots of libraries, etc...
             memory = get_current_memory()
         else:
-            assert get_current_memory() - memory < 200, """Shouldn't have any 
(or at least much) extra RAM allocated..."""
+            current = get_current_memory()
+            assert current - memory < 200, (
+                """Shouldn't have any (or at least much) extra RAM allocated, 
lost: %s"""
+                % (current - memory)
+            )  # fails only when run in the whole suite...
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/PyOpenGL-3.1.5/tests/tests.py 
new/PyOpenGL-3.1.6/tests/tests.py
--- old/PyOpenGL-3.1.5/tests/tests.py   2019-11-25 03:18:31.000000000 +0100
+++ new/PyOpenGL-3.1.6/tests/tests.py   2022-02-19 23:44:47.000000000 +0100
@@ -8,13 +8,15 @@
 
 PYTHONS = [
     # order is so that most-important platforms are checked first
+    'python3.10',
+    'python3.9',
+    'python3.8',
+    'python3.6',
     'python2.7',
-    'python3.4',
-    'python3.3',
     # python2.6 support is less important than the above at this point,
     # and doing a --user install clobbers 2.7's version of the packages
     # should use a virtualenv for all of them, really...
-    'python2.6', 
+    #'python2.6', 
 ]
 PYGAME_SOURCE = os.path.join( HERE, '.pygame' )
 

Reply via email to