Colour maps

Rasjid Wilcox rasjidw at bigpond.com
Sat Dec 1 00:12:59 EST 2001


On Tue, 19 Mar 2002 9:10 pm, Jeremy wrote:
> For those games that need 16 or 8 bit colour depth on the X server.  Is
> there any tricky way to get them to run, maybe using Xnest or
> something?  I can't believe I need to edit my Xconfig to play the game.

I have not tried this (tm), but from man Xnest:
[option] -depth int
         This  option  specifies  the  default  visual depth of the nested 
server.  The depth of the default visual of the nested server need not be the 
same as the depth of the default visual of the real server; although, it has 
to  be supported  by  the  real  server.   See  xdpyinfo for a list of 
supported visual depths on the real server before starting Xnest.

> Failing that could someone rattle off the right way to start an X
> server on another 'vterm', say vt8?

I frequently have a couple of versions of X running - my main one with 
Xinerama, and sometimes another in single screen mode for games etc (since 
the Matrox G400 does not support DRI and Xinerama simultaneously).

I tend to run the programs requiring DRI directly from xinit, as it saves 
having two window managers running etc.

For example:

$ cat /usr/local/bin/armagetron
#!/bin/bash

cd /usr/local/games/armagetron

/usr/X11R6/bin/xinit ./armagetron -- :`/usr/local/bin/nextdisplay` 
-xf86config XF86Config.800

[note: the above two lines should be a single line]


Where /usr/local/bin/nextdisplay is:

$ cat /usr/local/bin/nextdisplay
#!/bin/bash
displayfound="n"
while [ x"$displayfound" = x"n" ]
do
        if ! [ -f /tmp/.X$n-lock ]
        then displayfound="y"
        fi
        n=$((n+1))
done
echo $n


and XF86Config.800 is an XF86Config file with Xinerama turned off and the 
screen resolution reduced to 800x600.

Each new instance of X will just appear on a higher vterm.

Alternately, you could edit /etc/X11/xdm/Xservers (if using xdm / kdm) or the 
[servers] section of /etc/X11/gdm/gdm.conf to have additional servers (with 
possibly different configurations) started by [x|k|g]dm.

I'm sure there are other possibilities too.  ;-)

Cheers,

Rasjid.




More information about the linux mailing list