Closed Bug 889212 Opened 11 years ago Closed 5 years ago

Look for and use EGL on Linux

Categories

(Core :: Graphics, task)

ARM
Linux
task
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 788319

People

(Reporter: vlad, Assigned: vlad)

Details

Attachments

(1 file)

On a ARM Linux install, e.g. on a Samsung Chromebook, we should be looking for and trying EGL, not GLX (or at least in addition to GLX).  This is probably easiest to fix for WebGL first since it explicitly creates different kinds of GLContexts.
On something like the Samsung Chromebook, we have EGL, but we're still in X11.  This patch at least gets WebGL working with readback, which is helpful for debugging asm.js issues that involve WebGL.  More work is needed to get full layers going.
Assignee: nobody → vladimir
Attachment #770614 - Flags: review?(jgilbert)
Comment on attachment 770614 [details] [diff] [review]
build EGL on X11, and attempt to use it for WebGL

Review of attachment 770614 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good. Indents in that mess of #ifs would be nice, though.

::: gfx/gl/GLContextProvider.h
@@ +44,5 @@
>  #define GL_CONTEXT_PROVIDER_NAME GLContextProviderEGL
>  #include "GLContextProviderImpl.h"
>  #undef GL_CONTEXT_PROVIDER_NAME
> +// Don't make it the default on MOZ_X11
> +#ifndef MOZ_X11

This increasingly-deep nesting is getting hard to read, and could benefit from using indents, especially since this file doesn't really have actual code in it anyways.

::: gfx/gl/moz.build
@@ +15,4 @@
>  elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa':
>      gl_provider = 'CGL'
>  elif CONFIG['MOZ_WIDGET_GTK']:
> +    if CONFIG['MOZ_PLATFORM_MAEMO']:

Not sure why it was like that before, but it looks right now. Honestly, having any Maemo stuff anymore is a little iffy, as we have no way to test it.
Attachment #770614 - Flags: review?(jgilbert) → review+
> > +    if CONFIG['MOZ_PLATFORM_MAEMO']:
> 
> Not sure why it was like that before, but it looks right now. Honestly,
> having any Maemo stuff anymore is a little iffy, as we have no way to test
> it.

Not 100% sure, but I guess maemo flags are not used anymore by anyone..
There are another approach available for current upstream based on more generic embedding approach.. so I believe we should file bug and get rid of maemo defines in favor generic linux embedding approach which works on Maemo5/6/7...
(In reply to Oleg Romashin (:romaxa) from comment #3)
> > > +    if CONFIG['MOZ_PLATFORM_MAEMO']:
> > 
> > Not sure why it was like that before, but it looks right now. Honestly,
> > having any Maemo stuff anymore is a little iffy, as we have no way to test
> > it.
> 
> Not 100% sure, but I guess maemo flags are not used anymore by anyone..
> There are another approach available for current upstream based on more
> generic embedding approach.. so I believe we should file bug and get rid of
> maemo defines in favor generic linux embedding approach which works on
> Maemo5/6/7...

That would be excellent. Can you file this and CC me?
Status: NEW → RESOLVED
Type: defect → task
Closed: 5 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: