How to do a Quick, Dirty bloom effect FAST!

I am trying to add a bloom effect by copying the back buffer to a texture, apply a scale and bias to make it grayscale, and downsample it to make it pixelated. However there are no examples of this on the 'net, any better ways (not using fbos or pbos or pbuffers), or examples of how to do this?

You could render the scene (with exaggerated lighting if necessary) to a small viewport (say 64x64), copy that to a texture, then draw scaled using linear filtering over the top of your full sized scene using additive blending.

The minus is the need to render your scene twice, but pluses are that a small texture is faster to copy and you don't have to do anything 'clever' in terms of downsampling or blurring.

None of those will work, Im trying to go without extensions for now.
I get a white screen with glCopyTexSubImage2d, I am allocating memory but it refuses to work. I also looked at the Ocean demo, but that does hideous glReadBuffer ops.

In regards to the original post... no idea. But in response to the reply... You could just render it once, scale it down into a new texture, and scale that back up. I'd imagine it'd be a lot faster than rendering twice. The results would look different, but probably not significantly?

There was a tutorial once that explained how to do this. If you would like to search for it, the article was called "Real-Time "TRON 2.0" Glow For Low-Spec Hardware". It's pretty fast, works without any extensions and you can leave out different parts such as the multiplication of the source image or the blur to make it faster.

_ibd_ Wrote:There was a tutorial once that explained how to do this. If you would like to search for it, the article was called "Real-Time "TRON 2.0" Glow For Low-Spec Hardware". It's pretty fast, works without any extensions and you can leave out different parts such as the multiplication of the source image or the blur to make it faster.

I searched for it but found only dead links.

Quote:BTW, why don't you want to use any FBOs?

No matter what the reason is, glCopyTexSubImage is an alternative. It is not as fast as using FBOs, but it is the best choice I know if you must work without FBOs. But you will also need to do (fake) some degree of filtering. Just using a low-res texture can't be enough.

I did a halfway faked glow. I tried doing it the "real" way until I found that the GMA GPU can't do FP buffers. Then I rendered the scene with an offset to put the low ranges under 0, and filtered that with shaders. Worked OK, but doesn't quite fit the demands above.

Just stretching a copy over the previous frame will not work: everything will be pushed outwards toward the edges. Try it in Photoshop or GIMP, you'll see why immediately. I feel obligated to question why you're not using EXTs - fixed pipeline is dead and slow. The modern approaches are not expensive, and much easier to use. Let go of the ringside, man!

Fenris Wrote:Just stretching a copy over the previous frame will not work: everything will be pushed outwards toward the edges. Try it in Photoshop or GIMP, you'll see why immediately. I feel obligated to question why you're not using EXTs - fixed pipeline is dead and slow. The modern approaches are not expensive, and much easier to use. Let go of the ringside, man!

_ibd_ Wrote:There was a tutorial once that explained how to do this. If you would like to search for it, the article was called "Real-Time "TRON 2.0" Glow For Low-Spec Hardware". It's pretty fast, works without any extensions and you can leave out different parts such as the multiplication of the source image or the blur to make it faster.