qeglfscontext.cpp

Absolute File Name:/home/qt/qt5_coco/qt5/qtbase/src/plugins/platforms/eglfs/qeglfscontext.cpp
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5QEglFSContext::QEglFSContext(const QSurfaceFormat &format, QPlatformOpenGLContext *share, EGLDisplay display,-
6 EGLConfig *config, const QVariant &nativeHandle)-
7 : QEGLPlatformContext(format, share, display, config, nativeHandle,-
8 qt_egl_device_integration()->supportsSurfacelessContexts() ? Flags(0) : QEGLPlatformContext::NoSurfaceless),-
9 m_tempWindow(0)-
10{-
11}
never executed: end of block
0
12-
13EGLSurface QEglFSContext::eglSurfaceForPlatformSurface(QPlatformSurface *surface)-
14{-
15 if (surface->surface()->surfaceClass() == QSurface::Window
surface->surfa...urface::WindowDescription
TRUEnever evaluated
FALSEnever evaluated
)
0
16 return
never executed: return static_cast<QEglFSWindow *>(surface)->surface();
static_cast<QEglFSWindow *>(surface)->surface();
never executed: return static_cast<QEglFSWindow *>(surface)->surface();
0
17 else-
18 return
never executed: return static_cast<QEGLPbuffer *>(surface)->pbuffer();
static_cast<QEGLPbuffer *>(surface)->pbuffer();
never executed: return static_cast<QEGLPbuffer *>(surface)->pbuffer();
0
19}-
20-
21EGLSurface QEglFSContext::createTemporaryOffscreenSurface()-
22{-
23 if (qt_egl_device_integration()->supportsPBuffers()
qt_egl_device_...ortsPBuffers()Description
TRUEnever evaluated
FALSEnever evaluated
)
0
24 return
never executed: return QEGLPlatformContext::createTemporaryOffscreenSurface();
QEGLPlatformContext::createTemporaryOffscreenSurface();
never executed: return QEGLPlatformContext::createTemporaryOffscreenSurface();
0
25-
26 if (!m_tempWindow
!m_tempWindowDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
27 m_tempWindow = qt_egl_device_integration()->createNativeOffscreenWindow(format());-
28 if (!m_tempWindow
!m_tempWindowDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
29 QMessageLogger(__FILE__, 76, __PRETTY_FUNCTION__).warning("QEglFSContext: Failed to create temporary native window");-
30 return
never executed: return ((EGLSurface)0);
((EGLSurface)0);
never executed: return ((EGLSurface)0);
0
31 }-
32 }
never executed: end of block
0
33 EGLConfig config = q_configFromGLFormat(eglDisplay(), format());-
34 return
never executed: return eglCreateWindowSurface(eglDisplay(), config, m_tempWindow, 0);
eglCreateWindowSurface(eglDisplay(), config, m_tempWindow, 0);
never executed: return eglCreateWindowSurface(eglDisplay(), config, m_tempWindow, 0);
0
35}-
36-
37void QEglFSContext::destroyTemporaryOffscreenSurface(EGLSurface surface)-
38{-
39 if (qt_egl_device_integration()->supportsPBuffers()
qt_egl_device_...ortsPBuffers()Description
TRUEnever evaluated
FALSEnever evaluated
) {
0
40 QEGLPlatformContext::destroyTemporaryOffscreenSurface(surface);-
41 }
never executed: end of block
else {
0
42 eglDestroySurface(eglDisplay(), surface);-
43 qt_egl_device_integration()->destroyNativeWindow(m_tempWindow);-
44 m_tempWindow = 0;-
45 }
never executed: end of block
0
46}-
47-
48void QEglFSContext::runGLChecks()-
49{-
50-
51-
52 const char *renderer = reinterpret_cast<const char *>(glGetString(0x1F01));-
53-
54 if (renderer
rendererDescription
TRUEnever evaluated
FALSEnever evaluated
&& strstr(renderer, "llvmpipe")
strstr(renderer, "llvmpipe")Description
TRUEnever evaluated
FALSEnever evaluated
)
0
55 QMessageLogger(__FILE__, 102, __PRETTY_FUNCTION__).warning("Running on a software rasterizer (LLVMpipe), expect limited performance.");
never executed: QMessageLogger(__FILE__, 102, __PRETTY_FUNCTION__).warning("Running on a software rasterizer (LLVMpipe), expect limited performance.");
0
56}
never executed: end of block
0
57-
58void QEglFSContext::swapBuffers(QPlatformSurface *surface)-
59{-
60-
61 if (surface->surface()->surfaceClass() == QSurface::Window
surface->surfa...urface::WindowDescription
TRUEnever evaluated
FALSEnever evaluated
) {
0
62 QPlatformWindow *window = static_cast<QPlatformWindow *>(surface);-
63 if (QEglFSCursor *cursor = qobject_cast<QEglFSCursor *>(window->screen()->cursor())
QEglFSCursor *...n()->cursor())Description
TRUEnever evaluated
FALSEnever evaluated
)
0
64 cursor->paintOnScreen();
never executed: cursor->paintOnScreen();
0
65 }
never executed: end of block
0
66-
67 qt_egl_device_integration()->waitForVSync(surface);-
68 QEGLPlatformContext::swapBuffers(surface);-
69 qt_egl_device_integration()->presentBuffer(surface);-
70}
never executed: end of block
0
71-
72-
Switch to Source codePreprocessed file

Generated by Squish Coco Non-Commercial 4.3.0-BETA-master-30-08-2018-4cb69e9