PDA

View Full Version : Alpha channel affectation



Vinnie
11-29-2000, 04:15 AM
Hi,

I need to affect, change or clear the Alpha componant.
I know it works cause I can see the result on the screen with BLEND but why the glReadPixels always give me a value equal to 255 !?!?

Vinnie

jc
11-29-2000, 05:33 AM
what format do you use in the glreadpixel function ???

Vinnie
11-29-2000, 05:47 AM
I'm using the format GL_RGBA

Serge K
11-29-2000, 08:30 PM
Looks like similar problem :
glReadPixels on GeForce2 (http://www.opengl.org/discussion_boards/ubb/Forum3/HTML/001365.html) .

> I know it works cause I can see the result on the screen with BLEND

??? What do you mean?
Alpha blending works without alpha channel in the color buffer (if you don't use _DST_ALPHA).

Vinnie
11-30-2000, 01:58 AM
>> I know it works cause I can see the result >>on the screen with BLEND

>??? What do you mean?

I made an operation with glblendfunc using the alpha componant and it works.
I just can't read something different than 255 with glReadPixels

I'm on a SGI o2
Vinnie

DFrey
11-30-2000, 04:52 AM
Does your pixel format include a destination alpha buffer? If not, then obviously, the alpha is not being read back because it doesn't exist.