Hi all,

I have 12 bit gray images and want them to use as transparent textures.
What method would be the best if you look at speed and/or memory ? (I
will have about 60-100 images of format 512x512, so it's hard work for
my graphics card and memory bus)

1) convert it to RGBA format and use ImageComponent.FORMAT_RGBA.

2) convert it to an individual Format of 2 byte components (one for
alpha, one for gray value) and use ImageComponent.FORMAT_LUM8_ALPHA8 and
color object white (or black ? ) ?

3) convert it to 1 byte format and use it twice with format
FORMAT_CHANNEL8 (one time used as gray value (= luminance ?) and one
time used as alpha value) and combine the textures ?

Do I have to convert it into a byte format at all ?

Any other suggestions ?


This is a bit off topic but can I define a BandedSampleModel e.g. like
this:

new BandedSampleModel( DataBuffer.TYPE_BYTE, width, height, width, new
int[ ]{ 0 }, new int[ ]{ 0, 0, 0, 0 } ) ?

Then I could define only one bank in (DataBuffer object) with
DataBuffer.TYPE_BYTE (If I must convert) and use this bank for all color
bands (should save a quarter of memory !).

regards
Paul

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to