OpenGL anti-aliasing without accumulation buffer

On an NVIDIA card, I can do a full smoothing of the scene using the accumulation buffer like this:

if(m_antialias)
{
    glClear(GL_ACCUM_BUFFER_BIT);
    for(int j = 0; j < antialiasing; j++)
    {
        accPerspective(m_camera.FieldOfView(), // Vertical field of view in degrees.
            aspectratio, // The aspect ratio.
            20., // Near clipping
            1000.,
            JITTER[antialiasing][j].X(), JITTER[antialiasing][j].Y(),
            0.0, 0.0, 1.0);

        m_camera.gluLookAt();

        ActualDraw();

        glAccum(GL_ACCUM, float(1.0 / antialiasing));

        glDrawBuffer(GL_FRONT);
        glAccum(GL_RETURN, float(antialiasing) / (j + 1));
        glDrawBuffer(GL_BACK);
    }

    glAccum(GL_RETURN, 1.0);
}

The memory buffer is not implemented on ATI cards, and everyone says that now you can do it in shader language. The problem with this, of course, is that GLSL is a pretty high barrier to entry for beginner OpenGL.

Can someone point me to something that will show me how to smooth out a whole scene like ATI cards do, and what a beginner can understand?

+5
source share
1 answer

, , ? multisampling; , , , .

. , WGL/GLX_ARB_multisample, , Windows . 1 *_SAMPLE_BUFFERS_ARB *_SAMPLES_ARB. , ( ). wglGetPixelFormatAttribfv glXGetConfig.

framebuffer, , : glEnable(GL_MULTISAMPLE) . .

, .

, GL 3.x ARB_framebuffer_object, , . renderbuffers , - ( - ).

- ( ). FBO ( glEnable(GL_MULTISAMPLE), ). , glBlitFramebuffer, - ( ).

, , , GLSL - OpenGL.

? . , , , , .

+14

All Articles