void mainRender()
{
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
renderSTLs();
glEnable(GL_ALPHA_TEST);
glEnable(GL_BLEND);
if( bPointThroughSTL )
{
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
}
else
{ glBlendFun(GL_ONE_MINUS_DST_ALPHA, GL_DST_ALPHA);
}
renderPoints();
}
glBlendFunc(GL_ONE_MINUS_DST_ALPHA, GL_DST_ALPHA);
wont work because alpha value in destination buffer(FrameBuffer) will be always 1.0.
If you can prepare two textures with these STLs and points by rendering to texture method[
http://www.songho.ca/opengl/gl_fbo.html], a shader can blend these textures as you required.