Multiseat hardware accelerated setup with one graphics card.

... offonoffoffonoff at gmail.com
Sun Jan 26 19:15:57 PST 2014


Hi all,

I am interested in making a multiseat gaming system with only one graphics
card.  As of now, I have a two terminal system, one of which is capable of
playing games requiring opengl.  The other is just a web browser.  I just
wanted to share what I've done, what I'm thinking, and ask for input from
those here who know more than me.

PROBLEM:
Multiseat set ups on only one graphics card must rely on Xephyr, which does
not do hardware accelerated opengl (not sure if this is true), thus games
will not run through Xephyr.

SOLUTION:
Use xorg.conf to set up two distinct screens.

Use Xephyr (must have evdev support built in, which not all repo versions
do) on only one screen.  It grabs one mouse and one keyboard (leaving the
others for the main X session), and displays its non-accelerated output on
one screen.  The other screen is controlled by X directly, and uses the
graphics card as normal.

I start this up using the following commands:

$ sudo /usr/bin/X -config xorg.conf.multiseat &

$ DISPLAY=:0.0 java -jar /home/imauser/Games/Minecraft.jar &

$ DISPLAY=:0.1 sudo ./multiseat/Xephyr :2 -fullscreen -dpms -keybd
"evdev,,device=/dev/input/by-id/usb-Dell_Dell_USB_Keyboard-event-kbd,'xkbrules=xorg,xkbmodel=evdev,xkblayout=us'"
-mouse
"evdev,,device=/dev/input/by-id/usb-413c_Dell_Premium_USB_Optical_Mouse-event-mouse"
&

$ DISPLAY=:2 firefox &

notes: I have two different xorg configuration files, because when not
running in multiseat, I want on virtual screen.  For multiseat, I want two
distinct screens. ./multiseat/Xephyr refers to a binary version I
downloaded which already has evdev support compiled into it.  found it
here: http://code.google.com/p/multiseat-wizard-bicefalo/ (script did not
work for me but I stole the binary from it).

NEXT STEPS:

Xephyr really doesn't seem needed at all.  All it does here is divert part
of the input stream to a particular window, and the cost of this is that it
controls the display also and prevents hardware rendering of opengl.  I'd
like to see if

1) there is a way to make Xephyr hardware render?

2) there is a way to not use Xephyr, and instead have some other
application direct which mouse and keyboard input is directed to which
application.  I would be happy to have this be a one application per screen
setup (ie: no window manager).

Towards #2, there is a way to have two individual mice, and assign a second
keyboard:
http://ao2.it/en/blog/2010/01/19/poor-mans-multi-touch-using-multiple-mice-xorg

Perhaps there is a way to use xlib (or python-xlib) to direct the focus of
these two sets of input.  Or maybe it is possible to use k-drive to simply
control input streams and pass its video rendering onto X directly.

I will do a write up on this if I make any progress beyond this.

Thanks all,
  Elliot


(1) is this true?  Its hard to tell from google.  It seems like a feature
that has been put in and taken out again, and which never worked all that
well.

$ DISPLAY=:0.1 sudo /usr/bin/Xephyr :100 -screen 1280x1024 -dpms &
$ DISPLAY=:100 glxinfo | grep render
Xlib:  extension "NV-GLX" missing on display ":100".
direct rendering: No (If you want to find out why, try setting
LIBGL_DEBUG=verbose)
OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 3.2, 128 bits)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg/attachments/20140126/d35e36b7/attachment.html>


More information about the xorg mailing list