MLM Veraart (Veraart++at++fel.tno.nl)
Fri, 22 Oct 1999 15:19:35 +0100
You can use glColorTableSGI(GL_TEXTURE_COLOR_TABLE_SGI, ...) to select a color
table to be applied to the samples taken from the texture.
You call this function in the drawcallback or in the node drawcallback.
Select a monochroom one to translate the texture colors to grey values.
Examples can be seen at http://www.dorbie.com in the section about infrared
rendering.
Mario Veraart
> Mark E. Wear
> Senior Electronic Systems Engineer:
> Real-Time Simulation
> Lockheed Martin Missiles and Fire Control
> (972) 603-2758
> mark.wear++at++lmco.com
>
> > ----------
> > > I need to be able to render both color and monochrome versions of the
> > same
> > > OpenFlight model simultaneously. I would like to derive the monochrome
> > > version from a model with color texture during initialization. Are there
> > any
> > > shortcuts to doing this?
> > >
> > > Thanks,
> > > Mark
> >
> > I suggest you modify the color table at runtime. Is it possible that you
> > use
> > two separate channels (one color, one monochrome)? That way you won't
> > have to
> > toggle the state every time you draw the object.
> >
> > You might also be able to do this by using color conversion while doing a
> > glCopyPixel but even if it is possible, it would probably be slower than
> > using
> > the color table.
> >
> > regards, Sylvain
This archive was generated by hypermail 2.0b2 on Fri Oct 22 1999 - 06:20:15 PDT