Class FragmentShader¶
Defined in File Shader.hpp
Inheritance Relationships¶
Base Type¶
public Shader(Class Shader)
Class Documentation¶
-
class FragmentShader : public Shader¶
Represents a fragment shader, responsible for handling pixel-level processing in the rendering pipeline.
This class inherits from Shader and specifically loads, compiles, and manages a fragment shader from a given file path. Fragment shaders are executed for each pixel and are typically used to compute color and other attributes of each fragment.
Example usage:
FragmentShader fragmentShader("shaders/fragment.glsl");
See also
Public Functions
-
inline FragmentShader()¶
Constructs a FragmentShader object by loading and compiling a fragment shader from a file.
See also
- Parameters:
path – The file path to the fragment shader source code.
- Throws:
std::runtime_error – If the shader file cannot be opened or compilation fails.
-
inline FragmentShader()¶