Python Raspberry Pi上的Kivy:将提供者从EGL更改为SDL2?
在我的Raspberry Pi上运行Kivy应用程序会得到如下输出:Python Raspberry Pi上的Kivy:将提供者从EGL更改为SDL2?,python,kivy,raspberry-pi3,Python,Kivy,Raspberry Pi3,在我的Raspberry Pi上运行Kivy应用程序会得到如下输出: [INFO ] [Logger ] Record log in /home/pi/.kivy/logs/kivy_16-04-26_23.txt [INFO ] [Kivy ] v1.9.2-dev0 [INFO ] [Python ] v2.7.9 (default, Mar 8 2015, 00:52:26) [GCC 4.9.2] [INFO ] [Factory
[INFO ] [Logger ] Record log in /home/pi/.kivy/logs/kivy_16-04-26_23.txt
[INFO ] [Kivy ] v1.9.2-dev0
[INFO ] [Python ] v2.7.9 (default, Mar 8 2015, 00:52:26)
[GCC 4.9.2]
[INFO ] [Factory ] 193 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_gif, img_pygame, img_pil (img_ffpyplayer ignored)
[INFO ] [Text ] Provider: pygame
[INFO ] [Window ] Provider: egl_rpi
[INFO ] [GL ] OpenGL version <OpenGL ES 2.0>
[INFO ] [GL ] OpenGL vendor <Broadcom>
[INFO ] [GL ] OpenGL renderer <VideoCore IV HW>
[INFO ] [GL ] OpenGL parsed version: 2, 0
[INFO ] [GL ] Shading version <OpenGL ES GLSL ES 1.00>
[INFO ] [GL ] Texture max size <2048>
[INFO ] [GL ] Texture max units <8>
[INFO ] [Shader ] fragment shader: <Compiled>
[INFO ] [Shader ] vertex shader: <Compiled>
[INFO ] [Window ] virtual keyboard not allowed, single mode, not docked
[INFO ] [OSC ] using <multiprocessing> for socket
[INFO ] [Base ] Start application main loop
[INFO ] [GL ] NPOT texture support is available
我的问题是:如何在Pi上将Kivy的提供程序更改为SDL2?将以下代码行添加到Python文件的顶部应将提供程序切换为SDL2
import os
os.environ['KIVY_WINDOW'] = 'sdl2'
参考:
我和你有同样的问题,没有显示带有egl\u rpi
的窗口。我切换到SDL2
,但应用程序无法加载。我相信这是因为我的3.5英寸SPI显示器有一个定制的驱动程序。也许你的视频驱动程序会更好
import os
os.environ['KIVY_WINDOW'] = 'sdl2'