SDL3pp
A slim C++ wrapper for SDL3
Loading...
Searching...
No Matches
Public Member Functions | List of all members
SDL::GLContext Struct Reference

Handle to an owned gLContext. More...

Inheritance diagram for SDL::GLContext:
Inheritance graph
[legend]

Public Member Functions

constexpr GLContext (SDL_GLContextState *resource={})
 Constructs from the underlying resource.
 
constexpr GLContext (const GLContext &other)=delete
 
constexpr GLContext (GLContext &&other)=default
 Move constructor.
 
 ~GLContext ()
 Frees up resource when object goes out of scope.
 
GLContextoperator= (GLContext other)
 Assignment operator.
 
constexpr GLContextRef (const GLContextRef &other)
 Copy constructor.
 
constexpr GLContextRef (GLContextRef &&other)
 Move constructor.
 
- Public Member Functions inherited from SDL::GLContextRef
constexpr GLContextRef (const GLContextRef &other)
 Copy constructor.
 
constexpr GLContextRef (GLContextRef &&other)
 Move constructor.
 
constexpr ~GLContextRef ()=default
 Default constructor.
 
GLContextRefoperator= (GLContextRef other)
 Assignment operator.
 
bool reset (SDL_GLContextState *newResource={})
 Delete an OpenGL context.
 
 GLContextBase (WindowBase &window)
 Create an OpenGL context for an OpenGL window, and make it current.
 
- Public Member Functions inherited from SDL::GLContextBase
 GLContextBase (WindowBase &window)
 Create an OpenGL context for an OpenGL window, and make it current.
 
void MakeCurrent (WindowBase &window)
 Set up an OpenGL context for rendering into an OpenGL window.
 
constexpr Resource (T resource={})
 Constructs the underlying resource.
 
constexpr Resource (std::nullptr_t)
 Equivalent to default ctor.
 
constexpr Resource (std::nullopt_t)
 Equivalent to default ctor.
 
 Resource (const Resource &other)=delete
 
 Resource (Resource &&other)=delete
 
- Public Member Functions inherited from SDL::Resource< SDL_GLContextState * >
constexpr Resource (SDL_GLContextState * resource={})
 Constructs the underlying resource.
 
constexpr Resource (std::nullptr_t)
 Equivalent to default ctor.
 
constexpr Resource (std::nullopt_t)
 Equivalent to default ctor.
 
 Resource (const Resource &other)=delete
 
 Resource (Resource &&other)=delete
 
Resourceoperator= (const Resource &other)=delete
 
Resourceoperator= (Resource &&other)=delete
 
constexpr operator bool () const
 True if contains a valid resource.
 
constexpr bool operator== (const Resource &other) const=default
 Comparison.
 
constexpr bool operator== (std::nullopt_t) const
 Comparison.
 
constexpr bool operator== (std::nullptr_t) const
 Comparison.
 
constexpr SDL_GLContextState * get () const
 Return contained resource;.
 
constexpr SDL_GLContextState * release (SDL_GLContextState * newResource={})
 Return contained resource and empties or replace value.
 
constexpr const SDL_GLContextState * operator-> () const
 Access to fields.
 
constexpr SDL_GLContextState * operator-> ()
 Access to fields.
 

Detailed Description

Category:
Resource
See also
GLContextBase
GLContextRef

The documentation for this struct was generated from the following file: