Copyright | (c) Sven Panne 2013 |
---|---|
License | BSD3 |
Maintainer | Sven Panne <svenpanne@gmail.com> |
Stability | stable |
Portability | portable |
Safe Haskell | None |
Language | Haskell2010 |
Utilities for shader handling, adapted from LoadShaders.cpp which is (c) The Red Book Authors.
Synopsis
Documentation
data ShaderSource Source #
The source of the shader source code.
ByteStringSource ByteString | The shader source code is directly given as a |
StringSource String | The shader source code is directly given as a |
FileSource FilePath | The shader source code is located in the file at the given |
Instances
Eq ShaderSource Source # | |
Defined in Graphics.RedViz.LoadShaders (==) :: ShaderSource -> ShaderSource -> Bool # (/=) :: ShaderSource -> ShaderSource -> Bool # | |
Ord ShaderSource Source # | |
Defined in Graphics.RedViz.LoadShaders compare :: ShaderSource -> ShaderSource -> Ordering # (<) :: ShaderSource -> ShaderSource -> Bool # (<=) :: ShaderSource -> ShaderSource -> Bool # (>) :: ShaderSource -> ShaderSource -> Bool # (>=) :: ShaderSource -> ShaderSource -> Bool # max :: ShaderSource -> ShaderSource -> ShaderSource # min :: ShaderSource -> ShaderSource -> ShaderSource # | |
Show ShaderSource Source # | |
Defined in Graphics.RedViz.LoadShaders showsPrec :: Int -> ShaderSource -> ShowS # show :: ShaderSource -> String # showList :: [ShaderSource] -> ShowS # |
data ShaderInfo Source #
A description of a shader: The type of the shader plus its source code.
Instances
Eq ShaderInfo Source # | |
Defined in Graphics.RedViz.LoadShaders (==) :: ShaderInfo -> ShaderInfo -> Bool # (/=) :: ShaderInfo -> ShaderInfo -> Bool # | |
Ord ShaderInfo Source # | |
Defined in Graphics.RedViz.LoadShaders compare :: ShaderInfo -> ShaderInfo -> Ordering # (<) :: ShaderInfo -> ShaderInfo -> Bool # (<=) :: ShaderInfo -> ShaderInfo -> Bool # (>) :: ShaderInfo -> ShaderInfo -> Bool # (>=) :: ShaderInfo -> ShaderInfo -> Bool # max :: ShaderInfo -> ShaderInfo -> ShaderInfo # min :: ShaderInfo -> ShaderInfo -> ShaderInfo # | |
Show ShaderInfo Source # | |
Defined in Graphics.RedViz.LoadShaders showsPrec :: Int -> ShaderInfo -> ShowS # show :: ShaderInfo -> String # showList :: [ShaderInfo] -> ShowS # |
loadShaders :: [ShaderInfo] -> IO Program Source #
Create a new program object from the given shaders, throwing an
IOException
if something goes wrong.