PDA

View Full Version : glBlendFunc



alark
07-09-2003, 09:53 AM
Hi,
I am using alpha blending, but I can still see the background through some slices nearer to my eye. I did try setting glDepthFunc() to different values, but it doesnt make a difference(it either looks the same or for some values I get a blank window). Please could you help.

Thanks,
Alark

roffe
07-09-2003, 12:19 PM
Originally posted by alark:
Hi,
I did try setting glDepthFunc() to different
I am assuming glDepthFunc() is a "typo". You probably want to use glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA). You requested/allocated an alpha buffer,correct?

jwatte
07-09-2003, 12:56 PM
You don't need an alpha buffer to use SRC_ALPHA.

However, the question is so imprecise that it's impossible to determine what the problem is, or what could cause it.

roffe
07-09-2003, 03:06 PM
Originally posted by jwatte:
You don't need an alpha buffer to use SRC_ALPHA.

Of course, you are right. What was I thinking.


[This message has been edited by roffe (edited 07-09-2003).]

errno
07-10-2003, 10:41 PM
check your near frustum plane. if the slice are nearest than this plane, they won't be displayed and you'llo see the background.