Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Khaos Dragon

wierd blending artifact

This topic is 5156 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Whenever I use glEnable( GL_BLEND ); glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); over a series of polygons, the outlines of each polygon are transparent for some reason. For obvious reasons, this is an undesired result. Is there anyway to avoid this. The reason I am doing this because I have alpha textures over some of my models and some areas of the texture need to be blended with their respective alpha values.

Share this post


Link to post
Share on other sites
Advertisement
Isn''t blending used to achieve transparency??
You should rephrase your question,what you''ve said doesn''t make much sense,at least to me.State exactly what you want to accomplish,how you do it,and what is the problem.Maybe even post a screenshot of the artifacts.

Share this post


Link to post
Share on other sites
Yes I am using the blending to achieve transparency on pixels in my textures that have alpha values. However I also get unwanted transparency on the "outline" of each polygon for some reason.

Here is a screen to show you what I mean, normally the map isn''t blended but I am using Enable( GL_BLEND ); glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA ); on the map to show how you can see through the outlines, despite the fact that the map texture has no alpha values whatsoever.

Share this post


Link to post
Share on other sites
I don''t get it.If you don''t want your outlines to be transparent,then why don''t you simply disable blending when you''re drawing them?And enable it when you really need it?

Share this post


Link to post
Share on other sites
well for example, do you see that house... It has one texture overlayed on it. If I would the windows to be transparent as I eventually will, I have to have blending on for more than one polygon, which means all the polygons used to draw the house will have outlines...But I don't want the outlines to show, and it makes no sense to me why they should show.

[edited by - Khaos Dragon on June 9, 2004 5:59:46 PM]

[edited by - Khaos Dragon on June 9, 2004 6:00:18 PM]

Share this post


Link to post
Share on other sites
Wait a minute...you say that you don't want outlines to show at all?I thought you drew them explicitly and your problem was that they're transparent.

[edited by - mikeman on June 9, 2004 6:09:33 PM]

Share this post


Link to post
Share on other sites
I don''t think we can help you,man.All you say is "when I enable blending,I have outlines showing".We have no idea what your rendering context is.I don''t know,post some code.

Share this post


Link to post
Share on other sites
Ah I finally found the culprit... glEnable( GL_POLYGON_SMOOTH ); It turns out that while blending with multiple polygons with this enabled, outlines will not be drawn.

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!