Sign in to follow this  
Ajare

Glowing lines

Recommended Posts

I'm trying to find a simple way of creating glowing lines. I read a paper about creating glow - rendering to a texture and then blurring - but this seems like overkill, and considering the thinness of lines, the blur will probably look weird. I don't really want to draw lots of blended lines on top of each other, either. Just wondering if anyone's got a good technique.

Share this post


Link to post
Share on other sites
Your best bet is billboarding. Use a textured quad as long as you need it to be, and the width of the blur. The texture should be a constant color, but with a gradient alpha. Keep in mind that you can save space by making the texture only 1 pixel high, since all the values will be the same in that direction. Then, just render the quad with the appropriate size and length.

Share this post


Link to post
Share on other sites
Alternatively, and probably slower:
You could render lines to a texture, then process them with a fragmentprogram/pixelshader to blur the texture, then blend the blured lines texture with scene.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this