Skip to content

Commit

Permalink
Silence platformheaders syncqt warning about qt_egl_p.h
Browse files Browse the repository at this point in the history
Drop the include for qt_egl_p.h. For Qt itself this should have no effect
since platform plugins including this header include EGL headers on their
own anyway.

Similarly, applications relying on such advanced functionality will likely
include EGL/OpenGL headers on their own - the point is anyhow to interoperate
with native, non-Qt EGL and GL code.

This avoids a lot of hassle since normally no EGL (or other winsys interface
API) bits are exposed in the public Qt APIs, and thus there are no public
headers provided to set up EGL headers in the same way Qt does internally.

Change-Id: Icdbc28811b753799abc06085bc8dff7f09bdbff9
Reviewed-by: Oswald Buddenhagen <[email protected]>
Reviewed-by: Lars Knoll <[email protected]>
  • Loading branch information
alpqr authored and jaheikk committed Dec 16, 2016
1 parent 21f283b commit 179045f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/platformheaders/nativecontexts/qeglnativecontext.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@
#define QEGLNATIVECONTEXT_H

#include <QtCore/QMetaType>
#include <QtEglSupport/private/qt_egl_p.h>

// Leave including egl.h with the appropriate defines to the client.

QT_BEGIN_NAMESPACE

Expand Down
6 changes: 6 additions & 0 deletions src/platformheaders/nativecontexts/qeglnativecontext.qdoc
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@
that an application using it is only guaranteed to work with the Qt version it was
developed against.

\note Due to being public while relying on otherwise hidden EGL types, this header
itself does not include \c{EGL/egl.h}. It is the application's responsibility to
include egl.h with any appropriate defines (for example, \c{MESA_EGL_NO_X11_HEADERS}
or other vendor-specific defines controlling the typedefs for EGL's native resources)
before this header.

\sa QOpenGLContext::setNativeHandle(), QOpenGLContext::nativeHandle()
*/

Expand Down

0 comments on commit 179045f

Please sign in to comment.