Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
- class OpenGLResource innertype a | a -> innertype where
Documentation
class OpenGLResource innertype a | a -> innertype where Source
All OpenGL resources implement this typeclass.
The resources have an inner type, usually a GLuint
but not always.
If you work with raw OpenGL resources, you may need to use touch
to make
sure the resource is not garbage collected prematurely.
getRaw :: MonadIO m => a -> m innertype Source
Returns the raw OpenGL type.
Guarantees that the resource has not been garbage collected at the point this function is invoked.
OpenGLResource GLsync Fence | |
OpenGLResource GLuint Buffer | |
OpenGLResource GLuint Texture | |
OpenGLResource GLuint Framebuffer | |
OpenGLResource GLuint Pipeline | Despite the Haskell name, |
OpenGLResource GLuint Shader | |
OpenGLResource GLuint VAO | |
OpenGLResource a (WrappedOpenGLResource a) | |
OpenGLResource GLuint (Query a) |