Blender Shader in OpenGL/GLSL
Yes you can if you use an addon, see  the BlenderArtists page here. That page doesn't have the correct download link but you can get it here.
From memory, this addon generates rather long and possibly unoptimised GLSL fragment code.