Versions
Python: 2.7.13
OS: Raspian Jessie
Kivy: v1.10.1.dev0, git-8776f28, 20180123
RPi: 3
Description I am migrating an operational kivy app from Android using the same resources now on Raspberry Pi that is failing to display images in the kivy screen manager. I asked on the kivy forum but was told to use KivyPie, which I did but got the same results. My configuration is NOOBS, manually installed Kivy for Raspian Jessie, on a Raspberry Pi 3. I will also ask this same question on the OpenGL forum.
In the log after starting my app, the following sections appear regarding OpenGL and Shader (see attached ‘python main.py -c kivy:log_level:trace’ file). It appears these are working and setup.py reports the library files are in the /opt/vc/lib/ folder.
[INFO ] [GL ] Using the "OpenGL ES 2" graphics system
[DEBUG ] [GL ] glShaderBinary is not available
[INFO ] [GL ] Backend used
[INFO ] [GL ] OpenGL version <OpenGL ES 2.0>
[INFO ] [GL ] OpenGL vendor
[INFO ] [GL ] OpenGL renderer
[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>
[DEBUG ] [Shader ] Fragment compiled successfully
[DEBUG ] [Shader ] Vertex compiled successfully
After my app starts displaying images through screenmanager, the following error appears in the same log (invalid operation):
glGetError 0x502
After 7 of these invalid operation error messages, the following error appears (out-of-memory):
Exception: FBO Initialization failed: Incomplete attachment (36054)
Exception Exception: Exception('FBO Initialization failed: Incomplete attachment (36054)',) in 'kivy.graphics.fbo.Fbo.raise_exception' ignored
glGetError 0x505
After 3 of these Exeption messages, my app crashes with the following end of process regarding Fbo and Shader:
File "/home/pi/kivy/kivy/uix/screenmanager.py", line 508, in add_screen self.fbo_out = self.make_screen_fbo(self.screen_out)
File "/home/pi/kivy/kivy/uix/screenmanager.py", line 472, in make_screen_fbo
fbo = Fbo(size=screen.size, with_stencilbuffer=True)
File "kivy/graphics/fbo.pyx", line 152, in kivy.graphics.fbo.Fbo.init
File "kivy/graphics/instructions.pyx", line 753, in kivy.graphics.instructions.RenderContext.init
File "kivy/graphics/shader.pyx", line 184, in kivy.graphics.shader.Shader.init
File "kivy/graphics/shader.pyx", line 695, in kivy.graphics.shader.Shader.vs.set
File "kivy/graphics/shader.pyx", line 555, in kivy.graphics.shader.Shader.build_vertex
File "kivy/graphics/shader.pyx", line 585, in kivy.graphics.shader.Shader.link_program
Exception: Shader didnt link, check info log.
I’ve searched anywhere I can to find any clues to what to do but below are the attempts to find a solution, unsuccessfully.
I have updated the rpi gpu memory as displayed below:
/boot/config.txt: gpu_mem=512
One comment suggested generating a listing, as attempted below, but I received the error instead.
[email]pi@goddard-rpi:~/.kivy[/email]/logs $ glxinfo -l
Error: unable to open display
I get the following response when running setup.py:
Detected Cython version 0.27.3
Using this graphics system: OpenGL ES 2
GStreamer found via pkg-config
SDL2 found via pkg-config
Found brcmEGL and brcmGLES library filesfor rpi platform at /opt/vc/lib/
SDL2: found SDL header at /usr/include/SDL2/SDL.h
SDL2: found SDL_mixer header at /usr/include/SDL2/SDL_mixer.h
SDL2: found SDL_ttf header at /usr/include/SDL2/SDL_ttf.h
SDL2: found SDL_image header at /usr/include/SDL2/SDL_image.h
Please let me know what to do to solve this error and app crashing.