OpenGL-2.9.2.0: A binding for the OpenGL graphics system

Copyright(c) Sven Panne 2013
LicenseBSD3
MaintainerSven Panne <svenpanne@gmail.com>
Stabilitystable
Portabilityportable
Safe HaskellSafe-Inferred
LanguageHaskell98

Graphics.Rendering.OpenGL.GL.ObjectName

Description

This module corresponds to section 2.5 (Objects and the Object Model) of the OpenGL 4.4 specs.

Object names are explicitly handled identifiers for API objects, e.g. a texture object name in OpenGL or a buffer object name in OpenAL.

Synopsis

Documentation

class ObjectName a where Source

An ObjectName is an explicitly handled identifier for API objects, e.g. a texture object name in OpenGL or a buffer object name in OpenAL.

Minimal complete definition: isObjectName plus one of deleteObjectName or deleteObjectNames.

Minimal complete definition

isObjectName

Methods

isObjectName :: a -> IO Bool Source

Test if the given object name is currently in use, i.e. test if it has been generated, but not been deleted so far.

deleteObjectName :: a -> IO () Source

Make the given object name available again, declaring it as unused.

deleteObjectNames :: [a] -> IO () Source

Bulk version of deleteObjectName.

class ObjectName a => GeneratableObjectName a where Source

A GeneratableObjectName is an ObjectName which can be generated without creating an associated object at the same time, e.g. a buffer object name. Note that e.g. program object names do not fall into this category, because you can only create such a name together with a program object itself.

Minimal complete definition: One of genObjectName or genObjectNames.

Minimal complete definition

Nothing

Methods

genObjectName :: IO a Source

Generate a new unused object name. By generating the name, it becomes used.

genObjectNames :: Int -> IO [a] Source

Bulk version of genObjectName.