Types of shaders.
Load either the vertex or fragment shader from a file.
Load both the vertex and fragment shaders from files.
Load either the vertex or fragment shader from a source code in memory.
Load both the vertex and fragment shaders from source codes in memory.
Load either the vertex or fragment shader from a custom stream.
Load both the vertex and fragment shaders from custom streams.
Change a float parameter of the shader.
Change variable length vector parameter of the shader. The length of the set of floats must be between 1 and 4.
Change a 2-components vector parameter of the shader.
Change a 3-components vector parameter of the shader.
Change a color vector parameter of the shader.
Change a matrix parameter of the shader.
Change a texture parameter of the shader.
Change a texture parameter of the shader.
Change a float parameter of the shader.
Change a 2-components vector parameter of the shader.
Change a 3-components vector parameter of the shader.
Change a 4-components vector parameter of the shader.
Change a 2-components vector parameter of the shader.
Change a 3-components vector parameter of the shader.
Change a color vector parameter of the shader.
Change a matrix parameter of the shader.
Change a texture parameter of the shader.
Change a texture parameter of the shader.
Bind a shader for rendering.
Tell whether or not the system supports shaders.
Special type/value that can be passed to setParameter, and that represents the texture of the object being drawn.
Shader class (vertex and fragment).
Shaders are programs written using a specific language, executed directly by the graphics card and allowing one to apply real-time operations to the rendered entities.
There are two kinds of shaders: - Vertex shaders, that process vertices - Fragment (pixel) shaders, that process pixels
A DSFML Shader can be composed of either a vertex shader alone, a fragment shader alone, or both combined (see the variants of the load functions).
Shaders are written in GLSL, which is a C-like language dedicated to OpenGL shaders. You'll probably need to learn its basics before writing your own shaders for SFML.
Like any D/C/C++ program, a shader has its own variables that you can set from your D application. DSFML's Shader handles 5 different types of variables: - floats - vectors (2, 3, or 4 components) - colors - textures - transforms (matrices)