Skip to main content

shader Namespace

Shader program management. More...

Definition

namespace helios::rendering::shader { ... }

Classes Index

classShader

Abstract representation of a Shader program (e.g. composed of vertex/fragment shader). More...

classUniformValueMap

Maps uniform semantics to their values for shader parameter binding. More...

Typedefs Index

usingUniformValue = std::variant< helios::math::mat4f, helios::math::vec4f, float, int >

A type alias for the variant containing all supported uniform types. More...

Enumerations Index

enum classUniformSemantics { ... }

Enumeration of semantic identifiers for shader uniform variables. More...

Description

Shader program management.

This namespace provides shader program management, uniform semantics, and value mapping for shader parameter configuration in the rendering pipeline. Manages shader programs and their parameters, providing a type-safe interface for configuring shader uniforms and semantics.

Typedefs

UniformValue

using helios::rendering::shader::UniformValue = std::variant< helios::math::mat4f, helios::math::vec4f, float, int >

A type alias for the variant containing all supported uniform types.

See Also

[Str22, 100]

Definition at line 25 of file UniformValueMap.ixx.

25 using UniformValue = std::variant<

Enumerations

UniformSemantics

enum class helios::rendering::shader::UniformSemantics
strong

Enumeration of semantic identifiers for shader uniform variables.

Enumeration values
ModelMatrixRepresents the object-to-world transformation matrix of an object (= 0)
ProjectionMatrixRepresents the projection matrix
ViewMatrixRepresents the (camera) view space, transforming world space to view space
MaterialBaseColorRepresents the (material's) base color
MaterialRoughnessRepresents the (material's) roughness factor
TextTextureRepresents the texture sampler for text glyph rendering
TextColorRepresents the text color for glyph rendering
deltaTimeRepresents the time elapsed since the last frame
totalTimeRepresents the total time elapsed since measuring frame times
size_Number of entries in this enum

`UniformSemantics` provides strongly-typed identifiers for standard uniform variables passed to shaders. These semantics abstract the actual uniform names, allowing the rendering pipeline to work with meaningful identifiers.

## Categories

  • **Transform Matrices:** `ModelMatrix`, `ViewMatrix`, `ProjectionMatrix`
  • **Material Properties:** `MaterialBaseColor`, `MaterialRoughness`
  • **Text Rendering:** `TextTexture`, `TextColor`
  • **Time Values:** `deltaTime`, `totalTime`

## Usage

```cpp UniformValueMap uniforms; uniforms.set(UniformSemantics::ModelMatrix, modelMat); uniforms.set(UniformSemantics::MaterialBaseColor, vec4f{1.0f, 0.0f, 0.0f, 1.0f}); ```

See Also

UniformValueMap

Definition at line 36 of file UniformSemantics.ixx.

36 enum class UniformSemantics {
37
38 /**
39 * @brief Represents the object-to-world transformation matrix of an object.
40 */
42
43 /**
44 * @brief Represents the projection matrix.
45 */
47
48 /**
49 * @brief Represents the (camera) view space, transforming world space to view space.
50 */
52
53 /**
54 * @brief Represents the (material's) base color.
55 */
57
58 /**
59 * @brief Represents the (material's) roughness factor.
60 */
62
63 /**
64 * @brief Represents the texture sampler for text glyph rendering.
65 */
67
68 /**
69 * @brief Represents the text color for glyph rendering.
70 */
72
73 /**
74 * @brief Represents the time elapsed since the last frame.
75 */
77
78 /**
79 * @brief Represents the total time elapsed since measuring frame times.
80 */
82
83 /**
84 * @brief Number of entries in this enum.
85 */
87 };

The documentation for this namespace was generated from the following files:


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.