Question about fullscreen
tmr83 opened this issue · 12 comments
I believe SDL requests the stretch on the GPU (called the renderer in the code), if you have a working driver. Because it did not happen, it's some kind of system issue. Could you share the sdl.txt file? Explain the details of your driver and system environment.
What happened with issue #227?
=== Seven Kingdoms 2.15.5 ===
Platform: Linux
Little endian
Current SDL video driver: x11
SDL version: 2.0.22
Compiled SDL version: 2.0.22
-- Video drivers --
0: x11
1: wayland
2: KMSDRM
3: dummy
-- Current window --
Active on display: 0
Geometry: 800x600 @ (323, 75)
Pixel format: SDL_PIXELFORMAT_RGB888
Full screen: no
Input grabbed: yes
-- Current renderer: opengl --
Viewport: x=0,y=0,w=800,h=600
Scale: xscale=1.000000,yscale=1.000000
Logical size: w=800, h=600
Capabilities: hardware accelerated
V-sync: off
Rendering to texture supported: yes
Maximum texture size: 8192x8192
Pixel formats:
SDL_PIXELFORMAT_ARGB8888
SDL_PIXELFORMAT_ABGR8888
SDL_PIXELFORMAT_RGB888
SDL_PIXELFORMAT_BGR888
SDL_PIXELFORMAT_YV12
SDL_PIXELFORMAT_IYUV
SDL_PIXELFORMAT_NV12
SDL_PIXELFORMAT_NV21
-- Streaming texture --
Size: 800x600
Pixel format: SDL_PIXELFORMAT_RGB888
-- Display 0 using mode 0--
Mode 0: 1366x768x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f3fa0
Mode 1: 1280x720x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc64aabc0
Mode 2: 1280x720x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f0130
Mode 3: 1024x768x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f77e0
Mode 4: 1024x768x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc57cd0d0
Mode 5: 1024x576x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f3ec0
Mode 6: 1024x576x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63eccf0
Mode 7: 960x720x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f8cd0
Mode 8: 960x600x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6452910
Mode 9: 960x540x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc64097c0
Mode 10: 960x540x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc60240f0
Mode 11: 928x696x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc64a6530
Mode 12: 896x672x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63fbd70
Mode 13: 864x486x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6403d80
Mode 14: 840x525x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f4bb0
Mode 15: 800x600x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6457d30
Mode 16: 800x600x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f2d30
Mode 17: 800x600x24bpp 56Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6406b10
Mode 18: 800x450x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6021440
Mode 19: 720x405x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6403c40
Mode 20: 720x405x24bpp 59Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63edfa0
Mode 21: 700x525x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f48b0
Mode 22: 700x450x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc64066e0
Mode 23: 684x384x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63edfe0
Mode 24: 640x512x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc64064a0
Mode 25: 640x480x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f5cf0
Mode 26: 640x480x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6403c00
Mode 27: 640x400x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6407d10
Mode 28: 640x360x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6407d50
Mode 29: 640x360x24bpp 60Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63efbf0
Mode 30: 640x360x24bpp 59Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63efc30
Mode 31: 512x384x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc57ccf40
Mode 32: 512x288x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc57ccf80
Mode 33: 480x270x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f85d0
Mode 34: 480x270x24bpp 119Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f8260
Mode 35: 432x243x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc65739b0
Mode 36: 432x243x24bpp 119Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc65739f0
Mode 37: 400x300x24bpp 121Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f8fc0
Mode 38: 400x300x24bpp 113Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f9c20
Mode 39: 360x202x24bpp 119Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6573bd0
Mode 40: 360x202x24bpp 118Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f2a50
Mode 41: 320x240x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc6573b90
Mode 42: 320x180x24bpp 120Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc63f2a90
Mode 43: 320x180x24bpp 119Hz format=SDL_PIXELFORMAT_RGB888 driver=0x558bc65737d0
DPI: diag=118.371483 horiz=96.000000 vert=96.000000
Bounds: x=0 y=0 w=1366 h=768
Usable bounds: x=0 y=32 w=1366 h=704
-- Renderer opengl (0) --
Capabilities: hardware accelerated
V-sync capable: on
Rendering to texture supported: yes
Pixel formats:
SDL_PIXELFORMAT_ARGB8888
SDL_PIXELFORMAT_ABGR8888
SDL_PIXELFORMAT_RGB888
SDL_PIXELFORMAT_BGR888
-- Renderer opengles2 (1) --
Capabilities: hardware accelerated
V-sync capable: on
Rendering to texture supported: yes
Pixel formats:
SDL_PIXELFORMAT_ARGB8888
SDL_PIXELFORMAT_ABGR8888
SDL_PIXELFORMAT_RGB888
SDL_PIXELFORMAT_BGR888
-- Renderer software (2) --
Capabilities: software fallback
V-sync capable: on
Rendering to texture supported: yes
Pixel formats:
SDL_PIXELFORMAT_ARGB8888
SDL_PIXELFORMAT_ABGR8888
SDL_PIXELFORMAT_RGBA8888
SDL_PIXELFORMAT_BGRA8888
SDL_PIXELFORMAT_RGB888
SDL_PIXELFORMAT_BGR888
SDL_PIXELFORMAT_RGB565
SDL_PIXELFORMAT_RGB555
I am using a mostly stock Arch Linux install with gnome shell 42.1, gdm, and Mesa.
glxinfo | grep OpenGL
OpenGL vendor string: Intel
OpenGL renderer string: Mesa Intel(R) HD Graphics (ILK)
OpenGL version string: 2.1 Mesa 22.0.4
OpenGL shading language version string: 1.20
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 2.0 Mesa 22.0.4
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 1.0.16
OpenGL ES profile extensions:
You will have to be specific about what information you want If I provided the incorrect info. And issue #227 happened again this morning, so I was going through the logs to try to find something out about it, but I wasn't sure which entries were from 7kaa, so I tried to trigger the issue again and again but wasn't able to yet.
Can you run on a different window manager? (no gnome shell) Something very basic.
I don't think the game is causing this.
I will try installing the LXDE group and let you know. I can tell you now that logging into gnome with wayland fixes the issue.
With LXDE, sometimes it goes into fullscreen normally, and sometimes it does not. I am seeing this in the log:
dbus-daemon[1543]: [session uid=1000 pid=1543] Activating service name='org.gnome.ScreenSaver' requested by ':1.64' (uid=1000 pid=4731 comm="src/7kaa")
dbus-daemon[1543]: [session uid=1000 pid=1543] Successfully activated service 'org.gnome.ScreenSaver
I just do not know how to deactivate a d-bus service. I will try to switch from GDM now.
Don't deactive dbus. I am not familiar enough with LXDE to know if it is a compositing window manager.
However, an issue with LXDE does imply the issue is probably in the Intel graphics driver. I wonder if this is a regression.
If you want to try one more time, I would suggest fvwm, jwm, icewm, or something based on openbox. These are pretty simple and won't demand much from the graphics driver.
LXDE is based on openbox and does not enable compositing by default (on Arch).
OK. So LXDE in Arch might be a friendly Arch-centric fork to modernize it to GTK3. Which may make it GNOME based anyway. So please pick something that is not based on GNOME (suggested fvwm, jwm, icewm, etc), and not heavily tweaked in the Arch community.
I tried icewm, and it basically stays in fullscreen mode, but I am able to move the window around.
You used to have a working game correct? What systems have you run on successfully? Did this one used to work? Please downgrade until it is working again. One idea is to downgrade SDL2 to version 2.0.20 or earlier. What were you running one year ago? Other things to look at are Xorg-server and Mesa.
Downgrading to sdl2 2.0.20-1 fixed the issue.
So the fullscreen issue you have I can see with the latest version of SDL2, 2.0.22. Running 2.0.20 is fine. This is sort of a regression with SDL2, a minor one for 7kaa when running under linux, but some people had additional issues under windows. This issue and others were filed with SDL2, one seen here libsdl-org/SDL#5457. This might be also fixed in the latest git for SDL2. Please take this to upstream with the Arch team. I think they should back down to SDL2 2.0.20 at least. For issue #227, you should downgrade to at least 2.0.20 or earlier and see if it also related.