darn glBlend
ok, my program uses OpenGL. At the beginning of my program I call glEnable(GL_BLEND) because this seems to be the only was to draw the different objects in my world with keeping the colors correct. well, the colors are correct, but the objects are transparent. do I need to disable GL_BLEND before I draw a polygon and then re-enable it again? is there some function I''m missing? I''ve reviewed tutorials and books and found nothing.
Thanks,
Joe
JoeMont001@aol.com
quote:Original post by Julio
At the beginning of my program I call glEnable(GL_BLEND) because this seems to be the only was to draw the different objects in my world with keeping the colors correct.
The way to draw your colors correctly is DISABLING blend. Use blending when you want transparency. What happens with your colors when you disable blending?
Nicodemus.
----
"When everything goes well, something will go wrong." - Murphy
ya. well, when I disable it, (when I don''t call it at the beggining) it draws the textures fine, then it draws the colored polygons black.
Thanks,
Joe
JoeMont001@aol.com
Thanks,
Joe
JoeMont001@aol.com
Before you draw your colored polygons, disable GL_TEXTURE_2D. They get black because OpenGL tries to apply a texture to them (That I think you set glBindTexture to texture 0).
Nicodemus.
----
"When everything goes well, something will go wrong." - Murphy
Nicodemus.
----
"When everything goes well, something will go wrong." - Murphy
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement