From: Performer Newsgroup (csklu_pf++at++yahoo.com)
Date: 08/29/2002 17:05:32
What behaviour do you want? Do you want to clip the
values above 0.9 or scale all values by 0.9. For the
latter case you could use glPixelTransfer to set a
red/green/blue scale factor that affects all pixel
transfer operations thereafter. The problem with this
is then you have to call glCopyPixels or something
similar so the pixel operations take place. This of
course may affect your performance significantly.
--- Jürgen Gotschlich <juergen.gotschlich++at++dlr.de>
wrote:
> Hi performer,
>
> I need a hint, how to limit the color values of an
> application to a
> specific threshold, e.g. to make sure that no pixels
> are drawn with
> R,G,B-values above 0.9, if this is the threshold.
> So, all pixels with
> color-values from 0.9-1.0 need to be limited to 0.9.
>
> Here are some general thoughts:
>
> Is it possible to do this with an overall function,
> independent of the
> actual scenery ? How much does this affect the
> performance. Is it better
> to reduce the limit-functions to specific objects ?
>
> My application is using lots of DECALed textured
> objects. If I make
> sure, that these textures only have limited
> pixel-values, then no
> shading or lighting, etc. should change these
> values. Is that right ? So
> this would be a 'pre-offline-check', nothing to do
> inside performer, but
> a lot of work outside.
>
> But what about the MODULATEd textures ? The
> color-values will change
> according to the lighting model. I played around
> with basic gl-routines
> like glBlendFunc, glBlendEquation, etc. but no
> result. May be I didn't
> use them correctly.
>
> Maybe there's another way via performer shader
> (chapter 10 in the Perf.
> Prog. Guide) ? But I don't understand how to
> implement.
>
> So, what is the best way ? Any hints are welcome.
>
> Juergen
> --
>
________________________________________________________________________
>
> Jürgen Gotschlich email:
> juergen.gotschlich++at++dlr.de __/|_
> Phone: +49(531)295-3248/2778
> /_/_/_/
> Fax : +49(531)295-2640
> |/ DLR
>
> Deutsches Zentrum für Luft-und Raumfahrt | German
> Aerospace Center
> Institut für Flugsystemtechnik | Inst. of
> Flight Research
> Abt. Flugsimulation | Flight
> Simulation Dep.
> Lilienthalplatz 7 |
> Lilienthalplatz 7
> D-38108 Braunschweig | D-38108
> Braunschweig, Germany
>
________________________________________________________________________
>
>
-----------------------------------------------------------------------
> List Archives, Info, FAQ:
> http://www.sgi.com/software/performer/
> Open Development Project:
> http://oss.sgi.com/projects/performer/
> Submissions: info-performer++at++sgi.com
> Admin. requests:
> info-performer-request++at++sgi.com
>
-----------------------------------------------------------------------
>
__________________________________________________
Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes
http://finance.yahoo.com
This archive was generated by hypermail 2b29 : Thu Aug 29 2002 - 17:05:41 PDT