Hello there.
I have ported one graphic application from Openframeworks 7.4 to 8.3 under Visual Studio. The code is just the same for both of them, nothing changes.
However fps performance have decreased from 250 fps in 7.4, to 170 fps in 8.3. I am running the app in the same PC. Of course, I am using the release file.
Mostly I am using ofLine and glColor3f calls for drawing.
Is it normal, have you seen the same behavior? Is there something that I can do?
The code for ofLine is exactly the same so not sure what might be the difference.
ofLine might be relatively slow if you are drawing lots of them since you are sending vertices 2 by 2 to the graphics card, in order to optimize it, i would use an ofVboMesh in OF_PRIMITIVE_LINES mode and only update the lines that change every frame. Then you will have 1 draw instead of lots of them which should make the application run much faster.
Thank you Arturo. Will try that ofVboMesh, however I would like to find the “difference”.
Anyway, I forgot to mention that I am also usinf ofxUI from rezaali, but I think the problem is not there because if I disable it the performance boost is similar in both versions.
Besides, the rendering of ofLine is not exactly the same, in the old OFv7.4 the lines were sharper. That is why I asked about if OpenGL has changed.
even if you disable antialiasing the context is now created with support for it so it might be that that’s affecting the performance. you can try to use a glut window which should have the same defaults as before to see if that’s the reason. i wouldn’t care much unless you hit the 60fps of the vsync and in any case there’s ways to optimize the code, like not using ofLine, which should give you much more performance raise than disabling antialiasing