| Copyright | (c) Sven Panne 2006-2018 |
|---|---|
| License | BSD3 |
| Maintainer | Sven Panne <svenpanne@gmail.com> |
| Stability | stable |
| Portability | portable |
| Safe Haskell | None |
| Language | Haskell2010 |
Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects
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
- 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)
- packUtf8 :: String -> ByteString
- unpackUtf8 :: ByteString -> String
Shader Objects
data ShaderType #
Constructors
| VertexShader | |
| TessControlShader | |
| TessEvaluationShader | |
| GeometryShader | |
| FragmentShader | |
| ComputeShader |
Instances
| Eq ShaderType # | |
| Ord ShaderType # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects Methods compare :: ShaderType -> ShaderType -> Ordering # (<) :: ShaderType -> ShaderType -> Bool # (<=) :: ShaderType -> ShaderType -> Bool # (>) :: ShaderType -> ShaderType -> Bool # (>=) :: ShaderType -> ShaderType -> Bool # max :: ShaderType -> ShaderType -> ShaderType # min :: ShaderType -> ShaderType -> ShaderType # | |
| Show ShaderType # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects Methods showsPrec :: Int -> ShaderType -> ShowS # show :: ShaderType -> String # showList :: [ShaderType] -> ShowS # | |
Instances
| Eq Shader # | |
| Ord Shader # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.Shader | |
| Show Shader # | |
| ObjectName Shader # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.Shader Methods isObjectName :: MonadIO m => Shader -> m Bool # deleteObjectName :: MonadIO m => Shader -> m () # deleteObjectNames :: MonadIO m => [Shader] -> m () # | |
| CanBeLabeled Shader # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.Shader | |
createShader :: ShaderType -> IO Shader #
shaderSourceBS :: Shader -> StateVar ByteString #
UTF8 encoded.
shaderSource :: Shader -> StateVar [String] #
Deprecated: Use a combination of shaderSourceBS and packUtf8 or unpackUtf8 instead.
compileShader :: Shader -> IO () #
releaseShaderCompiler :: IO () #
Shader Queries
compileStatus :: Shader -> GettableStateVar Bool #
data PrecisionType #
Instances
| Eq PrecisionType # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects Methods (==) :: PrecisionType -> PrecisionType -> Bool # (/=) :: PrecisionType -> PrecisionType -> Bool # | |
| Ord PrecisionType # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects Methods compare :: PrecisionType -> PrecisionType -> Ordering # (<) :: PrecisionType -> PrecisionType -> Bool # (<=) :: PrecisionType -> PrecisionType -> Bool # (>) :: PrecisionType -> PrecisionType -> Bool # (>=) :: PrecisionType -> PrecisionType -> Bool # max :: PrecisionType -> PrecisionType -> PrecisionType # min :: PrecisionType -> PrecisionType -> PrecisionType # | |
| Show PrecisionType # | |
Defined in Graphics.Rendering.OpenGL.GL.Shaders.ShaderObjects Methods showsPrec :: Int -> PrecisionType -> ShowS # show :: PrecisionType -> String # showList :: [PrecisionType] -> ShowS # | |
shaderPrecisionFormat :: ShaderType -> PrecisionType -> GettableStateVar ((GLint, GLint), GLint) #
Bytestring utilities
packUtf8 :: String -> ByteString #
unpackUtf8 :: ByteString -> String #