From 6534898cc69e22115cf158f71a1e0edd7f13877b Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Sun, 27 Nov 2011 20:42:22 +0100 Subject: directfb: Introduce EGL integration for DirectFB MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Introduce a new platform called 'directfbegl' that allows platform integration with EGL. Change the QDirectFbIntegration to make it more easy to hook up in the creation process, introduce an EGL integration with custom screen, window and EGL Platform Context. Vendors might need to add custom code to initialize EGL to be used with DirectFB, this can be done in QDirectFbScreenEGL::platformInit. Change-Id: I7bee277ede27c72437cd7c5977fa6ed85e65f538 Reviewed-by: Jørgen Lind --- src/plugins/platforms/directfb/qdirectfbwindow.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src/plugins/platforms/directfb/qdirectfbwindow.cpp') diff --git a/src/plugins/platforms/directfb/qdirectfbwindow.cpp b/src/plugins/platforms/directfb/qdirectfbwindow.cpp index 55fce90252..4648ed42f0 100644 --- a/src/plugins/platforms/directfb/qdirectfbwindow.cpp +++ b/src/plugins/platforms/directfb/qdirectfbwindow.cpp @@ -202,4 +202,15 @@ IDirectFBWindow *QDirectFbWindow::dfbWindow() const return m_dfbWindow.data(); } -QT_END_NAMESPACE +IDirectFBSurface *QDirectFbWindow::dfbSurface() +{ + if (!m_dfbSurface) { + DFBResult res = m_dfbWindow->GetSurface(m_dfbWindow.data(), m_dfbSurface.outPtr()); + if (res != DFB_OK) + DirectFBError(QDFB_PRETTY, res); + } + + return m_dfbSurface.data(); +} + +QT_END_NAMESPACE \ No newline at end of file -- cgit v1.2.3