Re: [PATCH xwayland] xwayland: Add hack for FWXGA resolution #99574
On Fri, 2017-02-03 at 02:41 -0500, Olivier Fourdan wrote: > > For some applications (like fullscreen games) it matters for XRandr > > resolution to be correctly set and equal to root window resolution. > > > > In XServer there is already hack for this, adapted it for XWayland. > > > > Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=99574 > > > > Signed-off-by: Svitozar Cherepii> Acked-by: Olivier Fourdan remote: I: patch #136706 updated using rev 1c78bec9ca3cd1975a38bf5ebdba7dea65b309ab. remote: I: 1 patch(es) updated to state Accepted. To ssh://git.freedesktop.org/git/xorg/xserver 542d9f6..1c78bec master -> master - ajax ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH xwayland] xwayland: Add hack for FWXGA resolution #99574
> For some applications (like fullscreen games) it matters for XRandr > resolution to be correctly set and equal to root window resolution. > > In XServer there is already hack for this, adapted it for XWayland. > > Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=99574 > > Signed-off-by: Svitozar Cherepii> --- > hw/xwayland/xwayland-cvt.c | 7 +++ > 1 file changed, 7 insertions(+) > > diff --git a/hw/xwayland/xwayland-cvt.c b/hw/xwayland/xwayland-cvt.c > index 9655e104e..8564fdbae 100644 > --- a/hw/xwayland/xwayland-cvt.c > +++ b/hw/xwayland/xwayland-cvt.c > @@ -296,6 +296,13 @@ xwayland_cvt(int HDisplay, int VDisplay, float VRefresh, > Bool Reduced, > if (Interlaced) > modeinfo.modeFlags |= RR_Interlace; > > +/* FWXGA hack adapted from hw/xfree86/modes/xf86EdidModes.c, because you > can't say 1366 */ > +if (HDisplay == 1366 && VDisplay == 768) { > + modeinfo.width = 1366; > + modeinfo.hSyncStart--; > + modeinfo.hSyncEnd--; > +} > + > snprintf(name, sizeof name, "%dx%d", > modeinfo.width, modeinfo.height); > modeinfo.nameLength = strlen(name); > -- > 2.11.0 LGTM. Acked-by: Olivier Fourdan ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
Re: [PATCH xwayland] xwayland: Add hack for FWXGA resolution #99574
Tested-by: Svitozar CherepiiI tested it on my Arch (GNU/Linux) x86_64 with this patch only applied on 1.19.1 release version: > pacman -Qi xorg-server-xwayland > Name: xorg-server-xwayland > Version : 1.19.1-1 > Description : run X clients under wayland > Architecture: x86_64 > URL : http://xorg.freedesktop.org > Licenses: custom > Groups : xorg > Provides: None > Depends On : libxfont2 libepoxy libunwind libsystemd libgl pixman > xorg-server-common > Optional Deps : None > Required By : gdm > Optional For: None > Conflicts With : None > Replaces: None > Installed Size : 2.07 MiB > Packager: Unknown Packager > Build Date : Fri Feb 3 01:28:58 2017 > Install Date: Fri Feb 3 01:30:40 2017 > Install Reason : Installed as a dependency for another package > Install Script : No > Validated By: None ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel
[PATCH xwayland] xwayland: Add hack for FWXGA resolution #99574
For some applications (like fullscreen games) it matters for XRandr resolution to be correctly set and equal to root window resolution. In XServer there is already hack for this, adapted it for XWayland. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=99574 Signed-off-by: Svitozar Cherepii--- hw/xwayland/xwayland-cvt.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/xwayland/xwayland-cvt.c b/hw/xwayland/xwayland-cvt.c index 9655e104e..8564fdbae 100644 --- a/hw/xwayland/xwayland-cvt.c +++ b/hw/xwayland/xwayland-cvt.c @@ -296,6 +296,13 @@ xwayland_cvt(int HDisplay, int VDisplay, float VRefresh, Bool Reduced, if (Interlaced) modeinfo.modeFlags |= RR_Interlace; +/* FWXGA hack adapted from hw/xfree86/modes/xf86EdidModes.c, because you can't say 1366 */ +if (HDisplay == 1366 && VDisplay == 768) { + modeinfo.width = 1366; + modeinfo.hSyncStart--; + modeinfo.hSyncEnd--; +} + snprintf(name, sizeof name, "%dx%d", modeinfo.width, modeinfo.height); modeinfo.nameLength = strlen(name); -- 2.11.0 ___ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: https://lists.x.org/mailman/listinfo/xorg-devel