Setting colour depth on a per-user basis?

Setting colour depth on a per-user basis?

Post by Jonathan Searl » Fri, 02 Feb 2001 06:40:21



Students in my lab run various apps on a central SGI IRIX and HP-UX
system, which each then display graphical output simultaneously on
multiple remote Redat 7 linux boxes.

Some of these server apps only generate their remote graphics
correctly if the linux boxes are in an 8-bit color depth.  If set to
higher depths they either generate fatal colormap errors or just
generate screwed-up and non-usable colors.  We only have binaries of
the server apps, so have to work with them as they are.

However, on other occasions, the students want the linux screens set
in the highest color depth possible (eg when using GIMP, StarOffice,
etc)

One possible neat solution seemed to me to set different color depths
for different user accounts on each box.

Does anyone know if that's possible and how I should go about setting
it up?

Or is there a more elegant way of doing this?

 We did consider using CTRL-ALT-PLUS/MINUS to cycle through
preconfigured color depths, but this proved too unwieldy and
confusing....

 
 
 

Setting colour depth on a per-user basis?

Post by Tim Robert » Sat, 03 Feb 2001 13:48:01



>However, on other occasions, the students want the linux screens set
>in the highest color depth possible (eg when using GIMP, StarOffice,
>etc)

>One possible neat solution seemed to me to set different color depths
>for different user accounts on each box.

>Does anyone know if that's possible and how I should go about setting
>it up?

Are the users launching the server after they log in?  startx/xinit look in
~/.xserverrc to find the command to execute to run the server.  For a
student who always wants an 8-bit screen, ~/.xserverrc could contain
   #! /bin/sh  
  /etc/X11/X -depth 8 $*
while the student who wants a 24-bit screen could have:
   #! /bin/sh
  /etc/X11/X -depth 24 $*

Is that the kind of thing you were looking for?
--

  Providenza & Boekelheide, Inc.

 
 
 

Setting colour depth on a per-user basis?

Post by Jonathan Searl » Sun, 04 Feb 2001 17:33:03




Quote:

>Are the users launching the server after they log in?  startx/xinit look in
>~/.xserverrc to find the command to execute to run the server.  For a
>student who always wants an 8-bit screen, ~/.xserverrc could contain
>   #! /bin/sh  
>  /etc/X11/X -depth 8 $*
>while the student who wants a 24-bit screen could have:
>   #! /bin/sh
>  /etc/X11/X -depth 24 $*

>Is that the kind of thing you were looking for?

Thanks for the suggestion. it is indeed exactly the sort of thing I'm
looking for.

Sadly, I've tried your suggestion and it doesn't seem to work. The
desktop stays in the colour depth determined at system install/setup.
Probably because the users aren't manually launching X, but having it
done for them by gdm when they logon.  The configuration of each
system is pretty much a standard RedHat 7.0 gnome workstation, hence
using gdm for logins.

From looking at the process list it seems to me that gdm launches X
for a particular user after he logs on.  The startup parameters passed
to that  X session are the std ones from the gdm configuration, rather
than the ones in the ~/.xserverrc file.  So perhaps you suggestion is
on the right lines, I just need to find a way to do it that is picked
up by gdm when it initiates the new X server and session for that
user.

Jonathan Searle
Cranfield University

 
 
 

Setting colour depth on a per-user basis?

Post by Tim Robert » Mon, 05 Feb 2001 15:29:46



>Sadly, I've tried your suggestion and it doesn't seem to work. The
>desktop stays in the colour depth determined at system install/setup.
>Probably because the users aren't manually launching X, but having it
>done for them by gdm when they logon.

Yes, I should have mentioned that.  When you're using an xdm derivative for
logging in, the server is launched at boot time, and therefore uses
whatever the default depth is in XF86Config.

Quote:>From looking at the process list it seems to me that gdm launches X
>for a particular user after he logs on.

No, X is launched BEFORE the user logs on.  gdm is just an X application; X
has to be launched before gdm can display itself.  I don't think you get a
chance to intervene before the X server restarts itself.

One way to make this work is to get rid of gdm and switch to a text-mode
login (which you do by changing the initdefault in /etc/inittab).  You
could add startx to /etc/profile so that X is automatically started during
the login process.
--

  Providenza & Boekelheide, Inc.

 
 
 

Setting colour depth on a per-user basis?

Post by John Harri » Mon, 02 Apr 2001 13:10:23


Quote:> >However, on other occasions, the students want the linux screens set
> >in the highest color depth possible (eg when using GIMP, StarOffice,
> >etc)

> Are the users launching the server after they log in?  startx/xinit look in
> ~/.xserverrc to find the command to execute to run the server.  For a
> student who always wants an 8-bit screen, ~/.xserverrc could contain
>    #! /bin/sh
>   /etc/X11/X -depth 8 $*
> while the student who wants a 24-bit screen could have:
>    #! /bin/sh
>   /etc/X11/X -depth 24 $*

> Is that the kind of thing you were looking for?

I have the same problem, only on Sun boxes.  What makes me wonder though, is
that
the Sun boxes that have "Sun" graphics cards will have more than one "visual"
if you
look at "xdpyinfo".  On the Sun boxes, I usually have 6 different visuals,
with various
depths and color maps associated with them.  On my Linux boxes and my Sun
boxes
that have PC style graphics cards, xdpyinfo shows me only one visual.  The Sun
--
mult-visual boxes have no trouble running apps that require 8 bit plans at the
same
time as apps using 16 or 24 plans.  No switching...  Does anyone know what's
going
on here?

John Harris

 
 
 

1. IP accounting on a per-user basis, rather than per IP address.

I would like to be able to set up an Internet connection for one of our
offices using a Linux system as a firewall. Okay, this is easy enough
using ipfwadm which supports packet logging as well.

Problem: Management are saying: "Great, but we need to keep track of how
much each user accesses the Internet, you can only give us data on what
each /machine/ is doing - not good enough."

Their solution is to install MS Proxy Server on one of the NT servers.
I really, really don't want to have MS Poxy Server on any of my
machines!

Any ideas?

PS, Ideally I want to be able to track access by NT user account, but I
can probably kludge that up with Samba, if I can get accounting
happening on a Linux user account basis.

Lionel.
--
Grep bait: qmail, Archimedes Plutonium, turkey, Kibo, Wollmann, Meow.
Grep bait de jour: Theresa Willis, Terri
Perna condita delenda est. Agree? - See http://www.ybecker.net/pink/
 "Some people are alive only because it is illegal to kill them."

2. telnet through socks

3. Denying finger requests on per-user basis?

4. QUESTION: SunAda and XView

5. Different PAM modules on a per-user basis?

6. XFree86 for S3 ViRGE?

7. Is it possible to limit bandwidth on a per-user basis with cbq.init script?

8. TCP WRAPPER Like utility for NT

9. Setting sendmail "From:" field on a per user basis?

10. Restricting ftp directory access on a per user basis

11. restricting ftp on a per user basis

12. Raising ulimit's on a per user basis in Linux

13. MAXLOGINS on a per users basis