   Question about FBOs performance (using Cg and point_sprite)
  Hi,I asked a few days ago about OpenGL program using a framebuffer object and Cg in this forum.But, I can’t solved that problem.Problem is that when I use FBO in my code, if I use point sprite, heavy framerate drop.-----------------------------------------------------------------glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, fb);{glDrawArrays(GL_POINTS, first, num);}glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);.....glEnable(GL_TEXTURE_RECTANGLE_NV);glBindTexture(GL_TEXTURE_RECTANGLE_NV, tex);cgGLEnableProfile(cg_fragment_profile);cgGLBindProgram(cg_fragment_program);cg_framebuffer_texture = cgGetNamedParameter(cg_fragment_program, "texture");cgGLSetTextureParameter(cg_texture, tex);cgGLEnableTextureParameter(cg_texture);glMatrixMode(GL_PROJECTION);glPushMatrix();glLoadIdentity();glMatrixMode(GL_MODELVIEW);glPushMatrix();glLoadIdentity();glBegin(GL_QUADS);glTexCoord2f(gl_viewport[2], gl_viewport[3]);glVertex3f(1, 1, 0);glTexCoord2f(0, gl_viewport[3]);glVertex3f(-1, 1, 0);glTexCoord2f(0,0);glVertex3f(-1, -1, 0);glTexCoord2f(gl_viewport[2], 0);glVertex3f(1, -1, 0);glEnd();glMatrixMode(GL_PROJECTION);glPopMatrix();glMatrixMode(GL_MODELVIEW);glPopMatrix();-----------------------------------------------------------------This code is no problem.But,-----------------------------------------------------------------glTexEnvf(GL_POINT_SPRITE_NV, GL_COORD_REPLACE_NV, GL_DECAL);glEnable(GL_POINT_SPRITE_NV);.....glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, fb);{glDrawArrays(GL_POINTS, first, num);}glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);.....glEnable(GL_TEXTURE_RECTANGLE_NV);glBindTexture(GL_TEXTURE_RECTANGLE_NV, tex);cgGLEnableProfile(cg_fragment_profile);cgGLBindProgram(cg_fragment_program);cg_framebuffer_texture = cgGetNamedParameter(cg_fragment_program, "texture");cgGLSetTextureParameter(cg_texture, tex);cgGLEnableTextureParameter(cg_texture);glMatrixMode(GL_PROJECTION);glPushMatrix();glLoadIdentity();glMatrixMode(GL_MODELVIEW);glPushMatrix();glLoadIdentity();glBegin(GL_QUADS);glTexCoord2f(gl_viewport[2], gl_viewport[3]);glVertex3f(1, 1, 0);glTexCoord2f(0, gl_viewport[3]);glVertex3f(-1, 1, 0);glTexCoord2f(0,0);glVertex3f(-1, -1, 0);glTexCoord2f(gl_viewport[2], 0);glVertex3f(1, -1, 0);glEnd();glMatrixMode(GL_PROJECTION);glPopMatrix();glMatrixMode(GL_MODELVIEW);glPopMatrix();-----------------------------------------------------------------This code causes such a heavy framerate drop.What is problem?Thank you,Kim Hyeon-Joong - funky4d@gmail.com   