Original Post
I want to splat points such that a pixel would have increasing transparency if there is an object behind it closer than a threshold; so I basically need to read the current depth value and calculate alpha based on that. I'd like to know the most efficient way to do this, without FBOs if possible. (If it matters, depth test is on and depth mask off; the depth buffer has data in it already from drawing the scene beforehand. I'm using OpenGL 3.0 or 3.1 and avoid deprecated features.)