EGL_MESA_screen_surface version 7

Jon Smirl jonsmirl at gmail.com
Fri Apr 29 11:37:49 PDT 2005


On 4/29/05, Brian Paul <brian.paul at tungstengraphics.com> wrote:
> Jon Smirl wrote:
> > const char *eglQueryModeStringMESA(EGLDisplay dpy, EGLModeMESA mode);
> >
> > Should this be changed to:
> > int eglQueryModeStringMESA(EGLDisplay dpy, EGLModeMESA mode, const char **name);
> > can return:
> > EGL_BAD_DISPLAY
> > EGL_BAD_MODE
> >
> > Should all functions be changed to var params with int error returns?
> 
> eglQueryString() returns const char *.  That's what I was following.

How do know if the call failed from a bad handle? NULL is a legal
return. This is a problem for the whole egl API.

Linux kernel has it right in that the only thing that is ever returned
from a function is an err status. All results are returned via var
parameters. Error returns are always less than zero so it is easy to
check. Zero means no error.

-- 
Jon Smirl
jonsmirl at gmail.com


More information about the dri-egl mailing list