Re: Alpha bits hosing things up

New Message Reply Date view Thread view Subject view Author view

From: Angus Dorbie (dorbie++at++sgi.com)
Date: 05/22/2001 13:27:17


It may be getting resized because the additional component makes it too
large a texture for your platform.

The band may be the base of the treeline wraping on the top. Reducing
the resolution could cause this to be more pronounced due to larger
texels. Try setting the setRepeat method to set the PFTEX_WRAP_T to
PFTEX_CLAMP. you may want to leave PFTEX_WRAP_S as PFTEX_REPEAT.

Cheers,Angus.

Kevin.Dennen++at++rttc.army.mil wrote:
>
> Performers,
>
> I am trying to use a 12 bit textured treeline in an OpenFlight
> database. Thanks to some help from various sources at NVL and MPI, I
> am getting around the 8 bit texture limitation of the flight model.
> The performer calls I am making are:
>
> ...
>
> tex->setImage( ( unsigned int*)image, nc, sx, sy, 1 );
> tex->setFormat(PFTEX_IMAGE_FORMAT, PFTEX_LUMINANCE_ALPHA );
> tex->setFormat(PFTEX_INTERNAL_FORMAT, PFTEX_I_12A_4 );
> tex->setFormat(PFTEX_EXTERNAL_FORMAT, PFTEX_PACK16 );
> tex->setFilter( PFTEX_MINFILTER, PFTEX_BILINEAR );
>
> ...
> My treeline texture is an unsigned int with the upper 12 bits
> representing my intensity( This is an infrared simulation ) and the
> lower 4 bits either 0 or 15 for fully transparent or fully opaque.
> If I change the image format to PFTEX_LUMINANCE, then the treeline
> appears correctly except, of course, there is no alpha. But with the
> image format set to PFTEX_LUMINANCE_ALPHA, my treeline gets squashed
> down to about 1/4 the size it should be and there is some sort of band
> across the top. Does anyone know why changing the internal format
> would cause this problem?
> Is it a problem with my texture setup or the way I am rendering the
> texture? Appreciate the help.
>
> KD
>
> KD
> ---------------------------------------------
>
> Kevin Dennen
> Senior Staff Engineer
> ERC, Inc.
> (256) 842-2030
> kdennen++at++rttc.redstone.army.mil
>
> "Do not worry about your difficulties in Mathematics. I can assure you
> mine are still greater." - Albert Einstein
> ---------------------------------------------
>
> -----------------------------------------------------------------------
> List Archives, FAQ, FTP: 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

-- 
For Performer+OpenGL tutorials http://www.dorbie.com/

"Whenever there is a conflict between human rights and property rights, human rights must prevail." --Abraham Lincoln


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Tue May 22 2001 - 13:27:51 PDT

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