An instance of an EGL context.
const EGLContext & GetHandle() const
Get the underlying handle to the EGL context.
std::function< void(LifecycleEvent)> LifecycleListener
std::optional< UniqueID > AddLifecycleListener(const LifecycleListener &listener)
Add a listener that gets invoked when the context is made and cleared current from the thread....
bool MakeCurrent(const Surface &surface) const
Make the context current on the calling thread. It is the caller responsibility to ensure that any co...
bool ClearCurrent() const
Clear the thread association of this context.
bool IsValid() const
Determines if a valid context could be created. The context still needs to be made current on the thr...
bool RemoveLifecycleListener(UniqueID id)
Remove a previously added context listener.