File: check_init_framebufferarb.py

package info (click to toggle)
pyopengl 3.1.10%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 15,024 kB
  • sloc: python: 108,056; sh: 13; makefile: 8
file content (26 lines) | stat: -rw-r--r-- 585 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import pygame as pg
import OpenGL

OpenGL.setPlatform("wayland")
import OpenGL.GL
from pygame.locals import *
from OpenGL.GL import *
from OpenGL.GLU import *
from OpenGL.GL.ARB.framebuffer_object import glInitFramebufferObjectARB


def main():
    pg.init()
    pg.display.set_mode((50, 50), DOUBLEBUF | OPENGL)
    pg.display.init()
    OpenGL.GL.glGetString(OpenGL.GL.GL_VERSION)
    if not glInitFramebufferObjectARB:
        print("SKIP")
        return
    print(glInitFramebufferObjectARB())
    print(OpenGL.__version__)
    print('OK')


if __name__ == "__main__":
    main()