Closed seken closed 9 years ago
I have heard that other have had similar problems, even on windows. RenderToTexture cameras normally use GL_FRONT, so I really don't see why you are getting these flicker issues. I think it may be a driver related issue.
Would you mind changing your proposed code to the following code and see if that helps your situation:
GLenum buffer = gc->getTraits()->doubleBuffer ? GL_BACK : GL_FRONT;
camera->setDrawBuffer(buffer);
camera->setReadBuffer(buffer);
I would prefer to have a solution which is not platform dependent.
Do you have the same problems with the osgdistortion
example? Since it uses a similar camera setup, i.e. using GL_FRONT as both read and draw buffer.
Hi everyone,
Same issue here on linux / nvidia, your code fixes the issue for me (both, platform dependant and not dependant). Although launching example with optirun (i'm using an nvidia optimus) also solved the issue.
@perezsolerj Can you try running the osgdistortion
example and see if the same error happens there?
osgdistortion seems OK. no flickering.
Ok, that is strange since the osgdistortion
example uses that same setup for the cameras.
May I ask what type of Nvidia cards it is? GeForce or Quadro?
I've just run the osg distortion demo and do not have the same issue. I am using a GTX Titan Black, your code change also stops the flickering, but I cannot test on platforms other than Linux.
Hi again,
using: GeForce GTX 660M
Well, this seems to be a common problem on Linux and there do not seem to be any side effects of the proposed change so I will merge this latest change.
On linux, with a Nvidia card, some wierd flickering occurs where ~1 in 30 frames are the first frame ever rendered, either a bug in osg or driver