Re: Alpha-only textures

New Message Reply Date view Thread view Subject view Author view

Angus Dorbie (dorbie++at++sgi.com)
Thu, 09 Apr 1998 15:16:48 -0700


DANIEL BASS wrote:
>
> Hi Performers,
>
> For my application, I want to create a texture map which consists of a series of
> silhouettes, stored as different alpha values. Then by setting an appropriate
> alpha reference value and alpha function, I can choose which sillhouette to use.
> The polygon I attach this to, I just want black and z-buffered, so it just hides or
> doesn't hide things behind it.
>
> So my question is, what is the most efficient way to store and use a set of these
> textures? Since I am only really using 8 bits of interest, can I somehow use the
> Texture environment channel select feature and overlay 4 different textures
> in a single RGBA image?
>
> P.S. For what its worth, my application is running on an O2, with Performer 2.0

You could use the GL_ALPHA8 token for the components which is probably
best
on O2, on ONYX2 you probably want to use GL_DUAL_ALPHA8_SGIS.

For occlusion information unless you need 8 bits fo rthe blend you
should
consider even smaller formats like GL_QUAD_ALPHA4_SGIS.

You need to select which bits of the image you want to address for the
DUAL & QUAD formats using glTexParameter with
GL_DUAL_TEXTURE_SELECT_SGIS
or GL_QUAD_TEXTURE_SELECT_SGIS tokens.

Cheers,Angus.

-- 
"Only the mediocre are always at their best." -- Jean Giraudoux 

For advanced 3D graphics Performer + OpenGL based examples and tutors: http://www.dorbie.com/ ======================================================================= List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/ Submissions: info-performer++at++sgi.com Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:57:14 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.