visible 'beam' light

Hi agian,
I am looking to create a visible ‘beam’ light. The light will work similar to a spot light, however the cone of the light will be visible so that you can view the light. Think about a high powered (police) spot light or a flash light in fog.

I have tryed to think of ways to do this, but the only way I can really think of is making a semi transparent cone with the same color as the light. How ever, while I have never tryed. I have heard transparency does not work well with deferred rendering…

Any ideas??

An idea:
“resolve” the deferred solid render onto the backbuffer (as you would do usually). Copy the depth-buffer to backbuffer depth (or to FBO) - so that the transparent fragments you’ll be rendering now will need both their Z-value and the Z from the scene. The difference between those Z can directly be used for per-pixel fog, for instance. Draw the cone, backface culling enabled, blending enabled. Clamp the difference to the expected width of the cone-light (transformed) - might need some interesting maths, and this way you’ll get alpha for the blending.

Or just draw simple cones with blending the way transparency is done in deferred renderers. (again doing a “resolve” of solid color, then drawing the blended stuff in a regular-rendering way)

Thanks for the information, I figured that’s what I’d have to do… guess I’ll just have to make my mapper’s plan around the flaws this present (IE, cone going threw edges and such… ) but in the end it should work fine… THanks