I'm trying to create 2d drop shadow filter using glsl.
what I'm doing now is first render my pixels into a texture, then apply a gaussian blur filter to it, then draw it to main frame buffer with tinted color, then draw the actual pixels on top.
The result is quite, nice, but the performance is quite low. so it's there a simpler way to create drop shadow using glsl, since the shadow doesn't need all the color components of the actual pixel, only the alpha value?
If the shapes are constant, you could precompute the drop shadow. If not, it is simply a matter of making your blur shader more efficient. There is a lot of information available about this online, such as Rideout's article (archived) or ivankuckir's article (archived).
The trick is to minimize the amount of Texture2D calls and to use built-in features like lineair interpolation.
Also refer to Fastest Gaussian blur implementation