OpenGL-2.9.2.0: A binding for the OpenGL graphics system

Copyright | (c) Sven Panne 2006-2013
License | BSD3
Maintainer | Sven Panne <svenpanne@gmail.com>
Stability | stable
Portability | portable
Safe Haskell | None
Language | Haskell98

Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects

Contents

- Shader Objects
- Shader Queries

Description

This module corresponds to section 7.1 (Shader Objects) and 7.13 (Shader, Program, and Program Pipeline Queries) of the OpenGL 4.4 spec.

Synopsis

- shaderCompiler :: GettableStateVar Bool
- data ShaderType
  - = VertexShader
  - | TessControlShader
  - | TessEvaluationShader
  - | GeometryShader
  - | FragmentShader
  - | ComputeShader
- data Shader
- createShader :: ShaderType -> IO Shader
- shaderSourceBS :: Shader -> StateVar ByteString
- shaderSource :: Shader -> StateVar [String]
- compileShader :: Shader -> IO ()
- releaseShaderCompiler :: IO ()
- shaderType :: Shader -> GettableStateVar ShaderType
- shaderDeleteStatus :: Shader -> GettableStateVar Bool
- compileStatus :: Shader -> GettableStateVar Bool
- shaderInfoLog :: Shader -> GettableStateVar String
- data PrecisionType
- shaderPrecisionFormat :: ShaderType -> PrecisionType -> GettableStateVar ((GLint, GLint), GLint)

# Shader Objects

shaderCompiler :: GettableStateVar Bool

data ShaderType

Constructors

VertexShader |
TessControlShader |
TessEvaluationShader |
GeometryShader |
FragmentShader |
ComputeShader |

Instances

Eq ShaderType |
Ord ShaderType |
Show ShaderType |

data Shader

Instances

Eq Shader |
Ord Shader |
Show Shader |
ObjectName Shader |

createShader :: ShaderType -> IO Shader

shaderSourceBS :: Shader -> StateVar ByteString

UTF8 encoded.

shaderSource :: Shader -> StateVar [String]

Deprecated: Use `shaderSourceBS` instead.

compileShader :: Shader -> IO ()

releaseShaderCompiler :: IO ()

# Shader Queries

shaderType :: Shader -> GettableStateVar ShaderType

shaderDeleteStatus :: Shader -> GettableStateVar Bool

compileStatus :: Shader -> GettableStateVar Bool

shaderInfoLog :: Shader -> GettableStateVar String

data PrecisionType

Instances

Eq PrecisionType |
Ord PrecisionType |
Show PrecisionType |

shaderPrecisionFormat :: ShaderType -> PrecisionType -> GettableStateVar ((GLint, GLint), GLint)