MCPcopy Create free account
hub / github.com/SFML/SFML / createContext

Method createContext

src/SFML/Window/EglContext.cpp:239–249  ·  view source on GitHub ↗

///////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

237
238////////////////////////////////////////////////////////////
239void EglContext::createContext(EglContext* shared)
240{
241 static constexpr std::array contextVersion = {EGL_CONTEXT_CLIENT_VERSION, 1, EGL_NONE};
242
243 const EGLContext toShared = shared ? shared->m_context : EGL_NO_CONTEXT;
244 if (toShared != EGL_NO_CONTEXT)
245 eglCheck(eglMakeCurrent(m_display, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT));
246
247 // Create EGL context
248 m_context = eglCheck(eglCreateContext(m_display, m_config, toShared, contextVersion.data()));
249}
250
251
252////////////////////////////////////////////////////////////

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected