Newsgroups: comp.sys.sgi Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!hobbes.physics.uiowa.edu!news.iastate.edu!ux1.cso.uiuc.edu!yoyodyne!marcc From: marcc@yoyodyne.ncsa.uiuc.edu (Marc Cooper) Subject: getmcolor() on VGX's Message-ID: <1991Jun24.142930.29853@ux1.cso.uiuc.edu> Sender: usenet@ux1.cso.uiuc.edu (News) Organization: National Center for Supercomputing Applications at Urbana Illinois Date: Mon, 24 Jun 1991 14:29:30 GMT Lines: 37 Here's an interesting little problem: It was recently my pleasure (right) to convert an 8 bit GL program to 24 bit. Wanting to take the path of least resistence, thus freeing me from redoing all the nifty pallette manipulation stuff that was already there, I simply wrote a routine I called rbgcolor() that took the place of color() It looks something like the following: rbgcolor(int index) { short r,g,b; getmcolor(index,&r,&g,&b); RGBcolor(r,g,b); } wallah! 24 bit color! (This was madified to do lighting and depthcuing and other stuff, so it isn't quite as pointless as it looks..) Anyway, it works just fine on my PI. But when I go run it on a VGX, the r,g, and b values all come back 0. There was something in the manual about the last 256 entries in the map being used for gamma corrections, but I'm starting my map at 512 (just after the system colors). And again, this works just fine on a PI. It fails on VGX machines. Any hints, clues, etc? -Marc Cooper marcc@ncsa.uiuc.edu