maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Xlib+OpenGLES performace (https://talk.maemo.org/showthread.php?t=37356)

Miika 2009-12-16 17:13

Re: Xlib+OpenGLES performace
 
Yes, in Bounce we use _HILDON_NON_COMPOSITED_WINDOW. This should bring clear&swap performance up to at least 80 fps.

There is no need to resort to any trickery like sleeping or flushing to gain performance, they will only make things slower. The fewer you bother EGL/GLES the better.

Notice also that the rendering is asynchronous if you don't do anything that forces synchronization. This means that the application doesn't have to wait rendering to complete before starting the next one which allows CPU and GPU to work concurrently.

exoticorn 2009-12-16 22:52

Re: Xlib+OpenGLES performace
 
Thanks, Miika, it's good to hear that _HILDON_NON_COMPOSITED_WINDOW is all you need and that no further black magic is required.

I have now tried it and I'm very happy with the results, so all is now set for some game programming over the Xmas holiday.

Mr_Smiley 2009-12-20 02:33

Re: Xlib+OpenGLES performace
 
Hello,

Would you be able to post the new source code for your simple example? I've tried modifying your simplegl code with _HILDON_NON_COMPOSITED_WINDOW and I'm getting about 30 FPS. Shouldn't it be faster?

Thanks!

Mara 2009-12-20 02:57

Re: Xlib+OpenGLES performace
 
So my first on hand experience and gut feeling was correct whats' going on....

http://talk.maemo.org/showpost.php?p...&postcount=412

:D

Master of Gizmo 2009-12-20 16:00

Re: Xlib+OpenGLES performace
 
Quote:

Originally Posted by Mr_Smiley (Post 434995)
Hello,

Would you be able to post the new source code for your simple example? I've tried modifying your simplegl code with _HILDON_NON_COMPOSITED_WINDOW and I'm getting about 30 FPS. Shouldn't it be faster?

Thanks!

Agreed! We really should create a simple gles demo that's a) as fast as possible and b) as simple as possible. This might then become the starting point for real apps.

And please put this into extras-devel so people easily find it, can easily test it and most important are only one tiny "apt-get source" step away from the complete source code and all dependencies they need to compile it themselves.

exoticorn 2009-12-21 15:28

Re: Xlib+OpenGLES performace
 
Quote:

Originally Posted by Mr_Smiley (Post 434995)
Hello,

Would you be able to post the new source code for your simple example? I've tried modifying your simplegl code with _HILDON_NON_COMPOSITED_WINDOW and I'm getting about 30 FPS. Shouldn't it be faster?

Thanks!

You can find the updated code at http://exoticorn.de/simpleglv2.tgz. With this, I get about 42fps. (The framerate is very dependent on the size of the triangle on the screen, as the pixel shader with its sinus is killing the fillrate.)
Looking at the version of my code you posted at http://wiki.maemo.org/SimpleGL_Example, I see that you still have the 'usleep(1000*30)' in there, which I guess is the cause for your 30 fps. You also set _NET_WM_STATE_FULLSCREEN twice.

Good luck with your game.

Mr_Smiley 2009-12-21 23:44

Re: Xlib+OpenGLES performace
 
Quote:

Originally Posted by exoticorn (Post 436473)
I see that you still have the 'usleep(1000*30)' in there, which I guess is the cause for your 30 fps. You also set _NET_WM_STATE_FULLSCREEN twice.

Good luck with your game.

I totally missed that, thanks! I have added a link to the code on the wiki page (http://wiki.maemo.org/OpenGL_ES_Libraries). Hope this is OK.

Cheers.

endboss 2010-02-16 15:53

Re: Xlib+OpenGLES performace
 
Hi,

I'm currently learning openGL ES 2.0. I was studying that nice example. Thnks for that.

I was reorganizing and commenting it a bit in order to be more understandable. I would like to replace the wiki-example with my version, which you can find here:
http://www.agnld.uni-potsdam.de/~ber...gl-example.cpp

Is that ok?

Mr_Smiley 2010-02-17 05:24

Re: Xlib+OpenGLES performace
 
Quote:

Originally Posted by endboss (Post 529794)
Hi,

I'm currently learning openGL ES 2.0. I was studying that nice example. Thnks for that.

I was reorganizing and commenting it a bit in order to be more understandable. I would like to replace the wiki-example with my version, which you can find here:
http://www.agnld.uni-potsdam.de/~ber...gl-example.cpp

Is that ok?

That's fine with me. Good work commenting it :)

endboss 2010-02-17 12:08

Re: Xlib+OpenGLES performace
 
Ok, I updated the example program and added a screen shot.
I commented the code, cleaned it up (removing useless includes...) and corrected some small mistakes. I also changed a bit what it's doing, to be a little bit more attractive (watch the screen shot).


All times are GMT. The time now is 21:35.

vBulletin® Version 3.8.8