Bug 364729 - Breaks age of empires 2
Summary: Breaks age of empires 2
Status: RESOLVED WORKSFORME
Alias: None
Product: kwin
Classification: Plasma
Component: scene-opengl (show other bugs)
Version: 5.6.4
Platform: Debian unstable Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-25 00:01 UTC by Salvo "LtWorf" Tomaselli
Modified: 2021-11-07 09:01 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Photo of the problem (349.13 KB, image/jpeg)
2016-06-25 00:01 UTC, Salvo "LtWorf" Tomaselli
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Salvo "LtWorf" Tomaselli 2016-06-25 00:01:01 UTC
I play Age of empires 2 with wine. It's an old game and it changes the resolution of the screen.

Until 3 months ago it worked fine. Now half the screen becomes black and half of the image goes out of the screen.

Reproducible: Always

Steps to Reproduce:
1. Play age of empires 2
Comment 1 Salvo "LtWorf" Tomaselli 2016-06-25 00:01:29 UTC
Created attachment 99682 [details]
Photo of the problem
Comment 2 Thomas Lübking 2016-06-25 07:25:36 UTC
(I doubt this is a kwin bug at all)

check "xrandr -q" while the game is running ("sleep 30; xrandr -q", start the game and wati > 30 seconds ;-)

Does the game run via steam?
Comment 3 Salvo "LtWorf" Tomaselli 2016-06-25 21:59:10 UTC
The game doesn't run with steam.

Also, sometimes it works, but pressing F12 to open yakuake will reset the resolution (before it used to remain the same resolution), and after giving the focus again to the window, it will be half out of the screen, but on the left rather than on the top.


Screen 0: minimum 8 x 8, current 1366 x 768, maximum 32767 x 32767
LVDS1 connected primary 1024x768+0+0 (normal left inverted right x axis y axis) 344mm x 193mm
   1366x768      60.04 +
   1360x768      59.80    59.96  
   1280x720      60.00  
   1024x768      60.00* 
   1024x576      60.00  
   960x540       60.00  
   800x600       60.32    56.25  
   864x486       60.00  
   640x480       59.94  
   720x405       60.00  
   680x384       60.00  
   640x360       60.00  
DP1 disconnected (normal left inverted right x axis y axis)
HDMI1 disconnected (normal left inverted right x axis y axis)
VGA1 disconnected (normal left inverted right x axis y axis)
VIRTUAL1 disconnected (normal left inverted right x axis y axis)
Comment 4 Thomas Lübking 2016-06-25 22:19:36 UTC
The resolution is totally fucked up.

You've a  1366x768 screen, run it at 1024x768 (likely because that's the games resolution) but the root window (ie. the workspace viewport) is still 1366x768

If the game doesn't grab the mouse, you should be able to shift the viewport by moving the mouse to the screen edges.

Try running
xrandr --output LVDS1 --mode 1024x768
aoe2.sh  # ie. the game, ensure it doesn't fork so the next line isn't reached before you quit
xrandr --output LVDS1 --auto

There's a chance that this is caused by the kscreen daemon ("kcmshell5 kded", deactivate it in doubt) but most likely, the game (wine?) simply fails to set the resolution (probably because it desires 4:3 but you're on 16:9)
It's not kwin related, though.
Comment 5 Salvo "LtWorf" Tomaselli 2016-06-26 16:58:20 UTC
Did not solve the issue.

I can assure you that I have been playing this game for years with wine, and I started having problems when the new plasma and qt arrived on debian.
Comment 6 Thomas Lübking 2016-06-26 17:03:14 UTC
What's the "xrandr -q" output under that altered condition?
I can only assure that kwin doesn't control the screen resolution :-P
Comment 7 Martin Flöser 2016-08-27 15:31:33 UTC
This looks similar to bug 367770

Can you try to suspend the compositor (Alt+shift+f12) before starting the game?
Comment 8 kde.org 2021-11-06 17:33:33 UTC
This issue report is quite old. Can you please confirm, that it still persists with KDE 5.23?
Comment 9 Salvo "LtWorf" Tomaselli 2021-11-07 07:46:27 UTC
To be honest it stopped working in wine… so I have no idea.
Comment 10 kde.org 2021-11-07 09:01:19 UTC
Unable to reproduce the issue. No point in keeping this open.