blur question..
Still got so much to learn when it comes to opengl but i was trying to get my head around how id add a blur to my game.
Im after that sorta blur that is normally around the edges of a flame for example not sure what they call it.
Having real difficulty understanding how to do it with what i know currently so simpler the method the better :D. I want to distort the image slightly not alot and in random places a bit like that effect you get in quake when you go under water.
Just after a nice simple starting point. One idea i did have but i dont know how to implement this,
1. Id some how copy everything that is currently being displayed into a texture
2. Have an alpha map with the parts of the screen i want blurred
3. blur the texture
4. combine my new blurred texture with my alpha map
5. draw a giant quad over the screen with the new texture
Its something id love to know how to do but quite simply dont have a clue at the moment.
thx alot for any help.
FBO and glsl is the solution
take a screen capture with fbo and the do all the blur in glsl
then draw to screen aligned quad
take a screen capture with fbo and the do all the blur in glsl
then draw to screen aligned quad
forgive my stupidity but i dont even know what they are..
Whats the best starting place for getting into those two ?
cheers
Whats the best starting place for getting into those two ?
cheers
Why not try using the accumulation buffer? I have read in many GL books you can do blur with it. I haven't used it myself so I dont know it is performance wise. Maybe one of the MANY experienced GL coders here will help ya.
No, do not use accumulation buffer, as on most pc it is very slow.
If you don't know fbo and glsl, you could try render-to-texture, nehe(http://nehe.gamedev.net/) has a tutorial on this.
If you don't know fbo and glsl, you could try render-to-texture, nehe(http://nehe.gamedev.net/) has a tutorial on this.
I don't know if you have read this recent thread, if you haven't go through it--it deals with some of the options you have.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement