Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kivy for python 3 detect OpenGL as 1.1 on windows 10/7 #5248

Closed
srudyanto opened this issue Jun 29, 2017 · 23 comments
Closed

Kivy for python 3 detect OpenGL as 1.1 on windows 10/7 #5248

srudyanto opened this issue Jun 29, 2017 · 23 comments

Comments

@srudyanto
Copy link

srudyanto commented Jun 29, 2017

Versions

  • Python: 3.6
  • OS: Windows 10/7 64bit
  • Kivy: 1.10.0
  • Kivy installation method: pip

Description

I try to running kivy for python 3 on windows 7 but get this error
Open GL detected as 1.1, actually using opengl viewer it is 3.1
This issue not found on kivy for python 2.7 for windows or kivy for python 3 for ubuntu

Code and Logs

from kivy.app import App
from kivy.uix.button import Button

class TestApp(App):
    def build(self):
        return Button(text='Hello World')

TestApp().run()
@KeyWeeUsr
Copy link
Contributor

What happens if you add this before the first line of your code?

from kivy import Config
Config.set('graphics', 'multisamples', '0')

@srudyanto
Copy link
Author

srudyanto commented Jun 29, 2017

nothing happened.
(clock) D:\anaconda project\clock>Scripts\python main.py
[INFO ] [Logger ] Record log in C:\Users\Yen.kivy\logs\kivy_17-06-29_9.txt
[INFO ] [Kivy ] v1.10.1.dev0, git-a4116a5, 20170507
[INFO ] [Python ] v3.6.1 |Anaconda 4.4.0 (64-bit)| (default, May 11 2017, 13:25:24) [MSC v.1900 64 bit (AMD64)]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_sdl2, img_pil, img_gif (img_ffpyplayer ignored)
[INFO ] [OSC ] using for socket
[INFO ] [Window ] Provider: sdl2
[INFO ] [GL ] Using the "OpenGL" graphics system
[INFO ] [GL ] GLEW initialization succeeded
[INFO ] [GL ] No framebuffers extension is supported
[INFO ] [GL ] Backend used
[INFO ] [GL ] OpenGL version <b'1.1.0'>
[INFO ] [GL ] OpenGL vendor <b'Microsoft Corporation'>
[INFO ] [GL ] OpenGL renderer <b'GDI Generic'>
[INFO ] [GL ] OpenGL parsed version: 1, 1
[CRITICAL] [GL ] Minimum required OpenGL version (2.0) NOT found!

OpenGL version detected: 1.1

Version: b'1.1.0'
Vendor: b'Microsoft Corporation'
Renderer: b'GDI Generic'

Try upgrading your graphics drivers and/or your graphics hardware in case of problems.

The application will leave now.

@srudyanto
Copy link
Author

I just try in windows 7 32 bit with python 3.6. It's worked

@dessant
Copy link
Contributor

dessant commented Jun 29, 2017

Ah, Anaconda. There are a couple of issues opened for their Python distribution not always working with Kivy.

@srudyanto
Copy link
Author

I just fresh install python 3.6 and the problem still remain.

(hello) D:\anaconda project\hello>Scripts\python main.py
[INFO ] [Logger ] Record log in C:\Users\Yen.kivy\logs\kivy_17-06-29_10.txt
[INFO ] [Kivy ] v1.10.0
[INFO ] [Python ] v3.6.1 (v3.6.1:69c0db5, Mar 21 2017, 17:54:52) [MSC v.1900 32 bit (Intel)]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_sdl2, img_gif (img_pil, img_ffpyplayer ignored)
[INFO ] [Text ] Provider: sdl2
[INFO ] [OSC ] using for socket
[INFO ] [Window ] Provider: sdl2
[INFO ] [GL ] Using the "OpenGL" graphics system
[INFO ] [GL ] GLEW initialization succeeded
[INFO ] [GL ] No framebuffers extension is supported
[INFO ] [GL ] Backend used
[INFO ] [GL ] OpenGL version <b'1.1.0'>
[INFO ] [GL ] OpenGL vendor <b'Microsoft Corporation'>
[INFO ] [GL ] OpenGL renderer <b'GDI Generic'>
[INFO ] [GL ] OpenGL parsed version: 1, 1
[CRITICAL] [GL ] Minimum required OpenGL version (2.0) NOT found!

OpenGL version detected: 1.1

Version: b'1.1.0'
Vendor: b'Microsoft Corporation'
Renderer: b'GDI Generic'

Try upgrading your graphics drivers and/or your graphics hardware in case of problems.

The application will leave now.

@dessant
Copy link
Contributor

dessant commented Jun 29, 2017

Anaconda crashes regardless of the Windows/Python bitness combination, while the official Python distribution only has issues when the 32 bit version is executed on a 64 bit Windows?

@srudyanto
Copy link
Author

at the last attempt, I use python36 not anaconda bundle, and the problem still there

@srudyanto
Copy link
Author

Please accept my apologize, my mistake to download wrong version of python 36. This is the correct one and the problem still there.

(hello) D:\anaconda project\hello>scripts\python main.py
[INFO ] [Logger ] Record log in C:\Users\Yen.kivy\logs\kivy_17-06-29_14.txt
[INFO ] [Kivy ] v1.10.0
[INFO ] [Python ] v3.6.1 (v3.6.1:69c0db5, Mar 21 2017, 18:41:36) [MSC v.1900 64 bit (AMD64)]
[INFO ] [Factory ] 194 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_sdl2, img_gif (img_pil, img_ffpyplayer ignored)
[INFO ] [Text ] Provider: sdl2
[INFO ] [OSC ] using for socket
[INFO ] [Window ] Provider: sdl2
[INFO ] [GL ] Using the "OpenGL" graphics system
[INFO ] [GL ] GLEW initialization succeeded
[INFO ] [GL ] No framebuffers extension is supported
[INFO ] [GL ] Backend used
[INFO ] [GL ] OpenGL version <b'1.1.0'>
[INFO ] [GL ] OpenGL vendor <b'Microsoft Corporation'>
[INFO ] [GL ] OpenGL renderer <b'GDI Generic'>
[INFO ] [GL ] OpenGL parsed version: 1, 1
[CRITICAL] [GL ] Minimum required OpenGL version (2.0) NOT found!

OpenGL version detected: 1.1

Version: b'1.1.0'
Vendor: b'Microsoft Corporation'
Renderer: b'GDI Generic'

Try upgrading your graphics drivers and/or your graphics hardware in case of problems.

The application will leave now.

@srudyanto
Copy link
Author

Somehow after reinstall python and using SET KIVY_GL_BACKEND=angle_sdl2 (I also used this method before and failed). Finally it's working. Thanks everyone for the support.
Case Closed

@KeyWeeUsr
Copy link
Contributor

KeyWeeUsr commented Jun 29, 2017

@srudyanto I see (hello) D:\anaconda project\hello>scripts\python main.py like in virtualenv. Before I only thought that's some kind of mistake, but now... try to install kivy normally, without virtualenv and run it normally (without angle, don't even install it for this test). I think it might be just an issue with the virtualenv and anaconda/virtualenv somehow removed the openGL libs from the path for you which resulted in this OpenGL 1.1 error.

What you may try with the current distribution before trying a non-virtualenv one is this:

echo %PATH%

if there's no C:\Windows\System32 (that's where the `opengl32.dll" and other important libs are) in there, do this:

set PATH=C:\Windows\System32;%PATH%

if there is that path, do this:

set

to show all env vars and look if anaconda doesn't use some special path for its libs. Then just run it.

@RibraX
Copy link

RibraX commented Mar 6, 2018

Angle backend for py3.5+. In the command line, I make this:

pip install kivy.deps.angle
set KIVY_GL_BACKEND=angle_sdl2

And change multisamples key value in config file (%HOMEPATH%.kivy\config.ini for me) from multisamples = 2 to multisamples = 0.

It works perfectly on windows 10.

@Archanciel
Copy link

Did not work for me on Windows 10 although I have OpenGL 3.1 !

snap1

@ShardulNalegave
Copy link

I had the same problem and solved it by running this in the cmd -

    pip install kivy.deps.angle && set KIVY_GL_BACKEND=angle_sdl2

@Ruithlzz09
Copy link

I am windows 10 user having opengl above 2.0 and face same problem and resolve it using help from ----

[link] (https://stackoverflow.com/questions/34969990/kivy-does-not-detect-opengl-2-0)

  1. right click on This PC then open Properties .
  2. go to Advanced system settings .
  3. click on Environment Variables .
  4. click on New in User variables for --- .
  5. put KIVY_GL_BACKEND in Variable name .
  6. put angle_sdl2 in Variable value

@rem-git-50
Copy link

Thank you, Ruithlzz09. It also works on Windows 10 in combination with opengl 1.1 !

@Archanciel
Copy link

WARNING: after you executed pip install kivy.deps.angle and you added the KIVY_GL_BACKEND environment variable as described above by Ruithlzz09, you must restart Pycharm in order for the solution to work !

@thunderking2111
Copy link

but isn't this a temporary solution, just for our system. what if this happens with the customer's pc? customer is not gonna go through the trouble of doing this much of settings. so is there any permanent solution? like adding new opengl libraries with the bundled files of our app or something like that?

@HeaTTheatR
Copy link

@thunderking2111
I constantly encounter a similar error on modern computers with the latest updates and the newest version of OpenGL. And you have to do this crutch set KIVY_GL_BACKEND = angle_sdl2 ( I never found another solution...

@TukangM
Copy link

TukangM commented Mar 23, 2022

help
image
i have opengl 2.1 but detect as 1.1 but i try
import os
os.environ['KIVY_GL_BACKEND'] = 'angle_sdl2'
the app blank

without import os os.environkivvy_gl_backed=angle sdl2
image

@LUISMAGAIVER341
Copy link

LUISMAGAIVER341 commented Nov 27, 2022

Hi!
@TukangM , did you have writed something on the kivy's code?
Well, to debug the code correctly, you need to activate the venv, and the
kivy's environment.
If the venv and the environment is activated, and the the software doens't worked(And you do the method), you(probally) have some problems with venv & environment.
Try to import the kivy.deps.angle library and put this import os os.environ['KIVY_GL_BACKEND'] = 'angle_sdl2' into the code.
This should work to everyone.
And, @TukangM , can you send the code plz?

@TukangM
Copy link

TukangM commented Dec 1, 2022

Hi! @TukangM , did you have writed something on the kivy's code? Well, to debug the code correctly, you need to activate the venv, and the kivy's environment. If the venv and the environment is activated, and the the software doens't worked(And you do the method), you(probally) have some problems with venv & environment. Try to import the kivy.deps.angle library and put this import os os.environ['KIVY_GL_BACKEND'] = 'angle_sdl2' into the code. This should work to everyone. And, @TukangM , can you send the code plz?

oh. hi. sorry for long respond (4 days). umm maybe this is bad news. the bad news is i dont use kivy and python for coding. (i just bored and wanted try coding python). the great news i just make own custom linux os (hehe)

@LUISMAGAIVER341
Copy link

@TukangM Ahoy!
Dont desist of python. It offers much things
You can install all kivy dependencies, and install pygame and cython!
I tried, and it worked!
if u want i can talk it more detailed.
But kivy/python apps is a good way to create a distro, with your own apps, and features.

@LUISMAGAIVER341
Copy link

Probally you dont see anything(only dark) because you dont writted nothing else

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests