We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpOpenGL and 3D Libraries › open gl slower than p3d
Page Index Toggle Pages: 1
open gl slower than p3d (Read 697 times)
open gl slower than p3d
Jul 6th, 2009, 1:03am
 
Hi,
I'm developing a 3d interective video, I'd like to run it in opengl mode cos the render quality seems better than p3d, the problem is when the sketch runs in opengl mode the frame rate is about 5 fps, while when it runs in p3d mode the it's about 70-80. Is this normal? I tought opengl mode is faster than p3d.

I use a windows based notebook, with a geforce 8400 gs and 4gb ram.
I've already tried to setting up the graphic card but nothing happens.

thanks in advance
Re: open gl slower than p3d
Reply #1 - Jul 6th, 2009, 6:05am
 
This is something people are working on everyday; It'll be better in future releases.

My conclusions:
1) Look at how to use "Pro gl" in your sketches;
see the bottom of http://processing.org/reference/libraries/opengl/

2) Don't use loadpixels, updatepixels, set, get, or filter on the opengl frame; because it is horrendously slow to grab lots of pixels from the graphics cards into Java memory.

3) Don't use text() in opengl. This is something that WILL get better; People have written tools for using crazy-fast rendering text in opengl, but the default processing impl is much slower right now. Eventually, one of these will be standard, and text() will be fast again. I myself am probably going to put up here my GLSL-shader based Text renderer soon...

Sorry if that let you down; it seems like P3D is always the right choice. However, for advanced users, if you milk opengl, you can get 120+ framerates on very complex sketches! It's just really something that you have to work on foreeevvveerr....
Page Index Toggle Pages: 1