Sign in to follow this  
Mathy

[SlimDX] Some kind of glow effect?

Recommended Posts

Mathy    104
Is it possible to render some kind of glow effect through a vertex or pixel shader or other methods? If so, how? I am using SlimDX.

Share this post


Link to post
Share on other sites
Mathy    104
Alright, so let's say I want to use the Glow Shader code here, that I had already found earlier:

http://www.steelskies.com/article/4/directx-shader-effects#

How do I implement that into SlimDX? I already know a lot about how HSLS works, but how do I use it correctly?

Share this post


Link to post
Share on other sites
jpetrie    13104
It depends -- you have to look at the shader's code, see what kinds of parameters it expects, and then give those parameters to the Effect object you created with the shader code before rendering with that effect.

Share this post


Link to post
Share on other sites
Mathy    104
Quote:
Original post by jpetrie
It depends -- you have to look at the shader's code, see what kinds of parameters it expects, and then give those parameters to the Effect object you created with the shader code before rendering with that effect.


It wants some texture coordinates. However, I'm not using textures. Actually, it's a wireframed model, and the lines generated by the wireframe are the ones I need to glow.

Share this post


Link to post
Share on other sites
jpetrie    13104
Well, you're going to have quite a bit of work ahead of you then. You should focus on reading and understanding the concepts behind the technique they are employing, then you can better understand how to adapt it to your own code.

Many glow effects are implemented by rendering glow sources (in your case, the lines) into a texture, and then blurring that texture and using it in a second rendering pass (for example). I know of no (practical) way to make a glow effect without using textures or extra geometry though -- and of the two of those, the latter is likely to be more efficient.

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