diff options
Diffstat (limited to 'examples/opengl/hellowindow/hellowindow.cpp')
-rw-r--r-- | examples/opengl/hellowindow/hellowindow.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/opengl/hellowindow/hellowindow.cpp b/examples/opengl/hellowindow/hellowindow.cpp index 9575d3e3c7..5a232e6a7b 100644 --- a/examples/opengl/hellowindow/hellowindow.cpp +++ b/examples/opengl/hellowindow/hellowindow.cpp @@ -12,7 +12,9 @@ Renderer::Renderer() m_format.setDepthBufferSize(16); m_format.setSamples(4); - m_context = new QGuiGLContext(m_format); + m_context = new QGuiGLContext; + m_context->setFormat(m_format); + m_context->create(); } QSurfaceFormat Renderer::format() const |