From: Kevin.Dennen++at++rttc.army.mil
Date: 05/22/2001 13:11:22
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
---------------------------------------------
This archive was generated by hypermail 2b29 : Tue May 22 2001 - 13:11:37 PDT