bare bones opengl weston client sample

jegde jedge bubbah.t at gmail.com
Thu Sep 6 08:25:20 PDT 2012


Thank you so much, that did the trick!

Next Question :)
On the same code, on the same hardware...
I am getting the glut 60 fps limit when running my app using the glut
front end via
gnome and X.
I am getting ~24 fps using the simple-egl front end on top of wayland.
I also noticed the display using wayland likes to hover around 20 fps.

Is there some kind of throttle built into the frame rate for the
redraw callback?

Thank you.



On Wed, Sep 5, 2012 at 8:59 PM, Kristian Høgsberg <krh at bitplanet.net> wrote:
> On Wed, Sep 5, 2012 at 8:11 PM, jegde jedge <bubbah.t at gmail.com> wrote:
>> Thanks,
>> I tried that route. it is a gles2 not gles or opengl example; and that
>> will not work with the fixed function pipeline functions like
>> glPushMatrix et.al.
>
> Sure, it's a gles2 example, but it shows you how to get a minimal
> egl/gles2 client working under wayland.  I figured you'd want to
> replace the gles2 code with your own code anyway, and yes, it is just
> a matter of using EGL_OPENGL_API, removing the context attributes and
> linking to libGL.
>
> Kristian
>
>> I went with the gears example since it binds the OPENGL API but it
>> uses the window/toytoolkit/libshared stuff with cairo
>> and I don't have enough insight to what is needed and what isnt.
>>
>> Is it as simple as replacing line 131:
>> ret = eglBindAPI(EGL_OPENGL_ES_API);
>> with
>> EGL_OPENGL_API and linking against GL/libGL instead of GLES2/libGLES2 ?
>>
>> Thank you.
>> I'll try in the morning.
>>
>>
>> On Wed, Sep 5, 2012 at 4:51 PM, Kristian Høgsberg <krh at bitplanet.net> wrote:
>>> Right under your nose:
>>>
>>>   http://cgit.freedesktop.org/wayland/weston/tree/clients/simple-egl.c
>>>
>>> Kristian
>>>
>>> On Wed, Sep 5, 2012 at 4:29 PM, jegde jedge <bubbah.t at gmail.com> wrote:
>>>> Is there a bare bones open gl example that implemnts the bare minimum
>>>> needed to get a wayland surface and begin drawing using openGL?
>>>>
>>>>
>>>> I'm having a hell of a time porting my GLES1 application to run as a
>>>> wayland/weston client.
>>>>
>>>> This application has run on psp, iPone, glut, and android.
>>>>
>>>> Since It is gles I used the weston gears client application as a template.
>>>> Basically, I just inserted the hooks to call my applications draw
>>>> routines using the egl config already provided.
>>>>
>>>> I have tiled textured maps working, but I am having some hoaky results
>>>> with the first texture that it loaded.
>>>>
>>>> I would like to eliminate cairo pixman, libtoytoolkit, libshare.a as variables.
>>>> I just dont see an example to do openGL with only wl_xxx() calls.
>>>> _______________________________________________
>>>> wayland-devel mailing list
>>>> wayland-devel at lists.freedesktop.org
>>>> http://lists.freedesktop.org/mailman/listinfo/wayland-devel


More information about the wayland-devel mailing list